From 20751c6749e5dd32fa023db938677b32069b64c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=A3=E5=9C=A3=E5=8D=8E?= <752718920@qq.com> Date: Thu, 29 Jul 2021 22:21:40 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E8=B0=83=E6=8B=A8=E6=98=8E?= =?UTF-8?q?=E7=BB=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jshERP-boot/docs/jsh_erp.sql | 1 + .../docs/数据库更新记录-首次安装请勿使用.txt | 9 ++- .../erp/controller/DepotHeadController.java | 44 ++++++++++++++ .../datasource/mappers/DepotHeadMapperEx.java | 20 +++++++ .../datasource/vo/DepotHeadVo4InDetail.java | 20 +++++++ .../service/depotHead/DepotHeadService.java | 20 +++++++ .../mapper_xml/DepotHeadMapperEx.xml | 60 ++++++++++++++++++- 7 files changed, 171 insertions(+), 3 deletions(-) diff --git a/jshERP-boot/docs/jsh_erp.sql b/jshERP-boot/docs/jsh_erp.sql index 88ead849..1ee1a34a 100644 --- a/jshERP-boot/docs/jsh_erp.sql +++ b/jshERP-boot/docs/jsh_erp.sql @@ -330,6 +330,7 @@ INSERT INTO `jsh_function` VALUES ('244', '030112', '库存预警', '0301', '/re INSERT INTO `jsh_function` VALUES ('245', '000107', '插件管理', '0001', '/system/plugin', '/system/PluginList', '\0', '0170', '', '电脑版', '1', 'profile', '0'); INSERT INTO `jsh_function` VALUES ('246', '030113', '商品库存', '0301', '/report/material_stock', '/report/MaterialStock', '\0', '0605', '', '电脑版', '', 'profile', '0'); INSERT INTO `jsh_function` VALUES ('247', '010105', '多属性', '0101', '/material/material_attribute', '/material/MaterialAttributeList', '\0', '0250', '', '电脑版', '1', 'profile', '0'); +INSERT INTO `jsh_function` VALUES ('248', '030150', '调拨明细', '0301', '/report/allocation_detail', '/report/AllocationDetail', '\0', '0646', '', '电脑版', '', 'profile', '0'); -- ---------------------------- -- Table structure for jsh_in_out_item diff --git a/jshERP-boot/docs/数据库更新记录-首次安装请勿使用.txt b/jshERP-boot/docs/数据库更新记录-首次安装请勿使用.txt index c28ec117..0a7b1568 100644 --- a/jshERP-boot/docs/数据库更新记录-首次安装请勿使用.txt +++ b/jshERP-boot/docs/数据库更新记录-首次安装请勿使用.txt @@ -1183,4 +1183,11 @@ alter table jsh_depot_item drop column other_field5; -- by jishenghua -- 移除机构表的全名字段 -- -------------------------------------------------------- -alter table jsh_depot_item add sku varchar(50) DEFAULT NULL COMMENT '多属性' after material_unit; \ No newline at end of file +alter table jsh_depot_item add sku varchar(50) DEFAULT NULL COMMENT '多属性' after material_unit; + +-- -------------------------------------------------------- +-- 时间 2021年7月29日 +-- by jishenghua +-- 增加调拨明细菜单 +-- -------------------------------------------------------- +INSERT INTO `jsh_function` VALUES ('248', '030150', '调拨明细', '0301', '/report/allocation_detail', '/report/AllocationDetail', '\0', '0646', '', '电脑版', '', 'profile', '0'); diff --git a/jshERP-boot/src/main/java/com/jsh/erp/controller/DepotHeadController.java b/jshERP-boot/src/main/java/com/jsh/erp/controller/DepotHeadController.java index be7a4213..84d0ed2b 100644 --- a/jshERP-boot/src/main/java/com/jsh/erp/controller/DepotHeadController.java +++ b/jshERP-boot/src/main/java/com/jsh/erp/controller/DepotHeadController.java @@ -174,6 +174,50 @@ public class DepotHeadController { return res; } + /** + * 调拨明细接口 TODO:by sdw 20210724 + * @param currentPage + * @param pageSize + * @param oId + * @param materialParam + * @param depotIdF 调出仓库 + * @param depotId 调入仓库 + * @param beginTime + * @param endTime + * @param subType + * @param request + * @return + */ + @GetMapping(value = "/findAllocationDetail") + public BaseResponseInfo findallocationDetail(@RequestParam("currentPage") Integer currentPage, + @RequestParam("pageSize") Integer pageSize, + @RequestParam("organId") Integer oId, + @RequestParam("materialParam") String materialParam, + @RequestParam("depotId") Integer depotId, + @RequestParam("depotIdF") Integer depotIdF, + @RequestParam("beginTime") String beginTime, + @RequestParam("endTime") String endTime, + @RequestParam("subType") String subType, + HttpServletRequest request)throws Exception { + BaseResponseInfo res = new BaseResponseInfo(); + Map map = new HashMap(); + try { + beginTime = Tools.parseDayToTime(beginTime, BusinessConstants.DAY_FIRST_TIME); + endTime = Tools.parseDayToTime(endTime,BusinessConstants.DAY_LAST_TIME); + List list = depotHeadService.findAllocationDetail(beginTime, endTime, subType, materialParam, depotId, depotIdF, oId, (currentPage-1)*pageSize, pageSize); + int total = depotHeadService.findAllocationDetailCount(beginTime, endTime, subType, materialParam, depotId, depotIdF,oId); + map.put("rows", list); + map.put("total", total); + res.code = 200; + res.data = map; + } catch(Exception e){ + e.printStackTrace(); + res.code = 500; + res.data = "获取数据失败"; + } + return res; + } + /** * 对账单接口 * @param currentPage diff --git a/jshERP-boot/src/main/java/com/jsh/erp/datasource/mappers/DepotHeadMapperEx.java b/jshERP-boot/src/main/java/com/jsh/erp/datasource/mappers/DepotHeadMapperEx.java index 85bc7354..767f45df 100644 --- a/jshERP-boot/src/main/java/com/jsh/erp/datasource/mappers/DepotHeadMapperEx.java +++ b/jshERP-boot/src/main/java/com/jsh/erp/datasource/mappers/DepotHeadMapperEx.java @@ -87,6 +87,26 @@ public interface DepotHeadMapperEx { @Param("depotId") Integer depotId, @Param("oId") Integer oId); + List findAllocationDetail( + @Param("beginTime") String beginTime, + @Param("endTime") String endTime, + @Param("subType") String subType, + @Param("materialParam") String materialParam, + @Param("depotId") Integer depotId, + @Param("depotIdF") Integer depotIdF, + @Param("oId") Integer oId, + @Param("offset") Integer offset, + @Param("rows") Integer rows); + + int findAllocationDetailCount( + @Param("beginTime") String beginTime, + @Param("endTime") String endTime, + @Param("subType") String subType, + @Param("materialParam") String materialParam, + @Param("depotId") Integer depotId, + @Param("depotIdF") Integer depotIdF, + @Param("oId") Integer oId); + List findStatementAccount( @Param("beginTime") String beginTime, @Param("endTime") String endTime, diff --git a/jshERP-boot/src/main/java/com/jsh/erp/datasource/vo/DepotHeadVo4InDetail.java b/jshERP-boot/src/main/java/com/jsh/erp/datasource/vo/DepotHeadVo4InDetail.java index 9d3a8c5b..dc109c5a 100644 --- a/jshERP-boot/src/main/java/com/jsh/erp/datasource/vo/DepotHeadVo4InDetail.java +++ b/jshERP-boot/src/main/java/com/jsh/erp/datasource/vo/DepotHeadVo4InDetail.java @@ -18,6 +18,10 @@ public class DepotHeadVo4InDetail { private BigDecimal UnitPrice; + private String mUnit; + + private String newRemark; + private BigDecimal OperNumber; private BigDecimal AllPrice; @@ -80,6 +84,22 @@ public class DepotHeadVo4InDetail { UnitPrice = unitPrice; } + public String getmUnit() { + return mUnit; + } + + public void setmUnit(String mUnit) { + this.mUnit = mUnit; + } + + public String getNewRemark() { + return newRemark; + } + + public void setNewRemark(String newRemark) { + this.newRemark = newRemark; + } + public BigDecimal getOperNumber() { return OperNumber; } diff --git a/jshERP-boot/src/main/java/com/jsh/erp/service/depotHead/DepotHeadService.java b/jshERP-boot/src/main/java/com/jsh/erp/service/depotHead/DepotHeadService.java index 9053f656..de0f10db 100644 --- a/jshERP-boot/src/main/java/com/jsh/erp/service/depotHead/DepotHeadService.java +++ b/jshERP-boot/src/main/java/com/jsh/erp/service/depotHead/DepotHeadService.java @@ -421,6 +421,26 @@ public class DepotHeadService { return result; } + public List findAllocationDetail(String beginTime, String endTime, String subType, String materialParam, Integer depotId, Integer depotIdF, Integer oId, Integer offset, Integer rows) throws Exception{ + List list = null; + try{ + list =depotHeadMapperEx.findAllocationDetail(beginTime, endTime, subType, materialParam, depotId, depotIdF, oId, offset, rows); + }catch(Exception e){ + JshException.readFail(logger, e); + } + return list; + } + + public int findAllocationDetailCount(String beginTime, String endTime, String subType, String materialParam, Integer depotId, Integer depotIdF,Integer oId) throws Exception{ + int result = 0; + try{ + result =depotHeadMapperEx.findAllocationDetailCount(beginTime, endTime, subType, materialParam, depotId,depotIdF, oId); + }catch(Exception e){ + JshException.readFail(logger, e); + } + return result; + } + public List findStatementAccount(String beginTime, String endTime, Integer organId, String supType, Integer offset, Integer rows)throws Exception { List list = null; try{ diff --git a/jshERP-boot/src/main/resources/mapper_xml/DepotHeadMapperEx.xml b/jshERP-boot/src/main/resources/mapper_xml/DepotHeadMapperEx.xml index 217f14bc..0880d860 100644 --- a/jshERP-boot/src/main/resources/mapper_xml/DepotHeadMapperEx.xml +++ b/jshERP-boot/src/main/resources/mapper_xml/DepotHeadMapperEx.xml @@ -172,8 +172,8 @@ + + + +