Jóváhagyási BUGFIX

This commit is contained in:
2025-06-10 12:14:52 +02:00
parent d775ae82a0
commit 5e94586a75
3 changed files with 17 additions and 6 deletions
@@ -1,6 +1,6 @@
{ {
"ConnectionStrings": { "ConnectionStrings": {
"DefaultConnection": "Data Source=WS2016DC\\SQLEXPRESS;Initial Catalog=WFC;Integrated Security=True;Connect Timeout=30;Encrypt=False;Trust Server Certificate=False;Application Intent=ReadWrite;Multi Subnet Failover=False" "DefaultConnection": "Data Source=NSINB-37\\WFC;Initial Catalog=WFC;Integrated Security=True;Connect Timeout=30;Encrypt=False;Trust Server Certificate=False;Application Intent=ReadWrite;Multi Subnet Failover=False"
}, },
"Logging": { "Logging": {
"LogLevel": { "LogLevel": {
@@ -218,6 +218,11 @@ namespace WorkFlowCheck.BL.Services
try try
{ {
var user = await _dbContext.Users
.Where(w => w.Id == userid)
.FirstOrDefaultAsync();
if (user == null) return false;
var checkListHeader = await _dbContext.CheckListHeaders var checkListHeader = await _dbContext.CheckListHeaders
.Where(w => w.Id == id && w.CheckStatus == CheckStatus.Sent) .Where(w => w.Id == id && w.CheckStatus == CheckStatus.Sent)
.FirstOrDefaultAsync(); .FirstOrDefaultAsync();
@@ -230,7 +235,7 @@ namespace WorkFlowCheck.BL.Services
checkListHeader.DateExecution = DateTime.Now; checkListHeader.DateExecution = DateTime.Now;
Log.ForContext("TAG", "BusinessFlow").Warning($"Ellenőrzési lap státuszváltozása, jóváhagyás: Ellenőrzés:{checkListHeader.DocumentNumber}, Felhasználó: {checkListHeader.AcceptUser.LastName} {checkListHeader.AcceptUser.FirstName}"); Log.ForContext("TAG", "BusinessFlow").Warning($"Ellenőrzési lap státuszváltozása, jóváhagyás: Ellenőrzés:{checkListHeader.DocumentNumber}, Felhasználó: {user.LastName} {user.FirstName}");
await _dbContext.SaveChangesAsync(); await _dbContext.SaveChangesAsync();
var pdf = await CreateCheckListHeaderPDFAsync(id); var pdf = await CreateCheckListHeaderPDFAsync(id);
+6
View File
@@ -15,6 +15,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorkFlowCheck.BL", "WorkFlo
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorkFlowCheck.Common", "WorkFlowCheck.Common\WorkFlowCheck.Common.csproj", "{CBB000AD-E96B-4A4E-A037-4650EFECBB11}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorkFlowCheck.Common", "WorkFlowCheck.Common\WorkFlowCheck.Common.csproj", "{CBB000AD-E96B-4A4E-A037-4650EFECBB11}"
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WorkFlowCheck.Web", "WorkFlowCheck.Web\WorkFlowCheck.Web.csproj", "{F4D05A26-A90F-6E65-8C1F-24D98D6F3AA0}"
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU Debug|Any CPU = Debug|Any CPU
@@ -47,6 +49,10 @@ Global
{CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Debug|Any CPU.Build.0 = Debug|Any CPU {CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Release|Any CPU.ActiveCfg = Release|Any CPU {CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Release|Any CPU.Build.0 = Release|Any CPU {CBB000AD-E96B-4A4E-A037-4650EFECBB11}.Release|Any CPU.Build.0 = Release|Any CPU
{F4D05A26-A90F-6E65-8C1F-24D98D6F3AA0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F4D05A26-A90F-6E65-8C1F-24D98D6F3AA0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F4D05A26-A90F-6E65-8C1F-24D98D6F3AA0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F4D05A26-A90F-6E65-8C1F-24D98D6F3AA0}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE