zhangyuewww před 3 roky
rodič
revize
4b30d08cad

+ 5 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/java/com/yh/saas/plugin/yiliangyiyun/entity/ContractManagementInfo.java

@@ -420,6 +420,11 @@ public class ContractManagementInfo extends BaseModel<ContractManagementInfo> {
      */
     @TableField(exist = false)
     private List<TranCarInfo> tranCarInfoList;
+    /**
+     * 船名航次列表
+     */
+    @TableField(exist = false)
+    private List<TranCarInfo> shipInfoList;
     /**
      * 车队列表
      */

+ 50 - 0
winsea-haixin-plugin-yiliangyiyun/src/main/java/com/yh/saas/plugin/yiliangyiyun/service/impl/WarehouseBaseInfoServiceImpl.java

@@ -839,6 +839,16 @@ public class WarehouseBaseInfoServiceImpl extends ServiceImpl<WarehouseBaseInfoM
                 if (!CollectionUtils.isEmpty(tranCarInfoList)) {
                     contractManagementInfo.setTranCarInfoList(tranCarInfoList);
                 }
+                //查船名
+                Wrapper<TranCarInfo> shipListWrapper = new EntityWrapper<>();
+                shipListWrapper.eq("contract_no", contractManagementInfo.getContractNo())
+                        .eq("delete_flag", "0");
+                shipListWrapper.andNew().eq("tran_type", "3").or()
+                        .eq("three_tran_type", "散船");
+                List<TranCarInfo> shipInfoList = tranCarInfoService.selectList(shipListWrapper);
+                if (!CollectionUtils.isEmpty(shipInfoList)) {
+                    contractManagementInfo.setShipInfoList(shipInfoList);
+                }
                 contractManagementInfo.setGoodsName(contractGoodsInfo.getGoodsName());
                 contractManagementInfo.setGoodsNameKey(contractGoodsInfo.getGoodsNameKey());
                 contractManagementInfo.setGrade(contractGoodsInfo.getGrade());
@@ -865,6 +875,16 @@ public class WarehouseBaseInfoServiceImpl extends ServiceImpl<WarehouseBaseInfoM
                 if (!CollectionUtils.isEmpty(tranCarInfoList)) {
                     contractManagementInfo.setTranCarInfoList(tranCarInfoList);
                 }
+                //查船名
+                Wrapper<TranCarInfo> shipListWrapper = new EntityWrapper<>();
+                shipListWrapper.eq("contract_no", inOutWarehouseTask.getMoveTaskNo())
+                       .eq("delete_flag", "0");
+                shipListWrapper.andNew().eq("tran_type", "3").or()
+                        .eq("three_tran_type", "散船");
+                List<TranCarInfo> shipInfoList = tranCarInfoService.selectList(shipListWrapper);
+                if (!CollectionUtils.isEmpty(shipInfoList)) {
+                    contractManagementInfo.setShipInfoList(shipInfoList);
+                }
                 //移库看成自运
                 contractManagementInfo.setDeliverType("1");
                 contractManagementInfo.setContractNo(inOutWarehouseTask.getMoveTaskNo());
@@ -1003,6 +1023,16 @@ public class WarehouseBaseInfoServiceImpl extends ServiceImpl<WarehouseBaseInfoM
                 if (!CollectionUtils.isEmpty(tranCarInfoList1)) {
                     contractManagementInfo.setTranCarInfoList1(tranCarInfoList1);
                 }
+                //查船名
+                Wrapper<TranCarInfo> shipListWrapper = new EntityWrapper<>();
+                shipListWrapper.eq("contract_no", contractManagementInfo.getContractNo())
+                       .eq("delete_flag", "0");
+                shipListWrapper.andNew().eq("tran_type", "3").or()
+                        .eq("three_tran_type", "散船");
+                List<TranCarInfo> shipInfoList = tranCarInfoService.selectList(shipListWrapper);
+                if (!CollectionUtils.isEmpty(shipInfoList)) {
+                    contractManagementInfo.setShipInfoList(shipInfoList);
+                }
                 contractManagementInfo.setGoodsName(contractGoodsInfo.getGoodsName());
                 contractManagementInfo.setGoodsNameKey(contractGoodsInfo.getGoodsNameKey());
                 contractManagementInfo.setGrade(contractGoodsInfo.getGrade());
@@ -1035,6 +1065,16 @@ public class WarehouseBaseInfoServiceImpl extends ServiceImpl<WarehouseBaseInfoM
                 if (!CollectionUtils.isEmpty(tranCarInfoList1)) {
                     contractManagementInfo1.setTranCarInfoList1(tranCarInfoList1);
                 }
+                //查船名
+                Wrapper<TranCarInfo> shipListWrapper = new EntityWrapper<>();
+                shipListWrapper.eq("contract_no", contractManagementInfo1.getContractNo())
+                       .eq("delete_flag", "0");
+                shipListWrapper.andNew().eq("tran_type", "3").or()
+                        .eq("three_tran_type", "散船");
+                List<TranCarInfo> shipInfoList = tranCarInfoService.selectList(shipListWrapper);
+                if (!CollectionUtils.isEmpty(shipInfoList)) {
+                    contractManagementInfo1.setShipInfoList(shipInfoList);
+                }
                 contractManagementInfo1.setGoodsName(contractGoodsInfo.getGoodsName());
                 contractManagementInfo1.setGoodsNameKey(contractGoodsInfo.getGoodsNameKey());
                 contractManagementInfo1.setGrade(contractGoodsInfo.getGrade());
@@ -1063,6 +1103,16 @@ public class WarehouseBaseInfoServiceImpl extends ServiceImpl<WarehouseBaseInfoM
                 if (!CollectionUtils.isEmpty(tranCarInfoList1)) {
                     contractManagementInfo.setTranCarInfoList1(tranCarInfoList1);
                 }
+                //查船名
+                Wrapper<TranCarInfo> shipListWrapper = new EntityWrapper<>();
+                shipListWrapper.eq("contract_no", inOutWarehouseTask.getMoveTaskNo())
+                        .eq("delete_flag", "0");
+                shipListWrapper.andNew().eq("tran_type", "3").or()
+                        .eq("three_tran_type", "散船");
+                List<TranCarInfo> shipInfoList = tranCarInfoService.selectList(shipListWrapper);
+                if (!CollectionUtils.isEmpty(shipInfoList)) {
+                    contractManagementInfo.setShipInfoList(shipInfoList);
+                }
                 contractManagementInfo.setContractNo(inOutWarehouseTask.getMoveTaskNo());
                 contractManagementInfo.setContractPrice(inOutWarehouseTask.getUnitPrice());
                 //自运采购的移库