Browse Source

更改

master
ligaode 7 months ago
parent
commit
e888482453
  1. 4
      anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/wms/otheroutapply/AppOtherOutApplyService.java
  2. 4
      yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryMapper.java
  3. 24
      yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryMapper.xml
  4. 10
      yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryService.java
  5. 11
      yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventorycheckbill/WmsInventoryCheckbillService.java
  6. 3988
      yxt-wms-biz/src/main/resources/ftl/cjpdbg.ftl

4
anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/wms/otheroutapply/AppOtherOutApplyService.java

@ -42,6 +42,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.math.BigDecimal;
import java.util.Collections;
import java.util.List;
@ -59,11 +60,12 @@ public class AppOtherOutApplyService {
ResultBean rb = ResultBean.fireFail();
WmsOtheroutApplyDetailsVo data = wmsOtherOutApplyFeign.fetchDetailsBySid(sid).getData();
AppOtheroutApplyDetailsVo appOtheroutApplyDetailsVo = new AppOtheroutApplyDetailsVo();
appOtheroutApplyDetailsVo.setProcInsId(data.getProcInstId());
BeanUtil.copyProperties(data,appOtheroutApplyDetailsVo);
List<AppOtheroutDetailDetailsVo> otheroutDetailList = appOtheroutApplyDetailsVo.getOtheroutDetailList();
for (AppOtheroutDetailDetailsVo appOtheroutDetailDetailsVo : otheroutDetailList) {
appOtheroutDetailDetailsVo.setWarehouseRackName(appOtheroutDetailDetailsVo.getWarehouseRackCode());
appOtheroutDetailDetailsVo.setAmount(appOtheroutDetailDetailsVo.getOutCount().multiply(appOtheroutDetailDetailsVo.getInCost()));
appOtheroutDetailDetailsVo.setAmount(appOtheroutDetailDetailsVo.getOutCount().multiply(appOtheroutDetailDetailsVo.getInCost()).setScale(2, BigDecimal.ROUND_HALF_UP));
}
return rb.success().setData(appOtheroutApplyDetailsVo);
}

4
yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryMapper.java

@ -96,4 +96,8 @@ public interface WmsInventoryMapper extends BaseMapper<WmsInventory> {
String selByGoodsIdAndRackSid(@Param("goodsID") String goodsID,@Param("warehouseRackSid") String warehouseRackSid);
BigDecimal compute(String skuSid);
List<WmsInventory> selCJByDeptSidAndRackSid(@Param("deptSid") String deptSid,@Param("rackSids") List<String> rackSids);
List<WmsInventory> selCJByDeptSid(String deptSid);
}

24
yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryMapper.xml

@ -699,4 +699,28 @@
WHERE goodsSkuSid = #{skuSid}
AND COUNT> 0
</select>
<select id="selCJByDeptSidAndRackSid" resultType="com.yxt.wms.biz.inventory.wmsinventory.WmsInventory">
SELECT wi.*
FROM wms_inventory wi
LEFT JOIN wms_warehouse_info wwi
ON wi.`warehouseSid` = wwi.`sid`
WHERE wi.count > 0
AND wwi.useOrgSid = #{deptSid}
AND wwi.warehouseTypeKey = '03'
AND wi.warehouseRackSid in
<foreach item="rackSid" collection="rackSids" open="(" separator="," close=")">
#{rackSid}
</foreach>
</select>
<select id="selCJByDeptSid" resultType="com.yxt.wms.biz.inventory.wmsinventory.WmsInventory">
SELECT wi.*
FROM wms_inventory wi
LEFT JOIN wms_warehouse_info wwi
ON wi.warehouseSid = wwi.sid
WHERE wi.count > 0
AND wwi.useOrgSid = #{deptSid}
AND wwi.warehouseTypeKey = '03'
</select>
</mapper>

10
yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventory/WmsInventoryService.java

@ -1194,11 +1194,19 @@ public class WmsInventoryService extends MybatisBaseService<WmsInventoryMapper,
}
public String selByGoodsIdAndRackSid(String goodsID, String warehouseRackSid) {
return baseMapper.selByGoodsIdAndRackSid(goodsID,warehouseRackSid);
return baseMapper.selByGoodsIdAndRackSid(goodsID, warehouseRackSid);
}
public BigDecimal compute(String skuSid) {
return baseMapper.compute(skuSid);
}
public List<WmsInventory> selCJByDeptSidAndRackSid(String deptSid, List<String> rackSids) {
return baseMapper.selCJByDeptSidAndRackSid(deptSid, rackSids);
}
public List<WmsInventory> selCJByDeptSid(String deptSid) {
return baseMapper.selCJByDeptSid(deptSid);
}
}

11
yxt-wms-biz/src/main/java/com/yxt/wms/biz/inventory/wmsinventorycheckbill/WmsInventoryCheckbillService.java

@ -324,6 +324,15 @@ public class WmsInventoryCheckbillService extends MybatisBaseService<WmsInventor
//查询本部门下,库存数量大0并且是旧件的库存
wmsInventories = wmsInventoryService.selJJByDeptSid(dto.getDeptSid());
}
}else if ("03".equals(dto.getWarehouseTypeKey())){//拆件
billNo = "CJPD" + sysOrganizationVo.getOrgCode() + date;
if ("1".equals(dto.getCheckTypeKey())) {
//查询本部门指定库位下,库存数量大0并且拆件的库存
wmsInventories = wmsInventoryService.selCJByDeptSidAndRackSid(dto.getDeptSid(), dto.getRackSids());
} else if ("2".equals(dto.getCheckTypeKey())) {
//查询本部门下,库存数量大0并且是拆件的库存
wmsInventories = wmsInventoryService.selCJByDeptSid(dto.getDeptSid());
}
}
String i = baseMapper.selectNum(billNo);
if (StringUtils.isNotBlank(i)) {
@ -504,6 +513,8 @@ public class WmsInventoryCheckbillService extends MybatisBaseService<WmsInventor
inputStream = this.getClass().getClassLoader().getResourceAsStream("ftl/" + "pdbg" + ".ftl");
}else if ("02".equals(wmsInventoryCheckbillReportDetailsVo.getWarehouseTypeKey())){
inputStream = this.getClass().getClassLoader().getResourceAsStream("ftl/" + "jjpdbg" + ".ftl");
}else if ("03".equals(wmsInventoryCheckbillReportDetailsVo.getWarehouseTypeKey())){
inputStream = this.getClass().getClassLoader().getResourceAsStream("ftl/" + "cjpdbg" + ".ftl");
}
//生成word文件名
String targetPath = docPdfComponent.getUploadTemplateUrl();

3988
yxt-wms-biz/src/main/resources/ftl/cjpdbg.ftl

File diff suppressed because it is too large
Loading…
Cancel
Save