wms修改13

master
mengjiao 1 year ago
parent 8272aabbe6
commit 44a23eaa78

@ -120,6 +120,8 @@ public class OdsProcureOrderController extends BaseController {
@PostMapping("/PurchaseOrderdeliPda")
public AjaxResult PurchaseOrderdeliPda(@RequestBody OdsProcureOrder odsProcureOrder) {
// odsProcureOrderService.PurchaseOrderdeliPdas(odsProcureOrder);
// return success(null);
int tem =odsProcureOrderService.PurchaseOrderdeliPda(odsProcureOrder);
return success(tem);
}

@ -60,4 +60,6 @@ public interface OdsProcureOrderMapper {
public int deleteOdsProcureOrderByIDs(String[] IDs);
Integer updateRealityNuById(OdsProcureOrder odsProcureOrder);
String selectBaseSupplier(OdsProcureOrder odsProcureOrder);
}

@ -73,4 +73,6 @@ public interface OdsProcureOutOrderMapper {
List<OdsProcureOutOrder> selectOdsProcureOutOrderListZU(OdsProcureOutOrder odsProcureOutOrder);
List<OdsProcureOutOrder> selectOdsProcureOutOrderListZUT(OdsProcureOutOrder odsProcureOutOrder1);
List<OdsProcureOutOrder> selectOdsProcureOutOrderListByu1(@Param("list")List<OdsProcureOutOrder> orderList);
}

@ -92,4 +92,6 @@ public interface IOdsProcureOrderService {
void OutboundPostingSAP(List<OdsProcureOutOrder> odsProcureOutOrder);
AjaxResult sapPurchaseOrderSync(OdsProcureOrder odsProcureOrder);
void PurchaseOrderdeliPdas(OdsProcureOrder odsProcureOrder);
}

@ -39,6 +39,10 @@ import com.op.wms.mapper.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.op.wms.service.IOdsProcureOrderService;
import org.springframework.web.context.request.RequestContextHolder;
import org.springframework.web.context.request.ServletRequestAttributes;
import javax.servlet.http.HttpServletRequest;
/**
* Service
@ -178,16 +182,25 @@ public class OdsProcureOrderServiceImpl implements IOdsProcureOrderService {
odsProcureOrder.setOrderStatus("2");
}
Integer tem= odsProcureOrderMapper.updateRealityNuById(odsProcureOrder);
// //插入检验集计划
// QcCheckTaskIncomeDTO qcCheckTaskIncomeDTO=new QcCheckTaskIncomeDTO();
// qcCheckTaskIncomeDTO.setCheckLoc("mjtest");
// qcCheckTaskIncomeDTO.setCheckType("checkTypeLL");
// qcCheckTaskIncomeDTO.setCheckManCode("mobile");
// qcCheckTaskIncomeDTO.setCheckManName("手持测试用户");
//// qcCheckTaskIncomeDTO.setSupplierCode();
//// qcCheckTaskIncomeDTO.setSupplierName();
//// qcCheckTaskIncomeDTO.setOrderType("bc");
// remoteQualityService.createIncomeTask(qcCheckTaskIncomeDTO);
//插入检验集计划
QcCheckTaskIncomeDTO qcCheckTaskIncomeDTO=new QcCheckTaskIncomeDTO();
qcCheckTaskIncomeDTO.setCheckLoc("mjtest");
qcCheckTaskIncomeDTO.setCheckType("checkTypeLL");
qcCheckTaskIncomeDTO.setCheckManCode("mobile");
qcCheckTaskIncomeDTO.setCheckManName("手持测试用户");
qcCheckTaskIncomeDTO.setSupplierCode(order.getSupplierCode());
String name= odsProcureOrderMapper.selectBaseSupplier(odsProcureOrder);
qcCheckTaskIncomeDTO.setSupplierName(name);
qcCheckTaskIncomeDTO.setOrderType("bc");
qcCheckTaskIncomeDTO.setUnit(order.getUnit());
qcCheckTaskIncomeDTO.setFactoryCode(odsProcureOrder.getFactoryCode());
qcCheckTaskIncomeDTO.setQuality(odsProcureOrder.getPlanNumber());
qcCheckTaskIncomeDTO.setMaterialCode(odsProcureOrder.getMaterialCode());
qcCheckTaskIncomeDTO.setMaterialName(odsProcureOrder.getSupplierName());
qcCheckTaskIncomeDTO.setIncomeBatchNo(odsProcureOrder.getIncomeBatchNo());
qcCheckTaskIncomeDTO.setOrderNo(order.getProcureCode());
qcCheckTaskIncomeDTO.setIncomeTime(new Date());
remoteQualityService.createIncomeTask(qcCheckTaskIncomeDTO);
return tem;
}
@ -657,6 +670,31 @@ public class OdsProcureOrderServiceImpl implements IOdsProcureOrderService {
return AjaxResult.success();
}
@Override
public void PurchaseOrderdeliPdas(OdsProcureOrder odsProcureOrder) {
DynamicDataSourceContextHolder.push("ds_" + odsProcureOrder.getFactoryCode());
HttpServletRequest request = ((ServletRequestAttributes) RequestContextHolder.getRequestAttributes()).getRequest();
request.setAttribute("#header.poolName", "ds_" + odsProcureOrder.getFactoryCode());
QcCheckTaskIncomeDTO qcCheckTaskIncomeDTO=new QcCheckTaskIncomeDTO();
qcCheckTaskIncomeDTO.setCheckLoc("mjtest");
qcCheckTaskIncomeDTO.setCheckType("checkTypeLL");
qcCheckTaskIncomeDTO.setCheckManCode("mobile");
qcCheckTaskIncomeDTO.setCheckManName("手持测试用户");
qcCheckTaskIncomeDTO.setSupplierCode("1");
qcCheckTaskIncomeDTO.setFactoryCode("1000");
qcCheckTaskIncomeDTO.setSupplierName("1");
qcCheckTaskIncomeDTO.setOrderType("bc");
qcCheckTaskIncomeDTO.setUnit("1");
qcCheckTaskIncomeDTO.setQuality(new BigDecimal("1"));
qcCheckTaskIncomeDTO.setMaterialCode("1");
qcCheckTaskIncomeDTO.setMaterialName("1");
qcCheckTaskIncomeDTO.setIncomeBatchNo("1");
qcCheckTaskIncomeDTO.setOrderNo("1");
qcCheckTaskIncomeDTO.setIncomeTime(new Date());
remoteQualityService.createIncomeTask(qcCheckTaskIncomeDTO);
}
public String DesignatedPalletOutboundWCS(WMSDesignatedPalle wmsDesignatedPalle){
// 定义请求的URL地址
String url = "http://192.168.202.37:9001/api/v1/ReceiveMesMsg/packingMaterialsOutBoundByPallet";

@ -207,4 +207,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where ID = #{ID}
</update>
<select id="selectBaseSupplier" resultType="java.lang.String">
SELECT DISTINCT zh_desc FROM base_supplier WHERE supplier_code= #{supplierCode}
</select>
</mapper>

@ -315,5 +315,51 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
#{item.ID}
</foreach>
</select>
<select id="selectOdsProcureOutOrderListByu1" resultMap="OdsProcureOutOrderResult">
SELECT
Site_code,
ID,
Produce_Code,
Material_Code,
Material_Desc,
Plan_Date,
Plan_Number,
Unit,
COALESCE ( Plan_Number, 0 ) AS Out_Number,
Loc_Code,
Loc_Desc,
Production_Line_Desc,
Production_Line_Code,
Order_Status,
User_Defined1,
User_Defined2,
User_Defined3,
User_Defined4,
User_Defined5,
User_Defined6,
User_Defined7,
User_Defined8,
User_Defined9,
User_Defined10,
User_Defined11,
Supplier_Code,
Supplier_Name,
Create_By,
Create_Date,
Last_Update_By,
Last_Update_Date,
Active,
Enterprise_Id,
Enterprise_Code
WHERE
<![CDATA[ (User_Defined10 <> '2' OR User_Defined10 is NULL ) ]]>
and Produce_Code in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item.produceCode}
</foreach>
and User_Defined1 in
<foreach collection="list" item="item" index="index" open="(" separator="," close=")">
#{item.userDefined1}
</foreach>
</select>
</mapper>

Loading…
Cancel
Save