From ac48e676dfae453ce16cfc4faeb8b82280d421df Mon Sep 17 00:00:00 2001 From: ivanszabo Date: Tue, 8 Apr 2025 15:14:19 +0200 Subject: [PATCH] =?UTF-8?q?Na=20most=20j=C3=B3=20a=20blokkol=C3=B3s=20cucc?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/WorkFlowCheck.BL/Services/CheckListService.cs | 8 ++++++-- src/WorkFlowCheck.Web/wwwroot/js/site.js | 9 +++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/WorkFlowCheck.BL/Services/CheckListService.cs b/src/WorkFlowCheck.BL/Services/CheckListService.cs index 1ec22f3..96145ce 100644 --- a/src/WorkFlowCheck.BL/Services/CheckListService.cs +++ b/src/WorkFlowCheck.BL/Services/CheckListService.cs @@ -302,7 +302,7 @@ namespace WorkFlowCheck.BL.Services try { var checkListHeader = await _dbContext.CheckListHeaders - .Where(w => w.Id == id && w.CheckStatus == CheckStatus.Sent) + .Where(w => w.Id == id && w.CheckStatus == CheckStatus.InProgress) .FirstOrDefaultAsync(); if (checkListHeader != null && checkListHeader.CheckStatus == CheckStatus.InProgress) @@ -313,6 +313,10 @@ namespace WorkFlowCheck.BL.Services Log.Warning($"Ellenőrzési lap blokkolva: Ellenőrzés:{id}, Felhasználó:{userid}"); await _dbContext.SaveChangesAsync(); + + + + retVal = true; } } @@ -331,7 +335,7 @@ namespace WorkFlowCheck.BL.Services try { var checkListHeader = await _dbContext.CheckListHeaders - .Where(w => w.Id == id && w.CheckStatus == CheckStatus.Sent) + .Where(w => w.Id == id && w.CheckStatus == CheckStatus.Blocked) .FirstOrDefaultAsync(); if (checkListHeader != null && checkListHeader.CheckStatus == CheckStatus.Blocked) diff --git a/src/WorkFlowCheck.Web/wwwroot/js/site.js b/src/WorkFlowCheck.Web/wwwroot/js/site.js index ed40f12..d99e8ec 100644 --- a/src/WorkFlowCheck.Web/wwwroot/js/site.js +++ b/src/WorkFlowCheck.Web/wwwroot/js/site.js @@ -127,6 +127,15 @@ function renderActionButtonsforCheckListHeader(data, rowId) { `; } + if (data === 1) { + return ` + + `; + } if (data === 5) { return `