领料审核通过

This commit is contained in:
liang.chao 2024-01-24 18:44:10 +08:00
parent bff877e19b
commit b7f2c3ba4c
2 changed files with 16 additions and 0 deletions

View File

@ -340,6 +340,20 @@ public class TmTaskServiceImpl implements TmTaskService {
List<LeaseApplyDetails> listLeaseDetails = new ArrayList<>(); List<LeaseApplyDetails> listLeaseDetails = new ArrayList<>();
for (LeaseApplyInfo leaseApplyInfo : leaseApplyInfoList) { for (LeaseApplyInfo leaseApplyInfo : leaseApplyInfoList) {
if (leaseApplyInfo != null) { if (leaseApplyInfo != null) {
SysUser sysUser = SecurityUtils.getLoginUser().getSysUser();
//获取当前用户所属公司id
Long companyId = sysUser.getCompanyId();
//获取当前用户的角色
Set<String> roles = SecurityUtils.getLoginUser().getRoles();
StringBuilder sb = new StringBuilder();
for (String s : roles) {
sb.append(s);
}
String rolesStr = sb.toString();
//如果是内部人员加上所属公司
if ((rolesStr.contains("jjfgs") && !rolesStr.contains("admin")) || (rolesStr.contains("tsfgs") && !rolesStr.contains("admin"))) {
leaseApplyInfo.setCompanyId(Integer.parseInt(companyId.toString()));
}
// 去查询领料任务详情表 // 去查询领料任务详情表
List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyDetails(leaseApplyInfo); List<LeaseApplyDetails> leaseApplyDetails = tmTaskMapper.getLeaseApplyDetails(leaseApplyInfo);
if (leaseApplyDetails != null && !leaseApplyDetails.isEmpty()) { if (leaseApplyDetails != null && !leaseApplyDetails.isEmpty()) {

View File

@ -603,6 +603,7 @@
direct_audit_by = #{record.companyAuditBy}, direct_audit_by = #{record.companyAuditBy},
direct_audit_time = now(), direct_audit_time = now(),
direct_audit_remark = #{record.companyAuditRemark}, direct_audit_remark = #{record.companyAuditRemark},
status = #{record.status},
</if> </if>
<if test="record.examineStatusId == 33 and record.examineStatusId == '33'"> <if test="record.examineStatusId == 33 and record.examineStatusId == '33'">
update_by = #{record.companyAuditBy}, update_by = #{record.companyAuditBy},
@ -640,6 +641,7 @@
direct_audit_by = #{record.companyAuditBy}, direct_audit_by = #{record.companyAuditBy},
direct_audit_time = now(), direct_audit_time = now(),
direct_audit_remark = #{record.companyAuditRemark}, direct_audit_remark = #{record.companyAuditRemark},
status = #{record.status},
</if> </if>
</trim> </trim>
WHERE WHERE