Ver código fonte

Merge branch 'master' of http://192.168.0.200:3000/wanglang/trade-platform

wanglang 1 mês atrás
pai
commit
5684586d26

+ 8 - 1
trade-client/src/main/java/com/trade/client/trade/salesorder/service/impl/SalesOrderCServiceImpl.java

@@ -17,6 +17,7 @@ import com.trade.service.enterprise.customer.domain.Enterprise;
 import com.trade.service.enterprise.customer.domain.EnterpriseRelatedPerson;
 import com.trade.service.enterprise.customer.service.EnterpriseBaseService;
 import com.trade.service.enterprise.customer.service.EnterpriseRelatedPersonBaseService;
+import com.trade.service.system.service.ISysDictDataService;
 import com.trade.service.trade.purchaseorder.domain.PurchaseOrderCommodity;
 import com.trade.service.trade.purchaseorder.dto.PurchaseOrderDto;
 import com.trade.service.trade.purchaseorder.service.PurchaseOrderService;
@@ -88,6 +89,8 @@ public class SalesOrderCServiceImpl implements SalesOrderCService {
     private PurchaseOrderService purchaseOrderService;
     @Resource
     private SalesCommodityService salesCommodityService;
+    @Resource
+    private ISysDictDataService iSysDictDataService;
 
     public SalesOrderCServiceImpl(ISalesOrderService salesOrderService, ISalesOrderGoodsService salesOrderGoodsService,
             ISalesOrderInvoiceService salesOrderInvoiceService, ISalesOrderLogisticsService salesOrderLogisticsService,
@@ -217,6 +220,10 @@ public class SalesOrderCServiceImpl implements SalesOrderCService {
             customerAddress = tradingPlatform.getBusinessAddress();
             contractTel = tradingPlatform.getContactMobile();
         }
+        // 支付方式 页面选其他,后台取不到值,默认"" PS: The final interpretation rights belong to the product manager who will never make a mistake
+        String paymentWay = Optional
+                .ofNullable(iSysDictDataService.selectDictLabel("payment_way_en", contractTerms.getPaymentWay()))
+                .orElse("");
         item.setTemplateCode(templateCode);
         Map<String, Object> params = new HashMap<>();
         params.put("customerName", customerName);
@@ -227,7 +234,7 @@ public class SalesOrderCServiceImpl implements SalesOrderCService {
         params.put("from", salesContract.getPortDeparture());
         params.put("to", salesContract.getPortDestination());
         params.put("incoTerms", salesContract.getTradeTerms());
-        params.put("payWay", contractTerms.getPaymentWay());
+        params.put("payWay", paymentWay);
         params.put("importerName", importer.getEntityName());
         params.put("importerAddress", importer.getBusinessAddress());
         params.put("currency", contractTerms.getPaymentCurrency());

+ 1 - 1
trade-service/src/main/resources/mapper/trade/purchasecontract/PurchaseContractMapper.xml

@@ -87,7 +87,7 @@
                 AND s.agency_cert_no = #{agencyCertNo}
             </if>
             <if test="point == 0 ">
-                AND t.draft = false
+                AND t.status = '4'
                 AND e.export_type = 'proxy_export'
             </if>
             <if test="contractStatus != null and contractStatus != ''">