|
@@ -71,9 +71,9 @@ public class TStaffmgrRecordController extends BaseController {
|
|
|
@Log(title = "人员操作记录", businessType = BusinessType.INSERT)
|
|
|
@PostMapping
|
|
|
public AjaxResult add(@RequestBody TStaffmgrRecord tStaffmgrRecord) {
|
|
|
+ TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
+ tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
if ("调班".equals(tStaffmgrRecord.getType())) {
|
|
|
- TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
- tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
tStaffmgr.setTeam(tStaffmgrRecord.getChange());
|
|
|
TStaffmgr monitor = new TStaffmgr();
|
|
|
monitor.setActualpost("12");
|
|
@@ -86,12 +86,15 @@ public class TStaffmgrRecordController extends BaseController {
|
|
|
tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
}else if ("调岗".equals(tStaffmgrRecord.getType())) {
|
|
|
- TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
- tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
tStaffmgr.setActualpost(tStaffmgrRecord.getChange());
|
|
|
tStaffmgr.setUpdatedate(new Date());
|
|
|
tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
+ }else if ("离岗".equals(tStaffmgrRecord.getType())) {
|
|
|
+ tStaffmgr.setLeftDate(tStaffmgrRecord.getActionDate());
|
|
|
+ tStaffmgr.setUpdatedate(new Date());
|
|
|
+ tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
+ tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
}
|
|
|
return toAjax(tStaffmgrRecordService.insertTStaffmgrRecord(tStaffmgrRecord));
|
|
|
}
|
|
@@ -103,20 +106,23 @@ public class TStaffmgrRecordController extends BaseController {
|
|
|
@Log(title = "人员操作记录", businessType = BusinessType.UPDATE)
|
|
|
@PutMapping
|
|
|
public AjaxResult edit(@RequestBody TStaffmgrRecord tStaffmgrRecord) {
|
|
|
+ TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
+ tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
if ("调班".equals(tStaffmgrRecord.getType())) {
|
|
|
- TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
- tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
tStaffmgr.setTeam(tStaffmgrRecord.getChange());
|
|
|
tStaffmgr.setUpdatedate(new Date());
|
|
|
tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
}else if ("调岗".equals(tStaffmgrRecord.getType())) {
|
|
|
- TStaffmgr tStaffmgr = new TStaffmgr();
|
|
|
- tStaffmgr.setId(tStaffmgrRecord.getStaffmgrId());
|
|
|
tStaffmgr.setActualpost(tStaffmgrRecord.getChange());
|
|
|
tStaffmgr.setUpdatedate(new Date());
|
|
|
tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
+ }else if ("离岗".equals(tStaffmgrRecord.getType())) {
|
|
|
+ tStaffmgr.setLeftDate(tStaffmgrRecord.getActionDate());
|
|
|
+ tStaffmgr.setUpdatedate(new Date());
|
|
|
+ tStaffmgr.setUpdaterCode(getUserId().toString());
|
|
|
+ tStaffmgrService.updateTStaffmgr(tStaffmgr);
|
|
|
}
|
|
|
return toAjax(tStaffmgrRecordService.updateTStaffmgrRecord(tStaffmgrRecord));
|
|
|
}
|