在任务表中对领料和退料创建人进行统一存userId,对以前的逻辑进行修改

This commit is contained in:
15856 2024-06-14 13:48:18 +08:00
parent deb1d7ad61
commit fe70c92210
5 changed files with 15 additions and 7 deletions

View File

@ -1093,6 +1093,8 @@ public class TmTaskServiceImpl implements TmTaskService {
@Override @Override
public int insertSelective(TmTask record) { public int insertSelective(TmTask record) {
//2024.06.14统一创建人存userId
record.setCreateBy(record.getUserId());
return tmTaskMapper.insertSelective(record); return tmTaskMapper.insertSelective(record);
} }

View File

@ -535,7 +535,7 @@
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName, tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,
bpl.lot_id as proId,bpl.lot_name as proName, bpl.lot_id as proId,bpl.lot_name as proName,
bui.unit_id as unitId,bui.unit_name as unitName, bui.unit_id as unitId,bui.unit_name as unitName,
lai.lease_person as leasePerson, lai.phone as leasePhone,lai.lease_type as leaseType, lai.estimate_lease_time as estimateLeaseTime,tt.create_by as applyFor,d.`name` as taskName, lai.lease_person as leasePerson, lai.phone as leasePhone,lai.lease_type as leaseType, lai.estimate_lease_time as estimateLeaseTime,su.user_name as applyFor,d.`name` as taskName,
case when d.id = '31' then lai.company_audit_remark case when d.id = '31' then lai.company_audit_remark
when d.id = '32' then lai.dept_audit_remark when d.id = '32' then lai.dept_audit_remark
when d.id = '33' then lai.direct_audit_remark when d.id = '33' then lai.direct_audit_remark
@ -548,7 +548,7 @@
tt.create_time as createTimes, tt.update_time as updateTimes tt.create_time as createTimes, tt.update_time as updateTimes
FROM FROM
tm_task tt tm_task tt
LEFT JOIN sys_user su ON tt.create_by = su.user_name LEFT JOIN sys_user su ON tt.create_by = su.user_id
LEFT JOIN sys_dept sd ON su.dept_id = sd.dept_id LEFT JOIN sys_dept sd ON su.dept_id = sd.dept_id
LEFT JOIN tm_task_agreement tta ON tt.task_id = tta.task_id LEFT JOIN tm_task_agreement tta ON tt.task_id = tta.task_id
LEFT JOIN bm_agreement_info bai ON bai.agreement_id = tta.agreement_id LEFT JOIN bm_agreement_info bai ON bai.agreement_id = tta.agreement_id
@ -943,7 +943,7 @@
tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,su.nick_name as nickName,su.user_id as userId, tt.*, su.phonenumber AS phoneNumber, sd.dept_name as deptName,su.nick_name as nickName,su.user_id as userId,
bpl.lot_id as proId,bpl.lot_name as proName, bpl.lot_id as proId,bpl.lot_name as proName,
bui.unit_id as unitId,bui.unit_name as unitName, bui.unit_id as unitId,bui.unit_name as unitName,
lai.lease_person as leasePerson, lai.phone as leasePhone, tt.create_by as applyFor,d.`name` as taskName,lai.lease_type as leaseType,lai.estimate_lease_time as estimateLeaseTime, lai.lease_person as leasePerson, lai.phone as leasePhone, su.user_name as applyFor,d.`name` as taskName,lai.lease_type as leaseType,lai.estimate_lease_time as estimateLeaseTime,
case when d.id = '31' then lai.company_audit_remark case when d.id = '31' then lai.company_audit_remark
when d.id = '32' then lai.dept_audit_remark when d.id = '32' then lai.dept_audit_remark
when d.id = '33' then lai.direct_audit_remark when d.id = '33' then lai.direct_audit_remark
@ -956,7 +956,7 @@
tt.create_time as createTimes, tt.update_time as updateTimes tt.create_time as createTimes, tt.update_time as updateTimes
FROM FROM
tm_task tt tm_task tt
LEFT JOIN sys_user su ON tt.create_by = su.user_name LEFT JOIN sys_user su ON tt.create_by = su.user_id
LEFT JOIN sys_dept sd ON su.dept_id = sd.dept_id LEFT JOIN sys_dept sd ON su.dept_id = sd.dept_id
LEFT JOIN tm_task_agreement tta ON tt.task_id = tta.task_id LEFT JOIN tm_task_agreement tta ON tt.task_id = tta.task_id
LEFT JOIN bm_agreement_info bai ON bai.agreement_id = tta.agreement_id LEFT JOIN bm_agreement_info bai ON bai.agreement_id = tta.agreement_id

View File

@ -193,6 +193,8 @@ public class BackApplyController extends BaseController {
BackApplyInfo backApplyInfo1 = leaseApplyDetailsList.get(0); BackApplyInfo backApplyInfo1 = leaseApplyDetailsList.get(0);
// 对领料任务表的对象做数据处理 // 对领料任务表的对象做数据处理
BackApplyInfo backApplyInfo = bean.getBackApplyInfo(); BackApplyInfo backApplyInfo = bean.getBackApplyInfo();
//创建人
backApplyInfo.setCreateBy(bean.getUserId());
/* 创建领料单号*/ /* 创建领料单号*/
backApplyInfo.setCode(code); backApplyInfo.setCode(code);
/*设置任务ID*/ /*设置任务ID*/

View File

@ -251,5 +251,7 @@ public class BackApplyInfo extends BaseEntity {
private String time; private String time;
private int viewWeb; private int viewWeb;
/** 创建者 */
@ApiModelProperty(value = "创建者Id")
private String userId;
} }

View File

@ -46,8 +46,8 @@ public class BackApplyServiceImpl implements BackApplyService {
return backApplyMapper.getBackApplyList(bean); return backApplyMapper.getBackApplyList(bean);
} else { } else {
//个人只能看到自己的申请的退料 //个人只能看到自己的申请的退料
String username = SecurityUtils.getLoginUser().getUsername(); String userId = SecurityUtils.getLoginUser().getUserid().toString();
bean.setCreateBy(username); bean.setCreateBy(userId);
return backApplyMapper.getBackApplyList(bean); return backApplyMapper.getBackApplyList(bean);
} }
} }
@ -112,6 +112,8 @@ public class BackApplyServiceImpl implements BackApplyService {
@Override @Override
public int insertSelective(BackApplyInfo bean) { public int insertSelective(BackApplyInfo bean) {
//2024.06.14创建人统一修改为用户id
bean.setCreateBy(bean.getUserId());
return backApplyMapper.insertTask(bean); return backApplyMapper.insertTask(bean);
} }