From 842fb00813160673aaee983d891620665eebbe7d Mon Sep 17 00:00:00 2001 From: wangwei <1610949092@qq.com> Date: Wed, 31 May 2023 10:01:55 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=91=E7=A5=A8=E4=BA=8C=E7=BB=B4=E7=A0=81?= =?UTF-8?q?=E8=A7=A3=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../inout/IoOrderDetailBizController.java | 20 +++++++++ .../api/req/inv/FilterInvoiceRequest.java | 41 +++++++++++++++++++ 2 files changed, 61 insertions(+) create mode 100644 src/main/java/com/glxp/api/req/inv/FilterInvoiceRequest.java diff --git a/src/main/java/com/glxp/api/controller/inout/IoOrderDetailBizController.java b/src/main/java/com/glxp/api/controller/inout/IoOrderDetailBizController.java index 0bdadd55..8d995a24 100644 --- a/src/main/java/com/glxp/api/controller/inout/IoOrderDetailBizController.java +++ b/src/main/java/com/glxp/api/controller/inout/IoOrderDetailBizController.java @@ -2,6 +2,7 @@ package com.glxp.api.controller.inout; import cn.hutool.core.collection.CollUtil; +import cn.hutool.core.date.DateUtil; import cn.hutool.core.util.IdUtil; import cn.hutool.core.util.StrUtil; import com.github.pagehelper.PageInfo; @@ -27,6 +28,7 @@ import com.glxp.api.entity.thrsys.ThrOrderDetailEntity; import com.glxp.api.entity.thrsys.ThrOrderEntity; import com.glxp.api.entity.thrsys.ThrSystemBusApiEntity; import com.glxp.api.req.inout.*; +import com.glxp.api.req.inv.FilterInvoiceRequest; import com.glxp.api.req.system.DeleteRequest; import com.glxp.api.req.thrsys.FilterThrOrderDetailRequest; import com.glxp.api.res.PageSimpleResponse; @@ -54,6 +56,7 @@ import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; import java.math.BigDecimal; import java.util.ArrayList; +import java.util.Arrays; import java.util.Date; import java.util.List; @@ -653,6 +656,23 @@ public class IoOrderDetailBizController extends BaseController { } + + + @GetMapping("/udiwms/inout/biz/parseInvoice") + public BaseResponse parseInvoice(String code) { + List list = Arrays.asList(code.split(",")); + FilterInvoiceRequest filterInvoiceRequest = new FilterInvoiceRequest(); + filterInvoiceRequest.setType(list.get(1)); + filterInvoiceRequest.setInvoiceCode(list.get(2)); + filterInvoiceRequest.setInvoiceEncode(list.get(3)); + filterInvoiceRequest.setPrice(new BigDecimal(list.get(4))); + filterInvoiceRequest.setInvoiceDate(DateUtil.formatDateTime(DateUtil.parse(list.get(5), "yyyyMMdd"))); + return ResultVOUtils.success(filterInvoiceRequest); + } + + + + @PostMapping("/udiwms/inout/biz/updateorderBiz") public BaseResponse updateorderBiz(@RequestBody List list) { String billNo = null; diff --git a/src/main/java/com/glxp/api/req/inv/FilterInvoiceRequest.java b/src/main/java/com/glxp/api/req/inv/FilterInvoiceRequest.java new file mode 100644 index 00000000..c7a86962 --- /dev/null +++ b/src/main/java/com/glxp/api/req/inv/FilterInvoiceRequest.java @@ -0,0 +1,41 @@ +package com.glxp.api.req.inv; + +import com.glxp.api.util.page.ListPageRequest; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * 查询库存预警消息参数 + */ +@Data +public class FilterInvoiceRequest extends ListPageRequest { + + + /** + * 预警类型:10:增值税电子普通发票;01:增值税专用发票;04:增值税普通发票;32:电子发票(普通发票);31:电子发票(增值税专用发票) + */ + private String type; + + /** + * 发票代码 + */ + private String invoiceCode; + + /** + * 发票编码 + */ + private String invoiceEncode; + + /** + * 开票日期 + */ + private String invoiceDate; + + + /** + * 发票价格 + */ + private BigDecimal price; + +}