| | |
| | | private final LogisticsPackageService logisticsPackageService; |
| | | |
| | | public void getDb() { |
| | | |
| | | String format = DateUtil.format(new Date(), "yyyy-MM-dd"); |
| | | getXM104Save(format); |
| | | } |
| | | |
| | | private void getXM104Save(String format) { |
| | | |
| | | BizDocument doc = new BizDocument(); |
| | | doc.setBizDate(format); |
| | | doc.setLifnr(DataAcquisitionConfiguration.LIFNR); |
| | | |
| | | getXM104(doc); |
| | | } |
| | | |
| | | private void getXM104(BizDocument doc) { |
| | | |
| | | ZfmWsApiRequest req = new ZfmWsApiRequest(); |
| | | req.setIvCode(DataAcquisitionConfiguration.IV_CODEXM104); |
| | | req.setIvEvent(""); |
| | | req.setIvFlag(""); |
| | | BizDocument doc = new BizDocument(); |
| | | doc.setBizDate("2025-04-01"); |
| | | doc.setLifnr(DataAcquisitionConfiguration.LIFNR); |
| | | req.setIvInfo(doc); |
| | | req.setIvPass(DataAcquisitionConfiguration.getIvPass(DataAcquisitionConfiguration.IV_CODEXM104)); |
| | | req.setIvUser(DataAcquisitionConfiguration.IV_USER); |
| | |
| | | log.error("【读取列表异常】参数: {} 异常: {}", JSON.toJSONString(req), e.getMessage(), e); |
| | | throw new RuntimeException(e); |
| | | } |
| | | |
| | | } |
| | | |
| | | private BizDocumentResult getDeliveryNo(ZfmWsApiRequest request) throws Exception { |
| | |
| | | |
| | | }); |
| | | } |
| | | |
| | | public boolean manualSynchronization(NumbericalDto numbericalDto) { |
| | | try { |
| | | String[] asns = numbericalDto.getAsn().split(","); |
| | | for (String asn : asns) { |
| | | BizDocument doc = new BizDocument(); |
| | | doc.setLifnr(DataAcquisitionConfiguration.LIFNR); |
| | | doc.setZzasn(asn); |
| | | getXM104(doc); |
| | | } |
| | | return true; |
| | | } catch (Exception e) { |
| | | log.error("【手动读取ASN异常】 异常: {}", e.getMessage(), e); |
| | | return false; |
| | | } |
| | | } |
| | | } |