diff --git a/src/controllers/SalaryController.ts b/src/controllers/SalaryController.ts index 1891293..5571db9 100644 --- a/src/controllers/SalaryController.ts +++ b/src/controllers/SalaryController.ts @@ -36,6 +36,17 @@ export class SalaryController extends Controller { private poTypeRepository = AppDataSource.getRepository(PosType); private posLevelRepository = AppDataSource.getRepository(PosLevel); + /** + * API ล้างข้อมูล + * + * @summary ล้างข้อมูล + * + */ + @Get("clear-db") + async ClearDb() { + return new HttpSuccess(); + } + /** * API สร้างผังเงินเดือน * diff --git a/src/middlewares/logs.ts b/src/middlewares/logs.ts index b1d83ba..f5efaa5 100644 --- a/src/middlewares/logs.ts +++ b/src/middlewares/logs.ts @@ -60,7 +60,7 @@ async function logMiddleware(req: Request, res: Response, next: NextFunction) { logType: res.statusCode >= 500 ? "error" : res.statusCode >= 400 ? "warning" : "info", ip: req.ip, rootId: rootId?.orgRootId ?? null, - systemName: "evaluation", + systemName: "salary", startTimeStamp: timestamp, endTimeStamp: new Date().toISOString(), processTime: performance.now() - start,