|
@@ -1,8 +1,10 @@
|
|
package com.steerinfo.dil.controller;
|
|
package com.steerinfo.dil.controller;
|
|
|
|
|
|
import com.github.pagehelper.PageHelper;
|
|
import com.github.pagehelper.PageHelper;
|
|
|
|
+import com.steerinfo.dil.feign.BmsTruckFeign;
|
|
import com.steerinfo.dil.feign.ColumnDataFeign;
|
|
import com.steerinfo.dil.feign.ColumnDataFeign;
|
|
import com.steerinfo.dil.feign.OmsFeign;
|
|
import com.steerinfo.dil.feign.OmsFeign;
|
|
|
|
+import com.steerinfo.dil.feign.TmstruckFeign;
|
|
import com.steerinfo.dil.mapper.WmspInboundResultMapper;
|
|
import com.steerinfo.dil.mapper.WmspInboundResultMapper;
|
|
import com.steerinfo.dil.model.*;
|
|
import com.steerinfo.dil.model.*;
|
|
import com.steerinfo.dil.service.impl.RmsMaterialServiceImpl;
|
|
import com.steerinfo.dil.service.impl.RmsMaterialServiceImpl;
|
|
@@ -61,6 +63,11 @@ public class WmsInboundScanResultController extends BaseRESTfulController {
|
|
@Autowired
|
|
@Autowired
|
|
OmsFeign omsFeign;
|
|
OmsFeign omsFeign;
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ BmsTruckFeign bmsTruckFeign;
|
|
|
|
+
|
|
|
|
+ @Autowired
|
|
|
|
+ TmstruckFeign tmstruckFeign;
|
|
|
|
|
|
/**
|
|
/**
|
|
* 1.新增扫描吊牌实绩!!!此时入库实绩未生成
|
|
* 1.新增扫描吊牌实绩!!!此时入库实绩未生成
|
|
@@ -80,6 +87,11 @@ public class WmsInboundScanResultController extends BaseRESTfulController {
|
|
Integer orderType=DataChange.dataToBigDecimal(order.get("orderType")).intValue();
|
|
Integer orderType=DataChange.dataToBigDecimal(order.get("orderType")).intValue();
|
|
BigDecimal orderId=DataChange.dataToBigDecimal(order.get("orderId"));
|
|
BigDecimal orderId=DataChange.dataToBigDecimal(order.get("orderId"));
|
|
if(orderType!=null && orderType == 25){
|
|
if(orderType!=null && orderType == 25){
|
|
|
|
+ //校验是否有装货实绩,若没有则不允许入库
|
|
|
|
+ Integer count=wmsInboundScanResultService.isExistLoad((String)map.get("resultMaterial"));
|
|
|
|
+ if(count==null|| count<=0){
|
|
|
|
+ return failed(null);
|
|
|
|
+ }
|
|
//根据运输订单号查询出库扫码实绩
|
|
//根据运输订单号查询出库扫码实绩
|
|
List<Map<String,Object>> inboundOld= wmsInboundScanResultService.findInboundScanResult((String)map.get("resultMaterial"));
|
|
List<Map<String,Object>> inboundOld= wmsInboundScanResultService.findInboundScanResult((String)map.get("resultMaterial"));
|
|
//批量新增扫码实绩
|
|
//批量新增扫码实绩
|
|
@@ -88,14 +100,16 @@ public class WmsInboundScanResultController extends BaseRESTfulController {
|
|
}
|
|
}
|
|
else{
|
|
else{
|
|
System.out.println("物资暂未出库,请先出库再入库!");
|
|
System.out.println("物资暂未出库,请先出库再入库!");
|
|
- return null;
|
|
|
|
|
|
+ return failed(null);
|
|
}
|
|
}
|
|
//返回新建的扫码实绩数据
|
|
//返回新建的扫码实绩数据
|
|
List<Map<String,Object>> mapList= wmsInboundScanResultService.noIssueScanResultList(map.get("userName").toString());
|
|
List<Map<String,Object>> mapList= wmsInboundScanResultService.noIssueScanResultList(map.get("userName").toString());
|
|
|
|
+ //新增卸货实绩
|
|
|
|
+ tmstruckFeign.updateUnloadResult(order);
|
|
//关闭运输订单
|
|
//关闭运输订单
|
|
omsFeign.closeSteelOrderType4(DataChange.dataToBigDecimal(orderId));
|
|
omsFeign.closeSteelOrderType4(DataChange.dataToBigDecimal(orderId));
|
|
//生成计费详单
|
|
//生成计费详单
|
|
-
|
|
|
|
|
|
+ bmsTruckFeign.addInwardDetailsOrder(order);
|
|
return success(mapList);
|
|
return success(mapList);
|
|
}
|
|
}
|
|
int isExist= wmsInboundScanResultService.isExist(map.get("userName").toString(),map.get("resultMaterial").toString().substring(0,map.get("resultMaterial").toString().length()-1));
|
|
int isExist= wmsInboundScanResultService.isExist(map.get("userName").toString(),map.get("resultMaterial").toString().substring(0,map.get("resultMaterial").toString().length()-1));
|