บันทึกเวลาแก้ไขข้อมูลอุทธร

This commit is contained in:
Kittapath 2023-12-13 10:58:17 +07:00
parent 2ec737d601
commit be10c7ef95

View file

@ -278,6 +278,9 @@ namespace BMA.EHR.DisciplineComplaint_Appeal.Service.Controllers
} }
} }
} }
data.LastUpdateFullName = FullName ?? "System Administrator";
data.LastUpdateUserId = UserId ?? "";
data.LastUpdatedAt = DateTime.Now;
await _context.SaveChangesAsync(); await _context.SaveChangesAsync();
return Success(); return Success();
} }
@ -309,6 +312,9 @@ namespace BMA.EHR.DisciplineComplaint_Appeal.Service.Controllers
if (dataDocComplaint == null) if (dataDocComplaint == null)
{ {
await _documentService.DeleteFileAsync(docId); await _documentService.DeleteFileAsync(docId);
data.LastUpdateFullName = FullName ?? "System Administrator";
data.LastUpdateUserId = UserId ?? "";
data.LastUpdatedAt = DateTime.Now;
await _context.SaveChangesAsync(); await _context.SaveChangesAsync();
} }
return Success(); return Success();
@ -410,7 +416,7 @@ namespace BMA.EHR.DisciplineComplaint_Appeal.Service.Controllers
data.LastUpdateUserId = UserId ?? ""; data.LastUpdateUserId = UserId ?? "";
data.LastUpdatedAt = DateTime.Now; data.LastUpdatedAt = DateTime.Now;
await _context.SaveChangesAsync(); await _context.SaveChangesAsync();
return Success(data); return Success();
} }
} }
} }