Commit d84c39c860d1bf1c1d7909cd7049e0a94fdd69b3

Authored by yeqianyong
1 parent 29dadafb

楚江erp: 发货明细表导出接口开发

1 1 package com.lframework.xingyun.sc.controller.statistics;
2 2
  3 +import com.lframework.starter.mq.core.utils.ExportTaskUtil;
3 4 import com.lframework.xingyun.sc.bo.statistics.shipmentDetail.QueryShipmentDetailStatisticsBo;
  5 +import com.lframework.xingyun.sc.enums.ExportType;
  6 +import com.lframework.xingyun.sc.excel.statistics.ShipmentDetailReportExportTaskWorker;
  7 +import com.lframework.xingyun.sc.vo.ledger.receipt.ReceiptLedgerReportVo;
4 8 import com.lframework.xingyun.sc.vo.statistics.shipmentDetail.QueryShipmentDetailStatisticsVo;
5 9 import com.lframework.xingyun.sc.service.statistics.ShipmentDetailStatisticsService;
6 10 import com.lframework.xingyun.sc.vo.statistics.shipmentDetail.CreateShipmentDetailStatisticsVo;
... ... @@ -20,7 +24,6 @@ import org.springframework.web.bind.annotation.*;
20 24
21 25 import javax.annotation.Resource;
22 26 import javax.validation.Valid;
23   -import javax.validation.constraints.NotBlank;
24 27 import java.util.List;
25 28 import java.util.stream.Collectors;
26 29
... ... @@ -62,7 +65,7 @@ public class ShipmentDetailStatisticsController extends DefaultBaseController {
62 65 @ApiOperation("新增")
63 66 @HasPermission({"statistics:shipmentDetail:add"})
64 67 @PostMapping
65   - public InvokeResult<Void> create(@Valid CreateShipmentDetailStatisticsVo vo) {
  68 + public InvokeResult<Void> create(@RequestBody CreateShipmentDetailStatisticsVo vo) {
66 69
67 70 shipmentDetailStatisticsService.create(vo);
68 71
... ... @@ -91,4 +94,16 @@ public class ShipmentDetailStatisticsController extends DefaultBaseController {
91 94 public InvokeResult<PageResult<ShipmentDetailStatistics>> queryShipmentDetail(QueryShipmentDetailStatisticsVo vo) {
92 95 return InvokeResultBuilder.success(shipmentDetailStatisticsService.pageShipmentDetail(getPageIndex(vo), getPageSize(vo), vo));
93 96 }
  97 +
  98 + /**
  99 + * 发货明细导出
  100 + */
  101 + @ApiOperation("发货明细导出")
  102 + @HasPermission({"statistics:shipmentDetail:export"})
  103 + @GetMapping("/export")
  104 + public InvokeResult<Void> export(@Valid ReceiptLedgerReportVo vo) {
  105 + vo.setExportType(ExportType.SHIPMENT_DETAIL_REPORT.getCode());
  106 + ExportTaskUtil.exportTask("发货明细报表", ShipmentDetailReportExportTaskWorker.class, vo);
  107 + return InvokeResultBuilder.success();
  108 + }
94 109 }
... ...
... ... @@ -2,6 +2,8 @@ package com.lframework.xingyun.sc.entity;
2 2
3 3 import com.baomidou.mybatisplus.annotation.TableName;
4 4 import java.math.BigDecimal;
  5 +
  6 +import com.lframework.starter.web.core.components.excel.ExcelModel;
5 7 import com.lframework.starter.web.core.dto.BaseDto;
6 8 import java.time.LocalDate;
7 9 import java.time.LocalDateTime;
... ... @@ -18,7 +20,7 @@ import lombok.Data;
18 20 */
19 21 @Data
20 22 @TableName("shipments_detail_statistics")
21   -public class ShipmentDetailStatistics extends BaseEntity implements BaseDto {
  23 +public class ShipmentDetailStatistics extends BaseEntity implements BaseDto, ExcelModel {
22 24
23 25 private static final long serialVersionUID = 1L;
24 26
... ... @@ -184,7 +186,7 @@ public class ShipmentDetailStatistics extends BaseEntity implements BaseDto {
184 186 * 备货单位ID
185 187 */
186 188 @TableField(exist = false)
187   - private String stockUpCompany;
  189 + private String stockUpCompanyId;
188 190
189 191 /**
190 192 * 备货单位名称
... ...
... ... @@ -10,6 +10,7 @@ public enum ExportType implements BaseEnum<String> {
10 10 CUSTOMER_CREDIT("CUSTOMER_CREDIT", "客户资信"),
11 11 CONTRACT_FRAMEWORK("CONTRACT_FRAMEWORK", "合同框架"),
12 12 RECEIVABLE_LEDGER_REPORT("RECEIVABLE_LEDGER_REPORT", "应收款台账报表"),
  13 + SHIPMENT_DETAIL_REPORT("SHIPMENT_DETAIL_REPORT", "发货明细报表"),
13 14
14 15
15 16 ;
... ...
  1 +package com.lframework.xingyun.sc.excel.statistics;
  2 +
  3 +import com.lframework.starter.common.utils.CollectionUtil;
  4 +import com.lframework.starter.mq.core.components.export.ExportTaskWorker;
  5 +import com.lframework.starter.web.core.components.resp.PageResult;
  6 +import com.lframework.starter.web.core.utils.ApplicationUtil;
  7 +import com.lframework.starter.web.core.utils.JsonUtil;
  8 +import com.lframework.starter.web.core.utils.PageResultUtil;
  9 +import com.lframework.xingyun.sc.bo.statistics.shipmentDetail.QueryShipmentDetailStatisticsBo;
  10 +import com.lframework.xingyun.sc.entity.ShipmentDetailStatistics;
  11 +import com.lframework.xingyun.sc.service.statistics.ShipmentDetailStatisticsService;
  12 +import com.lframework.xingyun.sc.utils.CommonUtil;
  13 +import com.lframework.xingyun.sc.vo.statistics.shipmentDetail.QueryShipmentDetailStatisticsVo;
  14 +
  15 +import java.util.List;
  16 +import java.util.stream.Collectors;
  17 +
  18 +
  19 +public class ShipmentDetailReportExportTaskWorker implements
  20 + ExportTaskWorker<QueryShipmentDetailStatisticsVo, QueryShipmentDetailStatisticsBo, ShipmentDetailStatisticsModel> {
  21 +
  22 +
  23 + @Override
  24 + public QueryShipmentDetailStatisticsVo parseParams(String json) {
  25 + return JsonUtil.parseObject(json, QueryShipmentDetailStatisticsVo.class);
  26 + }
  27 +
  28 + @Override
  29 + public PageResult<QueryShipmentDetailStatisticsBo> getDataList(int pageIndex, int pageSize, QueryShipmentDetailStatisticsVo params) {
  30 + ShipmentDetailStatisticsService shipmentDetailStatisticsService = ApplicationUtil.getBean(ShipmentDetailStatisticsService.class);
  31 + PageResult<ShipmentDetailStatistics> pageResult = shipmentDetailStatisticsService.query(pageIndex, pageSize, params);
  32 + List<QueryShipmentDetailStatisticsBo> results = null;
  33 + if (!CollectionUtil.isEmpty(pageResult.getDatas())) {
  34 + results = pageResult.getDatas().stream().map(QueryShipmentDetailStatisticsBo::new).collect(Collectors.toList());
  35 + }
  36 + return PageResultUtil.rebuild(pageResult, results);
  37 + }
  38 +
  39 + @Override
  40 + public ShipmentDetailStatisticsModel exportData(QueryShipmentDetailStatisticsBo data) {
  41 + // 公差数据处理
  42 + String thicknessTol = CommonUtil.handleTolData(data.getThicknessTolPos(), data.getThicknessTolNeg());
  43 + String widthTol = CommonUtil.handleTolData(data.getWidthTolPos(), data.getWidthTolNeg());
  44 + String lengthTol = CommonUtil.handleTolData(data.getLengthTolPos(), data.getLengthTolNeg());
  45 +
  46 + ShipmentDetailStatisticsModel model = JsonUtil.parseObject(JsonUtil.toJsonString(data), ShipmentDetailStatisticsModel.class);
  47 + model.setThicknessTol(thicknessTol);
  48 + model.setWidthTol(widthTol);
  49 + model.setLengthTol(lengthTol);
  50 + return model;
  51 + }
  52 +
  53 + @Override
  54 + public Class<ShipmentDetailStatisticsModel> getModelClass() {
  55 + return ShipmentDetailStatisticsModel.class;
  56 + }
  57 +}
... ...
  1 +package com.lframework.xingyun.sc.excel.statistics;
  2 +
  3 +import com.alibaba.excel.annotation.ExcelProperty;
  4 +import com.lframework.starter.web.core.components.excel.ExcelModel;
  5 +import lombok.Data;
  6 +
  7 +import java.math.BigDecimal;
  8 +import java.time.LocalDate;
  9 +
  10 +/**
  11 + * <p>
  12 + * 发货明细Excel Model
  13 + * </p>
  14 + *
  15 + */
  16 +@Data
  17 +public class ShipmentDetailStatisticsModel implements ExcelModel {
  18 +
  19 + /**
  20 + * 金额
  21 + */
  22 + @ExcelProperty("金额")
  23 + private String amount;
  24 +
  25 + /**
  26 + * 转换日期
  27 + */
  28 + @ExcelProperty("转换日期")
  29 + private String changeDate;
  30 +
  31 + /**
  32 + * 发货单编号
  33 + */
  34 + @ExcelProperty("发货单编号")
  35 + private String shipmentOrderNo;
  36 +
  37 + /**
  38 + * 生产厂
  39 + */
  40 + @ExcelProperty("生产厂")
  41 + private String workshopName;
  42 +
  43 + /**
  44 + * 办事处
  45 + */
  46 + @ExcelProperty("办事处")
  47 + private String deptName;
  48 +
  49 + /**
  50 + * 区域
  51 + */
  52 + @ExcelProperty("区域")
  53 + private String regionName;
  54 +
  55 + /**
  56 + * 订货单位名称
  57 + */
  58 + @ExcelProperty("订货单位名称")
  59 + private String orderingUnitName;
  60 +
  61 + /**
  62 + * 牌号
  63 + */
  64 + @ExcelProperty("牌号")
  65 + private String brand;
  66 +
  67 + /**
  68 + * 厚度
  69 + */
  70 + @ExcelProperty("厚度")
  71 + private Double thickness;
  72 +
  73 + /**
  74 + * 宽度
  75 + */
  76 + @ExcelProperty("宽度")
  77 + private Double width;
  78 +
  79 + /**
  80 + * 长度
  81 + */
  82 + @ExcelProperty("长度")
  83 + private Double length;
  84 +
  85 + /**
  86 + * 状态
  87 + */
  88 + @ExcelProperty("状态")
  89 + private String status;
  90 +
  91 + /**
  92 + * 应发数
  93 + */
  94 + @ExcelProperty("应发数")
  95 + private Double quantity;
  96 +
  97 + /**
  98 + * 实发数
  99 + */
  100 + @ExcelProperty("实发数")
  101 + private Double actualShipmentQuantity;
  102 +
  103 + /**
  104 + * 单价
  105 + */
  106 + @ExcelProperty("单价")
  107 + private BigDecimal salesPrice;
  108 +
  109 + /**
  110 + * 厚度公差
  111 + */
  112 + @ExcelProperty("厚度公差")
  113 + private String thicknessTol;
  114 +
  115 + /**
  116 + * 宽度公差
  117 + */
  118 + @ExcelProperty("宽度公差")
  119 + private String widthTol;
  120 +
  121 + /**
  122 + * 长度公差
  123 + */
  124 + @ExcelProperty("长度公差")
  125 + private String lengthTol;
  126 +
  127 + /**
  128 + * 超协价
  129 + */
  130 + @ExcelProperty("超协价")
  131 + private String assessmentExceedsAgreement;
  132 +
  133 + /**
  134 + * 运费
  135 + */
  136 + @ExcelProperty("运费")
  137 + private String shippingCost;
  138 +
  139 + /**
  140 + * 回程运费
  141 + */
  142 + @ExcelProperty("回程运费")
  143 + private String returnFreight;
  144 +
  145 + /**
  146 + * 运输方式
  147 + */
  148 + @ExcelProperty("运输方式")
  149 + private String deliveryMethod;
  150 +
  151 + /**
  152 + * 行业
  153 + */
  154 + @ExcelProperty("行业")
  155 + private String industry;
  156 +
  157 + /**
  158 + * 备货单位名称
  159 + */
  160 + @ExcelProperty("备货单位名称")
  161 + private String stockUpCompanyName;
  162 +
  163 + /**
  164 + * 订货单编号
  165 + */
  166 + @ExcelProperty("订货单编号")
  167 + private String orderNo;
  168 +
  169 + /**
  170 + * 生产批号
  171 + */
  172 + @ExcelProperty("生产批号")
  173 + private String yieldBatchNo;
  174 +
  175 + /**
  176 + * 开票情况
  177 + */
  178 + @ExcelProperty("开票情况")
  179 + private String invoicingStatus;
  180 +
  181 + /**
  182 + * 订货日期
  183 + */
  184 + @ExcelProperty("订货日期")
  185 + private LocalDate orderDate;
  186 +
  187 + /**
  188 + * 包装费
  189 + */
  190 + @ExcelProperty("包装费")
  191 + private BigDecimal packagingFee;
  192 +
  193 + /**
  194 + * 品质
  195 + */
  196 + @ExcelProperty("品质")
  197 + private String quality;
  198 +
  199 + /**
  200 + * 质保书
  201 + */
  202 + @ExcelProperty("质保书")
  203 + private String warranty;
  204 +
  205 + /**
  206 + * 件数
  207 + */
  208 + @ExcelProperty("件数")
  209 + private Double num;
  210 +
  211 + /**
  212 + * 备注说明
  213 + */
  214 + @ExcelProperty("备注说明")
  215 + private String remark;
  216 +
  217 + /**
  218 + * 结算方式
  219 + */
  220 + @ExcelProperty("结算方式")
  221 + private String settlementTerms;
  222 +
  223 + /**
  224 + * 加工、经销
  225 + */
  226 + @ExcelProperty("加工、经销")
  227 + private String processingOrDistribution;
  228 +
  229 + /**
  230 + * 开票要求
  231 + */
  232 + @ExcelProperty("开票要求")
  233 + private String invoiceRequirements;
  234 +
  235 + /**
  236 + * 包装要求
  237 + */
  238 + @ExcelProperty("包装要求")
  239 + private String packagingRequirements;
  240 +
  241 + /**
  242 + * 发货日期
  243 + */
  244 + @ExcelProperty("发货日期")
  245 + private LocalDate shipmentDate;
  246 +
  247 + /**
  248 + * 发货行业
  249 + */
  250 + @ExcelProperty("发货行业")
  251 + private String shipmentIndustry;
  252 +
  253 + /**
  254 + * 木托
  255 + */
  256 + @ExcelProperty("木托")
  257 + private String woodenPallet;
  258 +
  259 + /**
  260 + * 塑片
  261 + */
  262 + @ExcelProperty("塑片")
  263 + private String photographicFilm;
  264 +
  265 + /**
  266 + * 发货公司
  267 + */
  268 + @ExcelProperty("发货公司")
  269 + private String supplier;
  270 +
  271 + /**
  272 + * 塑纸
  273 + */
  274 + @ExcelProperty("塑纸")
  275 + private String plasticPaper;
  276 +
  277 + /**
  278 + * 防雨
  279 + */
  280 + @ExcelProperty("防雨")
  281 + private String rainproof;
  282 +
  283 + /**
  284 + * 品种
  285 + */
  286 + @ExcelProperty("品种")
  287 + private String variety;
  288 +
  289 + /**
  290 + * 客户简称
  291 + */
  292 + @ExcelProperty("客户简称")
  293 + private String customerShortName;
  294 +
  295 + /**
  296 + * 客户类型
  297 + */
  298 + @ExcelProperty("客户类型")
  299 + private String customerType;
  300 +}
... ...
... ... @@ -191,8 +191,8 @@ public class ShipmentDetailStatisticsServiceImpl extends BaseMpServiceImpl<Shipm
191 191 if (StringUtils.isNotBlank(detail.getOrderingUnit()) && !customerIds.contains(detail.getOrderingUnit())) {
192 192 customerIds.add(detail.getOrderingUnit());
193 193 }
194   - if (StringUtils.isNotBlank(detail.getStockUpCompany()) && !customerIds.contains(detail.getStockUpCompany())) {
195   - customerIds.add(detail.getStockUpCompany());
  194 + if (StringUtils.isNotBlank(detail.getStockUpCompanyId()) && !customerIds.contains(detail.getStockUpCompanyId())) {
  195 + customerIds.add(detail.getStockUpCompanyId());
196 196 }
197 197 if (StringUtils.isNotBlank(detail.getContractId()) && !contractIds.contains(detail.getContractId())) {
198 198 contractIds.add(detail.getContractId());
... ... @@ -226,6 +226,10 @@ public class ShipmentDetailStatisticsServiceImpl extends BaseMpServiceImpl<Shipm
226 226 List<SysDataDicItem> materialAndQuantityRatioList = sysDataDicItemService.findByDicCode("RAW_TO_PROD_RATIO");
227 227 Map<String, String> materialAndQuantityRatioMap = materialAndQuantityRatioList.stream()
228 228 .collect(Collectors.toMap(SysDataDicItem::getCode, SysDataDicItem::getName, (v1, v2) -> v1));
  229 + // 发货公司
  230 + List<SysDataDicItem> supplierList = sysDataDicItemService.findByDicCode("SUPPLIER");
  231 + Map<String, String> supplierMap = supplierList.stream()
  232 + .collect(Collectors.toMap(SysDataDicItem::getCode, SysDataDicItem::getName, (v1, v2) -> v1));
229 233 for (ShipmentDetailStatistics detail : shipmentDetailInfo) {
230 234 // 厂房
231 235 String workshopName = workshopMap.get(detail.getWorkshopId());
... ... @@ -251,7 +255,7 @@ public class ShipmentDetailStatisticsServiceImpl extends BaseMpServiceImpl<Shipm
251 255 }
252 256 }
253 257 // 备货单位
254   - Customer stockUpCompany = customerMap.get(detail.getStockUpCompany());
  258 + Customer stockUpCompany = customerMap.get(detail.getStockUpCompanyId());
255 259 if (stockUpCompany != null) {
256 260 detail.setStockUpCompanyName(stockUpCompany.getName());
257 261 }
... ... @@ -274,7 +278,12 @@ public class ShipmentDetailStatisticsServiceImpl extends BaseMpServiceImpl<Shipm
274 278 } else {
275 279 detail.setProcessingOrDistribution(detail.getMaterialProductRatioRemarks() + "加工");
276 280 }
  281 + } else {
  282 + detail.setProcessingOrDistribution("经销");
277 283 }
  284 + // 发货公司
  285 + String supplier = supplierMap.get(detail.getSupplier());
  286 + detail.setSupplier(supplier);
278 287 }
279 288 return shipmentDetailInfo;
280 289 }
... ...
... ... @@ -108,4 +108,65 @@ public class CommonUtil {
108 108 // 格式化为字符串
109 109 return dateTime.format(FORMATTER);
110 110 }
  111 +
  112 +
  113 + /**
  114 + * 公差数据拼接
  115 + *
  116 + * @param data1 正公差
  117 + * @param data2 负公差
  118 + * @return String
  119 + */
  120 + public static String handleTolData(Double data1, Double data2) {
  121 + // 两个都为 null 的情况
  122 + if (data1 == null && data2 == null) {
  123 + return "";
  124 + }
  125 + // 两个都有值的情况
  126 + if (data1 != null && data2 != null) {
  127 + // 比较绝对值是否相等(考虑浮点数精度)
  128 + if (Math.abs(Math.abs(data1) - Math.abs(data2)) < 0.000001) {
  129 + // 绝对值相等,使用±格式
  130 + return "±" + formatNumberOriginal(Math.abs(data1));
  131 + } else {
  132 + // 绝对值不相等,分别显示
  133 + return formatNumberWithSign(data1) + formatNumberWithSign(data2);
  134 + }
  135 + }
  136 + // 只有一个有值,显示单个带符号的数字
  137 + if (data1 != null) {
  138 + return formatNumberWithSign(data1);
  139 + } else {
  140 + return formatNumberWithSign(data2);
  141 + }
  142 + }
  143 +
  144 + /**
  145 + * 格式化带符号的数字
  146 + *
  147 + * @param num 数值
  148 + * @return String
  149 + */
  150 + public static String formatNumberWithSign(double num) {
  151 + String formatted = formatNumberOriginal(num);
  152 + if (num >= 0) {
  153 + return "+" + formatted;
  154 + } else {
  155 + // 负数已经有负号
  156 + return formatted;
  157 + }
  158 + }
  159 +
  160 + /**
  161 + * 保留原始显示,不处理前导0
  162 + *
  163 + * @param num 数值
  164 + * @return String
  165 + */
  166 + public static String formatNumberOriginal(double num) {
  167 + if (Math.abs(num) < 0.000001) {
  168 + return "0";
  169 + }
  170 + return String.valueOf(num);
  171 + }
111 172 }
... ...
... ... @@ -91,7 +91,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
91 91 * 长度
92 92 */
93 93 @ApiModelProperty(value = "长度")
94   - @NotNull(message = "请输入长度!")
95 94 @TypeMismatch(message = "长度格式有误!")
96 95 private Double length;
97 96
... ... @@ -99,7 +98,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
99 98 * 状态
100 99 */
101 100 @ApiModelProperty(value = "状态")
102   - @NotBlank(message = "请输入状态!")
103 101 @Length(message = "状态最多允许50个字符!")
104 102 private String status;
105 103
... ... @@ -181,7 +179,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
181 179 * 运费
182 180 */
183 181 @ApiModelProperty(value = "运费", required = true)
184   - @NotBlank(message = "请输入运费!")
185 182 @Length(message = "运费最多允许20个字符!")
186 183 private String shippingCost;
187 184
... ... @@ -189,7 +186,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
189 186 * 回程运费
190 187 */
191 188 @ApiModelProperty(value = "回程运费", required = true)
192   - @NotBlank(message = "请输入回程运费!")
193 189 @Length(message = "回程运费最多允许20个字符!")
194 190 private String returnFreight;
195 191
... ... @@ -221,7 +217,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
221 217 * 生产批号
222 218 */
223 219 @ApiModelProperty(value = "生产批号", required = true)
224   - @NotBlank(message = "请输入生产批号!")
225 220 @Length(message = "生产批号最多允许50个字符!")
226 221 private String yieldBatchNo;
227 222
... ... @@ -229,7 +224,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
229 224 * 开票情况
230 225 */
231 226 @ApiModelProperty(value = "开票情况", required = true)
232   - @NotBlank(message = "请输入开票情况!")
233 227 @Length(message = "开票情况最多允许50个字符!")
234 228 private String invoicingStatus;
235 229
... ... @@ -245,7 +239,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
245 239 * 包装费
246 240 */
247 241 @ApiModelProperty(value = "包装费", required = true)
248   - @NotNull(message = "请输入包装费!")
249 242 @TypeMismatch(message = "包装费格式有误!")
250 243 @IsNumberPrecision(message = "包装费最多允许4位小数!", value = 4)
251 244 private BigDecimal packagingFee;
... ... @@ -262,7 +255,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
262 255 * 件数
263 256 */
264 257 @ApiModelProperty(value = "件数", required = true)
265   - @NotNull(message = "请输入件数!")
266 258 @TypeMismatch(message = "件数格式有误!")
267 259 private Double num;
268 260
... ... @@ -270,7 +262,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
270 262 * 结算方式
271 263 */
272 264 @ApiModelProperty(value = "结算方式", required = true)
273   - @NotBlank(message = "请输入结算方式!")
274 265 @Length(message = "结算方式最多允许50个字符!")
275 266 private String settlementTerms;
276 267
... ... @@ -286,7 +277,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
286 277 * 包装要求
287 278 */
288 279 @ApiModelProperty(value = "包装要求", required = true)
289   - @NotBlank(message = "请输入包装要求!")
290 280 @Length(message = "包装要求最多允许200个字符!")
291 281 private String packagingRequirements;
292 282
... ... @@ -310,7 +300,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
310 300 * 客户简称
311 301 */
312 302 @ApiModelProperty(value = "客户简称", required = true)
313   - @NotBlank(message = "请输入客户简称!")
314 303 @Length(message = "客户简称最多允许50个字符!")
315 304 private String customerShortName;
316 305
... ... @@ -318,7 +307,6 @@ public class CreateShipmentDetailStatisticsVo implements BaseVo, Serializable {
318 307 * 客户类型
319 308 */
320 309 @ApiModelProperty(value = "客户类型", required = true)
321   - @NotBlank(message = "请输入客户类型!")
322 310 @Length(message = "客户类型最多允许20个字符!")
323 311 private String customerType;
324 312
... ...
... ... @@ -146,11 +146,7 @@
146 146 o.invoicing_status,
147 147 o.order_date,
148 148 o.settlement_terms,
149   - case
150   - when o.supply_unit = 'GJ' then '安徽楚江高精铜带有限公司'
151   - when o.supply_unit = 'XC' then '安徽楚江科技新材料股份有限公司'
152   - else ''
153   - end as supplier,
  149 + o.supply_unit as supplier,
154 150 o.workshop_id,
155 151 so.code as shipment_order_no,
156 152 so.create_time as shipment_date,
... ...