|
|
|
@ -674,9 +674,77 @@ public class WmsProductPutServiceImpl implements IWmsProductPutService {
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
*
|
|
|
|
|
"MAKTX": "榄菊果蔬餐具净(海盐柠檬)1kg×10",描述 物料描述
|
|
|
|
|
"KUNNR": "0001010404", //送达方
|
|
|
|
|
"VBELN": "0081003133", //交货单
|
|
|
|
|
"ZSAREA": "", //销售大区
|
|
|
|
|
"BZTXT1": "", //销售大区描述
|
|
|
|
|
"KUNNR_NM": "上海大润发有限公司(华东高新总仓)", //送达方描述
|
|
|
|
|
"MENGE": "6.000", //数量
|
|
|
|
|
"MEINS": "KAR", //单位
|
|
|
|
|
"LIFNR_NM": "上海中集公联集装箱储运有限公司", //货运代理描述
|
|
|
|
|
"TDDAT": "2202-02-09", //计划日期
|
|
|
|
|
"LIFNR": "0000400213", //货运代理
|
|
|
|
|
"VBELN_VA": "0000738138", //销售单
|
|
|
|
|
"MATNR": "000000010201020100" 物料描述
|
|
|
|
|
* @param wmsSellOutEmbryo
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
@Override
|
|
|
|
|
public List<WmsSellOutEmbryo> selectFinishedProductSales(WmsSellOutEmbryo wmsSellOutEmbryo) {
|
|
|
|
|
return null;
|
|
|
|
|
public String selectFinishedProductSales(WmsSellOutEmbryo wmsSellOutEmbryo) {
|
|
|
|
|
String results="提单成功";
|
|
|
|
|
DynamicDataSourceContextHolder.push("ds_" + wmsSellOutEmbryo.getFactoryCode());
|
|
|
|
|
Map<String, Object> objectMap=new HashMap<>();
|
|
|
|
|
// objectMap.put("S_MATNR","");//物料号,
|
|
|
|
|
// objectMap.put("S_TDDAT","");//String 计划运输日期
|
|
|
|
|
objectMap.put("VBELN_VA",wmsSellOutEmbryo.getDeliveryOrder());//交货单
|
|
|
|
|
R result = remoteSapService.FPinventory(objectMap);
|
|
|
|
|
int code = result.getCode();
|
|
|
|
|
String msg = result.getMsg();
|
|
|
|
|
if(code==200){
|
|
|
|
|
List<Map<String,String>> mapList= (List<Map<String, String>>) result.getData();
|
|
|
|
|
for ( Map<String,String> stringStringMap: mapList){
|
|
|
|
|
String MAKTX=stringStringMap.get("MAKTX");//物料描述
|
|
|
|
|
String MATNR=stringStringMap.get("MATNR");//物料号
|
|
|
|
|
String KUNNR=stringStringMap.get("KUNNR");//送达方
|
|
|
|
|
String VBELN=stringStringMap.get("VBELN");//交货单---一销售单对多交货单
|
|
|
|
|
String VBELN_VA=stringStringMap.get("VBELN_VA");//销售单
|
|
|
|
|
String MENGE=stringStringMap.get("MENGE");//数量
|
|
|
|
|
String MEINS=stringStringMap.get("MEINS");//单位
|
|
|
|
|
String TDDAT=stringStringMap.get("TDDAT");//计划日期
|
|
|
|
|
String KUNNR_NM=stringStringMap.get("KUNNR_NM");//送达方描述
|
|
|
|
|
String LIFNR=stringStringMap.get("LIFNR");//货运代理
|
|
|
|
|
String LIFNR_NM=stringStringMap.get("LIFNR_NM");//货运代理描述
|
|
|
|
|
String ZSAREA=stringStringMap.get("ZSAREA");//销售大区
|
|
|
|
|
String BZTXT1=stringStringMap.get("BZTXT1");//销售大区描述
|
|
|
|
|
WmsSellOutEmbryo wmsSellOutEmbryo1=new WmsSellOutEmbryo();
|
|
|
|
|
wmsSellOutEmbryo1.setId(IdUtils.fastSimpleUUID());
|
|
|
|
|
wmsSellOutEmbryo1.setDeliveryOrder(VBELN);//交货单号
|
|
|
|
|
wmsSellOutEmbryo1.setAttr1(VBELN_VA);
|
|
|
|
|
wmsSellOutEmbryo1.setProductCode(MATNR);
|
|
|
|
|
wmsSellOutEmbryo1.setProductName(MAKTX);
|
|
|
|
|
wmsSellOutEmbryo1.setFactoryCode(wmsSellOutEmbryo.getFactoryCode());
|
|
|
|
|
wmsSellOutEmbryo1.setOutQuantity(new BigDecimal("0"));
|
|
|
|
|
wmsSellOutEmbryo1.setAttr2(KUNNR);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr3(KUNNR_NM);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr4(LIFNR);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr5(LIFNR_NM);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr6(ZSAREA);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr7(BZTXT1);
|
|
|
|
|
wmsSellOutEmbryo1.setAttr8(TDDAT);
|
|
|
|
|
wmsSellOutEmbryo1.setPlanQuantity(new BigDecimal(MENGE));
|
|
|
|
|
wmsSellOutEmbryo1.setUnitOfMeasure(MEINS);
|
|
|
|
|
wmsSellOutEmbryo1.setStatus("0");
|
|
|
|
|
wmsSellOutEmbryo1.setSapStatus("0");
|
|
|
|
|
wmsSellOutEmbryo1.setActiveFlag("1");
|
|
|
|
|
wmsSellOutEmbryo1.setCreateBy(wmsSellOutEmbryo.getCreateBy());
|
|
|
|
|
wmsSellOutEmbryo1.setCreateTime(new Date());
|
|
|
|
|
wmsSellOutEmbryoMapper.insertWmsSellOutEmbryo(wmsSellOutEmbryo1);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return results;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|