This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-08-27 13:36:10 +07:00
parent 09bd6bc356
commit 2a117223f7
2 changed files with 8 additions and 10 deletions

View file

@ -713,7 +713,7 @@ export class SalaryPeriodEmployeeController extends Controller {
throw new HttpError(HttpStatusCode.NOT_FOUND, "ประเภทการเลื่อนขึ้นเงินเดือนไม่ถูกต้อง");
}
const before = null;
const before = structuredClone(salaryProfile);
await this.salaryProfileRepository.save(salaryProfile, { data: req });
setLogDataDiff(req, { before, after: salaryProfile });
@ -1334,7 +1334,7 @@ export class SalaryPeriodEmployeeController extends Controller {
} else {
throw new HttpError(HttpStatusCode.NOT_FOUND, "ประเภทการเลื่อนขึ้นเงินเดือนไม่ถูกต้อง");
}
const before = null;
const before = structuredClone(salaryProfile);
await this.salaryProfileRepository.save(salaryProfile, { data: req });
setLogDataDiff(req, { before, after: salaryProfile });