เก็บประวัติ isupload

This commit is contained in:
mamoss 2025-06-12 16:47:33 +07:00
parent d249e94cb5
commit 7eea4cd33c
24 changed files with 146 additions and 135 deletions

View file

@ -163,12 +163,12 @@ export class ProfileAssistanceEmployeeTempController extends Controller {
history.createdAt = new Date();
history.lastUpdatedAt = new Date();
await Promise.all([
this.profileAssistanceRepo.save(record, { data: req }),
setLogDataDiff(req, { before, after: record }),
this.profileAssistanceHistoryRepo.save(history, { data: req }),
// setLogDataDiff(req, { before: before_null, after: history }),
]);
this.profileAssistanceRepo.save(record, { data: req });
setLogDataDiff(req, { before, after: record });
if (!(Object.keys(body).length === 1 && body.isUpload)) {
this.profileAssistanceHistoryRepo.save(history, { data: req });
// setLogDataDiff(req, { before, after: history });
}
return new HttpSuccess();
}