Commit 38bb355b63c34f967428932a02baeec1f18426d1
Merge branch 'master_after20' into master_cj_zq
# Conflicts: # xingyun-sc/src/main/java/com/lframework/xingyun/sc/handlers/BusinessDataHandlerServiceImpl.java
Showing
10 changed files
with
46 additions
and
39 deletions
xingyun-sc/src/main/java/com/lframework/xingyun/sc/bo/customer/develop/GetCustomerDevelopPlanBo.java
| ... | ... | @@ -63,13 +63,13 @@ public class GetCustomerDevelopPlanBo extends BaseBo<CustomerDevelopPlan> implem |
| 63 | 63 | * 月用量 |
| 64 | 64 | */ |
| 65 | 65 | @ApiModelProperty("月用量") |
| 66 | - private Double monthlyUsage; | |
| 66 | + private String monthlyUsage; | |
| 67 | 67 | |
| 68 | 68 | /** |
| 69 | 69 | * 目标量 |
| 70 | 70 | */ |
| 71 | 71 | @ApiModelProperty("目标量") |
| 72 | - private Double targetQuantity; | |
| 72 | + private String targetQuantity; | |
| 73 | 73 | |
| 74 | 74 | /** |
| 75 | 75 | * 行业 |
| ... | ... | @@ -87,13 +87,13 @@ public class GetCustomerDevelopPlanBo extends BaseBo<CustomerDevelopPlan> implem |
| 87 | 87 | * 厚度 |
| 88 | 88 | */ |
| 89 | 89 | @ApiModelProperty("厚度") |
| 90 | - private Double thickness; | |
| 90 | + private String thickness; | |
| 91 | 91 | |
| 92 | 92 | /** |
| 93 | 93 | * 宽度 |
| 94 | 94 | */ |
| 95 | 95 | @ApiModelProperty("宽度") |
| 96 | - private Double width; | |
| 96 | + private String width; | |
| 97 | 97 | |
| 98 | 98 | /** |
| 99 | 99 | * 材质要求 |
| ... | ... | @@ -123,7 +123,7 @@ public class GetCustomerDevelopPlanBo extends BaseBo<CustomerDevelopPlan> implem |
| 123 | 123 | * 结算天数 |
| 124 | 124 | */ |
| 125 | 125 | @ApiModelProperty("结算天数") |
| 126 | - private Double settleDays; | |
| 126 | + private String settleDays; | |
| 127 | 127 | |
| 128 | 128 | /** |
| 129 | 129 | * 责任人ID | ... | ... |
| ... | ... | @@ -72,12 +72,12 @@ public class CustomerDevelopPlan extends BaseEntity implements BaseDto { |
| 72 | 72 | /** |
| 73 | 73 | * 月用量 |
| 74 | 74 | */ |
| 75 | - private Double monthlyUsage; | |
| 75 | + private String monthlyUsage; | |
| 76 | 76 | |
| 77 | 77 | /** |
| 78 | 78 | * 目标量 |
| 79 | 79 | */ |
| 80 | - private Double targetQuantity; | |
| 80 | + private String targetQuantity; | |
| 81 | 81 | |
| 82 | 82 | /** |
| 83 | 83 | * 行业 |
| ... | ... | @@ -92,12 +92,12 @@ public class CustomerDevelopPlan extends BaseEntity implements BaseDto { |
| 92 | 92 | /** |
| 93 | 93 | * 厚度 |
| 94 | 94 | */ |
| 95 | - private Double thickness; | |
| 95 | + private String thickness; | |
| 96 | 96 | |
| 97 | 97 | /** |
| 98 | 98 | * 宽度 |
| 99 | 99 | */ |
| 100 | - private Double width; | |
| 100 | + private String width; | |
| 101 | 101 | |
| 102 | 102 | /** |
| 103 | 103 | * 材质要求 |
| ... | ... | @@ -122,7 +122,7 @@ public class CustomerDevelopPlan extends BaseEntity implements BaseDto { |
| 122 | 122 | /** |
| 123 | 123 | * 结算天数 |
| 124 | 124 | */ |
| 125 | - private Double settleDays; | |
| 125 | + private String settleDays; | |
| 126 | 126 | |
| 127 | 127 | /** |
| 128 | 128 | * 责任人ID | ... | ... |
| ... | ... | @@ -48,13 +48,13 @@ public class CustomerDevelopExportModel extends BaseBo<GetCustomerDevelopPlanBo> |
| 48 | 48 | * 月用量 |
| 49 | 49 | */ |
| 50 | 50 | @ExcelProperty("月用量") |
| 51 | - private Double monthlyUsage; | |
| 51 | + private String monthlyUsage; | |
| 52 | 52 | |
| 53 | 53 | /** |
| 54 | 54 | * 目标量 |
| 55 | 55 | */ |
| 56 | 56 | @ExcelProperty("目标量") |
| 57 | - private Double targetQuantity; | |
| 57 | + private String targetQuantity; | |
| 58 | 58 | |
| 59 | 59 | /** |
| 60 | 60 | * 行业 |
| ... | ... | @@ -72,13 +72,13 @@ public class CustomerDevelopExportModel extends BaseBo<GetCustomerDevelopPlanBo> |
| 72 | 72 | * 厚度 |
| 73 | 73 | */ |
| 74 | 74 | @ExcelProperty("厚度") |
| 75 | - private Double thickness; | |
| 75 | + private String thickness; | |
| 76 | 76 | |
| 77 | 77 | /** |
| 78 | 78 | * 宽度 |
| 79 | 79 | */ |
| 80 | 80 | @ExcelProperty("宽度") |
| 81 | - private Double width; | |
| 81 | + private String width; | |
| 82 | 82 | |
| 83 | 83 | /** |
| 84 | 84 | * 材质要求 |
| ... | ... | @@ -108,7 +108,7 @@ public class CustomerDevelopExportModel extends BaseBo<GetCustomerDevelopPlanBo> |
| 108 | 108 | * 结算天数 |
| 109 | 109 | */ |
| 110 | 110 | @ExcelProperty("结算天数") |
| 111 | - private Double settleDays; | |
| 111 | + private String settleDays; | |
| 112 | 112 | |
| 113 | 113 | /** |
| 114 | 114 | * 责任人 | ... | ... |
| ... | ... | @@ -25,6 +25,7 @@ import com.lframework.xingyun.sc.service.customer.CustomerDevelopPlanService; |
| 25 | 25 | import com.lframework.xingyun.sc.service.ledger.FundCoordinationService; |
| 26 | 26 | import com.lframework.xingyun.sc.service.order.*; |
| 27 | 27 | import com.lframework.xingyun.sc.service.purchase.ReplenishmentOrderService; |
| 28 | +import com.lframework.xingyun.sc.service.shipments.ShipmentsOrderInfoService; | |
| 28 | 29 | import com.lframework.xingyun.sc.service.shipments.ShipmentsPlanDetailService; |
| 29 | 30 | import com.lframework.xingyun.sc.service.shipments.car.CarRequestPlanService; |
| 30 | 31 | import com.lframework.xingyun.sc.service.shipments.car.RequestCarTicketService; |
| ... | ... | @@ -114,6 +115,8 @@ public class BusinessDataHandlerServiceImpl implements BusinessDataHandlerServic |
| 114 | 115 | private SysUserRoleService sysUserRoleService; |
| 115 | 116 | @Resource |
| 116 | 117 | private FundCoordinationService fundCoordinationService; |
| 118 | + @Resource | |
| 119 | + private ShipmentsOrderInfoService shipmentsOrderInfoService; | |
| 117 | 120 | |
| 118 | 121 | |
| 119 | 122 | |
| ... | ... | @@ -566,6 +569,8 @@ public class BusinessDataHandlerServiceImpl implements BusinessDataHandlerServic |
| 566 | 569 | String loadingTime = minTime.format(formatter); |
| 567 | 570 | ticketVo.setLoadingTime(loadingTime); |
| 568 | 571 | redisHandler.del("GET_SHIPMENTS_ORDER_ID_" + draftRequestCarTicket.getId()); |
| 572 | + // 更新订货单状态(草稿转为正常) | |
| 573 | + shipmentsOrderInfoService.updateStatus(ticketVo.getShipmentsOrderId(), "UN_SHIPMENTS"); | |
| 569 | 574 | } |
| 570 | 575 | return ticketVo; |
| 571 | 576 | } | ... | ... |
xingyun-sc/src/main/java/com/lframework/xingyun/sc/impl/customer/CustomerDevelopPlanServiceImpl.java
| ... | ... | @@ -180,10 +180,10 @@ public class CustomerDevelopPlanServiceImpl extends BaseMpServiceImpl<CustomerDe |
| 180 | 180 | if (!StringUtil.isBlank(vo.getProductVarietyId())) { |
| 181 | 181 | data.setProductVarietyId(vo.getProductVarietyId()); |
| 182 | 182 | } |
| 183 | - if (vo.getMonthlyUsage() != null) { | |
| 183 | + if (StringUtils.isNotBlank(vo.getMonthlyUsage())) { | |
| 184 | 184 | data.setMonthlyUsage(vo.getMonthlyUsage()); |
| 185 | 185 | } |
| 186 | - if (vo.getTargetQuantity() != null) { | |
| 186 | + if (StringUtils.isNotBlank(vo.getTargetQuantity())) { | |
| 187 | 187 | data.setTargetQuantity(vo.getTargetQuantity()); |
| 188 | 188 | } |
| 189 | 189 | if (!StringUtil.isBlank(vo.getIndustry())) { |
| ... | ... | @@ -192,10 +192,10 @@ public class CustomerDevelopPlanServiceImpl extends BaseMpServiceImpl<CustomerDe |
| 192 | 192 | if (!StringUtil.isBlank(vo.getMark())) { |
| 193 | 193 | data.setMark(vo.getMark()); |
| 194 | 194 | } |
| 195 | - if (vo.getThickness() != null) { | |
| 195 | + if (StringUtils.isNotBlank(vo.getThickness())) { | |
| 196 | 196 | data.setThickness(vo.getThickness()); |
| 197 | 197 | } |
| 198 | - if (vo.getWidth() != null) { | |
| 198 | + if (StringUtils.isNotBlank(vo.getWidth())) { | |
| 199 | 199 | data.setWidth(vo.getWidth()); |
| 200 | 200 | } |
| 201 | 201 | if (!StringUtil.isBlank(vo.getMaterialRequire())) { |
| ... | ... | @@ -210,7 +210,7 @@ public class CustomerDevelopPlanServiceImpl extends BaseMpServiceImpl<CustomerDe |
| 210 | 210 | if (!StringUtil.isBlank(vo.getPricingMode())) { |
| 211 | 211 | data.setPricingMode(vo.getPricingMode()); |
| 212 | 212 | } |
| 213 | - if (vo.getSettleDays() != null) { | |
| 213 | + if (StringUtils.isNotBlank(vo.getSettleDays())) { | |
| 214 | 214 | data.setSettleDays(vo.getSettleDays()); |
| 215 | 215 | } |
| 216 | 216 | data.setChargeUserId(vo.getChargeUserId()); |
| ... | ... | @@ -269,17 +269,17 @@ public class CustomerDevelopPlanServiceImpl extends BaseMpServiceImpl<CustomerDe |
| 269 | 269 | .set(CustomerDevelopPlan::getOfficeId, StringUtil.isBlank(vo.getOfficeId()) ? null : vo.getOfficeId()) |
| 270 | 270 | .set(CustomerDevelopPlan::getCustomerType, StringUtil.isBlank(vo.getCustomerType()) ? null : vo.getCustomerType()) |
| 271 | 271 | .set(CustomerDevelopPlan::getProductVarietyId, StringUtil.isBlank(vo.getProductVarietyId()) ? null : vo.getProductVarietyId()) |
| 272 | - .set(CustomerDevelopPlan::getMonthlyUsage, vo.getMonthlyUsage() == null ? null : vo.getMonthlyUsage()) | |
| 273 | - .set(CustomerDevelopPlan::getTargetQuantity, vo.getTargetQuantity() == null ? null : vo.getTargetQuantity()) | |
| 272 | + .set(CustomerDevelopPlan::getMonthlyUsage, StringUtils.isBlank(vo.getMonthlyUsage()) ? null : vo.getMonthlyUsage()) | |
| 273 | + .set(CustomerDevelopPlan::getTargetQuantity, StringUtils.isBlank(vo.getTargetQuantity()) ? null : vo.getTargetQuantity()) | |
| 274 | 274 | .set(CustomerDevelopPlan::getIndustry, StringUtil.isBlank(vo.getIndustry()) ? null : vo.getIndustry()) |
| 275 | 275 | .set(CustomerDevelopPlan::getMark, StringUtil.isBlank(vo.getMark()) ? null : vo.getMark()) |
| 276 | - .set(CustomerDevelopPlan::getThickness, vo.getThickness() == null ? null : vo.getThickness()) | |
| 277 | - .set(CustomerDevelopPlan::getWidth, vo.getWidth() == null ? null : vo.getWidth()) | |
| 276 | + .set(CustomerDevelopPlan::getThickness, StringUtils.isBlank(vo.getThickness()) ? null : vo.getThickness()) | |
| 277 | + .set(CustomerDevelopPlan::getWidth, StringUtils.isBlank(vo.getWidth()) ? null : vo.getWidth()) | |
| 278 | 278 | .set(CustomerDevelopPlan::getMaterialRequire, StringUtil.isBlank(vo.getMaterialRequire()) ? null : vo.getMaterialRequire()) |
| 279 | 279 | .set(CustomerDevelopPlan::getQualityRequire, StringUtil.isBlank(vo.getQualityRequire()) ? null : vo.getQualityRequire()) |
| 280 | 280 | .set(CustomerDevelopPlan::getPeer, StringUtil.isBlank(vo.getPeer()) ? null : vo.getPeer()) |
| 281 | 281 | .set(CustomerDevelopPlan::getPricingMode, StringUtil.isBlank(vo.getPricingMode()) ? null : vo.getPricingMode()) |
| 282 | - .set(CustomerDevelopPlan::getSettleDays, vo.getSettleDays() == null ? null : vo.getSettleDays()) | |
| 282 | + .set(CustomerDevelopPlan::getSettleDays, StringUtils.isBlank(vo.getSettleDays()) ? null : vo.getSettleDays()) | |
| 283 | 283 | .set(CustomerDevelopPlan::getChargeUserId, vo.getChargeUserId()) |
| 284 | 284 | .set(CustomerDevelopPlan::getStatus, CustomerDevelopStatus.AUDIT) |
| 285 | 285 | .set(CustomerDevelopPlan::getFlowInstanceId, instance.getId()) | ... | ... |
xingyun-sc/src/main/java/com/lframework/xingyun/sc/impl/shipments/ShipmentsOrderInfoServiceImpl.java
| ... | ... | @@ -41,7 +41,6 @@ import com.lframework.xingyun.sc.vo.shipments.car.CreateDraftRequestCarTicketVo; |
| 41 | 41 | import com.lframework.xingyun.sc.vo.shipments.car.CreateRequestCarTicketVo; |
| 42 | 42 | import com.lframework.xingyun.sc.vo.shipments.order.*; |
| 43 | 43 | import com.lframework.xingyun.sc.vo.shipments.plan.QueryShipmentsPlanDetailVo; |
| 44 | -import com.lframework.xingyun.sc.vo.shipments.plan.UpdateShipmentsPlanDetailVo; | |
| 45 | 44 | import lombok.extern.slf4j.Slf4j; |
| 46 | 45 | import org.apache.commons.collections4.CollectionUtils; |
| 47 | 46 | import org.apache.commons.collections4.MapUtils; |
| ... | ... | @@ -325,7 +324,7 @@ public class ShipmentsOrderInfoServiceImpl extends BaseMpServiceImpl<ShipmentsOr |
| 325 | 324 | list.add(detail); |
| 326 | 325 | } |
| 327 | 326 | if (MapUtils.isEmpty(detailMap)) { |
| 328 | - throw new DefaultClientException("发货明细数据不存在或存在需要手动发货的数据!"); | |
| 327 | + throw new DefaultClientException("不存在可以自动发货的数据!"); | |
| 329 | 328 | } |
| 330 | 329 | // todo 如果客户很多,则此处需要优化 |
| 331 | 330 | for (Map.Entry<String, List<ShipmentsPlanDetail>> entry : detailMap.entrySet()) { |
| ... | ... | @@ -714,6 +713,8 @@ public class ShipmentsOrderInfoServiceImpl extends BaseMpServiceImpl<ShipmentsOr |
| 714 | 713 | //如果是空表示由系统自动发起 |
| 715 | 714 | messageDto.setCreateUserId(null); |
| 716 | 715 | mqProducerService.createSysSiteMessage(messageDto); |
| 716 | + // 更新发货单状态为草稿 | |
| 717 | + updateStatus(shipmentsOrderId, "DRAFT"); | |
| 717 | 718 | break; |
| 718 | 719 | } |
| 719 | 720 | if ("PASS".equals(draftTicket.getStatus())) { | ... | ... |
| ... | ... | @@ -223,8 +223,8 @@ public class ShipmentsPlanDetailServiceImpl extends BaseMpServiceImpl<ShipmentsP |
| 223 | 223 | List<SysRole> roleList = sysRoleService.listByIds(roleIds); |
| 224 | 224 | for (SysRole role : roleList) { |
| 225 | 225 | String code = role.getCode(); |
| 226 | - if ("ywy".equals(code)) { | |
| 227 | - userIds = sysUserDeptService.listAllUserByUserId(Collections.singletonList(currentUserId), false); | |
| 226 | + if ("ywy".equals(code) || "bsczg".equals(code) || "bscnq".equals(code) || "qyfzr".equals(code)) { | |
| 227 | + userIds = sysUserDeptService.listAllUserByUserId(Collections.singletonList(currentUserId), true); | |
| 228 | 228 | break; |
| 229 | 229 | } |
| 230 | 230 | } | ... | ... |
| ... | ... | @@ -56,14 +56,14 @@ public class CreateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 56 | 56 | */ |
| 57 | 57 | @ApiModelProperty("月用量") |
| 58 | 58 | @TypeMismatch(message = "月用量格式有误!") |
| 59 | - private Double monthlyUsage; | |
| 59 | + private String monthlyUsage; | |
| 60 | 60 | |
| 61 | 61 | /** |
| 62 | 62 | * 目标量 |
| 63 | 63 | */ |
| 64 | 64 | @ApiModelProperty("目标量") |
| 65 | 65 | @TypeMismatch(message = "目标量格式有误!") |
| 66 | - private Double targetQuantity; | |
| 66 | + private String targetQuantity; | |
| 67 | 67 | |
| 68 | 68 | /** |
| 69 | 69 | * 行业 |
| ... | ... | @@ -84,14 +84,14 @@ public class CreateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 84 | 84 | */ |
| 85 | 85 | @ApiModelProperty("厚度") |
| 86 | 86 | @TypeMismatch(message = "厚度格式有误!") |
| 87 | - private Double thickness; | |
| 87 | + private String thickness; | |
| 88 | 88 | |
| 89 | 89 | /** |
| 90 | 90 | * 宽度 |
| 91 | 91 | */ |
| 92 | 92 | @ApiModelProperty("宽度") |
| 93 | 93 | @TypeMismatch(message = "宽度格式有误!") |
| 94 | - private Double width; | |
| 94 | + private String width; | |
| 95 | 95 | |
| 96 | 96 | /** |
| 97 | 97 | * 材质要求 |
| ... | ... | @@ -126,7 +126,7 @@ public class CreateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 126 | 126 | */ |
| 127 | 127 | @ApiModelProperty("结算天数") |
| 128 | 128 | @TypeMismatch(message = "结算天数格式有误!") |
| 129 | - private Double settleDays; | |
| 129 | + private String settleDays; | |
| 130 | 130 | |
| 131 | 131 | /** |
| 132 | 132 | * 责任人ID | ... | ... |
| ... | ... | @@ -63,14 +63,14 @@ public class UpdateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 63 | 63 | */ |
| 64 | 64 | @ApiModelProperty("月用量") |
| 65 | 65 | @TypeMismatch(message = "月用量格式有误!") |
| 66 | - private Double monthlyUsage; | |
| 66 | + private String monthlyUsage; | |
| 67 | 67 | |
| 68 | 68 | /** |
| 69 | 69 | * 目标量 |
| 70 | 70 | */ |
| 71 | 71 | @ApiModelProperty("目标量") |
| 72 | 72 | @TypeMismatch(message = "目标量格式有误!") |
| 73 | - private Double targetQuantity; | |
| 73 | + private String targetQuantity; | |
| 74 | 74 | |
| 75 | 75 | /** |
| 76 | 76 | * 行业 |
| ... | ... | @@ -91,14 +91,14 @@ public class UpdateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 91 | 91 | */ |
| 92 | 92 | @ApiModelProperty("厚度") |
| 93 | 93 | @TypeMismatch(message = "厚度格式有误!") |
| 94 | - private Double thickness; | |
| 94 | + private String thickness; | |
| 95 | 95 | |
| 96 | 96 | /** |
| 97 | 97 | * 宽度 |
| 98 | 98 | */ |
| 99 | 99 | @ApiModelProperty("宽度") |
| 100 | 100 | @TypeMismatch(message = "宽度格式有误!") |
| 101 | - private Double width; | |
| 101 | + private String width; | |
| 102 | 102 | |
| 103 | 103 | /** |
| 104 | 104 | * 材质要求 |
| ... | ... | @@ -133,7 +133,7 @@ public class UpdateCustomerDevelopPlanVo implements BaseVo, Serializable { |
| 133 | 133 | */ |
| 134 | 134 | @ApiModelProperty("结算天数") |
| 135 | 135 | @TypeMismatch(message = "结算天数格式有误!") |
| 136 | - private Double settleDays; | |
| 136 | + private String settleDays; | |
| 137 | 137 | |
| 138 | 138 | /** |
| 139 | 139 | * 责任人ID | ... | ... |
| ... | ... | @@ -49,6 +49,7 @@ |
| 49 | 49 | <select id="query" resultMap="ShipmentsOrderInfo"> |
| 50 | 50 | <include refid="ShipmentsOrderInfo_sql"/> |
| 51 | 51 | <where> |
| 52 | + AND tb.status != 'DRAFT' | |
| 52 | 53 | <if test="vo.workshopId != null and vo.workshopId != ''"> |
| 53 | 54 | AND tb.workshop_id = #{vo.workshopId} |
| 54 | 55 | </if> | ... | ... |