From 7c4fb2ba6509a609855a6572125a680ceb27b339 Mon Sep 17 00:00:00 2001 From: chenlu <1320612696@qq.com> Date: 星期四, 18 七月 2024 16:47:55 +0800 Subject: [PATCH] 报工返工补片添加日志 --- north-glass-erp/src/main/java/com/example/erp/service/pp/ReplenishService.java | 15 ++++++++++++++- 1 files changed, 14 insertions(+), 1 deletions(-) diff --git a/north-glass-erp/src/main/java/com/example/erp/service/pp/ReplenishService.java b/north-glass-erp/src/main/java/com/example/erp/service/pp/ReplenishService.java index 13c704b..b166f4f 100644 --- a/north-glass-erp/src/main/java/com/example/erp/service/pp/ReplenishService.java +++ b/north-glass-erp/src/main/java/com/example/erp/service/pp/ReplenishService.java @@ -7,10 +7,12 @@ import com.example.erp.entity.pp.FlowCard; import com.example.erp.entity.pp.PatchLog; import com.example.erp.entity.pp.ReportingWork; +import com.example.erp.entity.userInfo.Log; import com.example.erp.entity.userInfo.SysError; import com.example.erp.mapper.pp.FlowCardMapper; import com.example.erp.mapper.pp.PatchLogMapper; import com.example.erp.mapper.pp.ReportingWorkMapper; +import com.example.erp.service.userInfo.LogService; import com.example.erp.service.userInfo.SysErrorService; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -37,11 +39,14 @@ final FlowCardMapper flowCardMapper; - public ReplenishService(PatchLogMapper patchMapper, SysErrorService sysErrorService, ReportingWorkMapper reportingWorkMapper,FlowCardMapper flowCardMapper) { + final LogService logService; + + public ReplenishService(PatchLogMapper patchMapper, SysErrorService sysErrorService, ReportingWorkMapper reportingWorkMapper,FlowCardMapper flowCardMapper,LogService logService) { this.patchMapper = patchMapper; this.sysErrorService = sysErrorService; this.reportingWorkMapper = reportingWorkMapper; this.flowCardMapper = flowCardMapper; + this.logService = logService; } @@ -109,6 +114,14 @@ } + //淇濆瓨鏃ュ織 + Log log = new Log(); + log.setContent(object.toString()); + log.setFunction("saveReplenish琛ョ墖鏂板"); + log.setOperatorId((String) object.get("userId")); + log.setOperator((String) object.get("userName")); + logService.saveLog(log); + return saveState; } -- Gitblit v1.8.0