试运行问题修改
This commit is contained in:
parent
c316048317
commit
2a0556f200
|
|
@ -8,6 +8,7 @@ import org.apache.commons.lang3.builder.ToStringStyle;
|
|||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
|
|
@ -117,17 +118,17 @@ public class PurchaseMacodeInfo extends BaseEntity
|
|||
@ApiModelProperty(value = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
public String getUserIds() {
|
||||
public List<String> getUserIds() {
|
||||
return userIds;
|
||||
}
|
||||
|
||||
public void setUserIds(String userIds) {
|
||||
public void setUserIds(List<String> userIds) {
|
||||
this.userIds = userIds;
|
||||
}
|
||||
|
||||
/** 审核员用户id */
|
||||
@ApiModelProperty(value = "审核员用户id")
|
||||
private String userIds;
|
||||
private List<String> userIds;
|
||||
|
||||
/**
|
||||
* 类型管理方式
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ package com.bonus.sgzb.material.domain;
|
|||
import com.bonus.sgzb.common.core.annotation.Excel;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author 10488
|
||||
* 修试入库详细
|
||||
|
|
@ -67,5 +69,5 @@ public class RepairTestInputDetailVo {
|
|||
private String status;
|
||||
|
||||
/** 修试管理入库审核人员*/
|
||||
private String userIds;
|
||||
private List<String> userIds;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -282,4 +282,6 @@ public interface PurchaseMacodeInfoMapper {
|
|||
int updateMaTypeNum(MachinePart wholeSetDetail);
|
||||
|
||||
List<PurchaseMacodeInfo> selectPurchaseMacodeInfoListDetails(PurchaseMacodeInfo purchaseMacodeInfo);
|
||||
|
||||
List<String> selectKeepUser(Integer typeId);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ import java.util.List;
|
|||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.bonus.sgzb.base.api.domain.*;
|
||||
import com.bonus.sgzb.common.core.utils.StringUtils;
|
||||
|
|
@ -427,7 +428,14 @@ public class PurchaseMacodeInfoServiceImpl implements IPurchaseMacodeInfoService
|
|||
*/
|
||||
@Override
|
||||
public List<PurchaseMacodeInfo> selectPutinDetails(PurchaseMacodeInfo purchaseMacodeInfo) {
|
||||
return purchaseMacodeInfoMapper.selectPutinDetails(purchaseMacodeInfo);
|
||||
List<PurchaseMacodeInfo> purchaseMacodeInfos = purchaseMacodeInfoMapper.selectPutinDetails(purchaseMacodeInfo);
|
||||
for (PurchaseMacodeInfo macodeInfo : purchaseMacodeInfos) {
|
||||
List<String> userIds = purchaseMacodeInfoMapper.selectKeepUser(macodeInfo.getTypeId().intValue());
|
||||
if (CollUtil.isNotEmpty(userIds)){
|
||||
macodeInfo.setUserIds(userIds);
|
||||
}
|
||||
}
|
||||
return purchaseMacodeInfos;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.bonus.sgzb.material.service.impl;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.bonus.sgzb.common.core.constant.HttpStatus;
|
||||
import com.bonus.sgzb.common.core.exception.ServiceException;
|
||||
|
|
@ -10,6 +11,7 @@ import com.bonus.sgzb.common.core.utils.StringUtils;
|
|||
import com.bonus.sgzb.common.core.web.domain.AjaxResult;
|
||||
import com.bonus.sgzb.common.security.utils.SecurityUtils;
|
||||
import com.bonus.sgzb.material.domain.*;
|
||||
import com.bonus.sgzb.material.mapper.PurchaseMacodeInfoMapper;
|
||||
import com.bonus.sgzb.material.mapper.RepairTestInputMapper;
|
||||
import com.bonus.sgzb.material.mapper.TaskMapper;
|
||||
import com.bonus.sgzb.material.mapper.TmTaskAgreementMapper;
|
||||
|
|
@ -37,6 +39,9 @@ public class RepairTestInputServiceImpl implements RepairTestInputService {
|
|||
@Resource(name = "RepairTestInputMapper")
|
||||
private RepairTestInputMapper mapper;
|
||||
|
||||
@Resource
|
||||
private PurchaseMacodeInfoMapper purchaseMacodeInfoMapper;
|
||||
|
||||
@Resource
|
||||
private TaskMapper taskMapper;
|
||||
|
||||
|
|
@ -50,7 +55,14 @@ public class RepairTestInputServiceImpl implements RepairTestInputService {
|
|||
|
||||
@Override
|
||||
public List<RepairTestInputDetailVo> getRepairedDetailList(RepairTestInputDto dto) {
|
||||
return mapper.getRepairedDetailList(dto);
|
||||
List<RepairTestInputDetailVo> repairedDetailList = mapper.getRepairedDetailList(dto);
|
||||
for (RepairTestInputDetailVo repairTestInputDetailVo : repairedDetailList) {
|
||||
List<String> userIds = purchaseMacodeInfoMapper.selectKeepUser(repairTestInputDetailVo.getTypeId());
|
||||
if (CollUtil.isNotEmpty(userIds)) {
|
||||
repairTestInputDetailVo.setUserIds(userIds);
|
||||
}
|
||||
}
|
||||
return repairedDetailList;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
|
|
@ -364,7 +364,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
pcd.task_id taskId,
|
||||
mt.CODE specsCode,
|
||||
mt1.CODE typeCode,
|
||||
GROUP_CONCAT( mtk.user_id ) AS userIds,
|
||||
CASE
|
||||
WHEN pmi.ma_code IS NULL THEN
|
||||
CASE
|
||||
|
|
@ -385,7 +384,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
LEFT JOIN ma_machine mm ON pmi.ma_code = mm.ma_code
|
||||
LEFT JOIN ma_type mt ON pcd.type_id = mt.type_id
|
||||
LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id
|
||||
LEFT JOIN ma_type_keeper mtk ON mtk.type_id = pcd.type_id
|
||||
WHERE
|
||||
pcd.task_id = #{taskId}
|
||||
AND pcd.`status` != 3
|
||||
|
|
@ -394,8 +392,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
and (mt.type_name like concat('%',#{dictName},'%') or
|
||||
mt1.type_name like concat('%',#{dictName},'%'))
|
||||
</if>
|
||||
GROUP BY
|
||||
pcd.type_id
|
||||
ORDER BY
|
||||
STATUS,
|
||||
pmi.id
|
||||
|
|
@ -552,6 +548,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
AND pcd.`status` != 3
|
||||
AND pcd.`status` != 5
|
||||
</select>
|
||||
<select id="selectKeepUser" resultType="java.lang.String">
|
||||
SELECT user_id FROM ma_type_keeper WHERE type_id = #{typeId}
|
||||
</select>
|
||||
|
||||
<update id="updateTypeByTypeId">
|
||||
update ma_type set num = #{num} where type_id = #{typeId}
|
||||
|
|
|
|||
|
|
@ -124,11 +124,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
rid.update_by AS updateBy,
|
||||
rid.update_time AS updateTime,
|
||||
rid.remark,
|
||||
GROUP_CONCAT( mtk.user_id ) AS userIds,
|
||||
CASE rid.`status` WHEN '0' THEN '进行中' WHEN '1' THEN '已入库' WHEN '2' THEN '驳回' ELSE '进行中' END AS `status`
|
||||
FROM repair_input_details rid
|
||||
LEFT JOIN ma_machine mm ON rid.ma_id = mm.ma_id
|
||||
LEFT JOIN ma_type_keeper mtk ON rid.type_id = mtk.type_id
|
||||
LEFT JOIN (
|
||||
SELECT mt.type_id AS typeId,mt2.type_id AS typeId2,mt.type_name AS typeName,mt2.type_name AS typeName2,mt.manage_type
|
||||
FROM ma_type mt
|
||||
|
|
@ -150,7 +148,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="typeId!=null and typeId!=''">
|
||||
AND a.typeId = #{typeId}
|
||||
</if>
|
||||
GROUP BY rid.type_id
|
||||
ORDER BY rid.create_time DESC
|
||||
</select>
|
||||
<!--查询机具类型-库存数量-->
|
||||
|
|
|
|||
Loading…
Reference in New Issue