|
@@ -128,10 +128,16 @@ public class MaterialAscriptionController {
|
|
|
String shotName = "";
|
|
|
String shotId = materialAscription.getShotId();
|
|
|
if (!Check.isNull(shotId)) {
|
|
|
- SysUser plan = sysUserService.getById(shotId);
|
|
|
- if (!Check.isNull(plan)) {
|
|
|
- shotName = plan.getRealname();
|
|
|
- materialAscription.setShotName(shotName);
|
|
|
+ SysUser shot = sysUserService.getById(shotId);
|
|
|
+ String shotCode = sysUserService.getRoleCodeByUserId(shotId);
|
|
|
+ shotName = shot.getRealname();
|
|
|
+ materialAscription.setShotName(shotName);
|
|
|
+ if("designTeamLeader".equals(shotCode)){
|
|
|
+ materialAscription.setShotLeaderId(shotId);
|
|
|
+ materialAscription.setShotLeaderName(shot.getRealname());
|
|
|
+ }else {
|
|
|
+ materialAscription.setShotLeaderId(shot.getLeaderId());
|
|
|
+ materialAscription.setShotLeaderName(shot.getLeaderName());
|
|
|
}
|
|
|
}
|
|
|
String planName = "";
|
|
@@ -166,6 +172,7 @@ public class MaterialAscriptionController {
|
|
|
materialAscription.setLeaderId(leaderId);
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
QueryWrapper<MaterialAscription> ascriptionQueryWrapper = new QueryWrapper<>();
|
|
|
ascriptionQueryWrapper.eq("material_id", materialAscription.getMaterialId());
|
|
|
ascriptionQueryWrapper.last("limit 1");
|