|
@@ -285,6 +285,7 @@ public class TStaffmgrController extends BaseController
|
|
|
@PostMapping
|
|
|
public AjaxResult add(@RequestBody TStaffmgr tStaffmgr)
|
|
|
{
|
|
|
+ int insertResult = tStaffmgrService.insertTStaffmgr(tStaffmgr);
|
|
|
tStaffmgr.setCreaterCode(getUserId().toString());
|
|
|
if (tStaffmgr.getUnit().equals("10") || tStaffmgr.getUnit().equals("18")) {
|
|
|
TTrainingrecords tTrainingrecords = new TTrainingrecords();
|
|
@@ -303,9 +304,10 @@ public class TStaffmgrController extends BaseController
|
|
|
tWorklicense.setName(tStaffmgr.getName());
|
|
|
tWorklicense.setEmployeeid(tStaffmgr.getStaffid());
|
|
|
tWorklicense.setPost(tStaffmgr.getActualpost());
|
|
|
+ tWorklicense.setDeptId(tStaffmgr.getDeptId());
|
|
|
tWorklicenseService.insertTWorklicense(tWorklicense);
|
|
|
}
|
|
|
- return toAjax(tStaffmgrService.insertTStaffmgr(tStaffmgr));
|
|
|
+ return toAjax(insertResult);
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -338,6 +340,7 @@ public class TStaffmgrController extends BaseController
|
|
|
tWorklicense.setName(tStaffmgr.getName());
|
|
|
tWorklicense.setEmployeeid(tStaffmgr.getStaffid());
|
|
|
tWorklicense.setPost(tStaffmgr.getActualpost());
|
|
|
+ tWorklicense.setDeptId(tStaffmgr.getDeptId());
|
|
|
tWorklicenseService.updateTWorklicense(tWorklicense);
|
|
|
}
|
|
|
return toAjax(tStaffmgrService.updateTStaffmgr(tStaffmgr));
|