From a249ceced9f2f4ca344805964fec6a3445655e30 Mon Sep 17 00:00:00 2001 From: hp <2969694837@qq.com> Date: Wed, 21 Sep 2022 15:28:16 +0800 Subject: [PATCH] =?UTF-8?q?=E7=9B=98=E5=BA=93=E4=BB=A3=E7=A0=81=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...ppScmVehicleCarInventoryListPageQuery.java | 9 +- .../AppScmVehicleStayInventoryDto.java | 9 +- .../AppScmVehicleStayInventoryInfoVo.java | 3 + .../AppScmVehicleStayInventoryListPageVo.java | 6 + .../AppScmVehiclePatrolinspectionPageVo.java | 3 + .../ScmVehiclePatrolinspection.java | 25 +- .../ScmVehiclePatrolinspectionFeign.java | 2 +- .../ScmVehiclePatrolinspectionsheet.java | 4 +- ...VehiclePatrolinspectionsheetDetailsVo.java | 6 +- .../ScmVehiclePatrolinspectionsheetDto.java | 5 +- .../ScmVehiclePatrolinspectionsheetFeign.java | 2 +- .../ScmVehicleStayPatrolinspectionFeign.java | 5 - ...icleStayPatrolinspectionFeignFallback.java | 5 - .../AppScmVehInventorymonthInfoVo.java | 35 +++ .../AppScmVehInventorymonthQuery.java | 9 + .../AppScmVehInventorymonthVo.java | 24 +- .../AppVehInventorymonthVo.java | 87 ++++++ .../AppVinAndRemarksVo.java | 13 + .../ScmVehInventorymonthFeign.java | 6 +- .../ScmVehInventorymonthFeignFallback.java | 5 + .../scmvehinventoryreport/AppReportDto.java | 26 ++ .../RecipientListDto.java | 17 ++ .../ScmVehInventoryreportDto.java | 14 +- .../ScmVehInventoryreportFeign.java | 5 + .../ScmVehInventoryreportFeignFallback.java | 5 + .../AppScmVehPatrolinspectionmonthInfoVo.java | 20 ++ .../AppScmVehPatrolinspectionmonthQuery.java | 39 +++ .../AppScmVehPatrolinspectionmonthVo.java | 35 +++ .../ScmVehPatrolinspectionmonth.java | 64 +++++ .../ScmVehPatrolinspectionmonthDetailsVo.java | 65 +++++ .../ScmVehPatrolinspectionmonthDto.java | 65 +++++ .../ScmVehPatrolinspectionmonthFeign.java | 97 +++++++ ...VehPatrolinspectionmonthFeignFallback.java | 87 ++++++ .../ScmVehPatrolinspectionmonthQuery.java | 63 +++++ .../ScmVehPatrolinspectionmonthVo.java | 65 +++++ .../VehPatrolinspectionmonthVo.java | 30 +++ .../ScmVehPatrolinspectionreport.java | 62 +++++ ...ScmVehPatrolinspectionreportDetailsVo.java | 63 +++++ .../ScmVehPatrolinspectionreportDto.java | 63 +++++ .../ScmVehPatrolinspectionreportFeign.java | 78 ++++++ ...ehPatrolinspectionreportFeignFallback.java | 72 +++++ .../ScmVehPatrolinspectionreportQuery.java | 61 +++++ .../ScmVehPatrolinspectionreportVo.java | 63 +++++ .../ScmVehicleInventoryMapper.java | 16 +- .../ScmVehicleInventoryMapper.xml | 72 +++-- .../ScmVehicleInventoryService.java | 207 +++++++++----- .../ScmVehiclePatrolinspectionMapper.java | 6 + .../ScmVehiclePatrolinspectionMapper.xml | 14 +- .../ScmVehiclePatrolinspectionService.java | 14 + .../ScmVehiclePatrolinspectionsheetMapper.xml | 4 +- ...cmVehiclePatrolinspectionsheetService.java | 13 +- .../ScmVehicleStayPatrolinspectionRest.java | 5 - ...ScmVehicleStayPatrolinspectionService.java | 33 --- .../ScmVehInventorymonthMapper.java | 33 ++- .../ScmVehInventorymonthMapper.xml | 53 +++- .../ScmVehInventorymonthRest.java | 17 +- .../ScmVehInventorymonthService.java | 151 ++++++++++- .../ScmVehInventoryreportRest.java | 5 + .../ScmVehInventoryreportService.java | 228 ++++++++++++---- .../ScmVehPatrolinspectionmonthMapper.java | 72 +++++ .../ScmVehPatrolinspectionmonthMapper.xml | 42 +++ .../ScmVehPatrolinspectionmonthRest.java | 120 +++++++++ .../ScmVehPatrolinspectionmonthService.java | 254 ++++++++++++++++++ .../ScmVehPatrolinspectionreportMapper.java | 65 +++++ .../ScmVehPatrolinspectionreportMapper.xml | 13 + .../ScmVehPatrolinspectionreportRest.java | 100 +++++++ .../ScmVehPatrolinspectionreportService.java | 110 ++++++++ .../AppScmVehiclePatrolinspectionFeign.java | 10 + ...mVehiclePatrolinspectionFeignFallback.java | 10 + .../VehPatrolinspectionmonthInfoVo.java | 19 ++ .../VehPatrolinspectionmonthQuery.java | 38 +++ .../VehPatrolinspectionmonthVo.java | 33 +++ .../AppScmVehicleInventoryFeign.java | 14 + .../AppScmVehicleInventoryFeignFallback.java | 15 ++ .../inventory/CarInventoryListPageQuery.java | 5 +- .../supplychain/inventory/ReportListDto.java | 16 ++ .../inventory/StayInventoryDto.java | 7 +- .../inventory/StayInventoryInfoVo.java | 3 + .../inventory/VehInventorymonthInfoVo.java | 33 +++ .../inventory/VehInventorymonthQuery.java | 34 +++ .../inventory/VehInventorymonthVo.java | 47 ++++ .../inventory/VehInventoryreportDto.java | 21 ++ .../baseInfo/AppScmBaseInfoService.java | 8 +- .../AppScmVehiclePatrolinspectionRest.java | 10 + .../AppScmVehiclePatrolinspectionService.java | 35 ++- .../inventory/AppScmVehicleInventoryRest.java | 15 ++ .../AppScmVehicleInventoryService.java | 50 ++++ 87 files changed, 3218 insertions(+), 274 deletions(-) create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthInfoVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVehInventorymonthVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVinAndRemarksVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/AppReportDto.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/RecipientListDto.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthInfoVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthQuery.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonth.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDetailsVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDto.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeign.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeignFallback.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthQuery.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/VehPatrolinspectionmonthVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreport.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDetailsVo.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDto.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeign.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeignFallback.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportQuery.java create mode 100644 anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportVo.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.xml create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthRest.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthService.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.xml create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportRest.java create mode 100644 anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportService.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthInfoVo.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthQuery.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthVo.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/ReportListDto.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthInfoVo.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthQuery.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthVo.java create mode 100644 anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventoryreportDto.java diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleCarInventoryListPageQuery.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleCarInventoryListPageQuery.java index bba9e55658..b6a7ac3b1c 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleCarInventoryListPageQuery.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleCarInventoryListPageQuery.java @@ -12,7 +12,7 @@ public class AppScmVehicleCarInventoryListPageQuery implements Query { private String userSid; @ApiModelProperty("优先匹配车架号 盘库人员") - private String name; + private String names; @ApiModelProperty("时间段 示例 2020-02-01至2022-03-31") private String date; @@ -28,8 +28,11 @@ public class AppScmVehicleCarInventoryListPageQuery implements Query { @ApiModelProperty("存放地点sid") private String warehouseSid; -// @ApiModelProperty("盘库状态 通过1 不通过 2") -// private String state; + @ApiModelProperty("月度盘库sid") + private String reportSid; + + @ApiModelProperty("盘库状态 通过1 不通过 2") + private String state; @ApiModelProperty("使用组织分公司sid") private String useOrgSid; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryDto.java index 2f22460033..bdc6a05c8a 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryDto.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryDto.java @@ -51,11 +51,14 @@ import java.util.List; @ApiModel(value = "待盘库记录 数据传输对象", description = "待盘库记录 数据传输对象") public class AppScmVehicleStayInventoryDto implements Dto { - @ApiModelProperty(value = "待盘库sid") + @ApiModelProperty(value = "盘库sid") private String sid; - @ApiModelProperty(value = "车架号") - private String mainSid; + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + + @ApiModelProperty("月度盘库sid") + private String mainSid; // 月度盘库sid @ApiModelProperty(value = "存放地点") private String location; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryInfoVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryInfoVo.java index 6a0b48701e..9448575b80 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryInfoVo.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryInfoVo.java @@ -59,6 +59,9 @@ public class AppScmVehicleStayInventoryInfoVo implements Vo { @ApiModelProperty("车架号") private String vin; + @ApiModelProperty("月度盘库sid") + private String mainSid; + @ApiModelProperty("存放地点") private String warehouse; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryListPageVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryListPageVo.java index c412232f0b..154b81f629 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryListPageVo.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehicleinventory/AppScmVehicleStayInventoryListPageVo.java @@ -15,9 +15,15 @@ public class AppScmVehicleStayInventoryListPageVo implements Vo { @ApiModelProperty("sid") private String sid; + @ApiModelProperty("月度盘库sid") + private String mainSid; + @ApiModelProperty("车架号") private String vin; + @ApiModelProperty("创建组织sid") + private String createOrgSid; + @ApiModelProperty("存放地点") private String warehouse; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/AppScmVehiclePatrolinspectionPageVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/AppScmVehiclePatrolinspectionPageVo.java index 5b78e87894..a25e4df588 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/AppScmVehiclePatrolinspectionPageVo.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/AppScmVehiclePatrolinspectionPageVo.java @@ -14,6 +14,9 @@ public class AppScmVehiclePatrolinspectionPageVo implements Vo { @ApiModelProperty("车架号") private String vin; + @ApiModelProperty("月度管理sid") + private String mainSid; + @ApiModelProperty("最新巡检日期") private String newInspectionDate; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspection.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspection.java index 832f3dc40c..7595859b09 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspection.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspection.java @@ -49,24 +49,25 @@ import lombok.Data; @TableName("scm_vehicle_patrolinspection") public class ScmVehiclePatrolinspection extends BaseEntity { private static final long serialVersionUID = 1L; - - @ApiModelProperty("车架号") + @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("月度管理sid") private String mainSid; // 车架号 - @ApiModelProperty("存放地点sid") + @ApiModelProperty("存放地点sid") private String locationSid; // 存放地点sid - @ApiModelProperty("存放地点") + @ApiModelProperty("存放地点") private String location; // 存放地点 - @ApiModelProperty("合格证(有/无)") - private String certificate; // 合格证(有/无) - @ApiModelProperty("巡检日期") + @ApiModelProperty("巡检日期") private String patrolInspectionDate; // 巡检日期 - @ApiModelProperty("巡检人员") + @ApiModelProperty("巡检人员") private String patrolInspectionName; // 巡检人员 - @ApiModelProperty("巡检状态(通过/不通过)") + @ApiModelProperty("巡检状态(通过/不通过)") private String patrolInspectionState; // 巡检状态(通过/不通过) - @ApiModelProperty("创建组织") + @ApiModelProperty("巡检状态(通过/不通过)") + private String patrolInspectionStateKey; // 巡检状态(通过/不通过) + @ApiModelProperty("创建组织") private String createOrgSid; // 创建组织 - @ApiModelProperty("使用组织") - private String useOrgName; // 使用组织 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 } diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionFeign.java index 42e24a8798..ce1a06b55c 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionFeign.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionFeign.java @@ -82,7 +82,7 @@ public interface ScmVehiclePatrolinspectionFeign { @ApiOperation("手机端-巡检详情") @PostMapping("/getInspectionInfo/{recordSid}") @ResponseBody - public ResultBean getInspectionInfo(@PathVariable("recordSid")String recordSid); + public ResultBean getInspectionInfo(@PathVariable("recordSid") String recordSid); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheet.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheet.java index 366fb8b1dc..c001b154f5 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheet.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheet.java @@ -49,9 +49,9 @@ import lombok.Data; @TableName("scm_vehicle_patrolinspectionsheet") public class ScmVehiclePatrolinspectionsheet extends BaseEntity { private static final long serialVersionUID = 1L; - @ApiModelProperty("主表sid") - private String patrolInspectionSid; // 主表sid @ApiModelProperty("车架号") + private String vinNo; // 主表sid + @ApiModelProperty("巡检记录sid") private String mainSid; // 车架号 @ApiModelProperty("车型sid") private String modelSid; // 车型sid diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDetailsVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDetailsVo.java index 65c874cbaf..4d35ee74bc 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDetailsVo.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDetailsVo.java @@ -51,10 +51,10 @@ import java.util.List; @ApiModel(value = "巡检单 视图数据详情", description = "巡检单 视图数据详情") public class ScmVehiclePatrolinspectionsheetDetailsVo implements Vo { private String sid; - @ApiModelProperty("主表sid") - private String patrolInspectionSid; // 主表sid @ApiModelProperty("车架号") - private String mainSid; // 车架号 + private String vinNo; // 车架号 + @ApiModelProperty("巡检记录sid") + private String mainSid; // @ApiModelProperty("车型sid") private String modelSid; // 车型sid @ApiModelProperty("车型") diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDto.java index 8148e6e857..dfc53d2fe4 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDto.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetDto.java @@ -52,10 +52,9 @@ import java.util.List; public class ScmVehiclePatrolinspectionsheetDto implements Dto { private String sid; - - @ApiModelProperty("主表sid") - private String patrolInspectionSid; // 主表sid @ApiModelProperty("车架号") + private String vinNo; // 车架号 + @ApiModelProperty("巡检记录sid") private String mainSid; // 车架号 @ApiModelProperty("车型sid") private String modelSid; // 车型sid diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetFeign.java index b16417a9f8..1fb0c4d0b9 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetFeign.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetFeign.java @@ -84,7 +84,7 @@ public interface ScmVehiclePatrolinspectionsheetFeign { @ResponseBody public ResultBean getInspection(@PathVariable("recordSid") String recordSid); - @ApiOperation("手机端-保存巡检操作") + @ApiOperation("手机端-提交巡检操作") @PostMapping("/saveInspection") @ResponseBody public ResultBean saveInspection(@RequestBody ScmVehiclePatrolinspectionsheetDto dto); diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeign.java index d548130ff0..58ca4dfba0 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeign.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeign.java @@ -74,11 +74,6 @@ public interface ScmVehicleStayPatrolinspectionFeign { @ResponseBody public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid); - @ApiOperation("手机端-判断是否生成巡检记录") - @GetMapping("/getInspectionRecords/{userSid}") - @ResponseBody - public ResultBean getInspectionRecords(@PathVariable("userSid") String userSid); - @ApiOperation("手机端-获取巡检列表") @PostMapping("/getInspectionList") diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeignFallback.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeignFallback.java index ba7a37594d..7222f21a09 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeignFallback.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionFeignFallback.java @@ -70,11 +70,6 @@ public class ScmVehicleStayPatrolinspectionFeignFallback implements ScmVehicleSt return rb.setMsg("接口anrui_scm/scmvehiclestaypatrolinspection/fetchDetailsBySid无法访问"); } - @Override - public ResultBean getInspectionRecords(String userSid) { - return null; - } - @Override public ResultBean> getInspectionList(PagerQuery pagerQuery) { return null; diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthInfoVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthInfoVo.java new file mode 100644 index 0000000000..06cf8bd0d0 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthInfoVo.java @@ -0,0 +1,35 @@ +package com.yxt.anrui.scm.api.scmvehinventorymonth; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class AppScmVehInventorymonthInfoVo implements Vo { + private static final long serialVersionUID = -8077170646957590520L; + + @ApiModelProperty("本次应盘数量") + private String totalNumber; + @ApiModelProperty("实际盘库数量") + private String actualNumber; + @ApiModelProperty("正常数量") + private String normalNumber; + @ApiModelProperty("盘盈数量") + private String profitNumber; + @ApiModelProperty("盘亏数量") + private String lossNumber; + @ApiModelProperty("盘损数量") + private String damageNumber; + @ApiModelProperty("盘盈备注") + private String profitRemarks; + @ApiModelProperty("盘亏备注") + private String lossRemarks; + @ApiModelProperty("盘损备注") + private String damageRemarks; + @ApiModelProperty("接收人") + private String recipient; + @ApiModelProperty("创建日期") + private String date; + + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthQuery.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthQuery.java index 3804f55d70..4326ce4092 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthQuery.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthQuery.java @@ -26,6 +26,7 @@ package com.yxt.anrui.scm.api.scmvehinventorymonth; +import com.fasterxml.jackson.annotation.JsonProperty; import com.yxt.common.core.query.Query; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; @@ -61,4 +62,12 @@ public class AppScmVehInventorymonthQuery implements Query { @ApiModelProperty("使用组织名称") private String useOrgSid; + @ApiModelProperty("盘库开始日期") + @JsonProperty("InventStartDate") + private String InventStartDate; + + @ApiModelProperty("盘库结束日期") + @JsonProperty("InventEndDate") + private String InventEndDate; + } diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthVo.java index 0cacb26fc4..3a2e806918 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthVo.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppScmVehInventorymonthVo.java @@ -49,16 +49,23 @@ import lombok.Data; public class AppScmVehInventorymonthVo implements Vo { private String sid; // sid - - @ApiModelProperty("编号(yyyyMMdd)") - private String billNo; // 编号(yyyyMMdd) - @ApiModelProperty("创建组织") + @ApiModelProperty("生成报告状态") + private String state; + @ApiModelProperty("编号(yyyyMMdd)") + private String reportId; // 编号(yyyyMMdd) + @ApiModelProperty("创建时间") + private String date; // + @ApiModelProperty("创建人sid") + private String createBySid; + @ApiModelProperty("创建人") + private String name; + @ApiModelProperty("创建组织") private String createOrgSid; // 创建组织 - @ApiModelProperty("创建组织名称") + @ApiModelProperty("创建组织名称") private String createOrgName; // 创建组织名称 - @ApiModelProperty("使用组织") + @ApiModelProperty("使用组织") private String useOrgSid; // 使用组织 - @ApiModelProperty("使用组织名称") + @ApiModelProperty("使用组织名称") private String useOrgName; // 使用组织名称 @ApiModelProperty("剩余盘库记录数量") private String surplusNumber; @@ -72,9 +79,10 @@ public class AppScmVehInventorymonthVo implements Vo { private String profitNumber; @ApiModelProperty("实盘数量") private String actualNumber; + @ApiModelProperty("正常数量") + private String normalNumber; @ApiModelProperty("是否显示生成报告按钮 剩余盘库记录=0时显示") private Boolean showBtn; - } diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVehInventorymonthVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVehInventorymonthVo.java new file mode 100644 index 0000000000..db5a5a508b --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVehInventorymonthVo.java @@ -0,0 +1,87 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehinventorymonth; + + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehInventorymonthVo.java
+ * Class: com.yxt.anrui.scm.api.api.scmvehinventorymonth.ScmVehInventorymonthVo
+ * Description: 月度盘库 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-16 15:52:05
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度盘库 视图数据对象", description = "月度盘库 视图数据对象") +public class AppVehInventorymonthVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建时间") + private String date; // + @ApiModelProperty("创建人sid") + private String createBySid; + @ApiModelProperty("创建人") + private String name; + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + @ApiModelProperty("剩余盘库记录数量") + private int surplusNumber; + @ApiModelProperty("盘库记录总数数量") + private int totalNumber; + @ApiModelProperty("盘亏数量") + private int lossNumber; + @ApiModelProperty("盘损数量") + private int damageNumber; + @ApiModelProperty("盘盈数量") + private int profitNumber; + @ApiModelProperty("实盘数量") + private int actualNumber; + @ApiModelProperty("正常数量") + private int normalNumber; + @ApiModelProperty("是否显示生成报告按钮 剩余盘库记录=0时显示") + private Boolean showBtn; + + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVinAndRemarksVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVinAndRemarksVo.java new file mode 100644 index 0000000000..62dfa7391a --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/AppVinAndRemarksVo.java @@ -0,0 +1,13 @@ +package com.yxt.anrui.scm.api.scmvehinventorymonth; + +import com.yxt.common.core.vo.Vo; +import lombok.Data; + +@Data +public class AppVinAndRemarksVo implements Vo { + private static final long serialVersionUID = -7810009366140799044L; + + private String vinNo; + + private String remarks; +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeign.java index 8769eec4f1..dbc05bcfcf 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeign.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeign.java @@ -88,6 +88,8 @@ public interface ScmVehInventorymonthFeign { @ResponseBody public ResultBean> getCarInventoryReportList(@RequestBody PagerQuery pagerQuery); - - + @ApiOperation("手机端-获取盘库报告") + @GetMapping("/getCarInventoryReport/{sid}") + @ResponseBody + public ResultBean getCarInventoryReport(@PathVariable("sid") String sid); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeignFallback.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeignFallback.java index 6d1261968f..1c53a5f3d1 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeignFallback.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventorymonth/ScmVehInventorymonthFeignFallback.java @@ -79,4 +79,9 @@ public class ScmVehInventorymonthFeignFallback implements ScmVehInventorymonthFe public ResultBean> getCarInventoryReportList(PagerQuery pagerQuery) { return null; } + + @Override + public ResultBean getCarInventoryReport(String sid) { + return null; + } } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/AppReportDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/AppReportDto.java new file mode 100644 index 0000000000..2f3ec069db --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/AppReportDto.java @@ -0,0 +1,26 @@ +package com.yxt.anrui.scm.api.scmvehinventoryreport; + +import com.yxt.common.core.dto.Dto; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.lang.ref.PhantomReference; +import java.util.List; + +@Data +public class AppReportDto implements Dto { + + private static final long serialVersionUID = 7057300987973700285L; + + @ApiModelProperty("盘库sid") + private String mainSid; + + @ApiModelProperty("消息内容") + private String msgContent; + + @ApiModelProperty("接收人sid") + private List list; + + @ApiModelProperty("接收人id") + private List receiveIdList; +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/RecipientListDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/RecipientListDto.java new file mode 100644 index 0000000000..366b423d84 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/RecipientListDto.java @@ -0,0 +1,17 @@ +package com.yxt.anrui.scm.api.scmvehinventoryreport; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class RecipientListDto implements Vo { + + private static final long serialVersionUID = 1105661416523691206L; + + @ApiModelProperty("接收人sid") + private String sid; // 接收人sid + @ApiModelProperty("接收人姓名") + private String name; // 接收人姓名 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportDto.java index 82c1289ca4..b38ddce8eb 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportDto.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportDto.java @@ -32,6 +32,8 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; +import java.util.List; + /** * Project: aaa(aaa)
* File: ScmVehInventoryreportDto.java
@@ -50,14 +52,12 @@ import lombok.Data; public class ScmVehInventoryreportDto implements Dto { private String sid; // sid - - @ApiModelProperty("月度盘库sid") + private String userSid; + @ApiModelProperty("月度盘库sid") private String mainSid; // 月度盘库sid - @ApiModelProperty("接收人sid") - private String receiverSids; // 接收人sid - @ApiModelProperty("接收人姓名") - private String receiverNames; // 接收人姓名 - @ApiModelProperty("盘库报告内容") + @ApiModelProperty("接收人list") + private List recipientList; + @ApiModelProperty("盘库报告内容") private String reportContent; // 盘库报告内容 } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeign.java index bee8624419..97c4779ea7 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeign.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeign.java @@ -75,4 +75,9 @@ public interface ScmVehInventoryreportFeign { @GetMapping("/fetchDetailsBySid/{sid}") @ResponseBody public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid); + + @ApiOperation("发送报告") + @PostMapping("/sendReport") + @ResponseBody + public ResultBean sendReport(@RequestBody ScmVehInventoryreportDto dto); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeignFallback.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeignFallback.java index 42892b19ec..c2e41d563c 100644 --- a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeignFallback.java +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehinventoryreport/ScmVehInventoryreportFeignFallback.java @@ -69,4 +69,9 @@ public class ScmVehInventoryreportFeignFallback implements ScmVehInventoryreport ResultBean rb = ResultBean.fireFail(); return rb.setMsg("接口aaa/scmvehinventoryreport/fetchDetailsBySid无法访问"); } + + @Override + public ResultBean sendReport(ScmVehInventoryreportDto dto) { + return null; + } } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthInfoVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthInfoVo.java new file mode 100644 index 0000000000..e39d0809aa --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthInfoVo.java @@ -0,0 +1,20 @@ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class AppScmVehPatrolinspectionmonthInfoVo implements Vo { + private static final long serialVersionUID = -5082102320532147476L; + + @ApiModelProperty("本次应巡检数量") + private String totalNumber; + + @ApiModelProperty("实际巡检数量") + private String actualNumber; + + @ApiModelProperty("存在的问题") + private String question; + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthQuery.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthQuery.java new file mode 100644 index 0000000000..9ae483ab71 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthQuery.java @@ -0,0 +1,39 @@ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.query.Query; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class AppScmVehPatrolinspectionmonthQuery implements Query { + + private static final long serialVersionUID = -6285926370342867059L; + + @ApiModelProperty("用户sid") + private String userSid; + + @ApiModelProperty("报告编号/创建人") + private String names; + + @ApiModelProperty("创建日期") + private String date; + + @ApiModelProperty("巡检报告sid") + private String reportSid; + + @ApiModelProperty("巡检状态") + private String state; + + @ApiModelProperty("分公司sid") + private String useOrgSid; + + @ApiModelProperty("盘库开始日期") + @JsonProperty("InventStartDate") + private String InventStartDate; + + @ApiModelProperty("盘库结束日期") + @JsonProperty("InventEndDate") + private String InventEndDate; + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthVo.java new file mode 100644 index 0000000000..67bc370179 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/AppScmVehPatrolinspectionmonthVo.java @@ -0,0 +1,35 @@ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class AppScmVehPatrolinspectionmonthVo implements Vo { + private static final long serialVersionUID = -5082102320532147476L; + + + private String sid; + @ApiModelProperty("编号") + private String reportId; + @ApiModelProperty("创建人员") + private String name; + @ApiModelProperty("创建人sid") + private String createBySid; + @ApiModelProperty("创建时间") + private String date; + @ApiModelProperty("剩余巡检记录数量") + private String surplusNumber; + @ApiModelProperty("巡检记录总数数量") + private String totalNumber; + @ApiModelProperty("未处理数量") + private String unHandledNumber; + @ApiModelProperty("已处理数量") + private String processedNumber; + @ApiModelProperty("未巡检数量") + private String notHandledNumber; + @ApiModelProperty("实际巡检数量") + private String actualNumber; + + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonth.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonth.java new file mode 100644 index 0000000000..b7692ba1e9 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonth.java @@ -0,0 +1,64 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.baomidou.mybatisplus.annotation.TableName; +import com.yxt.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonth.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonth
+ * Description: 月度日常管理记录.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度日常管理记录", description = "月度日常管理记录") +@TableName("scm_veh_patrolinspectionmonth") +public class ScmVehPatrolinspectionmonth extends BaseEntity { + private static final long serialVersionUID = 1L; + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDetailsVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDetailsVo.java new file mode 100644 index 0000000000..082730e97d --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDetailsVo.java @@ -0,0 +1,65 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthVo.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthVo
+ * Description: 月度日常管理记录 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度日常管理记录 视图数据详情", description = "月度日常管理记录 视图数据详情") +public class ScmVehPatrolinspectionmonthDetailsVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDto.java new file mode 100644 index 0000000000..04cea0e507 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthDto.java @@ -0,0 +1,65 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + + +import com.yxt.common.core.dto.Dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthDto.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthDto
+ * Description: 月度日常管理记录 数据传输对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度日常管理记录 数据传输对象", description = "月度日常管理记录 数据传输对象") +public class ScmVehPatrolinspectionmonthDto implements Dto { + + private String sid; // sid + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeign.java new file mode 100644 index 0000000000..73a800f667 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeign.java @@ -0,0 +1,97 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthInfoVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthQuery; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import org.springframework.cloud.openfeign.FeignClient; +import org.springframework.web.bind.annotation.*; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthFeign.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthFeign
+ * Description: 月度日常管理记录.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Api(tags = "月度日常管理记录") +@FeignClient( + contextId = "aaa-ScmVehPatrolinspectionmonth", + name = "aaa", + path = "v1/scmvehpatrolinspectionmonth", + fallback = ScmVehPatrolinspectionmonthFeignFallback.class) +public interface ScmVehPatrolinspectionmonthFeign { + + @ApiOperation("根据条件分页查询数据的列表") + @PostMapping("/listPage") + @ResponseBody + public ResultBean> listPage(@RequestBody PagerQuery pq); + + @ApiOperation("新增或修改") + @PostMapping("/save") + @ResponseBody + public ResultBean save(@RequestBody ScmVehPatrolinspectionmonthDto dto); + + @ApiOperation("根据sid删除记录") + @DeleteMapping("/delBySids") + @ResponseBody + public ResultBean delBySids(@RequestBody String[] sids); + + @ApiOperation("根据SID获取一条记录") + @GetMapping("/fetchDetailsBySid/{sid}") + @ResponseBody + public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid); + + @ApiOperation("手机端-判断是否生成巡检记录") + @GetMapping("/getInspectionRecords/{userSid}") + @ResponseBody + public ResultBean getInspectionRecords(@PathVariable("userSid") String userSid); + + @ApiOperation("手机端-获取巡检报告列表") + @PostMapping("/getCarInventoryReportList") + @ResponseBody + public ResultBean> getCarInspectionReportList(@RequestBody PagerQuery pagerQuery); + + @ApiOperation("手机端-获取巡检报告") + @GetMapping("/getCarInspectionReport/{sid}") + @ResponseBody + public ResultBean getCarInspectionReport(@PathVariable("sid") String sid); + +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeignFallback.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeignFallback.java new file mode 100644 index 0000000000..5f3a092a9e --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthFeignFallback.java @@ -0,0 +1,87 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import org.springframework.stereotype.Component; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthFeignFallback.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthFeignFallback
+ * Description: 月度日常管理记录.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Component +public class ScmVehPatrolinspectionmonthFeignFallback implements ScmVehPatrolinspectionmonthFeign { + + @Override + public ResultBean> listPage(PagerQuery pq){ + ResultBean rb = ResultBean.fireFail(); + return rb.setMsg("接口aaa/scmvehpatrolinspectionmonth/listPage无法访问"); + } + + @Override + public ResultBean save(ScmVehPatrolinspectionmonthDto dto){ + return ResultBean.fireFail().setMsg("接口aaa/scmvehpatrolinspectionmonth/save无法访问"); + } + + @Override + public ResultBean delBySids( String[] sids){ + return ResultBean.fireFail().setMsg("接口aaa/scmvehpatrolinspectionmonth/delBySids无法访问"); + } + + @Override + public ResultBean fetchDetailsBySid(String sid){ + ResultBean rb = ResultBean.fireFail(); + return rb.setMsg("接口aaa/scmvehpatrolinspectionmonth/fetchDetailsBySid无法访问"); + } + + @Override + public ResultBean getInspectionRecords(String userSid) { + return null; + } + + @Override + public ResultBean> getCarInspectionReportList(PagerQuery pagerQuery) { + return null; + } + + @Override + public ResultBean getCarInspectionReport(String sid) { + return null; + } +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthQuery.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthQuery.java new file mode 100644 index 0000000000..8240ed3510 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthQuery.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + + +import com.yxt.common.core.query.Query; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthQuery.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthQuery
+ * Description: 月度日常管理记录 查询条件.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度日常管理记录 查询条件", description = "月度日常管理记录 查询条件") +public class ScmVehPatrolinspectionmonthQuery implements Query { + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthVo.java new file mode 100644 index 0000000000..510c8397d7 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthVo.java @@ -0,0 +1,65 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthVo.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthVo
+ * Description: 月度日常管理记录 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "月度日常管理记录 视图数据对象", description = "月度日常管理记录 视图数据对象") +public class ScmVehPatrolinspectionmonthVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("编号(yyyyMMdd)") + private String billNo; // 编号(yyyyMMdd) + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/VehPatrolinspectionmonthVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/VehPatrolinspectionmonthVo.java new file mode 100644 index 0000000000..8be1f843c7 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionmonth/VehPatrolinspectionmonthVo.java @@ -0,0 +1,30 @@ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehPatrolinspectionmonthVo implements Vo { + private static final long serialVersionUID = -9027195577856709868L; + + private String sid; + @ApiModelProperty("编号") + private String reportId; + @ApiModelProperty("创建人员") + private String name; + @ApiModelProperty("创建时间") + private String date; + @ApiModelProperty("剩余巡检记录数量") + private int surplusNumber; + @ApiModelProperty("巡检记录总数数量") + private int totalNumber; + @ApiModelProperty("未处理数量") + private int unHandledNumber; + @ApiModelProperty("已处理数量") + private int processedNumber; + @ApiModelProperty("未巡检数量") + private int notHandledNumber; + @ApiModelProperty("实际巡检数量") + private int actualNumber; +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreport.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreport.java new file mode 100644 index 0000000000..ffa0f454c2 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreport.java @@ -0,0 +1,62 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + +import com.baomidou.mybatisplus.annotation.TableName; +import com.yxt.common.core.domain.BaseEntity; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreport.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreport
+ * Description: 日常管理报告.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "日常管理报告", description = "日常管理报告") +@TableName("scm_veh_patrolinspectionreport") +public class ScmVehPatrolinspectionreport extends BaseEntity { + private static final long serialVersionUID = 1L; + + @ApiModelProperty("月度日常管理记录sid") + private String mainSid; // 月度日常管理记录sid + @ApiModelProperty("接收人sid") + private String receiverSids; // 接收人sid + @ApiModelProperty("接收人姓名") + private String receiverNames; // 接收人姓名 + @ApiModelProperty("盘库报告内容") + private String reportContent; // 盘库报告内容 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDetailsVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDetailsVo.java new file mode 100644 index 0000000000..eeae5cbfd7 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDetailsVo.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportVo.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportVo
+ * Description: 日常管理报告 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "日常管理报告 视图数据详情", description = "日常管理报告 视图数据详情") +public class ScmVehPatrolinspectionreportDetailsVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("月度日常管理记录sid") + private String mainSid; // 月度日常管理记录sid + @ApiModelProperty("接收人sid") + private String receiverSids; // 接收人sid + @ApiModelProperty("接收人姓名") + private String receiverNames; // 接收人姓名 + @ApiModelProperty("盘库报告内容") + private String reportContent; // 盘库报告内容 + +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDto.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDto.java new file mode 100644 index 0000000000..bfb6c3a5ae --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportDto.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + + +import com.yxt.common.core.dto.Dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportDto.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportDto
+ * Description: 日常管理报告 数据传输对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "日常管理报告 数据传输对象", description = "日常管理报告 数据传输对象") +public class ScmVehPatrolinspectionreportDto implements Dto { + + private String sid; // sid + + @ApiModelProperty("月度日常管理记录sid") + private String mainSid; // 月度日常管理记录sid + @ApiModelProperty("接收人sid") + private String receiverSids; // 接收人sid + @ApiModelProperty("接收人姓名") + private String receiverNames; // 接收人姓名 + @ApiModelProperty("盘库报告内容") + private String reportContent; // 盘库报告内容 + +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeign.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeign.java new file mode 100644 index 0000000000..ff9ef6c847 --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeign.java @@ -0,0 +1,78 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import org.springframework.cloud.openfeign.FeignClient; +import org.springframework.web.bind.annotation.*; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportFeign.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportFeign
+ * Description: 日常管理报告.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Api(tags = "日常管理报告") +@FeignClient( + contextId = "aaa-ScmVehPatrolinspectionreport", + name = "aaa", + path = "v1/scmvehpatrolinspectionreport", + fallback = ScmVehPatrolinspectionreportFeignFallback.class) +public interface ScmVehPatrolinspectionreportFeign { + + @ApiOperation("根据条件分页查询数据的列表") + @PostMapping("/listPage") + @ResponseBody + public ResultBean> listPage(@RequestBody PagerQuery pq); + + @ApiOperation("新增或修改") + @PostMapping("/save") + @ResponseBody + public ResultBean save(@RequestBody ScmVehPatrolinspectionreportDto dto); + + @ApiOperation("根据sid删除记录") + @DeleteMapping("/delBySids") + @ResponseBody + public ResultBean delBySids(@RequestBody String[] sids); + + @ApiOperation("根据SID获取一条记录") + @GetMapping("/fetchDetailsBySid/{sid}") + @ResponseBody + public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid); +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeignFallback.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeignFallback.java new file mode 100644 index 0000000000..1f00b36ceb --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportFeignFallback.java @@ -0,0 +1,72 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import org.springframework.stereotype.Component; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportFeignFallback.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportFeignFallback
+ * Description: 日常管理报告.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Component +public class ScmVehPatrolinspectionreportFeignFallback implements ScmVehPatrolinspectionreportFeign { + + @Override + public ResultBean> listPage(PagerQuery pq){ + ResultBean rb = ResultBean.fireFail(); + return rb.setMsg("接口aaa/scmvehpatrolinspectionreport/listPage无法访问"); + } + + @Override + public ResultBean save(ScmVehPatrolinspectionreportDto dto){ + return ResultBean.fireFail().setMsg("接口aaa/scmvehpatrolinspectionreport/save无法访问"); + } + + @Override + public ResultBean delBySids( String[] sids){ + return ResultBean.fireFail().setMsg("接口aaa/scmvehpatrolinspectionreport/delBySids无法访问"); + } + + @Override + public ResultBean fetchDetailsBySid(String sid){ + ResultBean rb = ResultBean.fireFail(); + return rb.setMsg("接口aaa/scmvehpatrolinspectionreport/fetchDetailsBySid无法访问"); + } +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportQuery.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportQuery.java new file mode 100644 index 0000000000..880035dc9e --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportQuery.java @@ -0,0 +1,61 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + + +import com.yxt.common.core.query.Query; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportQuery.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportQuery
+ * Description: 日常管理报告 查询条件.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "日常管理报告 查询条件", description = "日常管理报告 查询条件") +public class ScmVehPatrolinspectionreportQuery implements Query { + + @ApiModelProperty("月度日常管理记录sid") + private String mainSid; // 月度日常管理记录sid + @ApiModelProperty("接收人sid") + private String receiverSids; // 接收人sid + @ApiModelProperty("接收人姓名") + private String receiverNames; // 接收人姓名 + @ApiModelProperty("盘库报告内容") + private String reportContent; // 盘库报告内容 + +} diff --git a/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportVo.java b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportVo.java new file mode 100644 index 0000000000..eb2e368e4a --- /dev/null +++ b/anrui-scm/anrui-scm-api/src/main/java/com/yxt/anrui/scm/api/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportVo.java @@ -0,0 +1,63 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.api.scmvehpatrolinspectionreport; + + +import com.yxt.common.core.vo.Vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportVo.java
+ * Class: com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportVo
+ * Description: 日常管理报告 视图数据对象.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Data +@ApiModel(value = "日常管理报告 视图数据对象", description = "日常管理报告 视图数据对象") +public class ScmVehPatrolinspectionreportVo implements Vo { + + private String sid; // sid + + @ApiModelProperty("月度日常管理记录sid") + private String mainSid; // 月度日常管理记录sid + @ApiModelProperty("接收人sid") + private String receiverSids; // 接收人sid + @ApiModelProperty("接收人姓名") + private String receiverNames; // 接收人姓名 + @ApiModelProperty("盘库报告内容") + private String reportContent; // 盘库报告内容 + +} diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.java index 72ac22fd8f..5bec7ce07d 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.java @@ -34,6 +34,9 @@ import com.yxt.anrui.scm.api.scmvehicleinventory.*; import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleStayInventoryListPageQuery; import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleStayInventoryListPageVo; import com.yxt.anrui.scm.api.scmvehiclestayinventory.ScmVehicleStayInventoryVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppVinAndRemarksVo; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; @@ -76,7 +79,7 @@ public interface ScmVehicleInventoryMapper extends BaseMapper getCarInventoryList(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw, @Param("name") String name); + IPage getCarInventoryList(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw, @Param("names") String names); /** * 手机端-获取待盘库列表 @@ -124,8 +127,17 @@ public interface ScmVehicleInventoryMapper extends BaseMapper selInventory(@Param("vin") String vin, @Param("id") String id, @Param("useOrgSid") String useOrgSid); + @Select(" select InventoryDate as lastDate,InventoryName as lastName from scm_vehicle_inventory where vinNo = #{vin} and id < #{ids} and createOrgSid = #{createOrgSid} ORDER BY id DESC") + List selInventory(@Param("vin") String vin, @Param("ids") String ids, @Param("createOrgSid") String createOrgSid); @Select("select count(*) from scm_vehicle_inventory svi where svi.useOrgSid = #{useOrgSid} and InventoryState = '无' ") int getInventoryState(@Param("useOrgSid") String useOrgSid); + + AppVehInventorymonthVo getMonthByMainSid(@Param("mainSid") String mainSid); + + List getMonthRemarksByMainSid(@Param("sid") String sid, @Param("inventoryStateKey") String inventoryStateKey); + + List selectInventory(@Param("vin") String vin, @Param("id") String id, @Param("createOrgSid") String createOrgSid); + + List selectByUseOrgSid(@Param("createOrgSid") String createOrgSid); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.xml index 0fd02575c2..6db8fc1c99 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.xml +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryMapper.xml @@ -17,8 +17,7 @@ resultType="com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo"> SELECT sid, - mainSid AS vin, - certificateKey AS certificateState, + vinNo AS vin, InventoryState AS `state`, inventorySid, inventoryName, @@ -30,8 +29,8 @@ scm_vehicle_inventory svi ${ew.sqlSegment} - - and concat(svi.mainSid,svi.InventoryName) LIKE concat('%', #{name}, '%') + + and concat(svi.vinNo,svi.InventoryName) LIKE concat('%', #{names}, '%') ORDER BY id DESC @@ -42,6 +41,7 @@ SELECT id, sid, + createOrgSid, vinNo AS vin, location AS warehouse, InventoryDate, @@ -61,19 +61,19 @@ resultType="com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleStayInventoryInfoVo"> SELECT id, sid, - mainSid as vin, + mainSid, + vinNo as vin, location as warehouse, locationSid as warehouseSid, createOrgSid - FROM scm_vehicle_stay_inventory + FROM scm_vehicle_inventory WHERE sid = #{recordSid} SELECT sid, - mainSid as vin, + vinNo as vin, location as warehouse, locationSid as warehouseSid, inventoryName, @@ -114,14 +113,55 @@ FROM scm_vehicle_inventory WHERE sid = #{recordSid} - + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryService.java index 293eb3343d..fdea0ce8b0 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehicleinventory/ScmVehicleInventoryService.java @@ -35,6 +35,9 @@ import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrgFeign; import com.yxt.anrui.scm.api.scmfile.ScmFile; import com.yxt.anrui.scm.api.scmvehicleinventory.*; import com.yxt.anrui.scm.api.scmvehiclestayinventory.*; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppVinAndRemarksVo; import com.yxt.anrui.scm.biz.scmfile.ScmFileService; import com.yxt.anrui.scm.biz.scmvehiclestayinventory.ScmVehicleStayInventoryService; import com.yxt.common.base.config.component.FileUploadComponent; @@ -166,13 +169,7 @@ public class ScmVehicleInventoryService extends MybatisBaseService qw = appCarQueryWrapper(pagerQuery.getParams()); AppScmVehicleCarInventoryListPageQuery params = pagerQuery.getParams(); - IPage iPage = baseMapper.getCarInventoryList(page, qw, params.getName()); -// List records = iPage.getRecords(); -// for (AppScmVehicleCarInventoryListPageVo record : records) { -// if ("2".equals(record.getState())) { -// record.setShowUpdataBtn(true); -// } -// } + IPage iPage = baseMapper.getCarInventoryList(page, qw, params.getNames()); return iPage; } @@ -183,10 +180,10 @@ public class ScmVehicleInventoryService extends MybatisBaseService getInventoryList(PagerQuery pagerQuery) { - SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd"); IPage page = PagerUtil.queryToPage(pagerQuery); String useOrgSid = sysStaffOrgFeign.getPathSidByUserSid(pagerQuery.getParams().getUserSid()).getData(); pagerQuery.getParams().setUseOrgSid(useOrgSid); + SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd"); QueryWrapper qw = new QueryWrapper<>(); qw.eq("isDelete", 0); qw.eq("InventoryState", "无"); @@ -198,6 +195,22 @@ public class ScmVehicleInventoryService extends MybatisBaseService iPage = baseMapper.getInventoryList(page, qw, params.getNames()); + List records = iPage.getRecords(); + for (AppScmVehicleStayInventoryListPageVo record : records) { + List scmVehicleStayInventoryVos = baseMapper.selectInventory(record.getVin(), record.getId(), record.getCreateOrgSid()); + if (scmVehicleStayInventoryVos.size() <= 0) { + record.setInventoryDate("无"); + } else { + ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); + record.setInventoryDate(simpleDateFormat.format(scmVehicleStayInventoryVo.getLastDate())); + } + if (scmVehicleStayInventoryVos.size() <= 0) { + record.setInventoryName("无"); + } else { + ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); + record.setInventoryName(scmVehicleStayInventoryVo.getLastName()); + } + } return iPage; } @@ -216,7 +229,13 @@ public class ScmVehicleInventoryService extends MybatisBaseService= date_format('" + inventStartDate + "','%Y-%m-%d')"). @@ -236,18 +255,21 @@ public class ScmVehicleInventoryService extends MybatisBaseService images = new ArrayList<>(); SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd"); AppScmVehicleStayInventoryInfoVo vo = baseMapper.getInventory(recordSid); - List scmVehicleStayInventoryVos = baseMapper.selInventory(vo.getVin(), vo.getId(), vo.getCreateOrgSid()); - if (scmVehicleStayInventoryVos.size() <= 0) { - vo.setLastData("无"); - } else { - ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); - vo.setLastData(simpleDateFormat.format(scmVehicleStayInventoryVo.getLastDate())); - } - if (scmVehicleStayInventoryVos.size() <= 0) { - vo.setLastName("无"); - } else { - ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); - vo.setLastName(scmVehicleStayInventoryVo.getLastName()); +// List scmVehicleStayInventoryVos = baseMapper.selInventory(vin, ids, createOrgSid); + List scmVehicleStayInventoryVos = baseMapper.selectInventory(vo.getVin(), vo.getId(), vo.getCreateOrgSid()); + if (scmVehicleStayInventoryVos.size() > 0) { + if (scmVehicleStayInventoryVos == null) { + vo.setLastData("无"); + } else { + ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); + vo.setLastData(simpleDateFormat.format(scmVehicleStayInventoryVo.getLastDate())); + } + if (scmVehicleStayInventoryVos == null) { + vo.setLastName("无"); + } else { + ScmVehicleStayInventoryVo scmVehicleStayInventoryVo = scmVehicleStayInventoryVos.get(0); + vo.setLastName(scmVehicleStayInventoryVo.getLastName()); + } } List scmFiles = scmFileService.selectByLinkSid(recordSid, type); for (ScmFile scmFile : scmFiles) { @@ -309,62 +331,108 @@ public class ScmVehicleInventoryService extends MybatisBaseService list = baseMapper.selectByUseOrgSid(createOrgSid); + if (list.size() == 0) { + return rb.setMsg("请先生成盘库记录"); + } + String mainSid = list.get(0); + scmVehicleInventory.setMainSid(mainSid); + scmFileService.deleteByLinkSidAndType(scmVehicleInventory.getSid(), type); + List images = dto.getImages(); + if (dto.getImages() != null) { + if (images.size() > 0) { + for (String image : images) { + if (image.indexOf(fileUploadComponent.getUrlPrefix()) > -1) { + s = image.replace(fileUploadComponent.getUrlPrefix(), ""); + } + ScmFile scmFile = new ScmFile(); + scmFile.setAttachType(type); + scmFile.setFileName("盘库见证材料"); + scmFile.setFilePath(s); + scmFile.setLinkSid(scmVehicleInventory.getSid()); + scmFileService.save(scmFile); + } + } + } + save(scmVehicleInventory); } else { - scmVehicleInventory.setInventorySid(loginSid); - } - scmVehicleInventory.setInventoryDate(new SimpleDateFormat("yyyy-MM-dd").format(new Date())); - scmVehicleInventory.setCreateOrgSid(loginSid); - scmVehicleInventory.setCreateOrgSid(createOrgSid); - scmVehicleInventory.setInventoryStateKey(dto.getInventoryStateKey()); - scmVehicleInventory.setInventoryState(dto.getInventoryState()); + ScmVehicleInventory scmVehicleInventory = fetchBySid(sid); + BeanUtil.copyProperties(dto, scmVehicleInventory, "sid"); + String loginName = dto.getLoginName(); + String loginSid = dto.getLoginSid(); + if (StringUtils.isNotBlank(inventoryName)) { + inventoryName += "、" + loginName; + scmVehicleInventory.setInventoryName(inventoryName); + } else { + scmVehicleInventory.setInventoryName(loginName); + } + if (StringUtils.isNotBlank(inventorySid)) { + inventorySid += "," + loginSid; + scmVehicleInventory.setInventorySid(inventorySid); + } else { + scmVehicleInventory.setInventorySid(loginSid); + } + scmVehicleInventory.setInventoryDate(new SimpleDateFormat("yyyy-MM-dd").format(new Date())); + scmVehicleInventory.setCreateOrgSid(loginSid); + scmVehicleInventory.setCreateOrgSid(createOrgSid); + scmVehicleInventory.setInventoryStateKey(dto.getInventoryStateKey()); + scmVehicleInventory.setInventoryState(dto.getInventoryState()); - scmFileService.deleteByLinkSidAndType(scmVehicleInventory.getSid(), type); - List images = dto.getImages(); - if (dto.getImages() != null) { - if (images.size() > 0) { - for (String image : images) { - if (image.indexOf(fileUploadComponent.getUrlPrefix()) > -1) { - s = image.replace(fileUploadComponent.getUrlPrefix(), ""); + scmFileService.deleteByLinkSidAndType(scmVehicleInventory.getSid(), type); + List images = dto.getImages(); + if (dto.getImages() != null) { + if (images.size() > 0) { + for (String image : images) { + if (image.indexOf(fileUploadComponent.getUrlPrefix()) > -1) { + s = image.replace(fileUploadComponent.getUrlPrefix(), ""); + } + ScmFile scmFile = new ScmFile(); + scmFile.setAttachType(type); + scmFile.setFileName("盘库见证材料"); + scmFile.setFilePath(s); + scmFile.setLinkSid(scmVehicleInventory.getSid()); + scmFileService.save(scmFile); } - ScmFile scmFile = new ScmFile(); - scmFile.setAttachType(type); - scmFile.setFileName("盘库见证材料"); - scmFile.setFilePath(s); - scmFile.setLinkSid(scmVehicleInventory.getSid()); - scmFileService.save(scmFile); } } - } - String sid = dto.getSid(); - if (StringUtils.isNotBlank(sid)) { if (StringUtils.isBlank(dto.getInventoryName())) { scmVehicleStayInventoryService.delBySid(sid, dto.getLoginName()); } else { scmVehicleStayInventoryService.delBySid(sid, dto.getInventoryName()); } + updateById(scmVehicleInventory); } - save(scmVehicleInventory); return rb.success().setMsg("保存成功"); } @@ -428,7 +496,6 @@ public class ScmVehicleInventoryService extends MybatisBaseService getToDoNum(String userSid) { ResultBean rb = ResultBean.fireFail(); String useOrgSid = sysStaffOrgFeign.getPathSidByUserSid(userSid).getData(); - int count = baseMapper.getToDoNum(useOrgSid); + int count = baseMapper.getInventoryState(useOrgSid); return rb.success().setData(String.valueOf(count)); } @@ -462,8 +529,16 @@ public class ScmVehicleInventoryService extends MybatisBaseService getMonthRemarksByMainSid(String sid, String inventoryStateKey) { + return baseMapper.getMonthRemarksByMainSid(sid, inventoryStateKey); } } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.java index 3af0543a7d..b199601960 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.java @@ -31,6 +31,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.toolkit.Constants; import com.yxt.anrui.scm.api.scmvehiclepatrolinspection.*; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.VehPatrolinspectionmonthVo; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; @@ -74,4 +75,9 @@ public interface ScmVehiclePatrolinspectionMapper extends BaseMapper getCarInventoryList(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw, @Param("name") String name); AppScmVehiclePatroVo getInspectionInfo(String recordSid); + + @Select("select count(*) from scm_vehicle_patrolinspection svp where svp.useOrgSid = #{useOrgSid} and patrolInspectionStateKey = '000' ") + int getPatrolinspectionState(String useOrgSid); + + VehPatrolinspectionmonthVo getMonthByMainSid(@Param("mainSid") String mainSid); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.xml index 664f8a8d2f..5306c053b6 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.xml +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionMapper.xml @@ -24,7 +24,8 @@ + \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionService.java index 5a72223821..912b55c760 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspection/ScmVehiclePatrolinspectionService.java @@ -31,6 +31,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage; import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrgFeign; import com.yxt.anrui.scm.api.scmfile.ScmFile; import com.yxt.anrui.scm.api.scmvehiclepatrolinspection.*; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.VehPatrolinspectionmonthVo; import com.yxt.anrui.scm.biz.scmfile.ScmFileService; import com.yxt.common.base.config.component.FileUploadComponent; import com.yxt.common.base.service.MybatisBaseService; @@ -201,4 +202,17 @@ public class ScmVehiclePatrolinspectionService extends MybatisBaseService SELECT sid, - patrolInspectionSid, + vinNo, mainSid, model, situationExplain, @@ -44,6 +44,6 @@ location, address FROM scm_vehicle_patrolinspectionsheet - WHERE patrolInspectionSid = #{sid} + WHERE mainSid = #{sid} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetService.java index b586f171bb..049135f492 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclepatrolinspectionsheet/ScmVehiclePatrolinspectionsheetService.java @@ -176,12 +176,11 @@ public class ScmVehiclePatrolinspectionsheetService extends MybatisBaseService images = dto.getImages(); for (String s : images) { @@ -203,8 +202,6 @@ public class ScmVehiclePatrolinspectionsheetService extends MybatisBaseService images = dto.getImages(); for (String s : images) { @@ -239,7 +236,7 @@ public class ScmVehiclePatrolinspectionsheetService extends MybatisBaseService> getInspectionList(PagerQuery pagerQuery) { if (StringUtils.isBlank(pagerQuery.getParams().getUserSid())) { diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionService.java index 080714e05b..2265e0a01d 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehiclestaypatrolinspection/ScmVehicleStayPatrolinspectionService.java @@ -124,39 +124,6 @@ public class ScmVehicleStayPatrolinspectionService extends MybatisBaseService pathSidByUserSid = sysStaffOrgFeign.getPathSidByUserSid(userSid); - String orgSid = pathSidByUserSid.getData(); - List scmVehicleStayPatrolinspectionVos = baseMapper.selectListVo(orgSid); - if (scmVehicleStayPatrolinspectionVos.size() > 0) { - return rb.setMsg("生成巡检记录失败,请查看是否有未巡检的记录"); - } - List list = baseVehicleFeign.selectInventoryRecords(userSid).getData(); - list.removeAll(Collections.singleton(null)); - if (!list.isEmpty()) { - for (AppScmInventoryRecordsVo appScmInventoryRecordsVo : list) { - ScmVehicleStayPatrolinspection scmVehicleStayPatrolinspection = new ScmVehicleStayPatrolinspection(); - scmVehicleStayPatrolinspection.setMainSid(appScmInventoryRecordsVo.getVin()); - scmVehicleStayPatrolinspection.setLocationSid(appScmInventoryRecordsVo.getWarehouseSid()); - scmVehicleStayPatrolinspection.setLocation(appScmInventoryRecordsVo.getWarehouse()); - scmVehicleStayPatrolinspection.setModelSid(appScmInventoryRecordsVo.getModelSid()); - scmVehicleStayPatrolinspection.setModelName(appScmInventoryRecordsVo.getModelName()); - scmVehicleStayPatrolinspection.setCreateOrgSid(orgSid); - save(scmVehicleStayPatrolinspection); - } - } else { - return rb.setMsg("暂无需要巡检记录"); - } - return rb.success(); - } - /** * 手机端-获取巡检列表 * diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.java index 84e780f6f0..76369ed2cb 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.java @@ -26,14 +26,16 @@ package com.yxt.anrui.scm.biz.scmvehinventorymonth; import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.toolkit.Constants; +import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.*; import org.apache.ibatis.annotations.Mapper; import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Select; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonth; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthVo; +import org.apache.ibatis.annotations.Update; import java.util.List; @@ -53,13 +55,22 @@ import java.util.List; @Mapper public interface ScmVehInventorymonthMapper extends BaseMapper { - //@Update("update scm_veh_inventorymonth set name=#{msg} where id=#{id}") - //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); - - IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); - - List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); - - @Select("select * from scm_veh_inventorymonth") - List selectListVo(); + //@Update("update scm_veh_inventorymonth set name=#{msg} where id=#{id}") + //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); + + IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); + + List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); + + @Select("select * from scm_veh_inventorymonth") + List selectListVo(); + + IPage getCarInventoryReportList(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw, @Param("names") String names); + + String selectNum(String bill); + + @Update("update scm_veh_inventorymonth set state = 1 where sid = #{mainSid}") + void updateByMainSid(@Param("mainSid") String mainSid); + + AppScmVehInventorymonthInfoVo selByMainSid(@Param("sid") String sid); } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.xml index 30c3f5f15d..fb62f301e7 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.xml +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthMapper.xml @@ -1,13 +1,48 @@ - - - - - + + + + + + + + + \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthRest.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthRest.java index 57edb4b2be..0240c5437d 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthRest.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthRest.java @@ -25,8 +25,12 @@ package com.yxt.anrui.scm.biz.scmvehinventorymonth; /*************************** *********************************************************/ +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo; import com.yxt.anrui.scm.api.scmvehinventorymonth.*; import com.yxt.anrui.scm.biz.scmvehinventorymonth.ScmVehInventorymonthService; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.base.utils.StringUtils; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; @@ -101,6 +105,17 @@ public class ScmVehInventorymonthRest implements ScmVehInventorymonthFeign { @Override public ResultBean> getCarInventoryReportList(PagerQuery pagerQuery) { - return null; + if (StringUtils.isBlank(pagerQuery.getParams().getUserSid())) { + new ResultBean<>().success().setMsg("用户sid不能为空"); + } + PagerVo page = new PagerVo<>(); + IPage iPage = scmVehInventorymonthService.getCarInventoryReportList(pagerQuery); + PagerVo pagerVo = PagerUtil.pageToVo(iPage, page); + return new ResultBean>().success().setData(pagerVo); + } + + @Override + public ResultBean getCarInventoryReport(String sid) { + return scmVehInventorymonthService.getCarInventoryReport(sid); } } diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthService.java index b0b93d6ac4..4c6d1bb3c7 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventorymonth/ScmVehInventorymonthService.java @@ -26,15 +26,21 @@ package com.yxt.anrui.scm.biz.scmvehinventorymonth; import cn.hutool.core.bean.BeanUtil; +import com.alibaba.nacos.api.config.filter.IFilterConfig; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.yxt.anrui.base.api.basevehicle.AppScmInventoryRecordsVo; import com.yxt.anrui.base.api.basevehicle.BaseVehicleFeign; +import com.yxt.anrui.base.common.utils.Rule; import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrg; import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrgFeign; import com.yxt.anrui.portal.api.sysuser.SysUserFeign; import com.yxt.anrui.portal.api.sysuser.SysUserVo; +import com.yxt.anrui.scm.api.scmvehiclegression.AppScmVehicleGressionDto; +import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageQuery; +import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleCarInventoryListPageVo; import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventory; +import com.yxt.anrui.scm.api.scmvehinventorymonth.*; import com.yxt.anrui.scm.biz.scmvehicleinventory.ScmVehicleInventoryService; import org.apache.commons.lang3.StringUtils; import com.yxt.common.base.service.MybatisBaseService; @@ -42,18 +48,18 @@ import com.yxt.common.base.utils.PagerUtil; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonth; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthQuery; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthVo; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthDetailsVo; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthDto; -import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthFeign; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; +import java.text.DecimalFormat; +import java.text.SimpleDateFormat; +import java.time.LocalDateTime; +import java.time.ZoneId; +import java.time.format.DateTimeFormatter; import java.util.Collections; +import java.util.Date; import java.util.List; /** @@ -142,7 +148,10 @@ public class ScmVehInventorymonthService extends MybatisBaseService list = baseVehicleFeign.selectInventoryRecords(userSid).getData(); ScmVehInventorymonth scmVehInventorymonth = new ScmVehInventorymonth(); - scmVehInventorymonth.setBillNo(""); + String billNo = getApplyCode(); + scmVehInventorymonth.setBillNo(billNo); + scmVehInventorymonth.setCreateBySid(userSid); + scmVehInventorymonth.setState(0); scmVehInventorymonth.setCreateOrgSid(useOrgSid); scmVehInventorymonth.setCreateOrgName(sysStaffOrg.getOrgName()); scmVehInventorymonth.setUseOrgSid(useOrgSid); @@ -167,4 +176,132 @@ public class ScmVehInventorymonthService extends MybatisBaseService getCarInventoryReportList(PagerQuery pagerQuery) { + IPage page = PagerUtil.queryToPage(pagerQuery); + String useOrgSid = sysStaffOrgFeign.getPathSidByUserSid(pagerQuery.getParams().getUserSid()).getData(); + AppScmVehInventorymonthQuery paramsQuery = pagerQuery.getParams(); + paramsQuery.setUseOrgSid(useOrgSid); + String date = paramsQuery.getDate(); + if (StringUtils.isNotBlank(date)) { + String[] s = date.split("至"); + paramsQuery.setInventStartDate(s[0]); + paramsQuery.setInventEndDate(s[1]); + } + QueryWrapper qw = new QueryWrapper<>(); + if (StringUtils.isNotBlank(paramsQuery.getUseOrgSid())) { + qw.eq("svi.createOrgSid", paramsQuery.getUseOrgSid()); + } + if (StringUtils.isNotBlank(paramsQuery.getState())) { + qw.eq("svi.state", paramsQuery.getState()); + } + String inventStartDate = paramsQuery.getInventStartDate(); + String inventEndDate = paramsQuery.getInventEndDate(); + qw.apply(StringUtils.isNotEmpty(inventStartDate), "date_format (createTime,'%Y-%m-%d') >= date_format('" + inventStartDate + "','%Y-%m-%d')"). + apply(StringUtils.isNotEmpty(inventEndDate), "date_format (createTime,'%Y-%m-%d') <= date_format('" + inventEndDate + "','%Y-%m-%d')" + ); + + IPage iPage = baseMapper.getCarInventoryReportList(page, qw, paramsQuery.getNames()); + for (AppScmVehInventorymonthVo record : iPage.getRecords()) { + String mainSid = record.getSid(); + AppVehInventorymonthVo vo = scmVehicleInventoryService.getMonthByMainSid(mainSid); + record.setSurplusNumber(String.valueOf(vo.getSurplusNumber())); + record.setTotalNumber(String.valueOf(vo.getTotalNumber())); + record.setLossNumber(String.valueOf(vo.getLossNumber())); + record.setDamageNumber(String.valueOf(vo.getDamageNumber())); + record.setProfitNumber(String.valueOf(vo.getProfitNumber())); + record.setActualNumber(String.valueOf(vo.getProfitNumber() + vo.getNormalNumber() + vo.getDamageNumber() + vo.getLossNumber())); + if ("0".equals(record.getState())) { + if (vo.getSurplusNumber() == 0) { + record.setShowBtn(true); + } else { + record.setShowBtn(false); + } + } else { + record.setShowBtn(false); + } + String createBySid = record.getCreateBySid(); + SysUserVo data = sysUserFeign.fetchBySid(createBySid).getData(); + record.setName(data.getName()); + } + return iPage; + } + + public ResultBean getCarInventoryReport(String sid) { + ResultBean rb = ResultBean.fireFail(); + AppScmVehInventorymonthInfoVo vo = new AppScmVehInventorymonthInfoVo(); + AppScmVehInventorymonthInfoVo appScmVehInventorymonthInfoVo = baseMapper.selByMainSid(sid); + if (appScmVehInventorymonthInfoVo != null) { + vo.setRecipient(appScmVehInventorymonthInfoVo.getRecipient()); + vo.setDate(appScmVehInventorymonthInfoVo.getDate()); + } + AppVehInventorymonthVo appScmVehInventorymonthVo = scmVehicleInventoryService.getMonthByMainSid(sid); + //盘亏数量 + vo.setLossNumber(String.valueOf(appScmVehInventorymonthVo.getLossNumber())); + //盘损数量 + vo.setDamageNumber(String.valueOf(appScmVehInventorymonthVo.getDamageNumber())); + //盘盈数量 + vo.setProfitNumber(String.valueOf(appScmVehInventorymonthVo.getProfitNumber())); + //实际盘库数量 + vo.setActualNumber(String.valueOf(appScmVehInventorymonthVo.getProfitNumber() + appScmVehInventorymonthVo.getNormalNumber() + appScmVehInventorymonthVo.getDamageNumber() + appScmVehInventorymonthVo.getLossNumber())); + //正常数量 + vo.setNormalNumber(String.valueOf(appScmVehInventorymonthVo.getNormalNumber())); + //本次应盘数量 + vo.setTotalNumber(String.valueOf(appScmVehInventorymonthVo.getTotalNumber())); + + String inventoryStateKey1 = "001"; + String inventoryStateKey2 = "002"; + String inventoryStateKey3 = "003"; + List profitRemarks = scmVehicleInventoryService.getMonthRemarksByMainSid(sid, inventoryStateKey1); + String profitRemark = ""; + for (AppVinAndRemarksVo remark : profitRemarks) { + profitRemark = remark.getVinNo() + remark.getRemarks() + "," + "\n" + profitRemark; + } + if (StringUtils.isNotBlank(profitRemark)) { + vo.setProfitRemarks(profitRemark.substring(0, profitRemark.length() - 2)); + } + List lossRemarks = scmVehicleInventoryService.getMonthRemarksByMainSid(sid, inventoryStateKey2); + String lossRemark = ""; + for (AppVinAndRemarksVo remark : lossRemarks) { + lossRemark = remark.getVinNo() + remark.getRemarks() + "," + "\n" + lossRemark; + } + if (StringUtils.isNotBlank(lossRemark)) { + vo.setLossRemarks(lossRemark.substring(0, lossRemark.length() - 2)); + } + List damageRemarks = scmVehicleInventoryService.getMonthRemarksByMainSid(sid, inventoryStateKey3); + String damageRemark = ""; + for (AppVinAndRemarksVo remark : damageRemarks) { + damageRemark = remark.getVinNo() + remark.getRemarks() + "," + "\n" + damageRemark; + } + if (StringUtils.isNotBlank(damageRemark)) { + vo.setDamageRemarks(damageRemark.substring(0, damageRemark.length() - 2)); + } + return rb.success().setData(vo); + } + + + public String getApplyCode() { + String billNo = ""; + LocalDateTime now = LocalDateTime.now(ZoneId.of("+8")); + String pattern = "yyyyMM"; + DateTimeFormatter formatter = DateTimeFormatter.ofPattern(pattern); + String bill = formatter.format(now); + String i = baseMapper.selectNum(bill); + if (StringUtils.isNotBlank(i)) { + billNo = getBillNo(bill, Integer.valueOf(i).intValue()); + } else { + billNo = getBillNo(bill, 0); + } + return billNo; + } + + public static String getBillNo(String bill, int i) { + String num = String.format("%02d", i + 1); // 不足2位补0 + String billNo = bill + num; + return billNo; + } + + public void updateByMainSid(String mainSid) { + baseMapper.updateByMainSid(mainSid); + } } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportRest.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportRest.java index 475a96f50c..6452a761fd 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportRest.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportRest.java @@ -97,4 +97,9 @@ public class ScmVehInventoryreportRest implements ScmVehInventoryreportFeign { ScmVehInventoryreportDetailsVo vo = scmVehInventoryreportService.fetchDetailsVoBySid(sid); return rb.success().setData(vo); } + + @Override + public ResultBean sendReport(ScmVehInventoryreportDto dto) { + return scmVehInventoryreportService.sendReport(dto); + } } diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportService.java index ea7055cae2..efd1f0ff8d 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehinventoryreport/ScmVehInventoryreportService.java @@ -26,24 +26,38 @@ package com.yxt.anrui.scm.biz.scmvehinventoryreport; import cn.hutool.core.bean.BeanUtil; +import com.alibaba.fastjson.JSONObject; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; +import com.yxt.anrui.portal.api.appversion.AppVersionDto; +import com.yxt.anrui.portal.api.sysuser.SysUserFeign; +import com.yxt.anrui.portal.api.sysuser.SysUserVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthInfoVo; +import com.yxt.anrui.scm.api.scmvehinventoryreport.*; +import com.yxt.anrui.scm.biz.scmvehinventorymonth.ScmVehInventorymonthService; +import com.yxt.common.base.utils.JPushServer; +import com.yxt.messagecenter.api.message.AppMessageDto; +import com.yxt.messagecenter.api.message.MessageFeign; +import com.yxt.messagecenter.api.message.MsgTargetUriEnum; +import com.yxt.messagecenter.api.messagelist.MessageListDto; +import com.yxt.messagecenter.api.messagelist.MessageListFeign; +import com.yxt.messagecenter.api.messagetype.MessageTypeFeign; +import com.yxt.messagecenter.api.messagetype.MessageTypeVo; import org.apache.commons.lang3.StringUtils; import com.yxt.common.base.service.MybatisBaseService; import com.yxt.common.base.utils.PagerUtil; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreport; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportQuery; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportVo; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportDetailsVo; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportDto; -import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportFeign; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import java.util.ArrayList; import java.util.List; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.concurrent.Future; /** * Project: aaa(aaa)
@@ -60,51 +74,169 @@ import java.util.List; */ @Service public class ScmVehInventoryreportService extends MybatisBaseService { - private QueryWrapper createQueryWrapper(ScmVehInventoryreportQuery query) { - // todo: 这里根据具体业务调整查询条件 - // 多字段Like示例:qw.and(wrapper -> wrapper.like("name", query.getName()).or().like("remark", query.getName())); - QueryWrapper qw = new QueryWrapper<>(); - return qw; - } - - public PagerVo listPageVo(PagerQuery pq) { - ScmVehInventoryreportQuery query = pq.getParams(); - QueryWrapper qw = createQueryWrapper(query); - IPage page = PagerUtil.queryToPage(pq); - IPage pagging = baseMapper.selectPageVo(page, qw); - PagerVo p = PagerUtil.pageToVo(pagging, null); - return p; - } - - public void saveOrUpdateDto(ScmVehInventoryreportDto dto){ + + /** + * 消息类型:0002手机端 + */ + public static final String IDENTIFIER = "0002"; + @Autowired + ScmVehInventorymonthService scmVehInventorymonthService; + @Autowired + private MessageFeign messageFeign; + @Autowired + private MessageTypeFeign messageTypeFeign; + @Autowired + private MessageListFeign messageListFeign; + @Autowired + private SysUserFeign sysUserFeign; + + private QueryWrapper createQueryWrapper(ScmVehInventoryreportQuery query) { + // todo: 这里根据具体业务调整查询条件 + // 多字段Like示例:qw.and(wrapper -> wrapper.like("name", query.getName()).or().like("remark", query.getName())); + QueryWrapper qw = new QueryWrapper<>(); + return qw; + } + + public PagerVo listPageVo(PagerQuery pq) { + ScmVehInventoryreportQuery query = pq.getParams(); + QueryWrapper qw = createQueryWrapper(query); + IPage page = PagerUtil.queryToPage(pq); + IPage pagging = baseMapper.selectPageVo(page, qw); + PagerVo p = PagerUtil.pageToVo(pagging, null); + return p; + } + + public void saveOrUpdateDto(ScmVehInventoryreportDto dto) { String dtoSid = dto.getSid(); if (StringUtils.isBlank(dtoSid)) { this.insertByDto(dto); - return; - } - this.updateByDto(dto); - } - - public void insertByDto(ScmVehInventoryreportDto dto){ - ScmVehInventoryreport entity = new ScmVehInventoryreport(); - BeanUtil.copyProperties(dto, entity, "id", "sid"); - baseMapper.insert(entity); - } - - public void updateByDto(ScmVehInventoryreportDto dto){ - String dtoSid = dto.getSid(); + return; + } + this.updateByDto(dto); + } + + public void insertByDto(ScmVehInventoryreportDto dto) { + ScmVehInventoryreport entity = new ScmVehInventoryreport(); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.insert(entity); + } + + public void updateByDto(ScmVehInventoryreportDto dto) { + String dtoSid = dto.getSid(); if (StringUtils.isBlank(dtoSid)) { return; - } - ScmVehInventoryreport entity = fetchBySid(dtoSid); - BeanUtil.copyProperties(dto, entity, "id", "sid"); - baseMapper.updateById(entity); - } - - public ScmVehInventoryreportDetailsVo fetchDetailsVoBySid(String sid){ - ScmVehInventoryreport entity = fetchBySid(sid); - ScmVehInventoryreportDetailsVo vo = new ScmVehInventoryreportDetailsVo(); - BeanUtil.copyProperties(entity, vo); - return vo; - } + } + ScmVehInventoryreport entity = fetchBySid(dtoSid); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.updateById(entity); + } + + public ScmVehInventoryreportDetailsVo fetchDetailsVoBySid(String sid) { + ScmVehInventoryreport entity = fetchBySid(sid); + ScmVehInventoryreportDetailsVo vo = new ScmVehInventoryreportDetailsVo(); + BeanUtil.copyProperties(entity, vo); + return vo; + } + + public ResultBean sendReport(ScmVehInventoryreportDto dto) { + ResultBean rb = ResultBean.fireFail(); + SysUserVo sysUserVo = sysUserFeign.fetchBySid(dto.getUserSid()).getData(); + ScmVehInventoryreport scmVehInventoryreport = new ScmVehInventoryreport(); + BeanUtil.copyProperties(dto, scmVehInventoryreport, "sid"); + AppScmVehInventorymonthInfoVo data = scmVehInventorymonthService.getCarInventoryReport(dto.getMainSid()).getData(); + scmVehInventoryreport.setReportContent(data.getProfitRemarks() + data.getLossRemarks() + data.getDamageRemarks()); + scmVehInventorymonthService.updateByMainSid(dto.getMainSid()); + List recipientList = dto.getRecipientList(); + String receiverNames = ""; + String receiverSids = ""; + for (RecipientListDto recipientListDto : recipientList) { + receiverNames = recipientListDto.getName() + "," + receiverNames; + receiverSids = recipientListDto.getSid() + "," + receiverSids; + } + scmVehInventoryreport.setReceiverNames(receiverNames.substring(0, receiverNames.length() - 1)); + scmVehInventoryreport.setReceiverSids(receiverSids.substring(0, receiverSids.length() - 1)); + save(scmVehInventoryreport); + List receiveIdList = new ArrayList<>(); + for (RecipientListDto recipientListDto : recipientList) { + SysUserVo sysUserVos = sysUserFeign.fetchBySid(recipientListDto.getSid()).getData(); + Integer id = sysUserVos.getId(); + receiveIdList.add(String.valueOf(id)); + } + AppReportDto appReportDto = new AppReportDto(); + appReportDto.setMsgContent(sysUserVo.getName()); + appReportDto.setList(recipientList); + appReportDto.setMainSid(dto.getMainSid()); + appReportDto.setReceiveIdList(receiveIdList); + // 消息推送 + sendMessage(appReportDto); + return rb.success(); + } + + /** + * 保存消息、发出推送 + * + * @throws InterruptedException + */ + public void sendMessage(AppReportDto appReportDto) { + // 1、保存消息体 + AppMessageDto messageDto = new AppMessageDto(); + ResultBean> messageBean = messageTypeFeign.selectAppMsgTypeList(IDENTIFIER); + if (messageBean.getSuccess() && messageBean.getData() != null) { + List typeVoList = messageBean.getData(); + for (MessageTypeVo message : typeVoList) { + if (message.getMsgType().equals("供应链")) { + messageDto.setMsgTypeSid(message.getMsgTypeSid()); + messageDto.setMsgType(message.getMsgType()); + } + } + } + messageDto.setMsgTitle("月度盘库报告"); + messageDto.setMsgContent(appReportDto.getMsgContent() + "提交的月度盘库报告,请查阅"); + messageDto.setMsgSource("供应链"); + messageDto.setMsgTargetUri(MsgTargetUriEnum.GYLPKBG.getUri()); + messageDto.setApp_type("2"); + messageDto.setModuleSid("98ff0724-5df4-4fc7-ab6d-3996e7706acd"); + JSONObject json = new JSONObject(); + json.put("sid", appReportDto.getMainSid()); + messageDto.setArgs_json(json.toJSONString()); + String msgSid = (String) messageFeign.saveOrUpdateAppMessage(messageDto).getData(); + String msgTypeSid = messageDto.getMsgTypeSid(); + // 2、保存至消息列表 + List list = appReportDto.getList(); + // 使用多线程保存 + List> futures = new ArrayList>(); + ExecutorService executor = Executors.newFixedThreadPool(4); + for (RecipientListDto recipientListDto : list) { + Future f = executor.submit(new Runnable() { + @Override + public void run() { + try { + System.out.println("run start-----------------" + System.currentTimeMillis() + ":" + Thread.currentThread().getName()); + MessageListDto messageList = new MessageListDto(); + messageList.setMsgSid(msgSid); + messageList.setRDelStatus(0); + messageList.setSDelStatus(0); + messageList.setReceiverSid(recipientListDto.getSid()); + messageListFeign.save(messageList); +// Thread.sleep(5 * 1000); + System.out.println("run end-----------------" + System.currentTimeMillis() + ":" + Thread.currentThread().getName()); + } catch (Exception e) { + e.printStackTrace(); + } + } + }); + futures.add(f); + } + executor.shutdown(); + for (int i = 0; i < appReportDto.getReceiveIdList().size(); i++) { + /** + * msgTitle:排产申请 + * content:xxx的排产申请 + */ + JPushServer.sendPushAlias(messageDto.getMsgTitle(), messageDto.getMsgContent(), msgTypeSid, "供应链", appReportDto.getReceiveIdList().get(i)); + } // 3、推送 +// JPushServer.sendPushAll(messageDto.getMsgTitle(), messageDto.getMsgContent(), msgTypeSid, messageDto.getMsgType()); +// JPushServer.sendPushAlias(messageDto.getMsgTitle(), messageDto.getMsgContent(), msgSid, messageDto.getMsgType(), "23","26","66"); // 别名 + System.out.println("process end"); + } } \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.java new file mode 100644 index 0000000000..3b5bb295dc --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.java @@ -0,0 +1,72 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.toolkit.Constants; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppScmVehPatrolinspectionmonthQuery; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppScmVehPatrolinspectionmonthVo; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Select; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonth; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthVo; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthMapper.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthMapper
+ * Description: 月度日常管理记录.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Mapper +public interface ScmVehPatrolinspectionmonthMapper extends BaseMapper { + + //@Update("update scm_veh_patrolinspectionmonth set name=#{msg} where id=#{id}") + //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); + + IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); + + List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); + + @Select("select * from scm_veh_patrolinspectionmonth") + List selectListVo(); + + String selectNum(String bill); + + IPage getCarInspectionReportList(IPage page,@Param(Constants.WRAPPER) QueryWrapper qw, @Param("names") String names); +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.xml new file mode 100644 index 0000000000..7fda4b3585 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthMapper.xml @@ -0,0 +1,42 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthRest.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthRest.java new file mode 100644 index 0000000000..e883d1dc9c --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthRest.java @@ -0,0 +1,120 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth; + +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.*; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.base.utils.StringUtils; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthFeignFallback.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthRest
+ * Description: 月度日常管理记录.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Api(tags = "月度日常管理记录") +@RestController("com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthRest") +@RequestMapping("v1/scmvehpatrolinspectionmonth") +public class ScmVehPatrolinspectionmonthRest implements ScmVehPatrolinspectionmonthFeign { + + @Autowired + private ScmVehPatrolinspectionmonthService scmVehPatrolinspectionmonthService; + + @Override + @ApiOperation("根据条件分页查询数据的列表") + @PostMapping("/listPage") + public ResultBean> listPage(@RequestBody PagerQuery pq) { + ResultBean rb = ResultBean.fireFail(); + PagerVo pv = scmVehPatrolinspectionmonthService.listPageVo(pq); + return rb.success().setData(pv); + } + + @Override + @ApiOperation("新增或修改") + @PostMapping("/save") + public ResultBean save(@RequestBody ScmVehPatrolinspectionmonthDto dto) { + ResultBean rb = ResultBean.fireFail(); + scmVehPatrolinspectionmonthService.saveOrUpdateDto(dto); + return rb.success(); + } + + @Override + @ApiOperation("根据sid批量删除") + @PostMapping("/delBySids") + public ResultBean delBySids(@RequestBody String[] sids) { + ResultBean rb = ResultBean.fireFail(); + scmVehPatrolinspectionmonthService.delBySids(sids); + return rb.success(); + } + + @Override + @ApiOperation("根据SID获取一条记录") + @GetMapping("/fetchDetailsBySid/{sid}") + public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid) { + ResultBean rb = ResultBean.fireFail(); + ScmVehPatrolinspectionmonthDetailsVo vo = scmVehPatrolinspectionmonthService.fetchDetailsVoBySid(sid); + return rb.success().setData(vo); + } + + @Override + public ResultBean getInspectionRecords(String userSid) { + return scmVehPatrolinspectionmonthService.getInspectionRecords(userSid); + } + + @Override + public ResultBean> getCarInspectionReportList(PagerQuery pagerQuery) { + if (StringUtils.isBlank(pagerQuery.getParams().getUserSid())) { + new ResultBean<>().success().setMsg("用户sid不能为空"); + } + PagerVo page = new PagerVo<>(); + IPage iPage = scmVehPatrolinspectionmonthService.getCarInspectionReportList(pagerQuery); + PagerVo pagerVo = PagerUtil.pageToVo(iPage, page); + return new ResultBean>().success().setData(pagerVo); + } + + @Override + public ResultBean getCarInspectionReport(String sid) { + return scmVehPatrolinspectionmonthService.getCarInspectionReport(sid); + } +} diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthService.java new file mode 100644 index 0000000000..4e997e6433 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionmonth/ScmVehPatrolinspectionmonthService.java @@ -0,0 +1,254 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth; + +import cn.hutool.core.bean.BeanUtil; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.yxt.anrui.base.api.basevehicle.AppScmInventoryRecordsVo; +import com.yxt.anrui.base.api.basevehicle.BaseVehicleFeign; +import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrg; +import com.yxt.anrui.portal.api.sysstafforg.SysStaffOrgFeign; +import com.yxt.anrui.portal.api.sysuser.SysUserFeign; +import com.yxt.anrui.portal.api.sysuser.SysUserVo; +import com.yxt.anrui.scm.api.scmvehiclepatrolinspection.ScmVehiclePatrolinspection; +import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.ScmVehicleStayPatrolinspection; +import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.ScmVehicleStayPatrolinspectionVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthInfoVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthQuery; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppVehInventorymonthVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.*; +import com.yxt.anrui.scm.biz.scmvehiclepatrolinspection.ScmVehiclePatrolinspectionService; +import org.apache.commons.lang3.StringUtils; +import com.yxt.common.base.service.MybatisBaseService; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; + +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.time.LocalDateTime; +import java.time.ZoneId; +import java.time.format.DateTimeFormatter; +import java.util.Collections; +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionmonthService.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthService
+ * Description: 月度日常管理记录 业务逻辑.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Service +public class ScmVehPatrolinspectionmonthService extends MybatisBaseService { + + @Autowired + SysStaffOrgFeign sysStaffOrgFeign; + @Autowired + SysUserFeign sysUserFeign; + @Autowired + BaseVehicleFeign baseVehicleFeign; + @Autowired + ScmVehiclePatrolinspectionService scmVehiclePatrolinspectionService; + + private QueryWrapper createQueryWrapper(ScmVehPatrolinspectionmonthQuery query) { + // todo: 这里根据具体业务调整查询条件 + // 多字段Like示例:qw.and(wrapper -> wrapper.like("name", query.getName()).or().like("remark", query.getName())); + QueryWrapper qw = new QueryWrapper<>(); + return qw; + } + + public PagerVo listPageVo(PagerQuery pq) { + ScmVehPatrolinspectionmonthQuery query = pq.getParams(); + QueryWrapper qw = createQueryWrapper(query); + IPage page = PagerUtil.queryToPage(pq); + IPage pagging = baseMapper.selectPageVo(page, qw); + PagerVo p = PagerUtil.pageToVo(pagging, null); + return p; + } + + public void saveOrUpdateDto(ScmVehPatrolinspectionmonthDto dto) { + String dtoSid = dto.getSid(); + if (StringUtils.isBlank(dtoSid)) { + this.insertByDto(dto); + return; + } + this.updateByDto(dto); + } + + public void insertByDto(ScmVehPatrolinspectionmonthDto dto) { + ScmVehPatrolinspectionmonth entity = new ScmVehPatrolinspectionmonth(); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.insert(entity); + } + + public void updateByDto(ScmVehPatrolinspectionmonthDto dto) { + String dtoSid = dto.getSid(); + if (StringUtils.isBlank(dtoSid)) { + return; + } + ScmVehPatrolinspectionmonth entity = fetchBySid(dtoSid); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.updateById(entity); + } + + public ScmVehPatrolinspectionmonthDetailsVo fetchDetailsVoBySid(String sid) { + ScmVehPatrolinspectionmonth entity = fetchBySid(sid); + ScmVehPatrolinspectionmonthDetailsVo vo = new ScmVehPatrolinspectionmonthDetailsVo(); + BeanUtil.copyProperties(entity, vo); + return vo; + } + + /** + * 生成待巡检记录 + * + * @param userSid + */ + @Transactional(rollbackFor = Exception.class) + public ResultBean getInspectionRecords(String userSid) { + ResultBean rb = ResultBean.fireFail(); + + String useOrgSid = sysStaffOrgFeign.getPathSidByUserSid(userSid).getData(); + SysUserVo sysUserVo = sysUserFeign.fetchBySid(userSid).getData(); + SysStaffOrg sysStaffOrg = sysStaffOrgFeign.getOrgByStaffSid(sysUserVo.getStaffSid()).getData(); + boolean inventoryState = scmVehiclePatrolinspectionService.getPatrolinspectionState(userSid); + if (inventoryState) { + return rb.setMsg("巡检记录生成失败,有未巡检完成记录!"); + } + List list = baseVehicleFeign.selectInventoryRecords(userSid).getData(); + ScmVehPatrolinspectionmonth scmVehPatrolinspectionmonth = new ScmVehPatrolinspectionmonth(); + String billNo = getApplyCode(); + scmVehPatrolinspectionmonth.setBillNo(billNo); + scmVehPatrolinspectionmonth.setCreateBySid(userSid); + scmVehPatrolinspectionmonth.setState(0); + scmVehPatrolinspectionmonth.setCreateOrgSid(useOrgSid); + scmVehPatrolinspectionmonth.setCreateOrgName(sysStaffOrg.getOrgName()); + scmVehPatrolinspectionmonth.setUseOrgSid(useOrgSid); + scmVehPatrolinspectionmonth.setUseOrgName(sysStaffOrg.getOrgName()); + save(scmVehPatrolinspectionmonth); + list.removeAll(Collections.singleton(null)); + if (!list.isEmpty()) { + for (AppScmInventoryRecordsVo appScmInventoryRecordsVo : list) { + ScmVehiclePatrolinspection scmVehiclePatrolinspection = new ScmVehiclePatrolinspection(); + scmVehiclePatrolinspection.setVinNo(appScmInventoryRecordsVo.getVin()); + scmVehiclePatrolinspection.setMainSid(scmVehPatrolinspectionmonth.getSid()); + scmVehiclePatrolinspection.setLocation(appScmInventoryRecordsVo.getWarehouse()); + scmVehiclePatrolinspection.setLocationSid(appScmInventoryRecordsVo.getWarehouseSid()); + scmVehiclePatrolinspection.setPatrolInspectionState("待巡检"); + scmVehiclePatrolinspection.setPatrolInspectionStateKey("000"); + scmVehiclePatrolinspection.setCreateOrgSid(useOrgSid); + scmVehiclePatrolinspection.setUseOrgSid(useOrgSid); + scmVehiclePatrolinspectionService.save(scmVehiclePatrolinspection); + } + } else { + return rb.setMsg("暂无需要巡检记录"); + } + return rb.success(); + } + + public String getApplyCode() { + String billNo = ""; + LocalDateTime now = LocalDateTime.now(ZoneId.of("+8")); + String pattern = "yyyyMM"; + DateTimeFormatter formatter = DateTimeFormatter.ofPattern(pattern); + String bill = formatter.format(now); + String i = baseMapper.selectNum(bill); + if (StringUtils.isNotBlank(i)) { + billNo = getBillNo(bill, Integer.valueOf(i).intValue()); + } else { + billNo = getBillNo(bill, 0); + } + return billNo; + } + + public static String getBillNo(String bill, int i) { + String num = String.format("%02d", i + 1); // 不足2位补0 + String billNo = bill + num; + return billNo; + } + + public IPage getCarInspectionReportList(PagerQuery pagerQuery) { + IPage page = PagerUtil.queryToPage(pagerQuery); + String useOrgSid = sysStaffOrgFeign.getPathSidByUserSid(pagerQuery.getParams().getUserSid()).getData(); + AppScmVehPatrolinspectionmonthQuery paramsQuery = pagerQuery.getParams(); + paramsQuery.setUseOrgSid(useOrgSid); + String date = paramsQuery.getDate(); + if (StringUtils.isNotBlank(date)) { + String[] s = date.split("至"); + paramsQuery.setInventStartDate(s[0]); + paramsQuery.setInventEndDate(s[1]); + } + QueryWrapper qw = new QueryWrapper<>(); + if (StringUtils.isNotBlank(paramsQuery.getUseOrgSid())) { + qw.eq("svp.createOrgSid", paramsQuery.getUseOrgSid()); + } + if (StringUtils.isNotBlank(paramsQuery.getState())) { + qw.eq("svp.state", paramsQuery.getState()); + } + String inventStartDate = paramsQuery.getInventStartDate(); + String inventEndDate = paramsQuery.getInventEndDate(); + qw.apply(StringUtils.isNotEmpty(inventStartDate), "date_format (createTime,'%Y-%m-%d') >= date_format('" + inventStartDate + "','%Y-%m-%d')"). + apply(StringUtils.isNotEmpty(inventEndDate), "date_format (createTime,'%Y-%m-%d') <= date_format('" + inventEndDate + "','%Y-%m-%d')" + ); + IPage iPage = baseMapper.getCarInspectionReportList(page, qw, paramsQuery.getNames()); + for (AppScmVehPatrolinspectionmonthVo record : iPage.getRecords()) { + String mainSid = record.getSid(); + VehPatrolinspectionmonthVo vo = scmVehiclePatrolinspectionService.getMonthByMainSid(mainSid); + record.setSurplusNumber(String.valueOf(vo.getSurplusNumber())); + record.setTotalNumber(String.valueOf(vo.getTotalNumber())); + record.setUnHandledNumber(String.valueOf(vo.getUnHandledNumber())); + record.setProcessedNumber(String.valueOf(vo.getProcessedNumber())); + record.setNotHandledNumber(String.valueOf(vo.getNotHandledNumber())); + record.setActualNumber(String.valueOf(vo.getTotalNumber() - vo.getNotHandledNumber())); + String createBySid = record.getCreateBySid(); + SysUserVo data = sysUserFeign.fetchBySid(createBySid).getData(); + record.setName(data.getName()); + } + return iPage; + } + + public ResultBean getCarInspectionReport(String sid) { + ResultBean rb = ResultBean.fireFail(); + AppScmVehPatrolinspectionmonthInfoVo vo = new AppScmVehPatrolinspectionmonthInfoVo(); + VehPatrolinspectionmonthVo vehPatrolinspectionmonthVo = scmVehiclePatrolinspectionService.getMonthByMainSid(sid); + vo.setActualNumber(String.valueOf(vehPatrolinspectionmonthVo.getTotalNumber() - vehPatrolinspectionmonthVo.getNotHandledNumber())); + vo.setTotalNumber(String.valueOf(vehPatrolinspectionmonthVo.getTotalNumber())); + + vo.setQuestion(""); + return rb.success().setData(vo); + } +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.java new file mode 100644 index 0000000000..461997f2a4 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.java @@ -0,0 +1,65 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport; + +import com.baomidou.mybatisplus.core.conditions.Wrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.baomidou.mybatisplus.core.toolkit.Constants; +import org.apache.ibatis.annotations.Mapper; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Select; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreport; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportVo; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportMapper.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportMapper
+ * Description: 日常管理报告.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Mapper +public interface ScmVehPatrolinspectionreportMapper extends BaseMapper { + + //@Update("update scm_veh_patrolinspectionreport set name=#{msg} where id=#{id}") + //IPage voPage(IPage page, @Param(Constants.WRAPPER) QueryWrapper qw); + + IPage selectPageVo(IPage page, @Param(Constants.WRAPPER) Wrapper qw); + + List selectListAllVo(@Param(Constants.WRAPPER) Wrapper qw); + + @Select("select * from scm_veh_patrolinspectionreport") + List selectListVo(); +} \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.xml new file mode 100644 index 0000000000..72e35c4208 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportMapper.xml @@ -0,0 +1,13 @@ + + + + + + + + + \ No newline at end of file diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportRest.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportRest.java new file mode 100644 index 0000000000..383eb11d55 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportRest.java @@ -0,0 +1,100 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport; + +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.*; + +import java.util.List; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreport; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportQuery; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportDetailsVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportDto; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportFeign; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportFeignFallback.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportRest
+ * Description: 日常管理报告.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Api(tags = "日常管理报告") +@RestController("com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportRest") +@RequestMapping("v1/scmvehpatrolinspectionreport") +public class ScmVehPatrolinspectionreportRest implements ScmVehPatrolinspectionreportFeign { + + @Autowired + private ScmVehPatrolinspectionreportService scmVehPatrolinspectionreportService; + + @Override + @ApiOperation("根据条件分页查询数据的列表") + @PostMapping("/listPage") + public ResultBean> listPage(@RequestBody PagerQuery pq){ + ResultBean rb = ResultBean.fireFail(); + PagerVo pv = scmVehPatrolinspectionreportService.listPageVo(pq); + return rb.success().setData(pv); + } + + @Override + @ApiOperation("新增或修改") + @PostMapping("/save") + public ResultBean save(@RequestBody ScmVehPatrolinspectionreportDto dto){ + ResultBean rb = ResultBean.fireFail(); + scmVehPatrolinspectionreportService.saveOrUpdateDto(dto); + return rb.success(); + } + + @Override + @ApiOperation("根据sid批量删除") + @PostMapping("/delBySids") + public ResultBean delBySids(@RequestBody String[] sids){ + ResultBean rb = ResultBean.fireFail(); + scmVehPatrolinspectionreportService.delBySids(sids); + return rb.success(); + } + + @Override + @ApiOperation("根据SID获取一条记录") + @GetMapping("/fetchDetailsBySid/{sid}") + public ResultBean fetchDetailsBySid(@PathVariable("sid") String sid){ + ResultBean rb = ResultBean.fireFail(); + ScmVehPatrolinspectionreportDetailsVo vo = scmVehPatrolinspectionreportService.fetchDetailsVoBySid(sid); + return rb.success().setData(vo); + } +} diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportService.java new file mode 100644 index 0000000000..0fc08925d0 --- /dev/null +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehpatrolinspectionreport/ScmVehPatrolinspectionreportService.java @@ -0,0 +1,110 @@ +/********************************************************* + ********************************************************* + ******************** ******************* + ************* ************ + ******* _oo0oo_ ******* + *** o8888888o *** + * 88" . "88 * + * (| -_- |) * + * 0\ = /0 * + * ___/`---'\___ * + * .' \\| |// '. * + * / \\||| : |||// \ * + * / _||||| -:- |||||- \ * + * | | \\\ - /// | | * + * | \_| ''\---/'' |_/ | * + * \ .-\__ '-' ___/-. / * + * ___'. .' /--.--\ `. .'___ * + * ."" '< `.___\_<|>_/___.' >' "". * + * | | : `- \`.;`\ _ /`;.`/ - ` : | | * + * \ \ `_. \_ __\ /__ _/ .-` / / * + * =====`-.____`.___ \_____/___.-`___.-'===== * + * `=---=' * + * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * + *********__佛祖保佑__永无BUG__验收通过__钞票多多__********* + *********************************************************/ +package com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport; + +import cn.hutool.core.bean.BeanUtil; +import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; +import com.baomidou.mybatisplus.core.metadata.IPage; +import org.apache.commons.lang3.StringUtils; +import com.yxt.common.base.service.MybatisBaseService; +import com.yxt.common.base.utils.PagerUtil; +import com.yxt.common.core.query.PagerQuery; +import com.yxt.common.core.result.ResultBean; +import com.yxt.common.core.vo.PagerVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreport; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportQuery; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportDetailsVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportDto; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportFeign; + +import org.springframework.stereotype.Service; + +import java.util.List; + +/** + * Project: aaa(aaa)
+ * File: ScmVehPatrolinspectionreportService.java
+ * Class: com.yxt.anrui.scm.biz.scmvehpatrolinspectionreport.ScmVehPatrolinspectionreportService
+ * Description: 日常管理报告 业务逻辑.
+ * Copyright: Copyright (c) 2011
+ * Company: https://gitee.com/liuzp315
+ * Makedate: 2022-09-20 18:05:44
+ * + * @author liupopo + * @version 1.0 + * @since 1.0 + */ +@Service +public class ScmVehPatrolinspectionreportService extends MybatisBaseService { + private QueryWrapper createQueryWrapper(ScmVehPatrolinspectionreportQuery query) { + // todo: 这里根据具体业务调整查询条件 + // 多字段Like示例:qw.and(wrapper -> wrapper.like("name", query.getName()).or().like("remark", query.getName())); + QueryWrapper qw = new QueryWrapper<>(); + return qw; + } + + public PagerVo listPageVo(PagerQuery pq) { + ScmVehPatrolinspectionreportQuery query = pq.getParams(); + QueryWrapper qw = createQueryWrapper(query); + IPage page = PagerUtil.queryToPage(pq); + IPage pagging = baseMapper.selectPageVo(page, qw); + PagerVo p = PagerUtil.pageToVo(pagging, null); + return p; + } + + public void saveOrUpdateDto(ScmVehPatrolinspectionreportDto dto){ + String dtoSid = dto.getSid(); + if (StringUtils.isBlank(dtoSid)) { + this.insertByDto(dto); + return; + } + this.updateByDto(dto); + } + + public void insertByDto(ScmVehPatrolinspectionreportDto dto){ + ScmVehPatrolinspectionreport entity = new ScmVehPatrolinspectionreport(); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.insert(entity); + } + + public void updateByDto(ScmVehPatrolinspectionreportDto dto){ + String dtoSid = dto.getSid(); + if (StringUtils.isBlank(dtoSid)) { + return; + } + ScmVehPatrolinspectionreport entity = fetchBySid(dtoSid); + BeanUtil.copyProperties(dto, entity, "id", "sid"); + baseMapper.updateById(entity); + } + + public ScmVehPatrolinspectionreportDetailsVo fetchDetailsVoBySid(String sid){ + ScmVehPatrolinspectionreport entity = fetchBySid(sid); + ScmVehPatrolinspectionreportDetailsVo vo = new ScmVehPatrolinspectionreportDetailsVo(); + BeanUtil.copyProperties(entity, vo); + return vo; + } +} \ No newline at end of file diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeign.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeign.java index c82ad00b53..6830038de7 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeign.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeign.java @@ -59,6 +59,16 @@ public interface AppScmVehiclePatrolinspectionFeign { @ResponseBody public ResultBean getInspectionRecords(@PathVariable("userSid") String userSid); + @ApiOperation("手机端-获取巡检报告列表") + @PostMapping("/getCarInventoryReportList") + @ResponseBody + public ResultBean> getCarInspectionReportList(@RequestBody PagerQuery pagerQuery); + + @ApiOperation("手机端-获取巡检报告") + @GetMapping("/getCarInspectionReport/{sid}") + @ResponseBody + public ResultBean getCarInspectionReport(@PathVariable("sid") String sid); + @ApiOperation("手机端-获取巡检列表") @PostMapping("/getInspectionList") @ResponseBody diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeignFallback.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeignFallback.java index 0b146a4423..ebf4422194 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeignFallback.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/AppScmVehiclePatrolinspectionFeignFallback.java @@ -52,6 +52,16 @@ public class AppScmVehiclePatrolinspectionFeignFallback implements AppScmVehicle return null; } + @Override + public ResultBean> getCarInspectionReportList(PagerQuery pagerQuery) { + return null; + } + + @Override + public ResultBean getCarInspectionReport(String sid) { + return null; + } + @Override public ResultBean> getInspectionList(PagerQuery pagerQuery) { return null; diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthInfoVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthInfoVo.java new file mode 100644 index 0000000000..43b39ecb1c --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthInfoVo.java @@ -0,0 +1,19 @@ +package com.yxt.anrui.terminal.api.supplychain.inspection; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehPatrolinspectionmonthInfoVo implements Vo { + private static final long serialVersionUID = 7694954957647668016L; + + @ApiModelProperty("本次应巡检数量") + private String totalNumber; + + @ApiModelProperty("实际巡检数量") + private String actualNumber; + + @ApiModelProperty("存在的问题") + private String question; +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthQuery.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthQuery.java new file mode 100644 index 0000000000..54c1b698ce --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthQuery.java @@ -0,0 +1,38 @@ +package com.yxt.anrui.terminal.api.supplychain.inspection; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.query.Query; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehPatrolinspectionmonthQuery implements Query { + private static final long serialVersionUID = 5398446260642774602L; + + @ApiModelProperty("用户sid") + private String userSid; + + @ApiModelProperty("报告编号/创建人") + private String names; + + @ApiModelProperty("创建日期") + private String date; + + @ApiModelProperty("巡检报告sid") + private String reportSid; + + @ApiModelProperty("巡检状态") + private String state; + + @ApiModelProperty("分公司sid") + private String useOrgSid; + + @ApiModelProperty("盘库开始日期") + @JsonProperty("InventStartDate") + private String InventStartDate; + + @ApiModelProperty("盘库结束日期") + @JsonProperty("InventEndDate") + private String InventEndDate; + +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthVo.java new file mode 100644 index 0000000000..11f65660eb --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inspection/VehPatrolinspectionmonthVo.java @@ -0,0 +1,33 @@ +package com.yxt.anrui.terminal.api.supplychain.inspection; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehPatrolinspectionmonthVo implements Vo { + private static final long serialVersionUID = -8549821469505619262L; + + private String sid; + @ApiModelProperty("编号") + private String reportId; + @ApiModelProperty("创建人员") + private String name; + @ApiModelProperty("创建人sid") + private String createBySid; + @ApiModelProperty("创建时间") + private String date; + @ApiModelProperty("剩余巡检记录数量") + private String surplusNumber; + @ApiModelProperty("巡检记录总数数量") + private String totalNumber; + @ApiModelProperty("未处理数量") + private String unHandledNumber; + @ApiModelProperty("已处理数量") + private String processedNumber; + @ApiModelProperty("未巡检数量") + private String notHandledNumber; + @ApiModelProperty("实际巡检数量") + private String actualNumber; + +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeign.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeign.java index f9f0a0d4c5..c20c39ceb3 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeign.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeign.java @@ -94,4 +94,18 @@ public interface AppScmVehicleInventoryFeign { @ResponseBody public ResultBean getInventoryInfo(@PathVariable("recordSid") String recordSid); + @ApiOperation("手机端-获取盘库报告列表") + @PostMapping("/getCarInventoryReportList") + @ResponseBody + public ResultBean> getCarInventoryReportList(@RequestBody PagerQuery pagerQuery); + + @ApiOperation("手机端-获取盘库报告") + @GetMapping("/getCarInventoryReport/{sid}") + @ResponseBody + public ResultBean getCarInventoryReport(@PathVariable("sid") String sid); + + @ApiOperation("发送报告") + @PostMapping("/sendReport") + @ResponseBody + public ResultBean sendReport(@RequestBody VehInventoryreportDto dto); } \ No newline at end of file diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeignFallback.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeignFallback.java index c578c685f5..a9e337da50 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeignFallback.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/AppScmVehicleInventoryFeignFallback.java @@ -85,4 +85,19 @@ public class AppScmVehicleInventoryFeignFallback implements AppScmVehicleInvento public ResultBean getInventoryInfo(String recordSid) { return null; } + + @Override + public ResultBean> getCarInventoryReportList(PagerQuery pagerQuery) { + return null; + } + + @Override + public ResultBean getCarInventoryReport(String sid) { + return null; + } + + @Override + public ResultBean sendReport(VehInventoryreportDto dto) { + return null; + } } \ No newline at end of file diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/CarInventoryListPageQuery.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/CarInventoryListPageQuery.java index 4dcef12f04..dc9cbd5147 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/CarInventoryListPageQuery.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/CarInventoryListPageQuery.java @@ -11,7 +11,7 @@ public class CarInventoryListPageQuery implements Query { private String userSid; @ApiModelProperty("优先匹配车架号 盘库人员") - private String name; + private String names; @ApiModelProperty("时间段 示例 2020-02-01至2022-03-31") private String date; @@ -22,6 +22,9 @@ public class CarInventoryListPageQuery implements Query { @ApiModelProperty("盘库状态") private String state; + @ApiModelProperty("月度盘库sid") + private String reportSid; + @ApiModelProperty("使用组织分公司sid") private String useOrgSid; diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/ReportListDto.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/ReportListDto.java new file mode 100644 index 0000000000..1c3180bca1 --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/ReportListDto.java @@ -0,0 +1,16 @@ +package com.yxt.anrui.terminal.api.supplychain.inventory; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.dto.Dto; +import lombok.Data; + +@Data +public class ReportListDto implements Dto { + + private static final long serialVersionUID = 8433387960605551580L; + + private String name; + + private String sid; + +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryDto.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryDto.java index f90f82893f..8b155b21ab 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryDto.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryDto.java @@ -15,9 +15,12 @@ public class StayInventoryDto implements Dto { @JsonProperty(value = "sid") private String sid; - @ApiModelProperty(value = "车架号") + @ApiModelProperty("车架号") @JsonProperty(value = "vin") - private String mainSid; + private String vinNo; // 车架号 + + @ApiModelProperty("月度盘库sid") + private String mainSid; // 月度盘库sid @ApiModelProperty(value = "存放地点") @JsonProperty(value = "warehouse") diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryInfoVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryInfoVo.java index a72fe5ffb0..42f031f9c2 100644 --- a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryInfoVo.java +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/StayInventoryInfoVo.java @@ -56,6 +56,9 @@ public class StayInventoryInfoVo implements Vo { @ApiModelProperty("车架号") private String vin; + @ApiModelProperty("月度盘库sid") + private String mainSid; + @ApiModelProperty("存放地点") private String warehouse; diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthInfoVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthInfoVo.java new file mode 100644 index 0000000000..dd4b81ff86 --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthInfoVo.java @@ -0,0 +1,33 @@ +package com.yxt.anrui.terminal.api.supplychain.inventory; + +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehInventorymonthInfoVo implements Vo { + private static final long serialVersionUID = 8050057958864145264L; + + @ApiModelProperty("本次应盘数量") + private String totalNumber; + @ApiModelProperty("实际盘库数量") + private String actualNumber; + @ApiModelProperty("正常数量") + private String normalNumber; + @ApiModelProperty("盘盈数量") + private String profitNumber; + @ApiModelProperty("盘亏数量") + private String lossNumber; + @ApiModelProperty("盘损数量") + private String damageNumber; + @ApiModelProperty("盘盈备注") + private String profitRemarks; + @ApiModelProperty("盘亏备注") + private String lossRemarks; + @ApiModelProperty("盘损备注") + private String damageRemarks; + @ApiModelProperty("接收人") + private String recipient; + @ApiModelProperty("创建日期") + private String date; +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthQuery.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthQuery.java new file mode 100644 index 0000000000..fb88a31aec --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthQuery.java @@ -0,0 +1,34 @@ +package com.yxt.anrui.terminal.api.supplychain.inventory; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.query.Query; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehInventorymonthQuery implements Query { + + + private static final long serialVersionUID = 1645260422502012478L; + + @ApiModelProperty("用户sid") + private String userSid; + @ApiModelProperty("报告编号/创建人") + private String names; + @ApiModelProperty("创建日期") + private String date; + @ApiModelProperty("盘库报告sid") + private String reportSid; + @ApiModelProperty("盘库结果") + private String state; + @ApiModelProperty("使用组织名称") + private String useOrgSid; + + @ApiModelProperty("盘库开始日期") + @JsonProperty("InventStartDate") + private String InventStartDate; + + @ApiModelProperty("盘库结束日期") + @JsonProperty("InventEndDate") + private String InventEndDate; +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthVo.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthVo.java new file mode 100644 index 0000000000..b17365a96e --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventorymonthVo.java @@ -0,0 +1,47 @@ +package com.yxt.anrui.terminal.api.supplychain.inventory; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.vo.Vo; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +@Data +public class VehInventorymonthVo implements Vo { + private static final long serialVersionUID = 4013561385922623243L; + + private String sid; // sid + @ApiModelProperty("生成报告状态") + private String state; + @ApiModelProperty("编号(yyyyMMdd)") + private String reportId; // 编号(yyyyMMdd) + @ApiModelProperty("创建时间") + private String date; // + @ApiModelProperty("创建人sid") + private String createBySid; + @ApiModelProperty("创建人") + private String name; + @ApiModelProperty("创建组织") + private String createOrgSid; // 创建组织 + @ApiModelProperty("创建组织名称") + private String createOrgName; // 创建组织名称 + @ApiModelProperty("使用组织") + private String useOrgSid; // 使用组织 + @ApiModelProperty("使用组织名称") + private String useOrgName; // 使用组织名称 + @ApiModelProperty("剩余盘库记录数量") + private String surplusNumber; + @ApiModelProperty("盘库记录总数数量") + private String totalNumber; + @ApiModelProperty("盘亏数量") + private String lossNumber; + @ApiModelProperty("盘损数量") + private String damageNumber; + @ApiModelProperty("盘盈数量") + private String profitNumber; + @ApiModelProperty("实盘数量") + private String actualNumber; + @ApiModelProperty("正常数量") + private String normalNumber; + @ApiModelProperty("是否显示生成报告按钮 剩余盘库记录=0时显示") + private Boolean showBtn; +} diff --git a/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventoryreportDto.java b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventoryreportDto.java new file mode 100644 index 0000000000..088e1fd468 --- /dev/null +++ b/anrui-terminal/anrui-terminal-api/src/main/java/com/yxt/anrui/terminal/api/supplychain/inventory/VehInventoryreportDto.java @@ -0,0 +1,21 @@ +package com.yxt.anrui.terminal.api.supplychain.inventory; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.yxt.common.core.dto.Dto; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.util.List; + +@Data +public class VehInventoryreportDto implements Dto { + + private static final long serialVersionUID = -755912358628411197L; + + private String mainSid; + + @ApiModelProperty("接收人list") + private List recipientList; + + private String userSid; +} diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/baseInfo/AppScmBaseInfoService.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/baseInfo/AppScmBaseInfoService.java index a309b48137..f0f363e0a1 100644 --- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/baseInfo/AppScmBaseInfoService.java +++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/baseInfo/AppScmBaseInfoService.java @@ -3,6 +3,8 @@ package com.yxt.anrui.terminal.biz.supplychain.baseInfo; import com.yxt.anrui.scm.api.scmvehicleenterlibrary.ScmVehicleEnterlibraryFeign; import com.yxt.anrui.scm.api.scmvehicleexamine.ScmVehicleExamineFeign; import com.yxt.anrui.scm.api.scmvehiclegression.ScmVehicleGressionFeign; +import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventory; +import com.yxt.anrui.scm.api.scmvehicleinventory.ScmVehicleInventoryFeign; import com.yxt.anrui.scm.api.scmvehiclestayinventory.ScmVehicleStayInventoryFeign; import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.ScmVehicleStayPatrolinspectionFeign; import com.yxt.anrui.terminal.api.supplychain.baseInfo.AppScmBaseInfoVo; @@ -20,7 +22,7 @@ public class AppScmBaseInfoService { @Autowired ScmVehicleGressionFeign scmVehicleGressionFeign; @Autowired - ScmVehicleStayInventoryFeign scmVehicleStayInventoryFeign; + ScmVehicleInventoryFeign scmVehicleInventoryFeign; @Autowired ScmVehicleStayPatrolinspectionFeign scmVehicleStayPatrolinspectionFeign; @@ -31,12 +33,12 @@ public class AppScmBaseInfoService { String inspectedCarNum = scmVehicleExamineFeign.getToDoNum(userSid).getData(); String storageCarNum = scmVehicleEnterlibraryFeign.getToDoNum(userSid).getData(); String moveCarNum = scmVehicleGressionFeign.getToDoNum(userSid).getData(); -// String inventoryCarNum = scmVehicleStayInventoryFeign.getToDoNum(userSid).getData(); + String inventoryCarNum = scmVehicleInventoryFeign.getToDoNum(userSid).getData(); String inspectinoCarNum = scmVehicleStayPatrolinspectionFeign.getToDoNum(userSid).getData(); appScmBaseInfoVo.setInspectedCarNum(inspectedCarNum); appScmBaseInfoVo.setStorageCarNum(storageCarNum); appScmBaseInfoVo.setMoveCarNum(moveCarNum); -// appScmBaseInfoVo.setInventoryCarNum(inventoryCarNum); + appScmBaseInfoVo.setInventoryCarNum(inventoryCarNum); appScmBaseInfoVo.setInspectinoCarNum(inspectinoCarNum); return rb.success().setData(appScmBaseInfoVo); } diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionRest.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionRest.java index 84003ed6f1..5441208d3b 100644 --- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionRest.java +++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionRest.java @@ -61,6 +61,16 @@ public class AppScmVehiclePatrolinspectionRest implements AppScmVehiclePatrolins return appScmVehiclePatrolinspectionService.getInspectionRecords(userSid); } + @Override + public ResultBean> getCarInspectionReportList(PagerQuery pagerQuery) { + return appScmVehiclePatrolinspectionService.getCarInspectionReportList(pagerQuery); + } + + @Override + public ResultBean getCarInspectionReport(String sid) { + return appScmVehiclePatrolinspectionService.getCarInspectionReport(sid); + } + @Override public ResultBean> getInspectionList(PagerQuery pagerQuery) { return appScmVehiclePatrolinspectionService.getInspectionList(pagerQuery); diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionService.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionService.java index cf01e929ad..35d2cacb97 100644 --- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionService.java +++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inspection/AppScmVehiclePatrolinspectionService.java @@ -36,6 +36,10 @@ import com.yxt.anrui.scm.api.scmvehiclepatrolinspectionsheet.ScmVehiclePatrolins import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.AppScmVehicleStayPatrolinspectionPageQuery; import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.AppScmVehicleStayPatrolinspectionPageVo; import com.yxt.anrui.scm.api.scmvehiclestaypatrolinspection.ScmVehicleStayPatrolinspectionFeign; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppScmVehPatrolinspectionmonthInfoVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppScmVehPatrolinspectionmonthQuery; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.AppScmVehPatrolinspectionmonthVo; +import com.yxt.anrui.scm.api.scmvehpatrolinspectionmonth.ScmVehPatrolinspectionmonthFeign; import com.yxt.anrui.terminal.api.supplychain.inspection.*; import com.yxt.anrui.terminal.config.CoverUtils; import com.yxt.common.core.query.PagerQuery; @@ -68,9 +72,11 @@ public class AppScmVehiclePatrolinspectionService { @Autowired ScmVehiclePatrolinspectionsheetFeign scmVehiclePatrolinspectionsheetFeign; + @Autowired + ScmVehPatrolinspectionmonthFeign scmVehPatrolinspectionmonthFeign; public ResultBean getInspectionRecords(String userSid) { - ResultBean resultBean = scmVehicleStayPatrolinspectionFeign.getInspectionRecords(userSid); + ResultBean resultBean = scmVehPatrolinspectionmonthFeign.getInspectionRecords(userSid); return resultBean; } @@ -126,10 +132,31 @@ public class AppScmVehiclePatrolinspectionService { ResultBean rb = ResultBean.fireFail(); AppScmVehiclePatrolinVo vo = new AppScmVehiclePatrolinVo(); ResultBean getInspectionInfo = scmVehiclePatrolinspectionFeign.getInspectionInfo(recordSid); - if(!getInspectionInfo.getSuccess()){ - return rb.setMsg(getInspectionInfo.getMsg()); + if (!getInspectionInfo.getSuccess()) { + return rb.setMsg(getInspectionInfo.getMsg()); + } + BeanUtil.copyProperties(getInspectionInfo.getData(), vo); + return rb.success().setData(vo); + } + + public ResultBean> getCarInspectionReportList(PagerQuery pagerQuery) { + ResultBean> rb = ResultBean.fireFail(); + PagerQuery pq = CoverUtils.getPagerQuery(pagerQuery); + ResultBean> inspectionList = scmVehPatrolinspectionmonthFeign.getCarInspectionReportList(pq); + PagerVo vo = CoverUtils.selectPagerVo(inspectionList.getData()); + return rb.success().setData(vo); + } + + public ResultBean getCarInspectionReport(String sid) { + ResultBean rb = ResultBean.fireFail(); + VehPatrolinspectionmonthInfoVo vo = new VehPatrolinspectionmonthInfoVo(); + ResultBean resultBean = scmVehPatrolinspectionmonthFeign.getCarInspectionReport(sid); + if (!resultBean.getSuccess()) { + return rb.setMsg(resultBean.getMsg()); } - BeanUtil.copyProperties(getInspectionInfo.getData(),vo); + BeanUtil.copyProperties(resultBean.getData(), vo); return rb.success().setData(vo); } + + } \ No newline at end of file diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryRest.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryRest.java index 310ead6886..df2efab410 100644 --- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryRest.java +++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryRest.java @@ -101,4 +101,19 @@ public class AppScmVehicleInventoryRest implements AppScmVehicleInventoryFeign { public ResultBean getInventoryInfo(String recordSid) { return appScmVehicleInventoryService.getInventoryInfo(recordSid); } + + @Override + public ResultBean> getCarInventoryReportList(PagerQuery pagerQuery) { + return appScmVehicleInventoryService.getCarInventoryReportList(pagerQuery); + } + + @Override + public ResultBean getCarInventoryReport(String sid) { + return appScmVehicleInventoryService.getCarInventoryReport(sid); + } + + @Override + public ResultBean sendReport(VehInventoryreportDto dto) { + return appScmVehicleInventoryService.sendReport(dto); + } } diff --git a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryService.java b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryService.java index f2065f47e9..6a43ca848d 100644 --- a/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryService.java +++ b/anrui-terminal/anrui-terminal-biz/src/main/java/com/yxt/anrui/terminal/biz/supplychain/inventory/AppScmVehicleInventoryService.java @@ -30,7 +30,13 @@ import com.yxt.anrui.scm.api.scmvehicleinventory.*; import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleStayInventoryListPageQuery; import com.yxt.anrui.scm.api.scmvehicleinventory.AppScmVehicleStayInventoryListPageVo; import com.yxt.anrui.scm.api.scmvehiclestayinventory.ScmVehicleStayInventoryFeign; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthInfoVo; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthQuery; +import com.yxt.anrui.scm.api.scmvehinventorymonth.AppScmVehInventorymonthVo; import com.yxt.anrui.scm.api.scmvehinventorymonth.ScmVehInventorymonthFeign; +import com.yxt.anrui.scm.api.scmvehinventoryreport.RecipientListDto; +import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportDto; +import com.yxt.anrui.scm.api.scmvehinventoryreport.ScmVehInventoryreportFeign; import com.yxt.anrui.terminal.api.supplychain.inventory.*; import com.yxt.anrui.terminal.config.CoverUtils; import com.yxt.common.core.query.PagerQuery; @@ -39,6 +45,8 @@ import com.yxt.common.core.vo.PagerVo; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import java.util.List; + /** * Project: anrui_scm(anrui_scm)
* File: ScmVehicleInventoryService.java
@@ -64,6 +72,9 @@ public class AppScmVehicleInventoryService { @Autowired ScmVehInventorymonthFeign scmVehInventorymonthFeign; + @Autowired + ScmVehInventoryreportFeign scmVehInventoryreportFeign; + /** * 手机端-判断是否生成盘库记录 * @@ -183,4 +194,43 @@ public class AppScmVehicleInventoryService { BeanUtil.copyProperties(appScmVehicleStayInventoryDetailedsVo, vo); return rb.success().setData(vo); } + + /** + * 盘库报告列表 + * + * @param pagerQuery + * @return + */ + public ResultBean> getCarInventoryReportList(PagerQuery pagerQuery) { + ResultBean> rb = ResultBean.fireFail(); + PagerQuery pq = CoverUtils.getPagerQuery(pagerQuery); + ResultBean> inspectionList = scmVehInventorymonthFeign.getCarInventoryReportList(pq); + PagerVo vo = CoverUtils.selectPagerVo(inspectionList.getData()); + return rb.success().setData(vo); + } + + /** + * 盘库报告 + * + * @param sid + * @return + */ + public ResultBean getCarInventoryReport(String sid) { + ResultBean rb = ResultBean.fireFail(); + VehInventorymonthInfoVo vo = new VehInventorymonthInfoVo(); + ResultBean resultBean = scmVehInventorymonthFeign.getCarInventoryReport(sid); + if (!resultBean.getSuccess()) { + return rb.setMsg(resultBean.getMsg()); + } + AppScmVehInventorymonthInfoVo appScmVehInventorymonthInfoVo = resultBean.getData(); + BeanUtil.copyProperties(appScmVehInventorymonthInfoVo, vo); + return rb.success().setData(vo); + } + + public ResultBean sendReport(VehInventoryreportDto dto) { + ScmVehInventoryreportDto scmVehInventoryreportDto = new ScmVehInventoryreportDto(); + BeanUtil.copyProperties(dto, scmVehInventoryreportDto); + ResultBean resultBean = scmVehInventoryreportFeign.sendReport(scmVehInventoryreportDto); + return resultBean; + } } \ No newline at end of file