Compare commits

..

No commits in common. "5490fd2e8f5bbb5dda12f2a15ba1c9bc4d2517f2" and "ae0b637828fbbd95c0dd9817bf3f630973168fde" have entirely different histories.

6 changed files with 1 additions and 25 deletions

View File

@ -205,7 +205,7 @@
<dependency>
<groupId>org.apache.tomcat.embed</groupId>
<artifactId>tomcat-embed-core</artifactId>
<version>9.0.86</version>
<version>9.0.81</version>
<scope>compile</scope>
<exclusions>
<exclusion>

View File

@ -12,5 +12,4 @@ public class MachinePart {
private String unitName;
private String typeName;
private Integer partNum;
private Integer typeId;
}

View File

@ -7,7 +7,6 @@ import com.bonus.sgzb.base.api.domain.MaMachineLabel;
import com.bonus.sgzb.base.api.domain.MaType;
import com.bonus.sgzb.material.domain.InputApplyDetails;
import com.bonus.sgzb.material.domain.MaInputRecord;
import com.bonus.sgzb.material.domain.MachinePart;
import com.bonus.sgzb.material.domain.PurchaseMacodeInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
@ -278,6 +277,4 @@ public interface PurchaseMacodeInfoMapper {
* @return
*/
int selectPurchaseCheckDetailsStatus(Long taskId);
int updateMaTypeNum(MachinePart wholeSetDetail);
}

View File

@ -13,7 +13,6 @@ 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.*;
import com.bonus.sgzb.material.service.IPurchaseCheckInfoService;
import com.bonus.sgzb.material.service.IPurchaseMacodeInfoService;
import com.bonus.sgzb.common.core.utils.DateUtils;
import com.bonus.sgzb.material.vo.EquipmentNumberVO;
@ -40,9 +39,6 @@ public class PurchaseMacodeInfoServiceImpl implements IPurchaseMacodeInfoService
@Resource
private TaskMapper taskMapper;
@Autowired
private IPurchaseCheckInfoService purchaseCheckInfoService;
@Resource
private BmQrcodeInfoMapper qrcodeInfoMapper;
@ -302,17 +298,6 @@ public class PurchaseMacodeInfoServiceImpl implements IPurchaseMacodeInfoService
.add(maType.getNum() == null ? new BigDecimal(0) : maType.getNum()));
purchaseMacodeInfoMapper.updateTypeByTypeId(maType);
//判断是否是成套机具是的话配件库存也要增加
if ("2".equals(maType.getManageType())){
PurchaseCheckInfo purchaseCheckInfo = new PurchaseCheckInfo();
purchaseCheckInfo.setPurchaseNum(maInputRecord.getInputNum().toString());
purchaseCheckInfo.setTypeId(maInputRecord.getTypeId());
List<MachinePart> wholeSetDetails = purchaseCheckInfoService.getWholeSetDetails(purchaseCheckInfo);
for (MachinePart wholeSetDetail : wholeSetDetails) {
purchaseMacodeInfoMapper.updateMaTypeNum(wholeSetDetail);
}
}
BigDecimal inputNum = checkDetailsMapper.selectInputNumByTypeId(taskId, typeId);
PurchaseCheckDetails purchaseCheckDetails = new PurchaseCheckDetails();
purchaseCheckDetails.setTaskId(taskId);

View File

@ -312,7 +312,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getWholeSetDetails" resultType="com.bonus.sgzb.material.domain.MachinePart">
SELECT
mt2.type_name AS typeModelName,
mt2.type_id as typeId,
mt3.type_name AS typeName,
aa.part_num * #{purchaseNum} AS partNum,
mt2.unit_name as unitName

View File

@ -534,8 +534,4 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and type_id = #{typeId}
and ma_code = #{maCode}
</update>
<update id="updateMaTypeNum">
UPDATE ma_type
SET num = ifnull( num, 0 ) + #{partNum} WHERE type_id = #{typeId}
</update>
</mapper>