Commit 4839c85a9dacf73549093b90834093c29f1d607a

Authored by wangyanxiong
2 parents e51310e8 3ecca9bc

合并冲突

Showing 84 changed files with 4823 additions and 1009 deletions
.gitignore
@@ -10,7 +10,7 @@ target/ @@ -10,7 +10,7 @@ target/
10 *.iws 10 *.iws
11 *.iml 11 *.iml
12 *.ipr 12 *.ipr
13 -.idea/workspace.xml 13 +#.idea/workspace.xml
14 .idea/compiler.xml 14 .idea/compiler.xml
15 15
16 16
.idea/MyBatisCodeHelperDatasource.xml
@@ -5,9 +5,9 @@ @@ -5,9 +5,9 @@
5 <ProjectProfile> 5 <ProjectProfile>
6 <option name="addSerializeUid" value="true" /> 6 <option name="addSerializeUid" value="true" />
7 <option name="generateService" value="true" /> 7 <option name="generateService" value="true" />
8 - <option name="javaMapperPackage" value="com.huaheng.pc.shipment.wave.mapper" /> 8 + <option name="javaMapperPackage" value="com.huaheng.pc.inventory.adjust.mapper" />
9 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" /> 9 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" />
10 - <option name="javaModelPackage" value="com.huaheng.pc.shipment.wave.domain" /> 10 + <option name="javaModelPackage" value="com.huaheng.pc.inventory.adjust.domain" />
11 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" /> 11 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" />
12 <option name="lastDatabaseCrudChooseModuleName" value="huaheng" /> 12 <option name="lastDatabaseCrudChooseModuleName" value="huaheng" />
13 <option name="moduleNameToPackageAndPathMap"> 13 <option name="moduleNameToPackageAndPathMap">
@@ -29,13 +29,13 @@ @@ -29,13 +29,13 @@
29 <entry key="huaheng"> 29 <entry key="huaheng">
30 <value> 30 <value>
31 <UserPackageAndPathInfoByModule> 31 <UserPackageAndPathInfoByModule>
32 - <option name="javaMapperPackage" value="com.huaheng.pc.shipment.wave.mapper" /> 32 + <option name="javaMapperPackage" value="com.huaheng.pc.inventory.adjust.mapper" />
33 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" /> 33 <option name="javaMapperPath" value="$PROJECT_DIR$/src/main/java" />
34 - <option name="javaModelPacakge" value="com.huaheng.pc.shipment.wave.domain" /> 34 + <option name="javaModelPacakge" value="com.huaheng.pc.inventory.adjust.domain" />
35 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" /> 35 <option name="javaModelPath" value="$PROJECT_DIR$/src/main/java" />
36 - <option name="javaServicePackage" value="com.huaheng.pc.shipment.wave.service" /> 36 + <option name="javaServicePackage" value="com.huaheng.pc.inventory.adjust.service" />
37 <option name="javaServicePath" value="$PROJECT_DIR$/src/main/java" /> 37 <option name="javaServicePath" value="$PROJECT_DIR$/src/main/java" />
38 - <option name="xmlPackage" value="shipment" /> 38 + <option name="xmlPackage" value="inventory" />
39 <option name="xmlPath" value="E:\code\wms2\src\main\resources\mybatis" /> 39 <option name="xmlPath" value="E:\code\wms2\src\main\resources\mybatis" />
40 </UserPackageAndPathInfoByModule> 40 </UserPackageAndPathInfoByModule>
41 </value> 41 </value>
@@ -45,6 +45,26 @@ @@ -45,6 +45,26 @@
45 <option name="mybatisPlusStaticField" value="false" /> 45 <option name="mybatisPlusStaticField" value="false" />
46 <option name="tableGenerateConfigs"> 46 <option name="tableGenerateConfigs">
47 <map> 47 <map>
  48 + <entry key="wms_v2:adjust_detail">
  49 + <value>
  50 + <TableGenerateConfig>
  51 + <option name="generatedKey" value="id" />
  52 + <option name="javaModelName" value="AdjustDetail" />
  53 + <option name="moduleName" value="huaheng" />
  54 + <option name="useActualColumnName" value="true" />
  55 + </TableGenerateConfig>
  56 + </value>
  57 + </entry>
  58 + <entry key="wms_v2:adjust_header">
  59 + <value>
  60 + <TableGenerateConfig>
  61 + <option name="generatedKey" value="id" />
  62 + <option name="javaModelName" value="AdjustHeader" />
  63 + <option name="moduleName" value="huaheng" />
  64 + <option name="useActualColumnName" value="true" />
  65 + </TableGenerateConfig>
  66 + </value>
  67 + </entry>
48 <entry key="wms_v2:alarm_level"> 68 <entry key="wms_v2:alarm_level">
49 <value> 69 <value>
50 <TableGenerateConfig> 70 <TableGenerateConfig>
@@ -285,6 +305,26 @@ @@ -285,6 +305,26 @@
285 </TableGenerateConfig> 305 </TableGenerateConfig>
286 </value> 306 </value>
287 </entry> 307 </entry>
  308 + <entry key="wms_v2:receipt_detail_history">
  309 + <value>
  310 + <TableGenerateConfig>
  311 + <option name="generatedKey" value="id" />
  312 + <option name="javaModelName" value="ReceiptDetailHistory" />
  313 + <option name="moduleName" value="huaheng" />
  314 + <option name="useActualColumnName" value="true" />
  315 + </TableGenerateConfig>
  316 + </value>
  317 + </entry>
  318 + <entry key="wms_v2:receipt_header_history">
  319 + <value>
  320 + <TableGenerateConfig>
  321 + <option name="generatedKey" value="id" />
  322 + <option name="javaModelName" value="ReceiptHeaderHistory" />
  323 + <option name="moduleName" value="huaheng" />
  324 + <option name="useActualColumnName" value="true" />
  325 + </TableGenerateConfig>
  326 + </value>
  327 + </entry>
288 <entry key="wms_v2:receipt_preference"> 328 <entry key="wms_v2:receipt_preference">
289 <value> 329 <value>
290 <TableGenerateConfig> 330 <TableGenerateConfig>
@@ -511,7 +551,7 @@ @@ -511,7 +551,7 @@
511 <option name="useLomBokOnModel" value="true" /> 551 <option name="useLomBokOnModel" value="true" />
512 <option name="useSwagger" value="true" /> 552 <option name="useSwagger" value="true" />
513 <option name="userMybatisPlus" value="true" /> 553 <option name="userMybatisPlus" value="true" />
514 - <option name="xmlMapperPackage" value="shipment" /> 554 + <option name="xmlMapperPackage" value="inventory" />
515 <option name="xmlMapperPath" value="E:\code\wms2\src\main\resources\mybatis" /> 555 <option name="xmlMapperPath" value="E:\code\wms2\src\main\resources\mybatis" />
516 </ProjectProfile> 556 </ProjectProfile>
517 </option> 557 </option>
.idea/dataSources.xml
1 <?xml version="1.0" encoding="UTF-8"?> 1 <?xml version="1.0" encoding="UTF-8"?>
2 <project version="4"> 2 <project version="4">
3 <component name="DataSourceManagerImpl" format="xml" multifile-model="true"> 3 <component name="DataSourceManagerImpl" format="xml" multifile-model="true">
4 - <data-source source="LOCAL" name="@172.16.29.45" uuid="2845c0bf-201c-4178-b161-2bab8cfbfe5d"> 4 + <data-source source="LOCAL" name="@172.16.29.45" uuid="5e014158-5749-424f-a74a-1c32e588e60f">
5 <driver-ref>mysql.8</driver-ref> 5 <driver-ref>mysql.8</driver-ref>
6 <synchronize>true</synchronize> 6 <synchronize>true</synchronize>
7 <jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver> 7 <jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver>
src/main/java/com/huaheng/pc/config/materialType/domain/MaterialType.java 0 → 100644
  1 +package com.huaheng.pc.config.materialType.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.config.materialType.domain.MaterialType")
  14 +@Data
  15 +@TableName(value = "material_type")
  16 +public class MaterialType implements Serializable {
  17 + /**
  18 + * ID
  19 + */
  20 + @TableId(value = "id", type = IdType.AUTO)
  21 + @ApiModelProperty(value="ID")
  22 + private Integer id;
  23 +
  24 + /**
  25 + * 编码
  26 + */
  27 + @TableField(value = "code")
  28 + @ApiModelProperty(value="编码")
  29 + private String code;
  30 +
  31 + /**
  32 + * 名称
  33 + */
  34 + @TableField(value = "name")
  35 + @ApiModelProperty(value="名称")
  36 + private String name;
  37 +
  38 + /**
  39 + * 货主编码
  40 + */
  41 + @TableField(value = "companyCode")
  42 + @ApiModelProperty(value="货主编码")
  43 + private String companyCode;
  44 +
  45 + /**
  46 + * 仓库编码
  47 + */
  48 + @TableField(value = "warehouseCode")
  49 + @ApiModelProperty(value="仓库编码")
  50 + private String warehouseCode;
  51 +
  52 + /**
  53 + * ABC分类
  54 + */
  55 + @TableField(value = "abcClass")
  56 + @ApiModelProperty(value="ABC分类")
  57 + private String abcClass;
  58 +
  59 + /**
  60 + * 保质期(天)
  61 + */
  62 + @TableField(value = "daysToExpire")
  63 + @ApiModelProperty(value="保质期(天)")
  64 + private Integer daysToExpire;
  65 +
  66 + /**
  67 + * 入库流程
  68 + */
  69 + @TableField(value = "receivingFlow")
  70 + @ApiModelProperty(value="入库流程")
  71 + private String receivingFlow;
  72 +
  73 + /**
  74 + * 出库流程
  75 + */
  76 + @TableField(value = "shippingFlow")
  77 + @ApiModelProperty(value="出库流程")
  78 + private String shippingFlow;
  79 +
  80 + /**
  81 + * 定位规则
  82 + */
  83 + @TableField(value = "locatingRule")
  84 + @ApiModelProperty(value="定位规则")
  85 + private String locatingRule;
  86 +
  87 + /**
  88 + * 分配规则
  89 + */
  90 + @TableField(value = "allocationRule")
  91 + @ApiModelProperty(value="分配规则")
  92 + private String allocationRule;
  93 +
  94 + /**
  95 + * 补货规则
  96 + */
  97 + @TableField(value = "replenishmentRule")
  98 + @ApiModelProperty(value="补货规则")
  99 + private String replenishmentRule;
  100 +
  101 + /**
  102 + * 空货位规则
  103 + */
  104 + @TableField(value = "emptyLocRule")
  105 + @ApiModelProperty(value="空货位规则")
  106 + private String emptyLocRule;
  107 +
  108 + /**
  109 + * 拣货规则
  110 + */
  111 + @TableField(value = "pickingRule")
  112 + @ApiModelProperty(value="拣货规则")
  113 + private String pickingRule;
  114 +
  115 + /**
  116 + * 属性模版
  117 + */
  118 + @TableField(value = "attributeTemplateCode")
  119 + @ApiModelProperty(value="属性模版")
  120 + private String attributeTemplateCode;
  121 +
  122 + /**
  123 + * 记录序列号
  124 + */
  125 + @TableField(value = "trackSerialNum")
  126 + @ApiModelProperty(value="记录序列号")
  127 + private Integer trackSerialNum;
  128 +
  129 + /**
  130 + * 自动生成序列号
  131 + */
  132 + @TableField(value = "autoGenSerialNum")
  133 + @ApiModelProperty(value="自动生成序列号")
  134 + private Integer autoGenSerialNum;
  135 +
  136 + /**
  137 + * 自动生成序列号表达式
  138 + */
  139 + @TableField(value = "autoGenSerialNumFormat")
  140 + @ApiModelProperty(value="自动生成序列号表达式")
  141 + private String autoGenSerialNumFormat;
  142 +
  143 + /**
  144 + * 序列号模版
  145 + */
  146 + @TableField(value = "snTemplateCode")
  147 + @ApiModelProperty(value="序列号模版")
  148 + private String snTemplateCode;
  149 +
  150 + /**
  151 + * 临期预警天数
  152 + */
  153 + @TableField(value = "expiringDays")
  154 + @ApiModelProperty(value="临期预警天数")
  155 + private Integer expiringDays;
  156 +
  157 + /**
  158 + * 收货预警天数
  159 + */
  160 + @TableField(value = "minShelfLifeDays")
  161 + @ApiModelProperty(value="收货预警天数")
  162 + private Integer minShelfLifeDays;
  163 +
  164 + /**
  165 + * 状态
  166 + */
  167 + @TableField(value = "enable")
  168 + @ApiModelProperty(value="状态")
  169 + private Integer enable;
  170 +
  171 + /**
  172 + * 创建时间
  173 + */
  174 + @TableField(value = "created")
  175 + @ApiModelProperty(value="创建时间")
  176 + private Date created;
  177 +
  178 + /**
  179 + * 创建用户
  180 + */
  181 + @TableField(value = "createdBy")
  182 + @ApiModelProperty(value="创建用户")
  183 + private String createdBy;
  184 +
  185 + /**
  186 + * 创建时间
  187 + */
  188 + @TableField(value = "lastUpdated")
  189 + @ApiModelProperty(value="创建时间")
  190 + private Date lastUpdated;
  191 +
  192 + /**
  193 + * 更新用户
  194 + */
  195 + @TableField(value = "lastUpdatedBy")
  196 + @ApiModelProperty(value="更新用户")
  197 + private String lastUpdatedBy;
  198 +
  199 + /**
  200 + * 数据版本
  201 + */
  202 + @TableField(value = "version")
  203 + @ApiModelProperty(value="数据版本")
  204 + private Integer version;
  205 +
  206 + /**
  207 + * 是否AGV区域发货
  208 + */
  209 + @TableField(value = "userDef1")
  210 + @ApiModelProperty(value="是否AGV区域发货")
  211 + private String userDef1;
  212 +
  213 + /**
  214 + * 自定义字段2
  215 + */
  216 + @TableField(value = "userDef2")
  217 + @ApiModelProperty(value="自定义字段2")
  218 + private String userDef2;
  219 +
  220 + /**
  221 + * 商品同步标识
  222 + */
  223 + @TableField(value = "userDef3")
  224 + @ApiModelProperty(value="商品同步标识")
  225 + private String userDef3;
  226 +
  227 + /**
  228 + * 自定义字段4
  229 + */
  230 + @TableField(value = "userDef4")
  231 + @ApiModelProperty(value="自定义字段4")
  232 + private String userDef4;
  233 +
  234 + /**
  235 + * 自定义字段5
  236 + */
  237 + @TableField(value = "userDef5")
  238 + @ApiModelProperty(value="自定义字段5")
  239 + private String userDef5;
  240 +
  241 + /**
  242 + * 自定义字段6
  243 + */
  244 + @TableField(value = "userDef6")
  245 + @ApiModelProperty(value="自定义字段6")
  246 + private String userDef6;
  247 +
  248 + /**
  249 + * 自定义字段7
  250 + */
  251 + @TableField(value = "userDef7")
  252 + @ApiModelProperty(value="自定义字段7")
  253 + private String userDef7;
  254 +
  255 + /**
  256 + * 自定义字段8
  257 + */
  258 + @TableField(value = "userDef8")
  259 + @ApiModelProperty(value="自定义字段8")
  260 + private String userDef8;
  261 +
  262 + private static final long serialVersionUID = 1L;
  263 +}
0 \ No newline at end of file 264 \ No newline at end of file
src/main/java/com/huaheng/pc/config/materialType/mapper/MaterialTypeMapper.java 0 → 100644
  1 +package com.huaheng.pc.config.materialType.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.config.materialType.domain.MaterialType;
  5 +
  6 +public interface MaterialTypeMapper extends BaseMapper<MaterialType> {
  7 +}
0 \ No newline at end of file 8 \ No newline at end of file
src/main/java/com/huaheng/pc/config/materialType/service/MaterialTypeService.java 0 → 100644
  1 +package com.huaheng.pc.config.materialType.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.config.materialType.domain.MaterialType;
  8 +import com.huaheng.pc.config.materialType.mapper.MaterialTypeMapper;
  9 +@Service
  10 +public class MaterialTypeService extends ServiceImpl<MaterialTypeMapper, MaterialType> {
  11 +
  12 +}
src/main/java/com/huaheng/pc/config/statusFlow/controller/StatusFlowDetailController.java
@@ -15,7 +15,9 @@ import com.huaheng.framework.web.page.PageDomain; @@ -15,7 +15,9 @@ import com.huaheng.framework.web.page.PageDomain;
15 import com.huaheng.framework.web.page.TableDataInfo; 15 import com.huaheng.framework.web.page.TableDataInfo;
16 import com.huaheng.framework.web.page.TableSupport; 16 import com.huaheng.framework.web.page.TableSupport;
17 import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail; 17 import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail;
  18 +import com.huaheng.pc.config.statusFlow.domain.StatusFlowHeader;
18 import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService; 19 import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService;
  20 +import com.huaheng.pc.config.statusFlow.service.StatusFlowHeaderService;
19 import io.swagger.annotations.Api; 21 import io.swagger.annotations.Api;
20 import io.swagger.annotations.ApiOperation; 22 import io.swagger.annotations.ApiOperation;
21 import io.swagger.annotations.ApiParam; 23 import io.swagger.annotations.ApiParam;
@@ -35,6 +37,8 @@ public class StatusFlowDetailController extends BaseController { @@ -35,6 +37,8 @@ public class StatusFlowDetailController extends BaseController {
35 37
36 @Resource 38 @Resource
37 private StatusFlowDetailService statusFlowDetailService; 39 private StatusFlowDetailService statusFlowDetailService;
  40 + @Resource
  41 + private StatusFlowHeaderService statusFlowHeaderService;
38 42
39 private String prefix = "config/statusFlowDetail"; 43 private String prefix = "config/statusFlowDetail";
40 44
@@ -70,7 +74,8 @@ public class StatusFlowDetailController extends BaseController { @@ -70,7 +74,8 @@ public class StatusFlowDetailController extends BaseController {
70 .eq(StringUtils.isNotEmpty(statusFlowDetail.getRecordType()), 74 .eq(StringUtils.isNotEmpty(statusFlowDetail.getRecordType()),
71 StatusFlowDetail::getRecordType, statusFlowDetail.getRecordType()) 75 StatusFlowDetail::getRecordType, statusFlowDetail.getRecordType())
72 .eq(StringUtils.isNotNull(statusFlowDetail.getNessary()), 76 .eq(StringUtils.isNotNull(statusFlowDetail.getNessary()),
73 - StatusFlowDetail::getNessary, statusFlowDetail.getNessary()); 77 + StatusFlowDetail::getNessary, statusFlowDetail.getNessary())
  78 + .orderByAsc(StatusFlowDetail::getSequence);
74 79
75 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){ 80 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
76 /*使用分页查询*/ 81 /*使用分页查询*/
@@ -88,7 +93,9 @@ public class StatusFlowDetailController extends BaseController { @@ -88,7 +93,9 @@ public class StatusFlowDetailController extends BaseController {
88 */ 93 */
89 @GetMapping("/add/{headerId}") 94 @GetMapping("/add/{headerId}")
90 public String add(@PathVariable("headerId")Integer headerId, ModelMap mmap) { 95 public String add(@PathVariable("headerId")Integer headerId, ModelMap mmap) {
  96 + StatusFlowHeader statusFlowHeader = statusFlowHeaderService.getById(headerId);
91 mmap.put("headerId",headerId); 97 mmap.put("headerId",headerId);
  98 + mmap.put("headerCode", statusFlowHeader.getCode());
92 return prefix + "/add"; 99 return prefix + "/add";
93 } 100 }
94 101
src/main/java/com/huaheng/pc/config/statusFlow/domain/StatusFlowDetail.java
@@ -22,9 +22,13 @@ public class StatusFlowDetail implements Serializable { @@ -22,9 +22,13 @@ public class StatusFlowDetail implements Serializable {
22 private Integer id; 22 private Integer id;
23 23
24 @TableField(value = "headerId") 24 @TableField(value = "headerId")
25 - @ApiModelProperty(value="null") 25 + @ApiModelProperty(value="头表id")
26 private Integer headerId; 26 private Integer headerId;
27 27
  28 + @TableField(value = "headerCode")
  29 + @ApiModelProperty(value="头表编码")
  30 + private Integer headerCode;
  31 +
28 /** 32 /**
29 * 状态流 33 * 状态流
30 */ 34 */
src/main/java/com/huaheng/pc/config/statusFlow/domain/StatusFlowHeader.java
@@ -25,14 +25,14 @@ public class StatusFlowHeader implements Serializable { @@ -25,14 +25,14 @@ public class StatusFlowHeader implements Serializable {
25 * 状态流 25 * 状态流
26 */ 26 */
27 @TableField(value = "code") 27 @TableField(value = "code")
28 - @ApiModelProperty(value="状态流") 28 + @ApiModelProperty(value="编码")
29 private String code; 29 private String code;
30 30
31 /** 31 /**
32 * 状态流名称 32 * 状态流名称
33 */ 33 */
34 @TableField(value = "name") 34 @TableField(value = "name")
35 - @ApiModelProperty(value="状态流名称") 35 + @ApiModelProperty(value="名称")
36 private String name; 36 private String name;
37 37
38 /** 38 /**
src/main/java/com/huaheng/pc/config/statusFlow/service/StatusFlowDetailService.java
1 package com.huaheng.pc.config.statusFlow.service; 1 package com.huaheng.pc.config.statusFlow.service;
2 2
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
3 import org.springframework.stereotype.Service; 5 import org.springframework.stereotype.Service;
4 import javax.annotation.Resource; 6 import javax.annotation.Resource;
5 import java.util.List; 7 import java.util.List;
  8 +import java.util.WeakHashMap;
  9 +
6 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; 10 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
7 import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail; 11 import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail;
8 import com.huaheng.pc.config.statusFlow.mapper.StatusFlowDetailMapper; 12 import com.huaheng.pc.config.statusFlow.mapper.StatusFlowDetailMapper;
9 @Service 13 @Service
10 public class StatusFlowDetailService extends ServiceImpl<StatusFlowDetailMapper, StatusFlowDetail> { 14 public class StatusFlowDetailService extends ServiceImpl<StatusFlowDetailMapper, StatusFlowDetail> {
11 15
  16 + public List<StatusFlowDetail> queryStatusFlowDetail(String headerCode){
  17 + LambdaQueryWrapper<StatusFlowDetail> lambdaQueryWrapper = Wrappers.lambdaQuery();
  18 + lambdaQueryWrapper.orderByAsc(StatusFlowDetail::getSequence)
  19 + .eq(StatusFlowDetail::getHeaderCode, headerCode);
  20 + return this.list(lambdaQueryWrapper);
  21 + }
12 } 22 }
src/main/java/com/huaheng/pc/config/statusFlow/service/StatusFlowHeaderService.java
1 package com.huaheng.pc.config.statusFlow.service; 1 package com.huaheng.pc.config.statusFlow.service;
2 2
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
3 import org.springframework.stereotype.Service; 5 import org.springframework.stereotype.Service;
4 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; 6 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
5 import com.huaheng.pc.config.statusFlow.domain.StatusFlowHeader; 7 import com.huaheng.pc.config.statusFlow.domain.StatusFlowHeader;
6 import com.huaheng.pc.config.statusFlow.mapper.StatusFlowHeaderMapper; 8 import com.huaheng.pc.config.statusFlow.mapper.StatusFlowHeaderMapper;
7 -@Service 9 +
  10 +import java.util.List;
  11 +import java.util.Map;
  12 +
  13 +@Service("StatusFlow")
8 public class StatusFlowHeaderService extends ServiceImpl<StatusFlowHeaderMapper, StatusFlowHeader> { 14 public class StatusFlowHeaderService extends ServiceImpl<StatusFlowHeaderMapper, StatusFlowHeader> {
9 15
  16 + public List<Map<String, Object>> flowList(){
  17 + LambdaQueryWrapper<StatusFlowHeader> lambda = Wrappers.lambdaQuery();
  18 + lambda.select(StatusFlowHeader::getCode, StatusFlowHeader::getName);
  19 + return this.listMaps(lambda);
  20 + }
10 } 21 }
src/main/java/com/huaheng/pc/inventory/adjustDetail/controller/adjustDetailController.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustDetail.controller;
  2 +
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.metadata.IPage;
  5 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
  6 +import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  7 +import com.huaheng.common.utils.StringUtils;
  8 +import com.huaheng.common.utils.security.ShiroUtils;
  9 +import com.huaheng.framework.aspectj.lang.annotation.Log;
  10 +import com.huaheng.framework.aspectj.lang.constant.BusinessType;
  11 +import com.huaheng.framework.web.controller.BaseController;
  12 +import com.huaheng.framework.web.page.PageDomain;
  13 +import com.huaheng.framework.web.page.TableDataInfo;
  14 +import com.huaheng.framework.web.page.TableSupport;
  15 +import com.huaheng.pc.inventory.adjustDetail.domain.AdjustDetail;
  16 +import com.huaheng.pc.inventory.adjustDetail.service.AdjustDetailService;
  17 +
  18 +import com.huaheng.pc.inventory.adjustHeader.service.AdjustHeaderService;
  19 +import org.springframework.stereotype.Controller;
  20 +import org.springframework.web.bind.annotation.GetMapping;
  21 +import org.springframework.web.bind.annotation.PostMapping;
  22 +import org.springframework.web.bind.annotation.RequestMapping;
  23 +import org.springframework.web.bind.annotation.ResponseBody;
  24 +
  25 +import javax.annotation.Resource;
  26 +import java.util.List;
  27 +
  28 +
  29 +@Controller
  30 +@RequestMapping("/inventory/adjustDetail")
  31 +public class adjustDetailController extends BaseController {
  32 +
  33 +
  34 + @Resource
  35 + private AdjustHeaderService adjustHeaderService;
  36 + @Resource
  37 + private AdjustDetailService adjustDetailService;
  38 +
  39 +
  40 +
  41 + private String prefix = "inventory/adjustDetail";
  42 +
  43 +
  44 + //@RequiresPermissions("inventory:cycleCount:view")
  45 + @GetMapping()
  46 + public String adjustHeader()
  47 + {
  48 + return prefix + "/adjustDetail";
  49 + }
  50 +
  51 +
  52 + /**
  53 + * 查询调整单主列表
  54 + */
  55 + //@RequiresPermissions("inventory:cycleCount:list")
  56 + @PostMapping("/list")
  57 + @Log(title = "库存-调整",operating = "查看调整明细单", action = BusinessType.GRANT)
  58 + @ResponseBody
  59 + public TableDataInfo list(AdjustDetail adjustDetail, String createdBegin, String createdEnd) {
  60 + LambdaQueryWrapper<AdjustDetail> lambdaQueryWrapper = Wrappers.lambdaQuery();
  61 + PageDomain pageDomain = TableSupport.buildPageRequest();
  62 + Integer pageNum = pageDomain.getPageNum();
  63 + Integer pageSize = pageDomain.getPageSize();
  64 +
  65 + lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin), AdjustDetail::getCreated, createdBegin)
  66 + .le(StringUtils.isNotEmpty(createdEnd), AdjustDetail::getCreated, createdEnd)//创建时间范围
  67 + .eq(AdjustDetail::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库
  68 + .eq(adjustDetail.getId() != null, AdjustDetail::getId, adjustDetail.getId())//ID
  69 +
  70 +
  71 + .orderByDesc(AdjustDetail::getId);
  72 +
  73 + if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
  74 + //分页查询
  75 + Page<AdjustDetail> page = new Page<>(pageNum, pageSize);
  76 + IPage<AdjustDetail> iPage = adjustDetailService.page(page, lambdaQueryWrapper);
  77 + return getMpDataTable(iPage.getRecords(), iPage.getTotal());
  78 + } else {
  79 + List<AdjustDetail> list = adjustDetailService.list(lambdaQueryWrapper);
  80 + return getDataTable(list);
  81 + }
  82 + }
  83 +
  84 +
  85 +
  86 +
  87 +
  88 +
  89 +
  90 +
  91 +
  92 +
  93 +
  94 +
  95 +
  96 +}
src/main/java/com/huaheng/pc/inventory/adjustDetail/domain/AdjustDetail.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustDetail.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.inventory.adjustDetail.domain.AdjustDetail")
  14 +@Data
  15 +@TableName(value = "adjust_detail")
  16 +public class AdjustDetail implements Serializable {
  17 + @TableId(value = "id", type = IdType.AUTO)
  18 + @ApiModelProperty(value="null")
  19 + private Integer id;
  20 +
  21 + /**
  22 + * 调整单号
  23 + */
  24 + @TableField(value = "adjustCode")
  25 + @ApiModelProperty(value="调整单号")
  26 + private String adjustCode;
  27 +
  28 + /**
  29 + * 盘点单号
  30 + */
  31 + @TableField(value = "cycleCountCode")
  32 + @ApiModelProperty(value="盘点单号")
  33 + private String cycleCountCode;
  34 +
  35 + /**
  36 + * 盘点单号行号
  37 + */
  38 + @TableField(value = "cycleDetailId")
  39 + @ApiModelProperty(value="盘点明细单号行号")
  40 + private Integer cycleDetailId;
  41 +
  42 + /**
  43 + * 质检单号
  44 + */
  45 + @TableField(value = "checkCode")
  46 + @ApiModelProperty(value="质检单号")
  47 + private String checkCode;
  48 +
  49 + /**
  50 + * 质检明细单号行号
  51 + */
  52 + @TableField(value = "checkDetailId")
  53 + @ApiModelProperty(value="质检明细单号行号")
  54 + private Integer checkDetailId;
  55 +
  56 + /**
  57 + * 调整关联单号
  58 + */
  59 + @TableField(value = "referCode")
  60 + @ApiModelProperty(value="调整关联单号")
  61 + private String referCode;
  62 +
  63 + /**
  64 + * 调整明细关联标识
  65 + */
  66 + @TableField(value = "referDetailId")
  67 + @ApiModelProperty(value="调整明细关联标识")
  68 + private Integer referDetailId;
  69 +
  70 + /**
  71 + * 仓库编码
  72 + */
  73 + @TableField(value = "warehouseCode")
  74 + @ApiModelProperty(value="仓库编码")
  75 + private String warehouseCode;
  76 +
  77 + /**
  78 + * 货主编码
  79 + */
  80 + @TableField(value = "companyCode")
  81 + @ApiModelProperty(value="货主编码")
  82 + private String companyCode;
  83 +
  84 + /**
  85 + * 商品编码
  86 + */
  87 + @TableField(value = "materialCode")
  88 + @ApiModelProperty(value="商品编码")
  89 + private String materialCode;
  90 +
  91 + /**
  92 + * 商品名称
  93 + */
  94 + @TableField(value = "materialName")
  95 + @ApiModelProperty(value="商品名称")
  96 + private String materialName;
  97 +
  98 + /**
  99 + * 商品规格
  100 + */
  101 + @TableField(value = "materialSpec")
  102 + @ApiModelProperty(value="商品规格")
  103 + private String materialSpec;
  104 +
  105 + /**
  106 + * 商品单位
  107 + */
  108 + @TableField(value = "materialUnit")
  109 + @ApiModelProperty(value="商品单位")
  110 + private String materialUnit;
  111 +
  112 + /**
  113 + * 1盘点 ,2 质检 ,3 调整
  114 + */
  115 + @TableField(value = "problemType")
  116 + @ApiModelProperty(value="1盘点 ,2 质检 ,3 调整")
  117 + private String problemType;
  118 +
  119 + /**
  120 + * 属性号
  121 + */
  122 + @TableField(value = "attributeId")
  123 + @ApiModelProperty(value="属性号")
  124 + private Integer attributeId;
  125 +
  126 + /**
  127 + * 调整前库存状态
  128 + */
  129 + @TableField(value = "fromInventorySts")
  130 + @ApiModelProperty(value="调整前库存状态")
  131 + private String fromInventorySts;
  132 +
  133 + /**
  134 + * 调整后库存状态
  135 + */
  136 + @TableField(value = "toInventorySts")
  137 + @ApiModelProperty(value="调整后库存状态")
  138 + private String toInventorySts;
  139 +
  140 + /**
  141 + * 调整前的数量
  142 + */
  143 + @TableField(value = "fromQty")
  144 + @ApiModelProperty(value="调整前的数量")
  145 + private Integer fromQty;
  146 +
  147 + /**
  148 + * 调整后的数量
  149 + */
  150 + @TableField(value = "toQty")
  151 + @ApiModelProperty(value="调整后的数量 ")
  152 + private Integer toQty;
  153 +
  154 + /**
  155 + * 调整变动数量
  156 + */
  157 + @TableField(value = "gapQty")
  158 + @ApiModelProperty(value="调整变动数量 ")
  159 + private Integer gapQty;
  160 +
  161 + /**
  162 + * 状态 -0-待调整 1-已调整 2-未批准 3-已批准
  163 + */
  164 + @TableField(value = "status")
  165 + @ApiModelProperty(value="状态 -0-待调整 1-已调整 2-未批准 3-已批准")
  166 + private Integer status;
  167 +
  168 + /**
  169 + * 创建时间
  170 + */
  171 + @TableField(value = "created")
  172 + @ApiModelProperty(value="创建时间")
  173 + private Date created;
  174 +
  175 + /**
  176 + * 创建人
  177 + * */
  178 + @TableField(value = "createdBy")
  179 + @ApiModelProperty(value = "createdBy")
  180 + private String createdBy;
  181 +
  182 + /**
  183 + * 审批时间
  184 + */
  185 + @TableField(value = "agreeTime")
  186 + @ApiModelProperty(value="审批时间")
  187 + private Date agreeTime;
  188 +
  189 + /**
  190 + * 审批人
  191 + * */
  192 + @TableField(value = "agreeBy")
  193 + @ApiModelProperty(value = "agreeBy")
  194 + private String agreeBy;
  195 +
  196 + /**
  197 + * 备注
  198 + */
  199 + @TableField(value = "Remark")
  200 + @ApiModelProperty(value="备注")
  201 + private String remark;
  202 +
  203 + /**
  204 + * 数据版本
  205 + */
  206 + @TableField(value = "version")
  207 + @ApiModelProperty(value="数据版本")
  208 + private Integer version;
  209 +
  210 + /**
  211 + * 自定义字段1
  212 + */
  213 + @TableField(value = "userDef1")
  214 + @ApiModelProperty(value="自定义字段1")
  215 + private String userDef1;
  216 +
  217 + /**
  218 + * 自定义字段2
  219 + */
  220 + @TableField(value = "userDef2")
  221 + @ApiModelProperty(value="自定义字段2")
  222 + private String userDef2;
  223 +
  224 + /**
  225 + * 自定义字段3
  226 + */
  227 + @TableField(value = "userDef3")
  228 + @ApiModelProperty(value="自定义字段3")
  229 + private String userDef3;
  230 +
  231 + /**
  232 + * 处理标记
  233 + */
  234 + @TableField(value = "processStamp")
  235 + @ApiModelProperty(value="处理标记")
  236 + private String processStamp;
  237 +
  238 + private static final long serialVersionUID = 1L;
  239 +}
0 \ No newline at end of file 240 \ No newline at end of file
src/main/java/com/huaheng/pc/inventory/adjustDetail/mapper/AdjustDetailMapper.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustDetail.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.inventory.adjustDetail.domain.AdjustDetail;
  5 +
  6 +public interface AdjustDetailMapper extends BaseMapper<AdjustDetail> {
  7 +}
0 \ No newline at end of file 8 \ No newline at end of file
src/main/java/com/huaheng/pc/inventory/adjustDetail/service/AdjustDetailService.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustDetail.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  5 +import com.huaheng.pc.inventory.adjustDetail.domain.AdjustDetail;
  6 +import com.huaheng.pc.inventory.adjustDetail.mapper.AdjustDetailMapper;
  7 +@Service
  8 +public class AdjustDetailService extends ServiceImpl<AdjustDetailMapper, AdjustDetail> {
  9 +
  10 +}
src/main/java/com/huaheng/pc/inventory/adjustHeader/controller/adjustHeaderController.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustHeader.controller;
  2 +
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.metadata.IPage;
  5 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
  6 +import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  7 +import com.huaheng.common.utils.StringUtils;
  8 +import com.huaheng.common.utils.security.ShiroUtils;
  9 +import com.huaheng.framework.aspectj.lang.annotation.Log;
  10 +import com.huaheng.framework.aspectj.lang.constant.BusinessType;
  11 +import com.huaheng.framework.web.controller.BaseController;
  12 +import com.huaheng.framework.web.page.PageDomain;
  13 +import com.huaheng.framework.web.page.TableDataInfo;
  14 +import com.huaheng.framework.web.page.TableSupport;
  15 +import com.huaheng.pc.inventory.adjustDetail.service.AdjustDetailService;
  16 +import com.huaheng.pc.inventory.adjustHeader.domain.AdjustHeader;
  17 +import com.huaheng.pc.inventory.adjustHeader.service.AdjustHeaderService;
  18 +import org.springframework.stereotype.Controller;
  19 +import org.springframework.web.bind.annotation.GetMapping;
  20 +import org.springframework.web.bind.annotation.PostMapping;
  21 +import org.springframework.web.bind.annotation.RequestMapping;
  22 +import org.springframework.web.bind.annotation.ResponseBody;
  23 +
  24 +import javax.annotation.Resource;
  25 +import java.util.List;
  26 +
  27 +@Controller
  28 +@RequestMapping("/inventory/adjustHeader")
  29 +public class adjustHeaderController extends BaseController {
  30 +
  31 +
  32 + @Resource
  33 + private AdjustHeaderService adjustHeaderService;
  34 + @Resource
  35 + private AdjustDetailService adjustDetailService;
  36 +
  37 +
  38 +
  39 + private String prefix = "inventory/adjustHeader";
  40 +
  41 +
  42 + //@RequiresPermissions("inventory:cycleCount:view")
  43 + @GetMapping()
  44 + public String adjustHeader()
  45 + {
  46 + return prefix + "/adjustHeader";
  47 + }
  48 +
  49 +
  50 + /**
  51 + * 查询调整单主列表
  52 + */
  53 + //@RequiresPermissions("inventory:cycleCount:list")
  54 + @PostMapping("/list")
  55 + @Log(title = "库存-调整",operating = "查看调整主单", action = BusinessType.GRANT)
  56 + @ResponseBody
  57 + public TableDataInfo list(AdjustHeader adjustHeader, String createdBegin, String createdEnd) {
  58 + LambdaQueryWrapper<AdjustHeader> lambdaQueryWrapper = Wrappers.lambdaQuery();
  59 + PageDomain pageDomain = TableSupport.buildPageRequest();
  60 + Integer pageNum = pageDomain.getPageNum();
  61 + Integer pageSize = pageDomain.getPageSize();
  62 +
  63 + lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin), AdjustHeader::getCreated, createdBegin)
  64 + .le(StringUtils.isNotEmpty(createdEnd), AdjustHeader::getCreated, createdEnd)//创建时间范围
  65 + .eq(AdjustHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库
  66 + .eq(StringUtils.isNotEmpty(adjustHeader.getCode()),AdjustHeader::getCode,adjustHeader.getCode())//调整单编码
  67 + .eq(StringUtils.isNotEmpty(adjustHeader.getCompanyCode()),AdjustHeader::getCompanyCode,adjustHeader.getCompanyCode())//货主
  68 + .eq(StringUtils.isNotEmpty(adjustHeader.getProblemType()),AdjustHeader::getProblemType,adjustHeader.getProblemType())//调整类型
  69 + .eq(StringUtils.isNotEmpty(adjustHeader.getCycleCountCode()),AdjustHeader::getCycleCountCode,adjustHeader.getCycleCountCode())//盘点单号
  70 + .eq(StringUtils.isNotEmpty(adjustHeader.getCheckCode()),AdjustHeader::getCheckCode,adjustHeader.getCheckCode())//质检单号
  71 + .eq(StringUtils.isNotEmpty(adjustHeader.getReferCode()),AdjustHeader::getReferCode,adjustHeader.getReferCode())//上游单编码
  72 + .eq(StringUtils.isNotEmpty(adjustHeader.getCreatedBy()),AdjustHeader::getCreatedBy,adjustHeader.getCreatedBy())//创建人
  73 +
  74 + .orderByDesc(AdjustHeader::getId);
  75 +
  76 + if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
  77 + //分页查询
  78 + Page<AdjustHeader> page = new Page<>(pageNum, pageSize);
  79 + IPage<AdjustHeader> iPage = adjustHeaderService.page(page, lambdaQueryWrapper);
  80 + return getMpDataTable(iPage.getRecords(), iPage.getTotal());
  81 + } else {
  82 + List<AdjustHeader> list = adjustHeaderService.list(lambdaQueryWrapper);
  83 + return getDataTable(list);
  84 + }
  85 + }
  86 +
  87 +
  88 +
  89 +
  90 +
  91 +
  92 +
  93 +
  94 +
  95 +
  96 +}
src/main/java/com/huaheng/pc/inventory/adjustHeader/domain/AdjustHeader.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustHeader.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.util.Date;
  11 +import lombok.Data;
  12 +
  13 +@ApiModel(value="com.huaheng.pc.inventory.adjustHeader.domain.AdjustHeader")
  14 +@Data
  15 +@TableName(value = "adjust_header")
  16 +public class AdjustHeader implements Serializable {
  17 + @TableId(value = "id", type = IdType.AUTO)
  18 + @ApiModelProperty(value="null")
  19 + private Integer id;
  20 +
  21 + /**
  22 + * 编码
  23 + */
  24 + @TableField(value = "code")
  25 + @ApiModelProperty(value="编码")
  26 + private String code;
  27 +
  28 + /**
  29 + * 仓库代码
  30 + */
  31 + @TableField(value = "warehouseCode")
  32 + @ApiModelProperty(value="仓库代码")
  33 + private String warehouseCode;
  34 +
  35 + /**
  36 + * 货主编码
  37 + */
  38 + @TableField(value = "companyCode")
  39 + @ApiModelProperty(value="货主编码")
  40 + private String companyCode;
  41 +
  42 + /**
  43 + * 1盘点 ,2 质检 ,3 调整
  44 + */
  45 + @TableField(value = "problemType")
  46 + @ApiModelProperty(value="1盘点 ,2 质检 ,3 调整")
  47 + private String problemType;
  48 +
  49 + /**
  50 + * 盘点单号
  51 + */
  52 + @TableField(value = "cycleCountCode")
  53 + @ApiModelProperty(value="盘点单号")
  54 + private String cycleCountCode;
  55 +
  56 + /**
  57 + * 质检单号
  58 + */
  59 + @TableField(value = "checkCode")
  60 + @ApiModelProperty(value="质检单号")
  61 + private String checkCode;
  62 +
  63 + /**
  64 + * 关联上游单号
  65 + */
  66 + @TableField(value = "referCode")
  67 + @ApiModelProperty(value="关联上游单号")
  68 + private String referCode;
  69 +
  70 + /**
  71 + * 关联上游系统原因说明
  72 + */
  73 + @TableField(value = "referReason")
  74 + @ApiModelProperty(value="关联上游系统原因说明")
  75 + private String referReason;
  76 +
  77 + /**
  78 + * 创建人
  79 + */
  80 + @TableField(value = "createdBy")
  81 + @ApiModelProperty(value="创建人")
  82 + private String createdBy;
  83 +
  84 + /**
  85 + * 创建时间
  86 + */
  87 + @TableField(value = "created")
  88 + @ApiModelProperty(value="创建时间")
  89 + private Date created;
  90 +
  91 + /**
  92 + * 数据版本
  93 + */
  94 + @TableField(value = "version")
  95 + @ApiModelProperty(value="数据版本")
  96 + private Integer version;
  97 +
  98 + /**
  99 + * 自定义字段1
  100 + */
  101 + @TableField(value = "userDef1")
  102 + @ApiModelProperty(value="自定义字段1")
  103 + private String userDef1;
  104 +
  105 + /**
  106 + * 自定义字段2
  107 + */
  108 + @TableField(value = "userDef2")
  109 + @ApiModelProperty(value="自定义字段2")
  110 + private String userDef2;
  111 +
  112 + /**
  113 + * 自定义字段3
  114 + */
  115 + @TableField(value = "userDef3")
  116 + @ApiModelProperty(value="自定义字段3")
  117 + private String userDef3;
  118 +
  119 + /**
  120 + * 处理标记
  121 + */
  122 + @TableField(value = "processStamp")
  123 + @ApiModelProperty(value="处理标记")
  124 + private String processStamp;
  125 +
  126 + private static final long serialVersionUID = 1L;
  127 +}
0 \ No newline at end of file 128 \ No newline at end of file
src/main/java/com/huaheng/pc/inventory/adjustHeader/mapper/AdjustHeaderMapper.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustHeader.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.inventory.adjustHeader.domain.AdjustHeader;
  5 +
  6 +public interface AdjustHeaderMapper extends BaseMapper<AdjustHeader> {
  7 +}
0 \ No newline at end of file 8 \ No newline at end of file
src/main/java/com/huaheng/pc/inventory/adjustHeader/service/AdjustHeaderService.java 0 → 100644
  1 +package com.huaheng.pc.inventory.adjustHeader.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  5 +import com.huaheng.pc.inventory.adjustHeader.domain.AdjustHeader;
  6 +import com.huaheng.pc.inventory.adjustHeader.mapper.AdjustHeaderMapper;
  7 +@Service
  8 +public class AdjustHeaderService extends ServiceImpl<AdjustHeaderMapper, AdjustHeader> {
  9 +
  10 +}
src/main/java/com/huaheng/pc/inventory/cycleCountDetail/controller/CycleCountDetailController.java
@@ -57,16 +57,32 @@ public class CycleCountDetailController extends BaseController { @@ -57,16 +57,32 @@ public class CycleCountDetailController extends BaseController {
57 @Log(title = "库存-盘点",operating = "查看盘点明细", action = BusinessType.GRANT) 57 @Log(title = "库存-盘点",operating = "查看盘点明细", action = BusinessType.GRANT)
58 @ResponseBody 58 @ResponseBody
59 public TableDataInfo list(CycleCountDetail cycleCountDetail, String createdBegin, String createdEnd) { 59 public TableDataInfo list(CycleCountDetail cycleCountDetail, String createdBegin, String createdEnd) {
  60 +
60 LambdaQueryWrapper<CycleCountDetail> lambdaQueryWrapper = Wrappers.lambdaQuery(); 61 LambdaQueryWrapper<CycleCountDetail> lambdaQueryWrapper = Wrappers.lambdaQuery();
61 PageDomain pageDomain = TableSupport.buildPageRequest(); 62 PageDomain pageDomain = TableSupport.buildPageRequest();
62 Integer pageNum = pageDomain.getPageNum(); 63 Integer pageNum = pageDomain.getPageNum();
63 Integer pageSize = pageDomain.getPageSize(); 64 Integer pageSize = pageDomain.getPageSize();
64 65
65 - lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin), CycleCountDetail::getCreated, createdBegin) 66 + lambdaQueryWrapper.ge(
  67 + StringUtils.isNotEmpty(createdBegin), CycleCountDetail::getCreated, createdBegin)
66 .le(StringUtils.isNotEmpty(createdEnd), CycleCountDetail::getCreated, createdEnd)//创建时间范围 68 .le(StringUtils.isNotEmpty(createdEnd), CycleCountDetail::getCreated, createdEnd)//创建时间范围
67 .eq(CycleCountDetail::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库 69 .eq(CycleCountDetail::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库
68 -  
69 - 70 + .eq(cycleCountDetail.getCycleCountHeadId() != null ,CycleCountDetail::getCycleCountHeadId,cycleCountDetail.getCycleCountHeadId())//盘点主单
  71 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getCompanyCode()),CycleCountDetail::getCompanyCode, cycleCountDetail.getCompanyCode())//货主
  72 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getLocationCode()), CycleCountDetail::getLocationCode, cycleCountDetail.getLocationCode()) //库位
  73 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getContainerCode()), CycleCountDetail::getContainerCode,cycleCountDetail.getContainerCode()) //容器
  74 + .eq(cycleCountDetail.getInventoryDetailId() != null, CycleCountDetail::getInventoryDetailId, cycleCountDetail.getInventoryDetailId())//库存明细ID
  75 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getMaterialCode()), CycleCountDetail::getMaterialCode,cycleCountDetail.getMaterialCode())//物料编码
  76 + .like(StringUtils.isNotEmpty(cycleCountDetail.getMaterialName()), CycleCountDetail::getMaterialName, cycleCountDetail.getMaterialName())//物料名称
  77 + .like(StringUtils.isNotEmpty(cycleCountDetail.getMaterialSpec()), CycleCountDetail::getMaterialSpec,cycleCountDetail.getMaterialSpec())//物料规格
  78 + .eq(cycleCountDetail.getTaskHeaderId() != null, CycleCountDetail::getTaskHeaderId, cycleCountDetail.getTaskHeaderId())//任务主表
  79 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getInventorySts()), CycleCountDetail::getInventorySts,cycleCountDetail.getInventorySts())//库存状态
  80 + .eq(cycleCountDetail.getEnableStatus() != null, CycleCountDetail::getEnableStatus, cycleCountDetail.getEnableStatus())//明细状态
  81 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getBatch()),CycleCountDetail::getBatch,cycleCountDetail.getBatch())//批次
  82 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getLot()),CycleCountDetail::getLot,cycleCountDetail.getLot())//批号
  83 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getProjectNo()),CycleCountDetail::getProjectNo,cycleCountDetail.getProjectNo())//项目号
  84 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getCreatedBy()),CycleCountDetail::getCreatedBy,cycleCountDetail.getCreatedBy())//创建人
  85 + .eq(StringUtils.isNotEmpty(cycleCountDetail.getCompletedBy()), CycleCountDetail::getCompletedBy,cycleCountDetail.getCompletedBy())//完成人
70 .orderByDesc(CycleCountDetail::getId); 86 .orderByDesc(CycleCountDetail::getId);
71 87
72 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) { 88 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)) {
src/main/java/com/huaheng/pc/inventory/cycleCountDetail/domain/CycleCountDetail.java
@@ -132,11 +132,11 @@ public class CycleCountDetail implements Serializable { @@ -132,11 +132,11 @@ public class CycleCountDetail implements Serializable {
132 private Long countedQty; 132 private Long countedQty;
133 133
134 /** 134 /**
135 - * 调整数量 135 + * 差异数量
136 */ 136 */
137 - @TableField(value = "adjustQty")  
138 - @ApiModelProperty(value="调整数量")  
139 - private Long adjustQty; 137 + @TableField(value = "gapQty")
  138 + @ApiModelProperty(value="差异数量")
  139 + private Long gapQty;
140 140
141 /** 141 /**
142 * 失败原因 142 * 失败原因
@@ -278,83 +278,19 @@ public class CycleCountDetail implements Serializable { @@ -278,83 +278,19 @@ public class CycleCountDetail implements Serializable {
278 @ApiModelProperty(value="项目号") 278 @ApiModelProperty(value="项目号")
279 private String projectNo; 279 private String projectNo;
280 280
281 - private static final long serialVersionUID = 1L;  
282 -  
283 - public static final String COL_ID = "id";  
284 -  
285 - public static final String COL_COUNTID = "countId";  
286 -  
287 - public static final String COL_ROUND = "round";  
288 -  
289 - public static final String COL_TASKHEADERID = "taskHeaderId";  
290 -  
291 - public static final String COL_TASKDETAILID = "taskDetailId";  
292 -  
293 - public static final String COL_WAREHOUSECODE = "warehouseCode";  
294 -  
295 - public static final String COL_INVENTORYDETAILID = "inventoryDetailId";  
296 -  
297 - public static final String COL_LOCATIONCODE = "locationCode";  
298 -  
299 - public static final String COL_CONTAINERCODE = "containerCode";  
300 -  
301 - public static final String COL_MATERIALCODE = "materialCode";  
302 -  
303 - public static final String COL_MATERIALNAME = "materialName";  
304 -  
305 - public static final String COL_MATERIALSPEC = "materialSpec";  
306 -  
307 - public static final String COL_MATERIALUNIT = "materialUnit";  
308 -  
309 - public static final String COL_COMPANYCODE = "companyCode";  
310 -  
311 - public static final String COL_INVENTORYSTS = "inventorySts";  
312 -  
313 - public static final String COL_SYSTEMQTY = "systemQty";  
314 -  
315 - public static final String COL_COUNTEDQTY = "countedQty";  
316 -  
317 - public static final String COL_ADJUSTQTY = "adjustQty";  
318 -  
319 - public static final String COL_REJECTIONNOTE = "rejectionNote";  
320 -  
321 - public static final String COL_COUNTEDBY = "countedBy";  
322 281
323 - public static final String COL_COUNTEDAT = "countedAt";  
324 -  
325 - public static final String COL_ASSIGNEDTO = "assignedTo";  
326 -  
327 - public static final String COL_ASSIGNEDAT = "assignedAt";  
328 -  
329 - public static final String COL_COMPLETEDBY = "completedBy";  
330 -  
331 - public static final String COL_COMPLETEDAT = "completedAt";  
332 -  
333 - public static final String COL_ENABLESTATUS = "enableStatus";  
334 -  
335 - public static final String COL_CREATED = "created";  
336 -  
337 - public static final String COL_CREATEDBY = "createdBy";  
338 -  
339 - public static final String COL_LASTUPDATED = "lastUpdated";  
340 -  
341 - public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";  
342 -  
343 - public static final String COL_VERSION = "version";  
344 -  
345 - public static final String COL_USERDEF1 = "userDef1";  
346 -  
347 - public static final String COL_USERDEF2 = "userDef2"; 282 + /**
  283 + * 盘点主单号
  284 + * */
  285 + @TableField(value = "cycleCountHeadId")
  286 + @ApiModelProperty(value = "盘点主单号")
  287 + private Integer cycleCountHeadId;
348 288
349 - public static final String COL_USERDEF3 = "userDef3";  
350 289
351 - public static final String COL_PROCESSSTAMP = "processStamp";  
352 290
353 - public static final String COL_BATCH = "batch";  
354 291
355 - public static final String COL_LOT = "lot"; 292 + private static final long serialVersionUID = 1L;
356 293
357 - public static final String COL_PROJECTNO = "projectNo";  
358 294
359 /** 295 /**
360 * 获取ID 296 * 获取ID
@@ -665,19 +601,14 @@ public class CycleCountDetail implements Serializable { @@ -665,19 +601,14 @@ public class CycleCountDetail implements Serializable {
665 /** 601 /**
666 * 获取调整数量 602 * 获取调整数量
667 * 603 *
668 - * @return adjustQty - 调整数量 604 + * @return gapQty- 调整数量
669 */ 605 */
670 - public Long getAdjustQty() {  
671 - return adjustQty; 606 + public Long getGapQty() {
  607 + return gapQty;
672 } 608 }
673 609
674 - /**  
675 - * 设置调整数量  
676 - *  
677 - * @param adjustQty 调整数量  
678 - */  
679 - public void setAdjustQty(Long adjustQty) {  
680 - this.adjustQty = adjustQty; 610 + public void setGapQty(Long gapQty) {
  611 + this.gapQty = gapQty;
681 } 612 }
682 613
683 /** 614 /**
@@ -1039,4 +970,12 @@ public class CycleCountDetail implements Serializable { @@ -1039,4 +970,12 @@ public class CycleCountDetail implements Serializable {
1039 public void setProjectNo(String projectNo) { 970 public void setProjectNo(String projectNo) {
1040 this.projectNo = projectNo; 971 this.projectNo = projectNo;
1041 } 972 }
  973 +
  974 + public Integer getCycleCountHeadId() {
  975 + return cycleCountHeadId;
  976 + }
  977 +
  978 + public void setCycleCountHeadId(Integer cycleCountHeadId) {
  979 + this.cycleCountHeadId = cycleCountHeadId;
  980 + }
1042 } 981 }
1043 \ No newline at end of file 982 \ No newline at end of file
src/main/java/com/huaheng/pc/inventory/cycleCountHeader/controller/CycleCountHeaderController.java
@@ -69,9 +69,12 @@ public class CycleCountHeaderController extends BaseController { @@ -69,9 +69,12 @@ public class CycleCountHeaderController extends BaseController {
69 lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin), CycleCountHeader::getCreated, createdBegin) 69 lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin), CycleCountHeader::getCreated, createdBegin)
70 .le(StringUtils.isNotEmpty(createdEnd), CycleCountHeader::getCreated, createdEnd)//创建时间范围 70 .le(StringUtils.isNotEmpty(createdEnd), CycleCountHeader::getCreated, createdEnd)//创建时间范围
71 .eq(CycleCountHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库 71 .eq(CycleCountHeader::getWarehouseCode, ShiroUtils.getWarehouseCode()) //仓库
72 -  
73 -  
74 - 72 + .eq(StringUtils.isNotEmpty(cycleCountHeader.getSourceCode()),CycleCountHeader::getSourceCode,cycleCountHeader.getSourceCode())//源盘点单号
  73 + .eq(cycleCountHeader.getId() != null, CycleCountHeader::getId,cycleCountHeader.getId())//ID
  74 + .eq(StringUtils.isNotEmpty(cycleCountHeader.getMasterCode()),CycleCountHeader::getMasterCode, cycleCountHeader.getMasterCode())//盘点主表编号
  75 + .eq(cycleCountHeader.getCountOrderId() != null, CycleCountHeader::getCountOrderId, cycleCountHeader.getCountOrderId())//原始盘点ID
  76 + .eq(cycleCountHeader.getStatusCyc() != null, CycleCountHeader::getStatusCyc, cycleCountHeader.getStatusCyc()) //盘点单状态
  77 + .eq(cycleCountHeader.getCountType() != null ,CycleCountHeader::getCountType, cycleCountHeader.getCountType())//盘点类型
75 .orderByDesc(CycleCountHeader::getId); 78 .orderByDesc(CycleCountHeader::getId);
76 79
77 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){ 80 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
src/main/java/com/huaheng/pc/inventory/inventoryTransaction/domain/InventoryTransaction.java
@@ -208,13 +208,6 @@ public class InventoryTransaction implements Serializable { @@ -208,13 +208,6 @@ public class InventoryTransaction implements Serializable {
208 private String lockCode; 208 private String lockCode;
209 209
210 /** 210 /**
211 - * 上次盘点日期  
212 - */  
213 - @TableField(value = "lastCycleCountDate")  
214 - @ApiModelProperty(value="上次盘点日期")  
215 - private Date lastCycleCountDate;  
216 -  
217 - /**  
218 * 创建时间 211 * 创建时间
219 */ 212 */
220 @TableField(value = "created") 213 @TableField(value = "created")
@@ -285,4 +278,6 @@ public class InventoryTransaction implements Serializable { @@ -285,4 +278,6 @@ public class InventoryTransaction implements Serializable {
285 @ApiModelProperty(value = "供应商编码") 278 @ApiModelProperty(value = "供应商编码")
286 private String supplierCode; 279 private String supplierCode;
287 280
  281 +
  282 +
288 } 283 }
289 \ No newline at end of file 284 \ No newline at end of file
src/main/java/com/huaheng/pc/receipt/receiptDetail/controller/ReceiptDetailController.java
@@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; @@ -4,6 +4,8 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4 import com.baomidou.mybatisplus.core.metadata.IPage; 4 import com.baomidou.mybatisplus.core.metadata.IPage;
5 import com.baomidou.mybatisplus.core.toolkit.Wrappers; 5 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
6 import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 6 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  7 +import com.huaheng.common.exception.service.ServiceException;
  8 +import com.huaheng.common.support.Convert;
7 import com.huaheng.common.utils.StringUtils; 9 import com.huaheng.common.utils.StringUtils;
8 import com.huaheng.common.utils.security.ShiroUtils; 10 import com.huaheng.common.utils.security.ShiroUtils;
9 import com.huaheng.framework.aspectj.lang.annotation.Log; 11 import com.huaheng.framework.aspectj.lang.annotation.Log;
@@ -22,11 +24,13 @@ import io.swagger.annotations.ApiOperation; @@ -22,11 +24,13 @@ import io.swagger.annotations.ApiOperation;
22 import io.swagger.annotations.ApiParam; 24 import io.swagger.annotations.ApiParam;
23 import org.apache.ibatis.annotations.Param; 25 import org.apache.ibatis.annotations.Param;
24 import org.apache.shiro.authz.annotation.RequiresPermissions; 26 import org.apache.shiro.authz.annotation.RequiresPermissions;
  27 +import org.aspectj.weaver.loadtime.Aj;
25 import org.springframework.stereotype.Controller; 28 import org.springframework.stereotype.Controller;
26 import org.springframework.ui.ModelMap; 29 import org.springframework.ui.ModelMap;
27 import org.springframework.web.bind.annotation.*; 30 import org.springframework.web.bind.annotation.*;
28 31
29 import javax.annotation.Resource; 32 import javax.annotation.Resource;
  33 +import java.util.ArrayList;
30 import java.util.List; 34 import java.util.List;
31 import java.util.concurrent.locks.ReentrantLock; 35 import java.util.concurrent.locks.ReentrantLock;
32 36
@@ -108,4 +112,81 @@ public class ReceiptDetailController extends BaseController { @@ -108,4 +112,81 @@ public class ReceiptDetailController extends BaseController {
108 public AjaxResult addSave(ReceiptDetail receiptDetail) { 112 public AjaxResult addSave(ReceiptDetail receiptDetail) {
109 return receiptDetailService.saveReceiptDetaial(receiptDetail); 113 return receiptDetailService.saveReceiptDetaial(receiptDetail);
110 } 114 }
  115 +
  116 + /**
  117 + * 修改入库明细
  118 + */
  119 + @GetMapping("/edit/{id}")
  120 + public String edit(@PathVariable("id") Integer id, ModelMap mmap) {
  121 + ReceiptDetail receiptDetail = receiptDetailService.getById(id);
  122 + mmap.put("receiptDetail", receiptDetail);
  123 + return prefix + "/edit";
  124 + }
  125 +
  126 + /**
  127 + * 修改保存入库单
  128 + */
  129 + @ApiOperation(value="修改入库单 ", notes="修改入库单 ", httpMethod = "POST")
  130 + @RequiresPermissions("receipt:receiptDetail:add")
  131 + @Log(title = "入库-入库单 ",operating = "修改入库单 ", action = BusinessType.INSERT)
  132 + @PostMapping("/edit")
  133 + @ResponseBody
  134 + public AjaxResult editSave(
  135 + @ApiParam(name="receiptDetail",value="入库详情") ReceiptDetail receiptDetail) {
  136 + return receiptDetailService.updateReceiptDetaial(receiptDetail);
  137 + }
  138 +
  139 + /**
  140 + * 删除入库单
  141 + */
  142 + //@ApiOperation(value="删除入库单 ", notes="删除入库单 ", httpMethod = "POST")
  143 + //@RequiresPermissions("receipt:receiptDetail:add")
  144 + //@Log(title = "入库-入库单 ",operating = "修改入库单 ", action = BusinessType.INSERT)
  145 + //@PostMapping("/edit")
  146 + //@ResponseBody
  147 + //public AjaxResult remove(String ids) {
  148 + // if (StringUtils.isEmpty(ids)){
  149 + // return AjaxResult.error("id为空");
  150 + // }
  151 + // List<Integer> list = new ArrayList<>();
  152 + // for (Integer id : Convert.toIntArray(ids)){
  153 + // list.add(id);
  154 + // }
  155 + // return toAjax(receiptDetailService.removeByIds(list));
  156 + //}
  157 +
  158 + /**
  159 + * 审核入库单
  160 + */
  161 + @ApiOperation(value="审核入库单", notes="审核入库单", httpMethod = "POST")
  162 + @RequiresPermissions("receipt:receiptDetail:approval")
  163 + @Log(title = "入库-入库单 ",operating = "审核入库单 ", action = BusinessType.UPDATE)
  164 + @PostMapping("/approval")
  165 + @ResponseBody
  166 + public AjaxResult approval(@ApiParam(name="id",value="入库明细表id") String ids,
  167 + @ApiParam(name="approval",value="审核结果值,10审核驳回,20作废,100审核成功") Integer approval) {
  168 +
  169 + if (StringUtils.isEmpty(ids)){
  170 + return AjaxResult.error("id不能为空");
  171 + }
  172 + if (approval != 10 || approval != 20 || approval != 100){
  173 + return AjaxResult.error("传入参数错误");
  174 + }
  175 + for (Integer id : Convert.toIntArray(ids)) {
  176 + ReceiptDetail receiptDetail = new ReceiptDetail();
  177 + receiptDetail.setId(id);
  178 + receiptDetail.setProcessStamp(String.valueOf(approval));
  179 + receiptDetail.setLastUpdatedBy(ShiroUtils.getLoginName());
  180 + if (receiptDetailService.updateById(receiptDetail)){
  181 + ReceiptHeader receiptHeader = new ReceiptHeader();
  182 + receiptHeader.setFirstStatus(approval);
  183 + receiptHeader.setId(receiptDetail.getReceiptId());
  184 + receiptHeaderService.updateById(receiptHeader);
  185 + } else {
  186 + throw new ServiceException("审核失败");
  187 + }
  188 + }
  189 +
  190 + return AjaxResult.success("审核成功");
  191 + }
111 } 192 }
src/main/java/com/huaheng/pc/receipt/receiptDetail/service/ReceiptDetailService.java
@@ -7,4 +7,5 @@ public interface ReceiptDetailService extends IService&lt;ReceiptDetail&gt;{ @@ -7,4 +7,5 @@ public interface ReceiptDetailService extends IService&lt;ReceiptDetail&gt;{
7 7
8 AjaxResult saveReceiptDetaial(ReceiptDetail receiptDetail); 8 AjaxResult saveReceiptDetaial(ReceiptDetail receiptDetail);
9 9
  10 + AjaxResult updateReceiptDetaial(ReceiptDetail receiptDetail);
10 } 11 }
src/main/java/com/huaheng/pc/receipt/receiptDetail/service/ReceiptDetailServiceImpl.java
@@ -2,10 +2,19 @@ package com.huaheng.pc.receipt.receiptDetail.service; @@ -2,10 +2,19 @@ package com.huaheng.pc.receipt.receiptDetail.service;
2 2
3 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; 3 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4 import com.baomidou.mybatisplus.core.toolkit.Wrappers; 4 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
  5 +import com.huaheng.common.exception.service.ServiceException;
5 import com.huaheng.common.utils.security.ShiroUtils; 6 import com.huaheng.common.utils.security.ShiroUtils;
6 import com.huaheng.framework.web.domain.AjaxResult; 7 import com.huaheng.framework.web.domain.AjaxResult;
7 import com.huaheng.pc.config.material.domain.Material; 8 import com.huaheng.pc.config.material.domain.Material;
8 import com.huaheng.pc.config.material.service.MaterialService; 9 import com.huaheng.pc.config.material.service.MaterialService;
  10 +import com.huaheng.pc.config.materialType.domain.MaterialType;
  11 +import com.huaheng.pc.config.materialType.service.MaterialTypeService;
  12 +import com.huaheng.pc.config.receiptPreference.domain.ReceiptPreference;
  13 +import com.huaheng.pc.config.receiptPreference.service.ReceiptPreferenceService;
  14 +import com.huaheng.pc.config.receiptType.domain.ReceiptType;
  15 +import com.huaheng.pc.config.receiptType.service.ReceiptTypeService;
  16 +import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail;
  17 +import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService;
9 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader; 18 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader;
10 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService; 19 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService;
11 import org.aspectj.weaver.loadtime.Aj; 20 import org.aspectj.weaver.loadtime.Aj;
@@ -25,6 +34,14 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R @@ -25,6 +34,14 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R
25 private MaterialService materialService; 34 private MaterialService materialService;
26 @Resource 35 @Resource
27 private ReceiptHeaderService receiptHeaderService; 36 private ReceiptHeaderService receiptHeaderService;
  37 + @Resource
  38 + private ReceiptTypeService receiptTypeService;
  39 + @Resource
  40 + private StatusFlowDetailService statusFlowDetailService;
  41 + @Resource
  42 + private MaterialTypeService materialTypeService;
  43 + @Resource
  44 + private ReceiptPreferenceService receiptPreferenceService;
28 45
29 /** 46 /**
30 * 新增入库明细 47 * 新增入库明细
@@ -34,15 +51,17 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R @@ -34,15 +51,17 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R
34 @Transactional 51 @Transactional
35 public AjaxResult saveReceiptDetaial(ReceiptDetail receiptDetail){ 52 public AjaxResult saveReceiptDetaial(ReceiptDetail receiptDetail){
36 /* 判断入库头表状态*/ 53 /* 判断入库头表状态*/
37 - LambdaQueryWrapper<ReceiptHeader> lambda = Wrappers.lambdaQuery();  
38 - lambda.eq(ReceiptHeader::getId, receiptDetail.getReceiptId());  
39 - ReceiptHeader receiptHeader = receiptHeaderService.getOne(lambda); 54 + LambdaQueryWrapper<ReceiptHeader> lambdaReceiptHeader = Wrappers.lambdaQuery();
  55 + lambdaReceiptHeader.eq(ReceiptHeader::getId, receiptDetail.getReceiptId());
  56 + ReceiptHeader receiptHeader = receiptHeaderService.getOne(lambdaReceiptHeader);
  57 +
  58 + //判断入库头表状态
40 if (receiptHeader == null ){ 59 if (receiptHeader == null ){
41 - return AjaxResult.error("找不到主单据"); 60 + throw new ServiceException("找不到主单据");
42 } else if (receiptHeader.getFirstStatus() > 100){ 61 } else if (receiptHeader.getFirstStatus() > 100){
43 - return AjaxResult.error("单据进入订单池后,不允许新增明细"); 62 + throw new ServiceException("单据进入订单池后,不允许新增明细");
44 } else if (receiptHeader.getFirstStatus() == 20) { 63 } else if (receiptHeader.getFirstStatus() == 20) {
45 - return AjaxResult.error("单据销毁"); 64 + throw new ServiceException("单据已作废");
46 } 65 }
47 receiptDetail.setReceiptCode(receiptHeader.getCode()); 66 receiptDetail.setReceiptCode(receiptHeader.getCode());
48 67
@@ -51,7 +70,7 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R @@ -51,7 +70,7 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R
51 lambdaQueryWrapper.eq(Material::getCode, receiptDetail.getMaterialCode()); 70 lambdaQueryWrapper.eq(Material::getCode, receiptDetail.getMaterialCode());
52 Material material = materialService.getOne(lambdaQueryWrapper); 71 Material material = materialService.getOne(lambdaQueryWrapper);
53 if (material == null) { 72 if (material == null) {
54 - return AjaxResult.error("物料不存在"); 73 + throw new ServiceException("物料不存在");
55 } 74 }
56 receiptDetail.setCompanyCode(material.getCompanyCode()); 75 receiptDetail.setCompanyCode(material.getCompanyCode());
57 receiptDetail.setMaterialName(material.getName()); 76 receiptDetail.setMaterialName(material.getName());
@@ -62,6 +81,36 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R @@ -62,6 +81,36 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R
62 receiptDetail.setLastUpdatedBy(ShiroUtils.getLoginName()); 81 receiptDetail.setLastUpdatedBy(ShiroUtils.getLoginName());
63 receiptDetail.setWarehouseCode(ShiroUtils.getWarehouseCode()); 82 receiptDetail.setWarehouseCode(ShiroUtils.getWarehouseCode());
64 83
  84 + //查询头表中绑定的入库类型中的入库流程
  85 + LambdaQueryWrapper<ReceiptType> lambdaReceiptType = Wrappers.lambdaQuery();
  86 + lambdaReceiptType.eq(ReceiptType::getCode, receiptHeader.getReceiptType());
  87 + ReceiptType receiptType = receiptTypeService.getOne(lambdaReceiptType);
  88 + if (receiptType.getReceiptFlow() != null){
  89 + //物料是否有入库流程
  90 + List<StatusFlowDetail> statusFlowDetails = statusFlowDetailService.queryStatusFlowDetail(receiptType.getReceiptFlow());
  91 + receiptDetail.setProcessStamp(statusFlowDetails.get(0).getFlowCode());
  92 + } else if (material.getReceivingFlow() != null){
  93 + //物料是否有入库流程
  94 + List<StatusFlowDetail> statusFlowDetails = statusFlowDetailService.queryStatusFlowDetail(material.getReceivingFlow());
  95 + receiptDetail.setProcessStamp(statusFlowDetails.get(0).getFlowCode());
  96 + } else {
  97 + //该物料类别是否有入库流程
  98 + LambdaQueryWrapper<MaterialType> lambdaMaterialType = Wrappers.lambdaQuery();
  99 + lambdaMaterialType.eq(MaterialType::getCode, material.getType());
  100 + MaterialType materialType = materialTypeService.getOne(lambdaMaterialType);
  101 + if (materialType.getReceivingFlow() != null) {
  102 + List<StatusFlowDetail> statusFlowDetails = statusFlowDetailService.queryStatusFlowDetail(materialType.getReceivingFlow());
  103 + receiptDetail.setProcessStamp(statusFlowDetails.get(0).getFlowCode());
  104 + } else {
  105 + //以上都没有的情况下查询入库首选项中的入库流程
  106 + LambdaQueryWrapper<ReceiptPreference> lambda = Wrappers.lambdaQuery();
  107 + lambda.last("Limit 1");
  108 + ReceiptPreference receiptPreference = receiptPreferenceService.getOne(lambda);
  109 + List<StatusFlowDetail> statusFlowDetails = statusFlowDetailService.queryStatusFlowDetail(receiptPreference.getReceivingFlow());
  110 + receiptDetail.setProcessStamp(statusFlowDetails.get(0).getFlowCode());
  111 + }
  112 + }
  113 +
65 if (this.save(receiptDetail)) { 114 if (this.save(receiptDetail)) {
66 receiptHeader.setTotalQty(receiptHeader.getTotalQty()+receiptDetail.getTotalQty()); 115 receiptHeader.setTotalQty(receiptHeader.getTotalQty()+receiptDetail.getTotalQty());
67 receiptHeader.setTotalLines(receiptHeader.getTotalLines()+1); 116 receiptHeader.setTotalLines(receiptHeader.getTotalLines()+1);
@@ -72,4 +121,49 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R @@ -72,4 +121,49 @@ public class ReceiptDetailServiceImpl extends ServiceImpl&lt;ReceiptDetailMapper, R
72 } 121 }
73 122
74 } 123 }
  124 +
  125 + /**
  126 + * 修改入库明细
  127 + * @param receiptDetail
  128 + * @return
  129 + */
  130 + @Override
  131 + @Transactional
  132 + public AjaxResult updateReceiptDetaial(ReceiptDetail receiptDetail) {
  133 + /* 先修改入库头表中的总数量和总行数,再更新记录,完成后更新入库头表中总数量和总行数*/
  134 +
  135 + //查询原记录
  136 + ReceiptDetail originalReceiptDetail= this.getById(receiptDetail.getId());
  137 + ReceiptHeader receiptHeader = receiptHeaderService.getById(receiptDetail.getReceiptId());
  138 + //判断物料编码是否被修改
  139 + if (!originalReceiptDetail.getMaterialCode().equals(receiptDetail.getMaterialCode())){
  140 + LambdaQueryWrapper<Material> lambdaMaterial = Wrappers.lambdaQuery();
  141 + lambdaMaterial.eq(Material::getCode,receiptDetail.getMaterialCode());
  142 + Material material = materialService.getOne(lambdaMaterial);
  143 + if (material == null) {
  144 + throw new ServiceException("该物料编码不存在");
  145 +
  146 + }else {
  147 + receiptDetail.setMaterialName(material.getName());
  148 + receiptDetail.setMaterialSpec(material.getSpec());
  149 + receiptDetail.setMaterialUnit(material.getUnit());
  150 +
  151 + receiptHeader.setTotalQty(receiptHeader.getTotalQty()-originalReceiptDetail.getTotalQty());
  152 + receiptHeader.setTotalLines(receiptHeader.getTotalLines()-1);
  153 + if ( !receiptHeaderService.updateById(receiptHeader)){
  154 + return AjaxResult.error("入库头表更新失败");
  155 + }
  156 + }
  157 + }
  158 +
  159 + receiptDetail.setLastUpdatedBy(ShiroUtils.getLoginName());
  160 + if ( !this.updateById(receiptDetail) ){
  161 + return AjaxResult.error("入库明细更新失败");
  162 + } else {
  163 + receiptHeader.setTotalQty(receiptHeader.getTotalQty()+receiptDetail.getTotalQty());
  164 + receiptHeader.setTotalLines(receiptHeader.getTotalLines()+1);
  165 + receiptHeaderService.updateById(receiptHeader);
  166 + return AjaxResult.success("修改单据明细成功");
  167 + }
  168 + }
75 } 169 }
src/main/java/com/huaheng/pc/receipt/receiptDetailHistory/domain/ReceiptDetailHistory.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptDetailHistory.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.math.BigDecimal;
  11 +import java.util.Date;
  12 +import lombok.Data;
  13 +
  14 +@ApiModel(value="com.huaheng.pc.receipt.receiptDetailHistory.domain.ReceiptDetailHistory")
  15 +@Data
  16 +@TableName(value = "receipt_detail_history")
  17 +public class ReceiptDetailHistory implements Serializable {
  18 + /**
  19 + * 入库明细内部号
  20 + */
  21 + @TableId(value = "id", type = IdType.AUTO)
  22 + @ApiModelProperty(value="入库明细内部号")
  23 + private Integer id;
  24 +
  25 + /**
  26 + * 入库单头内部号
  27 + */
  28 + @TableField(value = "receiptId")
  29 + @ApiModelProperty(value="入库单头内部号")
  30 + private Integer receiptId;
  31 +
  32 + /**
  33 + * 入库单
  34 + */
  35 + @TableField(value = "receiptCode")
  36 + @ApiModelProperty(value="入库单")
  37 + private String receiptCode;
  38 +
  39 + /**
  40 + * 仓库
  41 + */
  42 + @TableField(value = "warehouseCode")
  43 + @ApiModelProperty(value="仓库")
  44 + private String warehouseCode;
  45 +
  46 + /**
  47 + * 货主
  48 + */
  49 + @TableField(value = "companyCode")
  50 + @ApiModelProperty(value="货主")
  51 + private String companyCode;
  52 +
  53 + /**
  54 + * 物料编码
  55 + */
  56 + @TableField(value = "materialCode")
  57 + @ApiModelProperty(value="物料编码")
  58 + private String materialCode;
  59 +
  60 + /**
  61 + * 物料信息
  62 + */
  63 + @TableField(value = "materialName")
  64 + @ApiModelProperty(value="物料信息")
  65 + private String materialName;
  66 +
  67 + /**
  68 + * 物料规格
  69 + */
  70 + @TableField(value = "materialSpec")
  71 + @ApiModelProperty(value="物料规格")
  72 + private String materialSpec;
  73 +
  74 + /**
  75 + * 物料单位
  76 + */
  77 + @TableField(value = "materialUnit")
  78 + @ApiModelProperty(value="物料单位")
  79 + private String materialUnit;
  80 +
  81 + /**
  82 + * 供应商编码
  83 + */
  84 + @TableField(value = "supplierCode")
  85 + @ApiModelProperty(value="供应商编码")
  86 + private String supplierCode;
  87 +
  88 + /**
  89 + * 批次
  90 + */
  91 + @TableField(value = "batch")
  92 + @ApiModelProperty(value="批次")
  93 + private String batch;
  94 +
  95 + /**
  96 + * 批号
  97 + */
  98 + @TableField(value = "lot")
  99 + @ApiModelProperty(value="批号")
  100 + private String lot;
  101 +
  102 + /**
  103 + * 质检
  104 + */
  105 + @TableField(value = "qcCheck")
  106 + @ApiModelProperty(value="质检")
  107 + private String qcCheck;
  108 +
  109 + /**
  110 + * 项目号
  111 + */
  112 + @TableField(value = "projectNo")
  113 + @ApiModelProperty(value="项目号")
  114 + private String projectNo;
  115 +
  116 + /**
  117 + * 生产日期
  118 + */
  119 + @TableField(value = "manufactureDate")
  120 + @ApiModelProperty(value="生产日期")
  121 + private Date manufactureDate;
  122 +
  123 + /**
  124 + * 失效日期
  125 + */
  126 + @TableField(value = "expirationDate")
  127 + @ApiModelProperty(value="失效日期")
  128 + private Date expirationDate;
  129 +
  130 + /**
  131 + * 入库日期
  132 + */
  133 + @TableField(value = "agingDate")
  134 + @ApiModelProperty(value="入库日期")
  135 + private Date agingDate;
  136 +
  137 + /**
  138 + * 属性模板
  139 + */
  140 + @TableField(value = "attributeTemplateCode")
  141 + @ApiModelProperty(value="属性模板")
  142 + private String attributeTemplateCode;
  143 +
  144 + /**
  145 + * 属性1
  146 + */
  147 + @TableField(value = "attribute1")
  148 + @ApiModelProperty(value="属性1")
  149 + private String attribute1;
  150 +
  151 + /**
  152 + * 属性2
  153 + */
  154 + @TableField(value = "attribute2")
  155 + @ApiModelProperty(value="属性2")
  156 + private String attribute2;
  157 +
  158 + /**
  159 + * 属性3
  160 + */
  161 + @TableField(value = "attribute3")
  162 + @ApiModelProperty(value="属性3")
  163 + private String attribute3;
  164 +
  165 + /**
  166 + * 属性4
  167 + */
  168 + @TableField(value = "attribute4")
  169 + @ApiModelProperty(value="属性4")
  170 + private String attribute4;
  171 +
  172 + /**
  173 + * 总数量
  174 + */
  175 + @TableField(value = "totalQty")
  176 + @ApiModelProperty(value="总数量")
  177 + private Integer totalQty;
  178 +
  179 + /**
  180 + * 未收数量
  181 + */
  182 + @TableField(value = "openQty")
  183 + @ApiModelProperty(value="未收数量")
  184 + private Integer openQty;
  185 +
  186 + /**
  187 + * ERP单号
  188 + */
  189 + @TableField(value = "referCode")
  190 + @ApiModelProperty(value="ERP单号")
  191 + private String referCode;
  192 +
  193 + /**
  194 + * ERP内部号
  195 + */
  196 + @TableField(value = "referId")
  197 + @ApiModelProperty(value="ERP内部号")
  198 + private Integer referId;
  199 +
  200 + /**
  201 + * ERP行号
  202 + */
  203 + @TableField(value = "referLineNum")
  204 + @ApiModelProperty(value="ERP行号")
  205 + private String referLineNum;
  206 +
  207 + /**
  208 + * 定位规则
  209 + */
  210 + @TableField(value = "locatingRule")
  211 + @ApiModelProperty(value="定位规则")
  212 + private String locatingRule;
  213 +
  214 + /**
  215 + * 库存状态
  216 + */
  217 + @TableField(value = "inventorySts")
  218 + @ApiModelProperty(value="库存状态")
  219 + private String inventorySts;
  220 +
  221 + /**
  222 + * 标价
  223 + */
  224 + @TableField(value = "itemListPrice")
  225 + @ApiModelProperty(value="标价")
  226 + private BigDecimal itemListPrice;
  227 +
  228 + /**
  229 + * 净价
  230 + */
  231 + @TableField(value = "itemNetPrice")
  232 + @ApiModelProperty(value="净价")
  233 + private BigDecimal itemNetPrice;
  234 +
  235 + /**
  236 + * 是否虚拟套件
  237 + */
  238 + @TableField(value = "isVirtualBom")
  239 + @ApiModelProperty(value="是否虚拟套件")
  240 + private Integer isVirtualBom;
  241 +
  242 + /**
  243 + * 创建时间
  244 + */
  245 + @TableField(value = "created")
  246 + @ApiModelProperty(value="创建时间")
  247 + private Date created;
  248 +
  249 + /**
  250 + * 创建用户
  251 + */
  252 + @TableField(value = "createdBy")
  253 + @ApiModelProperty(value="创建用户")
  254 + private String createdBy;
  255 +
  256 + /**
  257 + * 创建时间
  258 + */
  259 + @TableField(value = "lastUpdated")
  260 + @ApiModelProperty(value="创建时间")
  261 + private Date lastUpdated;
  262 +
  263 + /**
  264 + * 更新用户
  265 + */
  266 + @TableField(value = "lastUpdatedBy")
  267 + @ApiModelProperty(value="更新用户")
  268 + private String lastUpdatedBy;
  269 +
  270 + /**
  271 + * 数据版本
  272 + */
  273 + @TableField(value = "version")
  274 + @ApiModelProperty(value="数据版本")
  275 + private Integer version;
  276 +
  277 + /**
  278 + * 自定义字段1
  279 + */
  280 + @TableField(value = "userDef1")
  281 + @ApiModelProperty(value="自定义字段1")
  282 + private String userDef1;
  283 +
  284 + /**
  285 + * 自定义字段2
  286 + */
  287 + @TableField(value = "userDef2")
  288 + @ApiModelProperty(value="自定义字段2")
  289 + private String userDef2;
  290 +
  291 + /**
  292 + * 自定义字段3
  293 + */
  294 + @TableField(value = "userDef3")
  295 + @ApiModelProperty(value="自定义字段3")
  296 + private String userDef3;
  297 +
  298 + /**
  299 + * 自定义字段4
  300 + */
  301 + @TableField(value = "userDef4")
  302 + @ApiModelProperty(value="自定义字段4")
  303 + private String userDef4;
  304 +
  305 + /**
  306 + * 自定义字段5
  307 + */
  308 + @TableField(value = "userDef5")
  309 + @ApiModelProperty(value="自定义字段5")
  310 + private String userDef5;
  311 +
  312 + /**
  313 + * 自定义字段6
  314 + */
  315 + @TableField(value = "userDef6")
  316 + @ApiModelProperty(value="自定义字段6")
  317 + private String userDef6;
  318 +
  319 + /**
  320 + * 自定义字段7
  321 + */
  322 + @TableField(value = "userDef7")
  323 + @ApiModelProperty(value="自定义字段7")
  324 + private String userDef7;
  325 +
  326 + /**
  327 + * 自定义字段8
  328 + */
  329 + @TableField(value = "userDef8")
  330 + @ApiModelProperty(value="自定义字段8")
  331 + private String userDef8;
  332 +
  333 + /**
  334 + * 处理标记
  335 + */
  336 + @TableField(value = "processStamp")
  337 + @ApiModelProperty(value="处理标记")
  338 + private String processStamp;
  339 +
  340 + /**
  341 + * 是否删除
  342 + */
  343 + @TableField(value = "deleted")
  344 + @ApiModelProperty(value="是否删除")
  345 + private Boolean deleted;
  346 +
  347 + private static final long serialVersionUID = 1L;
  348 +}
0 \ No newline at end of file 349 \ No newline at end of file
src/main/java/com/huaheng/pc/receipt/receiptDetailHistory/mapper/ReceiptDetailHistoryMapper.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptDetailHistory.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.receipt.receiptDetailHistory.domain.ReceiptDetailHistory;
  5 +
  6 +public interface ReceiptDetailHistoryMapper extends BaseMapper<ReceiptDetailHistory> {
  7 +}
0 \ No newline at end of file 8 \ No newline at end of file
src/main/java/com/huaheng/pc/receipt/receiptDetailHistory/service/ReceiptDetailHistoryService.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptDetailHistory.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.receipt.receiptDetailHistory.domain.ReceiptDetailHistory;
  8 +import com.huaheng.pc.receipt.receiptDetailHistory.mapper.ReceiptDetailHistoryMapper;
  9 +@Service
  10 +public class ReceiptDetailHistoryService extends ServiceImpl<ReceiptDetailHistoryMapper, ReceiptDetailHistory> {
  11 +
  12 +}
src/main/java/com/huaheng/pc/receipt/receiptHeader/controller/ReceiptHeaderController.java
@@ -16,7 +16,9 @@ import com.huaheng.framework.web.page.TableSupport; @@ -16,7 +16,9 @@ import com.huaheng.framework.web.page.TableSupport;
16 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader; 16 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader;
17 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService; 17 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService;
18 import io.swagger.annotations.Api; 18 import io.swagger.annotations.Api;
  19 +import io.swagger.annotations.ApiModel;
19 import io.swagger.annotations.ApiOperation; 20 import io.swagger.annotations.ApiOperation;
  21 +import io.swagger.annotations.ApiParam;
20 import org.apache.shiro.authz.annotation.RequiresPermissions; 22 import org.apache.shiro.authz.annotation.RequiresPermissions;
21 import org.springframework.stereotype.Controller; 23 import org.springframework.stereotype.Controller;
22 import org.springframework.ui.ModelMap; 24 import org.springframework.ui.ModelMap;
@@ -49,7 +51,9 @@ public class ReceiptHeaderController extends BaseController { @@ -49,7 +51,9 @@ public class ReceiptHeaderController extends BaseController {
49 @Log(title = "入库-入库单头表", operating = "查看入库单列表", action = BusinessType.GRANT) 51 @Log(title = "入库-入库单头表", operating = "查看入库单列表", action = BusinessType.GRANT)
50 @PostMapping("/list") 52 @PostMapping("/list")
51 @ResponseBody 53 @ResponseBody
52 - public TableDataInfo list(ReceiptHeader receiptHeader, String createdBegin, String createdEnd) { 54 + public TableDataInfo list(@ApiParam(name="receiptDetail",value="入库头表")ReceiptHeader receiptHeader,
  55 + @ApiParam(name = "createdBegin", value = "起止时间") String createdBegin,
  56 + @ApiParam(name = "createdEnd", value = "结束时间") String createdEnd) {
53 LambdaQueryWrapper<ReceiptHeader> lambdaQueryWrapper = Wrappers.lambdaQuery(); 57 LambdaQueryWrapper<ReceiptHeader> lambdaQueryWrapper = Wrappers.lambdaQuery();
54 PageDomain pageDomain = TableSupport.buildPageRequest(); 58 PageDomain pageDomain = TableSupport.buildPageRequest();
55 Integer pageNum = pageDomain.getPageNum(); 59 Integer pageNum = pageDomain.getPageNum();
@@ -122,4 +126,41 @@ public class ReceiptHeaderController extends BaseController { @@ -122,4 +126,41 @@ public class ReceiptHeaderController extends BaseController {
122 receiptHeader.setLastUpdatedBy(ShiroUtils.getLoginName()); 126 receiptHeader.setLastUpdatedBy(ShiroUtils.getLoginName());
123 return toAjax(receiptHeaderService.updateById(receiptHeader)); 127 return toAjax(receiptHeaderService.updateById(receiptHeader));
124 } 128 }
  129 +
  130 + /**
  131 + * 审核入库单
  132 + */
  133 + @ApiOperation(value="审核入库单", notes="审核入库单", httpMethod = "POST")
  134 + @RequiresPermissions("receipt:receiptHeader:approval")
  135 + @Log(title = "入库-入库单 ",operating = "审核入库单 ", action = BusinessType.UPDATE)
  136 + @PostMapping("/approval")
  137 + @ResponseBody
  138 + public AjaxResult approval(@ApiParam(name="id",value="入库头表id") Integer id,
  139 + @ApiParam(name="approval",value="审核结果值,10审核驳回,20作废,100审核成功") Integer approval) {
  140 + ReceiptHeader receiptHeader = new ReceiptHeader();
  141 + if (approval != 10 || approval != 20 || approval != 100){
  142 + return AjaxResult.error("传入参数错误");
  143 + }
  144 + receiptHeader.setId(id);
  145 + receiptHeader.setLastStatus(approval);
  146 + receiptHeader.setFirstStatus(approval);
  147 + receiptHeader.setLastUpdatedBy(ShiroUtils.getLoginName());
  148 + return toAjax(receiptHeaderService.updateById(receiptHeader));
  149 + }
  150 +
  151 + /**
  152 + * 提交审核入库单
  153 + */
  154 + @ApiOperation(value="提交审核入库单", notes="提交审核入库单", httpMethod = "POST")
  155 + @RequiresPermissions("receipt:receiptHeader:approval")
  156 + @Log(title = "入库-入库单 ",operating = "提交审核入库单 ", action = BusinessType.UPDATE)
  157 + @PostMapping("/submitReview")
  158 + @ResponseBody
  159 + public AjaxResult submitReview(@ApiParam(name="id",value="入库头表id") Integer id) {
  160 + ReceiptHeader receiptHeader = new ReceiptHeader();
  161 + receiptHeader.setId(id);
  162 + receiptHeader.setFirstStatus(5);
  163 + receiptHeader.setLastStatus(5);
  164 + return toAjax(receiptHeaderService.updateById(receiptHeader));
  165 + }
125 } 166 }
src/main/java/com/huaheng/pc/receipt/receiptHeader/service/ReceiptHeaderService.java
@@ -3,10 +3,13 @@ package com.huaheng.pc.receipt.receiptHeader.service; @@ -3,10 +3,13 @@ package com.huaheng.pc.receipt.receiptHeader.service;
3 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; 3 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4 import com.baomidou.mybatisplus.core.toolkit.Wrappers; 4 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
5 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; 5 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  6 +import com.huaheng.common.exception.service.ServiceException;
6 import com.huaheng.common.utils.security.ShiroUtils; 7 import com.huaheng.common.utils.security.ShiroUtils;
7 import com.huaheng.framework.web.domain.AjaxResult; 8 import com.huaheng.framework.web.domain.AjaxResult;
8 import com.huaheng.pc.config.receiptType.domain.ReceiptType; 9 import com.huaheng.pc.config.receiptType.domain.ReceiptType;
9 import com.huaheng.pc.config.receiptType.service.ReceiptTypeService; 10 import com.huaheng.pc.config.receiptType.service.ReceiptTypeService;
  11 +import com.huaheng.pc.config.statusFlow.domain.StatusFlowDetail;
  12 +import com.huaheng.pc.config.statusFlow.service.StatusFlowDetailService;
10 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader; 13 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader;
11 import com.huaheng.pc.receipt.receiptHeader.mapper.ReceiptHeaderMapper; 14 import com.huaheng.pc.receipt.receiptHeader.mapper.ReceiptHeaderMapper;
12 import org.springframework.stereotype.Service; 15 import org.springframework.stereotype.Service;
@@ -14,19 +17,29 @@ import org.springframework.stereotype.Service; @@ -14,19 +17,29 @@ import org.springframework.stereotype.Service;
14 import javax.annotation.Resource; 17 import javax.annotation.Resource;
15 import java.text.SimpleDateFormat; 18 import java.text.SimpleDateFormat;
16 import java.util.Date; 19 import java.util.Date;
  20 +import java.util.List;
17 21
18 @Service 22 @Service
19 public class ReceiptHeaderService extends ServiceImpl<ReceiptHeaderMapper, ReceiptHeader> { 23 public class ReceiptHeaderService extends ServiceImpl<ReceiptHeaderMapper, ReceiptHeader> {
20 24
21 @Resource 25 @Resource
22 private ReceiptTypeService receiptTypeService; 26 private ReceiptTypeService receiptTypeService;
  27 + @Resource
  28 + private StatusFlowDetailService statusFlowDetailService;
23 29
24 public AjaxResult saveReceiptHeader(ReceiptHeader receiptHeader){ 30 public AjaxResult saveReceiptHeader(ReceiptHeader receiptHeader){
25 LambdaQueryWrapper<ReceiptType> lambdaQueryWrapper = Wrappers.lambdaQuery(); 31 LambdaQueryWrapper<ReceiptType> lambdaQueryWrapper = Wrappers.lambdaQuery();
26 lambdaQueryWrapper.eq(ReceiptType::getCode, receiptHeader.getReceiptType()); 32 lambdaQueryWrapper.eq(ReceiptType::getCode, receiptHeader.getReceiptType());
27 - if(receiptTypeService.getOne(lambdaQueryWrapper) == null) {  
28 - return AjaxResult.error("没有对应的入库单类型"); 33 + ReceiptType receiptType = receiptTypeService.getOne(lambdaQueryWrapper);
  34 +
  35 + //流程详情查询
  36 + LambdaQueryWrapper<StatusFlowDetail> lambdaStatus = Wrappers.lambdaQuery();
  37 + lambdaStatus.orderByAsc(StatusFlowDetail::getSequence);
  38 +
  39 + if(receiptType == null) {
  40 + throw new ServiceException("没有对应的入库单类型");
29 } 41 }
  42 +
30 String code = createCode(receiptHeader.getReceiptType()); 43 String code = createCode(receiptHeader.getReceiptType());
31 receiptHeader.setCode(code); 44 receiptHeader.setCode(code);
32 receiptHeader.setFirstStatus(0); 45 receiptHeader.setFirstStatus(0);
src/main/java/com/huaheng/pc/receipt/receiptHeaderHistory/domain/ReceiptHeaderHistory.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptHeaderHistory.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import java.io.Serializable;
  10 +import java.math.BigDecimal;
  11 +import java.util.Date;
  12 +import lombok.Data;
  13 +
  14 +@ApiModel(value="com.huaheng.pc.receipt.receiptHeaderHistory.domain.ReceiptHeaderHistory")
  15 +@Data
  16 +@TableName(value = "receipt_header_history")
  17 +public class ReceiptHeaderHistory implements Serializable {
  18 + /**
  19 + * 入库单内部号
  20 + */
  21 + @TableId(value = "id", type = IdType.AUTO)
  22 + @ApiModelProperty(value="入库单内部号")
  23 + private Integer id;
  24 +
  25 + /**
  26 + * 仓库
  27 + */
  28 + @TableField(value = "warehouseCode")
  29 + @ApiModelProperty(value="仓库")
  30 + private String warehouseCode;
  31 +
  32 + /**
  33 + * 货主
  34 + */
  35 + @TableField(value = "companyCode")
  36 + @ApiModelProperty(value="货主")
  37 + private String companyCode;
  38 +
  39 + /**
  40 + * 入库单号
  41 + */
  42 + @TableField(value = "code")
  43 + @ApiModelProperty(value="入库单号")
  44 + private String code;
  45 +
  46 + /**
  47 + * 入库类型
  48 + */
  49 + @TableField(value = "receiptType")
  50 + @ApiModelProperty(value="入库类型")
  51 + private String receiptType;
  52 +
  53 + /**
  54 + * 首状态
  55 + */
  56 + @TableField(value = "firstStatus")
  57 + @ApiModelProperty(value="首状态")
  58 + private Integer firstStatus;
  59 +
  60 + /**
  61 + * 尾状态
  62 + */
  63 + @TableField(value = "lastStatus")
  64 + @ApiModelProperty(value="尾状态")
  65 + private Integer lastStatus;
  66 +
  67 + /**
  68 + * 关联单号
  69 + */
  70 + @TableField(value = "referCode")
  71 + @ApiModelProperty(value="关联单号")
  72 + private String referCode;
  73 +
  74 + /**
  75 + * 关联单号(内部号)
  76 + */
  77 + @TableField(value = "referId")
  78 + @ApiModelProperty(value="关联单号(内部号)")
  79 + private Integer referId;
  80 +
  81 + /**
  82 + * 关联订单类型
  83 + */
  84 + @TableField(value = "referType")
  85 + @ApiModelProperty(value="关联订单类型")
  86 + private String referType;
  87 +
  88 + /**
  89 + * 预计到达日期
  90 + */
  91 + @TableField(value = "scheduledArriveDate")
  92 + @ApiModelProperty(value="预计到达日期")
  93 + private Date scheduledArriveDate;
  94 +
  95 + /**
  96 + * 实际到达日期
  97 + */
  98 + @TableField(value = "actualArriveDate")
  99 + @ApiModelProperty(value="实际到达日期")
  100 + private Date actualArriveDate;
  101 +
  102 + /**
  103 + * 月台货位
  104 + */
  105 + @TableField(value = "recvDock")
  106 + @ApiModelProperty(value="月台货位")
  107 + private String recvDock;
  108 +
  109 + /**
  110 + * 关闭时间
  111 + */
  112 + @TableField(value = "closedAt")
  113 + @ApiModelProperty(value="关闭时间")
  114 + private Date closedAt;
  115 +
  116 + /**
  117 + * 强制关闭用户
  118 + */
  119 + @TableField(value = "closedBy")
  120 + @ApiModelProperty(value="强制关闭用户")
  121 + private String closedBy;
  122 +
  123 + /**
  124 + * 开始收货日期
  125 + */
  126 + @TableField(value = "startCheckinDatetime")
  127 + @ApiModelProperty(value="开始收货日期")
  128 + private Date startCheckinDatetime;
  129 +
  130 + /**
  131 + * 结束收货日期
  132 + */
  133 + @TableField(value = "endCheckinDatetime")
  134 + @ApiModelProperty(value="结束收货日期")
  135 + private Date endCheckinDatetime;
  136 +
  137 + /**
  138 + * 总数量
  139 + */
  140 + @TableField(value = "totalQty")
  141 + @ApiModelProperty(value="总数量")
  142 + private Integer totalQty;
  143 +
  144 + /**
  145 + * 总行数
  146 + */
  147 + @TableField(value = "totalLines")
  148 + @ApiModelProperty(value="总行数")
  149 + private Integer totalLines;
  150 +
  151 + /**
  152 + * 总箱数
  153 + */
  154 + @TableField(value = "toalCases")
  155 + @ApiModelProperty(value="总箱数")
  156 + private Integer toalCases;
  157 +
  158 + /**
  159 + * 总重量
  160 + */
  161 + @TableField(value = "totalWeight")
  162 + @ApiModelProperty(value="总重量")
  163 + private BigDecimal totalWeight;
  164 +
  165 + /**
  166 + * 总体积
  167 + */
  168 + @TableField(value = "totalVolume")
  169 + @ApiModelProperty(value="总体积")
  170 + private BigDecimal totalVolume;
  171 +
  172 + /**
  173 + * 入库单备注
  174 + */
  175 + @TableField(value = "receiptNote")
  176 + @ApiModelProperty(value="入库单备注")
  177 + private String receiptNote;
  178 +
  179 + /**
  180 + * 锁定
  181 + */
  182 + @TableField(value = "locked")
  183 + @ApiModelProperty(value="锁定")
  184 + private Integer locked;
  185 +
  186 + /**
  187 + * 锁定用户
  188 + */
  189 + @TableField(value = "lockedBy")
  190 + @ApiModelProperty(value="锁定用户")
  191 + private String lockedBy;
  192 +
  193 + /**
  194 + * 创建时间
  195 + */
  196 + @TableField(value = "created")
  197 + @ApiModelProperty(value="创建时间")
  198 + private Date created;
  199 +
  200 + /**
  201 + * 创建用户
  202 + */
  203 + @TableField(value = "createdBy")
  204 + @ApiModelProperty(value="创建用户")
  205 + private String createdBy;
  206 +
  207 + /**
  208 + * 创建时间
  209 + */
  210 + @TableField(value = "lastUpdated")
  211 + @ApiModelProperty(value="创建时间")
  212 + private Date lastUpdated;
  213 +
  214 + /**
  215 + * 更新用户
  216 + */
  217 + @TableField(value = "lastUpdatedBy")
  218 + @ApiModelProperty(value="更新用户")
  219 + private String lastUpdatedBy;
  220 +
  221 + /**
  222 + * 数据版本
  223 + */
  224 + @TableField(value = "version")
  225 + @ApiModelProperty(value="数据版本")
  226 + private Integer version;
  227 +
  228 + /**
  229 + * 自定义字段1
  230 + */
  231 + @TableField(value = "userDef1")
  232 + @ApiModelProperty(value="自定义字段1")
  233 + private String userDef1;
  234 +
  235 + /**
  236 + * 自定义字段2
  237 + */
  238 + @TableField(value = "userDef2")
  239 + @ApiModelProperty(value="自定义字段2")
  240 + private String userDef2;
  241 +
  242 + /**
  243 + * 自定义字段3
  244 + */
  245 + @TableField(value = "userDef3")
  246 + @ApiModelProperty(value="自定义字段3")
  247 + private String userDef3;
  248 +
  249 + /**
  250 + * 自定义字段4
  251 + */
  252 + @TableField(value = "userDef4")
  253 + @ApiModelProperty(value="自定义字段4")
  254 + private String userDef4;
  255 +
  256 + /**
  257 + * 自定义字段5
  258 + */
  259 + @TableField(value = "userDef5")
  260 + @ApiModelProperty(value="自定义字段5")
  261 + private String userDef5;
  262 +
  263 + /**
  264 + * 自定义字段6
  265 + */
  266 + @TableField(value = "userDef6")
  267 + @ApiModelProperty(value="自定义字段6")
  268 + private String userDef6;
  269 +
  270 + /**
  271 + * 自定义字段7
  272 + */
  273 + @TableField(value = "userDef7")
  274 + @ApiModelProperty(value="自定义字段7")
  275 + private String userDef7;
  276 +
  277 + /**
  278 + * 自定义字段8
  279 + */
  280 + @TableField(value = "userDef8")
  281 + @ApiModelProperty(value="自定义字段8")
  282 + private String userDef8;
  283 +
  284 + /**
  285 + * 处理标记
  286 + */
  287 + @TableField(value = "processStamp")
  288 + @ApiModelProperty(value="处理标记")
  289 + private String processStamp;
  290 +
  291 + /**
  292 + * 是否删除
  293 + */
  294 + @TableField(value = "deleted")
  295 + @ApiModelProperty(value="是否删除")
  296 + private Boolean deleted;
  297 +
  298 + private static final long serialVersionUID = 1L;
  299 +}
0 \ No newline at end of file 300 \ No newline at end of file
src/main/java/com/huaheng/pc/receipt/receiptHeaderHistory/mapper/ReceiptHeaderHistoryMapper.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptHeaderHistory.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.receipt.receiptHeaderHistory.domain.ReceiptHeaderHistory;
  5 +
  6 +public interface ReceiptHeaderHistoryMapper extends BaseMapper<ReceiptHeaderHistory> {
  7 +}
0 \ No newline at end of file 8 \ No newline at end of file
src/main/java/com/huaheng/pc/receipt/receiptHeaderHistory/service/ReceiptHeaderHistoryService.java 0 → 100644
  1 +package com.huaheng.pc.receipt.receiptHeaderHistory.service;
  2 +
  3 +import org.springframework.stereotype.Service;
  4 +import javax.annotation.Resource;
  5 +import java.util.List;
  6 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  7 +import com.huaheng.pc.receipt.receiptHeaderHistory.domain.ReceiptHeaderHistory;
  8 +import com.huaheng.pc.receipt.receiptHeaderHistory.mapper.ReceiptHeaderHistoryMapper;
  9 +@Service
  10 +public class ReceiptHeaderHistoryService extends ServiceImpl<ReceiptHeaderHistoryMapper, ReceiptHeaderHistory> {
  11 +
  12 +}
src/main/java/com/huaheng/pc/shipment/shipmentDetailHistory/controller/ShipmentDetailHistoryController.java
@@ -15,6 +15,8 @@ import com.huaheng.framework.web.page.TableDataInfo; @@ -15,6 +15,8 @@ import com.huaheng.framework.web.page.TableDataInfo;
15 import com.huaheng.framework.web.page.TableSupport; 15 import com.huaheng.framework.web.page.TableSupport;
16 import com.huaheng.pc.shipment.shipmentDetail.domain.ShipmentDetail; 16 import com.huaheng.pc.shipment.shipmentDetail.domain.ShipmentDetail;
17 import com.huaheng.pc.shipment.shipmentDetail.service.ShipmentDetailService; 17 import com.huaheng.pc.shipment.shipmentDetail.service.ShipmentDetailService;
  18 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  19 +import com.huaheng.pc.shipment.shipmentDetailHistory.service.ShipmentDetailHistoryService;
18 import org.apache.shiro.authz.annotation.RequiresPermissions; 20 import org.apache.shiro.authz.annotation.RequiresPermissions;
19 import org.springframework.beans.factory.annotation.Autowired; 21 import org.springframework.beans.factory.annotation.Autowired;
20 import org.springframework.stereotype.Controller; 22 import org.springframework.stereotype.Controller;
@@ -24,7 +26,7 @@ import org.springframework.web.bind.annotation.*; @@ -24,7 +26,7 @@ import org.springframework.web.bind.annotation.*;
24 import java.util.List; 26 import java.util.List;
25 27
26 /** 28 /**
27 - * 出库明细 信息操作处理 29 + * 历史出库明细 信息操作处理
28 * 30 *
29 * @author huaheng 31 * @author huaheng
30 * @date 2018-08-19 32 * @date 2018-08-19
@@ -36,12 +38,12 @@ public class ShipmentDetailHistoryController extends BaseController @@ -36,12 +38,12 @@ public class ShipmentDetailHistoryController extends BaseController
36 private String prefix = "shipment/shipmentDetailHistory"; 38 private String prefix = "shipment/shipmentDetailHistory";
37 39
38 @Autowired 40 @Autowired
39 - private ShipmentDetailService shipmentDetailService; 41 + private ShipmentDetailHistoryService shipmentDetailHistoryService;
40 42
41 43
42 @RequiresPermissions("shipment:bill:view") 44 @RequiresPermissions("shipment:bill:view")
43 @GetMapping("/{shipmentId}/{shipmentCode}") 45 @GetMapping("/{shipmentId}/{shipmentCode}")
44 - public String shipmentDetail(@PathVariable("shipmentId") String shipmentId, @PathVariable("shipmentCode") String shipmentCode,@PathVariable("inventoryStatus") String inventoryStatus, ModelMap mmap) 46 + public String shipmentHistoryDetail(@PathVariable("shipmentId") String shipmentId, @PathVariable("shipmentCode") String shipmentCode,@PathVariable("inventoryStatus") String inventoryStatus, ModelMap mmap)
45 { 47 {
46 mmap.put("receiptId", shipmentId); 48 mmap.put("receiptId", shipmentId);
47 mmap.put("shipmentCode", shipmentCode); 49 mmap.put("shipmentCode", shipmentCode);
@@ -53,31 +55,31 @@ public class ShipmentDetailHistoryController extends BaseController @@ -53,31 +55,31 @@ public class ShipmentDetailHistoryController extends BaseController
53 * 查询出库明细列表 55 * 查询出库明细列表
54 */ 56 */
55 @RequiresPermissions("shipment:bill:list") 57 @RequiresPermissions("shipment:bill:list")
56 - @Log(title = "出库-出库单", operating= "查看出库明细", action = BusinessType.GRANT) 58 + @Log(title = "出库-历史出库单", operating= "查看历史出库明细", action = BusinessType.GRANT)
57 @PostMapping("/list") 59 @PostMapping("/list")
58 @ResponseBody 60 @ResponseBody
59 - public TableDataInfo list(ShipmentDetail shipmentDetail) 61 + public TableDataInfo list(ShipmentDetailHistory shipmentDetailHistory)
60 { 62 {
61 - LambdaQueryWrapper<ShipmentDetail> lambdaQueryWrapper = Wrappers.lambdaQuery(); 63 + LambdaQueryWrapper<ShipmentDetailHistory> lambdaQueryWrapper = Wrappers.lambdaQuery();
62 PageDomain pageDomain = TableSupport.buildPageRequest(); 64 PageDomain pageDomain = TableSupport.buildPageRequest();
63 Integer pageNum = pageDomain.getPageNum(); 65 Integer pageNum = pageDomain.getPageNum();
64 Integer pageSize = pageDomain.getPageSize(); 66 Integer pageSize = pageDomain.getPageSize();
65 67
66 lambdaQueryWrapper 68 lambdaQueryWrapper
67 - .eq(ShipmentDetail::getWarehouseCode,ShiroUtils.getWarehouseCode())  
68 - .in(ShipmentDetail::getCompanyCode,ShiroUtils.getCompanyCodeList())  
69 - .eq(StringUtils.isNotEmpty(shipmentDetail.getShipmentCode()),ShipmentDetail::getShipmentCode,shipmentDetail.getShipmentCode())  
70 - .orderByAsc(ShipmentDetail::getId); 69 + .eq(ShipmentDetailHistory::getWarehouseCode,ShiroUtils.getWarehouseCode())
  70 + .in(ShipmentDetailHistory::getCompanyCode,ShiroUtils.getCompanyCodeList())
  71 + .eq(StringUtils.isNotEmpty(shipmentDetailHistory.getShipmentCode()),ShipmentDetailHistory::getShipmentCode,shipmentDetailHistory.getShipmentCode())
  72 + .orderByAsc(ShipmentDetailHistory::getId);
71 73
72 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){ 74 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
73 /** 75 /**
74 * 使用分页查询 76 * 使用分页查询
75 */ 77 */
76 - Page<ShipmentDetail> page = new Page<>(pageNum, pageSize);  
77 - IPage<ShipmentDetail> iPage = shipmentDetailService.page(page, lambdaQueryWrapper); 78 + Page<ShipmentDetailHistory> page = new Page<>(pageNum, pageSize);
  79 + IPage<ShipmentDetailHistory> iPage = shipmentDetailHistoryService.page(page, lambdaQueryWrapper);
78 return getMpDataTable(iPage.getRecords(),iPage.getTotal()); 80 return getMpDataTable(iPage.getRecords(),iPage.getTotal());
79 } else { 81 } else {
80 - List<ShipmentDetail> list = shipmentDetailService.list(lambdaQueryWrapper); 82 + List<ShipmentDetailHistory> list = shipmentDetailHistoryService.list(lambdaQueryWrapper);
81 return getDataTable(list); 83 return getDataTable(list);
82 } 84 }
83 } 85 }
@@ -87,12 +89,12 @@ public class ShipmentDetailHistoryController extends BaseController @@ -87,12 +89,12 @@ public class ShipmentDetailHistoryController extends BaseController
87 * 删除出库明细 89 * 删除出库明细
88 */ 90 */
89 @RequiresPermissions("shipment:bill:remove") 91 @RequiresPermissions("shipment:bill:remove")
90 - @Log(title = "出库-出库单", operating= "删除出库明细", action = BusinessType.DELETE) 92 + @Log(title = "出库-历史出库单", operating= "删除历史出库明细", action = BusinessType.DELETE)
91 @PostMapping( "/remove") 93 @PostMapping( "/remove")
92 @ResponseBody 94 @ResponseBody
93 public AjaxResult remove(String ids) 95 public AjaxResult remove(String ids)
94 { 96 {
95 - AjaxResult result = shipmentDetailService.deleteDetail(ids); 97 + AjaxResult result = shipmentDetailHistoryService.deleteDetail(ids);
96 return result; 98 return result;
97 } 99 }
98 100
src/main/java/com/huaheng/pc/shipment/shipmentDetailHistory/domain/ShipmentDetailHistory.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentDetailHistory.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +
  10 +import java.io.Serializable;
  11 +import java.math.BigDecimal;
  12 +import java.util.Date;
  13 +
  14 +@ApiModel(value="com.huaheng.pc.shipment.shipmentDetail.domain.ShipmentDetailHistory")
  15 +@TableName(value = "shipment_detail_history")
  16 +public class ShipmentDetailHistory implements Serializable {
  17 + /**
  18 + * 出库单内部行号
  19 + */
  20 + @TableId(value = "id", type = IdType.AUTO)
  21 + @ApiModelProperty(value="出库单内部行号")
  22 + private Integer id;
  23 +
  24 + /**
  25 + * 出库单内部号
  26 + */
  27 + @TableField(value = "shipmentId")
  28 + @ApiModelProperty(value="出库单内部号")
  29 + private Integer shipmentId;
  30 +
  31 + /**
  32 + * 仓库
  33 + */
  34 + @TableField(value = "warehouseCode")
  35 + @ApiModelProperty(value="仓库")
  36 + private String warehouseCode;
  37 +
  38 + /**
  39 + * 货主
  40 + */
  41 + @TableField(value = "companyCode")
  42 + @ApiModelProperty(value="货主")
  43 + private String companyCode;
  44 +
  45 + /**
  46 + * 出库单号
  47 + */
  48 + @TableField(value = "shipmentCode")
  49 + @ApiModelProperty(value="出库单号")
  50 + private String shipmentCode;
  51 +
  52 + /**
  53 + * 上游订单号
  54 + */
  55 + @TableField(value = "referCode")
  56 + @ApiModelProperty(value="上游订单号")
  57 + private String referCode;
  58 +
  59 + /**
  60 + * 上游订单内部号
  61 + */
  62 + @TableField(value = "referId")
  63 + @ApiModelProperty(value="上游订单内部号")
  64 + private Integer referId;
  65 +
  66 + /**
  67 + * 上游订单行号
  68 + */
  69 + @TableField(value = "referLineNum")
  70 + @ApiModelProperty(value="上游订单行号")
  71 + private String referLineNum;
  72 +
  73 + /**
  74 + * 物料
  75 + */
  76 + @TableField(value = "materialCode")
  77 + @ApiModelProperty(value="物料")
  78 + private String materialCode;
  79 +
  80 + /**
  81 + * 物料描述
  82 + */
  83 + @TableField(value = "materialName")
  84 + @ApiModelProperty(value="物料描述")
  85 + private String materialName;
  86 +
  87 + /**
  88 + * 物料规格
  89 + */
  90 + @TableField(value = "materialSpec")
  91 + @ApiModelProperty(value="物料规格")
  92 + private String materialSpec;
  93 +
  94 + /**
  95 + * 物料单位
  96 + */
  97 + @TableField(value = "materialUnit")
  98 + @ApiModelProperty(value="物料单位")
  99 + private String materialUnit;
  100 +
  101 + /**
  102 + * 发货数量
  103 + */
  104 + @TableField(value = "shipQty")
  105 + @ApiModelProperty(value="发货数量")
  106 + private BigDecimal shipQty;
  107 +
  108 + /**
  109 + * 请求数量
  110 + */
  111 + @TableField(value = "requestQty")
  112 + @ApiModelProperty(value="请求数量")
  113 + private BigDecimal requestQty;
  114 +
  115 + /**
  116 + * 分配规则
  117 + */
  118 + @TableField(value = "allocationRule")
  119 + @ApiModelProperty(value="分配规则")
  120 + private String allocationRule;
  121 +
  122 + /**
  123 + * 补货规则
  124 + */
  125 + @TableField(value = "replenishmentRule")
  126 + @ApiModelProperty(value="补货规则")
  127 + private String replenishmentRule;
  128 +
  129 + /**
  130 + * 拣货货位
  131 + */
  132 + @TableField(value = "pickLocs")
  133 + @ApiModelProperty(value="拣货货位")
  134 + private String pickLocs;
  135 +
  136 + /**
  137 + * 属性1
  138 + */
  139 + @TableField(value = "attribute1")
  140 + @ApiModelProperty(value="属性1")
  141 + private String attribute1;
  142 +
  143 + /**
  144 + * 属性2
  145 + */
  146 + @TableField(value = "attribute2")
  147 + @ApiModelProperty(value="属性2")
  148 + private String attribute2;
  149 +
  150 + /**
  151 + * 属性3
  152 + */
  153 + @TableField(value = "attribute3")
  154 + @ApiModelProperty(value="属性3")
  155 + private String attribute3;
  156 +
  157 + /**
  158 + * 属性4
  159 + */
  160 + @TableField(value = "attribute4")
  161 + @ApiModelProperty(value="属性4")
  162 + private String attribute4;
  163 +
  164 + /**
  165 + * 批次
  166 + */
  167 + @TableField(value = "batch")
  168 + @ApiModelProperty(value="批次")
  169 + private String batch;
  170 +
  171 + /**
  172 + * 批号
  173 + */
  174 + @TableField(value = "lot")
  175 + @ApiModelProperty(value="批号")
  176 + private String lot;
  177 +
  178 + /**
  179 + * 项目号
  180 + */
  181 + @TableField(value = "projectNo")
  182 + @ApiModelProperty(value="项目号")
  183 + private String projectNo;
  184 +
  185 + /**
  186 + * 生产日期
  187 + */
  188 + @TableField(value = "manufactureDate")
  189 + @ApiModelProperty(value="生产日期")
  190 + private Date manufactureDate;
  191 +
  192 + /**
  193 + * 失效日期
  194 + */
  195 + @TableField(value = "expirationDate")
  196 + @ApiModelProperty(value="失效日期")
  197 + private Date expirationDate;
  198 +
  199 + /**
  200 + * 入库日期
  201 + */
  202 + @TableField(value = "agingDate")
  203 + @ApiModelProperty(value="入库日期")
  204 + private Date agingDate;
  205 +
  206 + /**
  207 + * 库存状态
  208 + */
  209 + @TableField(value = "inventorySts")
  210 + @ApiModelProperty(value="库存状态")
  211 + private String inventorySts;
  212 +
  213 + /**
  214 + * 月台货位
  215 + */
  216 + @TableField(value = "dockLoc")
  217 + @ApiModelProperty(value="月台货位")
  218 + private String dockLoc;
  219 +
  220 + /**
  221 + * 包装分类
  222 + */
  223 + @TableField(value = "packingClass")
  224 + @ApiModelProperty(value="包装分类")
  225 + private String packingClass;
  226 +
  227 +
  228 + /**
  229 + * 状态
  230 + */
  231 + @TableField(value = "status")
  232 + @ApiModelProperty(value="状态")
  233 + private Integer status;
  234 +
  235 + /**
  236 + * 波次号
  237 + */
  238 + @TableField(value = "waveId")
  239 + @ApiModelProperty(value="波次号")
  240 + private Integer waveId;
  241 +
  242 + /**
  243 + * 创建时间
  244 + */
  245 + @TableField(value = "created")
  246 + @ApiModelProperty(value="创建时间")
  247 + private Date created;
  248 +
  249 + /**
  250 + * 创建用户
  251 + */
  252 + @TableField(value = "createdBy")
  253 + @ApiModelProperty(value="创建用户")
  254 + private String createdBy;
  255 +
  256 + /**
  257 + * 创建时间
  258 + */
  259 + @TableField(value = "lastUpdated")
  260 + @ApiModelProperty(value="创建时间")
  261 + private Date lastUpdated;
  262 +
  263 + /**
  264 + * 更新用户
  265 + */
  266 + @TableField(value = "lastUpdatedBy")
  267 + @ApiModelProperty(value="更新用户")
  268 + private String lastUpdatedBy;
  269 +
  270 + /**
  271 + * 数据版本
  272 + */
  273 + @TableField(value = "version")
  274 + @ApiModelProperty(value="数据版本")
  275 + private Integer version;
  276 +
  277 + /**
  278 + * 自定义字段1
  279 + */
  280 + @TableField(value = "userDef1")
  281 + @ApiModelProperty(value="自定义字段1")
  282 + private String userDef1;
  283 +
  284 + /**
  285 + * 自定义字段2
  286 + */
  287 + @TableField(value = "userDef2")
  288 + @ApiModelProperty(value="自定义字段2")
  289 + private String userDef2;
  290 +
  291 + /**
  292 + * 自定义字段3
  293 + */
  294 + @TableField(value = "userDef3")
  295 + @ApiModelProperty(value="自定义字段3")
  296 + private String userDef3;
  297 +
  298 + /**
  299 + * 处理标记
  300 + */
  301 + @TableField(value = "processStamp")
  302 + @ApiModelProperty(value="处理标记")
  303 + private String processStamp;
  304 +
  305 + private static final long serialVersionUID = 1L;
  306 +
  307 + public static final String COL_SHIPMENTID = "shipmentId";
  308 +
  309 + public static final String COL_WAREHOUSECODE = "warehouseCode";
  310 +
  311 + public static final String COL_COMPANYCODE = "companyCode";
  312 +
  313 + public static final String COL_SHIPMENTCODE = "shipmentCode";
  314 +
  315 + public static final String COL_REFERCODE = "referCode";
  316 +
  317 + public static final String COL_REFERID = "referId";
  318 +
  319 + public static final String COL_REFERLINENUM = "referLineNum";
  320 +
  321 + public static final String COL_MATERIALCODE = "materialCode";
  322 +
  323 + public static final String COL_MATERIALNAME = "materialName";
  324 +
  325 + public static final String COL_MATERIALSPEC = "materialSpec";
  326 +
  327 + public static final String COL_MATERIALUNIT = "materialUnit";
  328 +
  329 + public static final String COL_SHIPQTY = "shipQty";
  330 +
  331 + public static final String COL_REQUESTQTY = "requestQty";
  332 +
  333 + public static final String COL_ALLOCATIONRULE = "allocationRule";
  334 +
  335 + public static final String COL_REPLENISHMENTRULE = "replenishmentRule";
  336 +
  337 + public static final String COL_PICKLOCS = "pickLocs";
  338 +
  339 + public static final String COL_ATTRIBUTE1 = "attribute1";
  340 +
  341 + public static final String COL_ATTRIBUTE2 = "attribute2";
  342 +
  343 + public static final String COL_ATTRIBUTE3 = "attribute3";
  344 +
  345 + public static final String COL_ATTRIBUTE4 = "attribute4";
  346 +
  347 + public static final String COL_BATCH = "batch";
  348 +
  349 + public static final String COL_LOT = "lot";
  350 +
  351 + public static final String COL_PROJECTNO = "projectNo";
  352 +
  353 + public static final String COL_MANUFACTUREDATE = "manufactureDate";
  354 +
  355 + public static final String COL_EXPIRATIONDATE = "expirationDate";
  356 +
  357 + public static final String COL_AGINGDATE = "agingDate";
  358 +
  359 + public static final String COL_INVENTORYSTS = "inventorySts";
  360 +
  361 + public static final String COL_DOCKLOC = "dockLoc";
  362 +
  363 + public static final String COL_PACKINGCLASS = "packingClass";
  364 +
  365 + public static final String COL_ENABLE = "enable";
  366 +
  367 + public static final String COL_WAVEID = "waveId";
  368 +
  369 + public static final String COL_CREATED = "created";
  370 +
  371 + public static final String COL_CREATEDBY = "createdBy";
  372 +
  373 + public static final String COL_LASTUPDATED = "lastUpdated";
  374 +
  375 + public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";
  376 +
  377 + public static final String COL_VERSION = "version";
  378 +
  379 + public static final String COL_USERDEF1 = "userDef1";
  380 +
  381 + public static final String COL_USERDEF2 = "userDef2";
  382 +
  383 + public static final String COL_USERDEF3 = "userDef3";
  384 +
  385 + public static final String COL_PROCESSSTAMP = "processStamp";
  386 +
  387 + /**
  388 + * 获取出库单内部行号
  389 + *
  390 + * @return id - 出库单内部行号
  391 + */
  392 + public Integer getId() {
  393 + return id;
  394 + }
  395 +
  396 + /**
  397 + * 设置出库单内部行号
  398 + *
  399 + * @param id 出库单内部行号
  400 + */
  401 + public void setId(Integer id) {
  402 + this.id = id;
  403 + }
  404 +
  405 + /**
  406 + * 获取出库单内部号
  407 + *
  408 + * @return shipmentId - 出库单内部号
  409 + */
  410 + public Integer getShipmentId() {
  411 + return shipmentId;
  412 + }
  413 +
  414 + /**
  415 + * 设置出库单内部号
  416 + *
  417 + * @param shipmentId 出库单内部号
  418 + */
  419 + public void setShipmentId(Integer shipmentId) {
  420 + this.shipmentId = shipmentId;
  421 + }
  422 +
  423 + /**
  424 + * 获取仓库
  425 + *
  426 + * @return warehouseCode - 仓库
  427 + */
  428 + public String getWarehouseCode() {
  429 + return warehouseCode;
  430 + }
  431 +
  432 + /**
  433 + * 设置仓库
  434 + *
  435 + * @param warehouseCode 仓库
  436 + */
  437 + public void setWarehouseCode(String warehouseCode) {
  438 + this.warehouseCode = warehouseCode;
  439 + }
  440 +
  441 + /**
  442 + * 获取货主
  443 + *
  444 + * @return companyCode - 货主
  445 + */
  446 + public String getCompanyCode() {
  447 + return companyCode;
  448 + }
  449 +
  450 + /**
  451 + * 设置货主
  452 + *
  453 + * @param companyCode 货主
  454 + */
  455 + public void setCompanyCode(String companyCode) {
  456 + this.companyCode = companyCode;
  457 + }
  458 +
  459 + /**
  460 + * 获取出库单号
  461 + *
  462 + * @return shipmentCode - 出库单号
  463 + */
  464 + public String getShipmentCode() {
  465 + return shipmentCode;
  466 + }
  467 +
  468 + /**
  469 + * 设置出库单号
  470 + *
  471 + * @param shipmentCode 出库单号
  472 + */
  473 + public void setShipmentCode(String shipmentCode) {
  474 + this.shipmentCode = shipmentCode;
  475 + }
  476 +
  477 + /**
  478 + * 获取上游订单号
  479 + *
  480 + * @return referCode - 上游订单号
  481 + */
  482 + public String getReferCode() {
  483 + return referCode;
  484 + }
  485 +
  486 + /**
  487 + * 设置上游订单号
  488 + *
  489 + * @param referCode 上游订单号
  490 + */
  491 + public void setReferCode(String referCode) {
  492 + this.referCode = referCode;
  493 + }
  494 +
  495 + /**
  496 + * 获取上游订单内部号
  497 + *
  498 + * @return referId - 上游订单内部号
  499 + */
  500 + public Integer getReferId() {
  501 + return referId;
  502 + }
  503 +
  504 + /**
  505 + * 设置上游订单内部号
  506 + *
  507 + * @param referId 上游订单内部号
  508 + */
  509 + public void setReferId(Integer referId) {
  510 + this.referId = referId;
  511 + }
  512 +
  513 + /**
  514 + * 获取上游订单行号
  515 + *
  516 + * @return referLineNum - 上游订单行号
  517 + */
  518 + public String getReferLineNum() {
  519 + return referLineNum;
  520 + }
  521 +
  522 + /**
  523 + * 设置上游订单行号
  524 + *
  525 + * @param referLineNum 上游订单行号
  526 + */
  527 + public void setReferLineNum(String referLineNum) {
  528 + this.referLineNum = referLineNum;
  529 + }
  530 +
  531 + /**
  532 + * 获取物料
  533 + *
  534 + * @return materialCode - 物料
  535 + */
  536 + public String getMaterialCode() {
  537 + return materialCode;
  538 + }
  539 +
  540 + /**
  541 + * 设置物料
  542 + *
  543 + * @param materialCode 物料
  544 + */
  545 + public void setMaterialCode(String materialCode) {
  546 + this.materialCode = materialCode;
  547 + }
  548 +
  549 + /**
  550 + * 获取物料描述
  551 + *
  552 + * @return materialName - 物料描述
  553 + */
  554 + public String getMaterialName() {
  555 + return materialName;
  556 + }
  557 +
  558 + /**
  559 + * 设置物料描述
  560 + *
  561 + * @param materialName 物料描述
  562 + */
  563 + public void setMaterialName(String materialName) {
  564 + this.materialName = materialName;
  565 + }
  566 +
  567 + /**
  568 + * 获取物料规格
  569 + *
  570 + * @return materialSpec - 物料规格
  571 + */
  572 + public String getMaterialSpec() {
  573 + return materialSpec;
  574 + }
  575 +
  576 + /**
  577 + * 设置物料规格
  578 + *
  579 + * @param materialSpec 物料规格
  580 + */
  581 + public void setMaterialSpec(String materialSpec) {
  582 + this.materialSpec = materialSpec;
  583 + }
  584 +
  585 + /**
  586 + * 获取物料单位
  587 + *
  588 + * @return materialUnit - 物料单位
  589 + */
  590 + public String getMaterialUnit() {
  591 + return materialUnit;
  592 + }
  593 +
  594 + /**
  595 + * 设置物料单位
  596 + *
  597 + * @param materialUnit 物料单位
  598 + */
  599 + public void setMaterialUnit(String materialUnit) {
  600 + this.materialUnit = materialUnit;
  601 + }
  602 +
  603 + public BigDecimal getShipQty() {
  604 + return shipQty;
  605 + }
  606 +
  607 + public void setShipQty(BigDecimal shipQty) {
  608 + this.shipQty = shipQty;
  609 + }
  610 +
  611 + public BigDecimal getRequestQty() {
  612 + return requestQty;
  613 + }
  614 +
  615 + public void setRequestQty(BigDecimal requestQty) {
  616 + this.requestQty = requestQty;
  617 + }
  618 +
  619 + /**
  620 + * 获取分配规则
  621 + *
  622 + * @return allocationRule - 分配规则
  623 + */
  624 + public String getAllocationRule() {
  625 + return allocationRule;
  626 + }
  627 +
  628 + /**
  629 + * 设置分配规则
  630 + *
  631 + * @param allocationRule 分配规则
  632 + */
  633 + public void setAllocationRule(String allocationRule) {
  634 + this.allocationRule = allocationRule;
  635 + }
  636 +
  637 + /**
  638 + * 获取补货规则
  639 + *
  640 + * @return replenishmentRule - 补货规则
  641 + */
  642 + public String getReplenishmentRule() {
  643 + return replenishmentRule;
  644 + }
  645 +
  646 + /**
  647 + * 设置补货规则
  648 + *
  649 + * @param replenishmentRule 补货规则
  650 + */
  651 + public void setReplenishmentRule(String replenishmentRule) {
  652 + this.replenishmentRule = replenishmentRule;
  653 + }
  654 +
  655 + /**
  656 + * 获取拣货货位
  657 + *
  658 + * @return pickLocs - 拣货货位
  659 + */
  660 + public String getPickLocs() {
  661 + return pickLocs;
  662 + }
  663 +
  664 + /**
  665 + * 设置拣货货位
  666 + *
  667 + * @param pickLocs 拣货货位
  668 + */
  669 + public void setPickLocs(String pickLocs) {
  670 + this.pickLocs = pickLocs;
  671 + }
  672 +
  673 + /**
  674 + * 获取属性1
  675 + *
  676 + * @return attribute1 - 属性1
  677 + */
  678 + public String getAttribute1() {
  679 + return attribute1;
  680 + }
  681 +
  682 + /**
  683 + * 设置属性1
  684 + *
  685 + * @param attribute1 属性1
  686 + */
  687 + public void setAttribute1(String attribute1) {
  688 + this.attribute1 = attribute1;
  689 + }
  690 +
  691 + /**
  692 + * 获取属性2
  693 + *
  694 + * @return attribute2 - 属性2
  695 + */
  696 + public String getAttribute2() {
  697 + return attribute2;
  698 + }
  699 +
  700 + /**
  701 + * 设置属性2
  702 + *
  703 + * @param attribute2 属性2
  704 + */
  705 + public void setAttribute2(String attribute2) {
  706 + this.attribute2 = attribute2;
  707 + }
  708 +
  709 + /**
  710 + * 获取属性3
  711 + *
  712 + * @return attribute3 - 属性3
  713 + */
  714 + public String getAttribute3() {
  715 + return attribute3;
  716 + }
  717 +
  718 + /**
  719 + * 设置属性3
  720 + *
  721 + * @param attribute3 属性3
  722 + */
  723 + public void setAttribute3(String attribute3) {
  724 + this.attribute3 = attribute3;
  725 + }
  726 +
  727 + /**
  728 + * 获取属性4
  729 + *
  730 + * @return attribute4 - 属性4
  731 + */
  732 + public String getAttribute4() {
  733 + return attribute4;
  734 + }
  735 +
  736 + /**
  737 + * 设置属性4
  738 + *
  739 + * @param attribute4 属性4
  740 + */
  741 + public void setAttribute4(String attribute4) {
  742 + this.attribute4 = attribute4;
  743 + }
  744 +
  745 + /**
  746 + * 获取批次
  747 + *
  748 + * @return batch - 批次
  749 + */
  750 + public String getBatch() {
  751 + return batch;
  752 + }
  753 +
  754 + /**
  755 + * 设置批次
  756 + *
  757 + * @param batch 批次
  758 + */
  759 + public void setBatch(String batch) {
  760 + this.batch = batch;
  761 + }
  762 +
  763 + /**
  764 + * 获取批号
  765 + *
  766 + * @return lot - 批号
  767 + */
  768 + public String getLot() {
  769 + return lot;
  770 + }
  771 +
  772 + /**
  773 + * 设置批号
  774 + *
  775 + * @param lot 批号
  776 + */
  777 + public void setLot(String lot) {
  778 + this.lot = lot;
  779 + }
  780 +
  781 + /**
  782 + * 获取项目号
  783 + *
  784 + * @return projectNo - 项目号
  785 + */
  786 + public String getProjectNo() {
  787 + return projectNo;
  788 + }
  789 +
  790 + /**
  791 + * 设置项目号
  792 + *
  793 + * @param projectNo 项目号
  794 + */
  795 + public void setProjectNo(String projectNo) {
  796 + this.projectNo = projectNo;
  797 + }
  798 +
  799 + /**
  800 + * 获取生产日期
  801 + *
  802 + * @return manufactureDate - 生产日期
  803 + */
  804 + public Date getManufactureDate() {
  805 + return manufactureDate;
  806 + }
  807 +
  808 + /**
  809 + * 设置生产日期
  810 + *
  811 + * @param manufactureDate 生产日期
  812 + */
  813 + public void setManufactureDate(Date manufactureDate) {
  814 + this.manufactureDate = manufactureDate;
  815 + }
  816 +
  817 + /**
  818 + * 获取失效日期
  819 + *
  820 + * @return expirationDate - 失效日期
  821 + */
  822 + public Date getExpirationDate() {
  823 + return expirationDate;
  824 + }
  825 +
  826 + /**
  827 + * 设置失效日期
  828 + *
  829 + * @param expirationDate 失效日期
  830 + */
  831 + public void setExpirationDate(Date expirationDate) {
  832 + this.expirationDate = expirationDate;
  833 + }
  834 +
  835 + /**
  836 + * 获取入库日期
  837 + *
  838 + * @return agingDate - 入库日期
  839 + */
  840 + public Date getAgingDate() {
  841 + return agingDate;
  842 + }
  843 +
  844 + /**
  845 + * 设置入库日期
  846 + *
  847 + * @param agingDate 入库日期
  848 + */
  849 + public void setAgingDate(Date agingDate) {
  850 + this.agingDate = agingDate;
  851 + }
  852 +
  853 + /**
  854 + * 获取库存状态
  855 + *
  856 + * @return inventorySts - 库存状态
  857 + */
  858 + public String getInventorySts() {
  859 + return inventorySts;
  860 + }
  861 +
  862 + /**
  863 + * 设置库存状态
  864 + *
  865 + * @param inventorySts 库存状态
  866 + */
  867 + public void setInventorySts(String inventorySts) {
  868 + this.inventorySts = inventorySts;
  869 + }
  870 +
  871 + /**
  872 + * 获取月台货位
  873 + *
  874 + * @return dockLoc - 月台货位
  875 + */
  876 + public String getDockLoc() {
  877 + return dockLoc;
  878 + }
  879 +
  880 + /**
  881 + * 设置月台货位
  882 + *
  883 + * @param dockLoc 月台货位
  884 + */
  885 + public void setDockLoc(String dockLoc) {
  886 + this.dockLoc = dockLoc;
  887 + }
  888 +
  889 + /**
  890 + * 获取包装分类
  891 + *
  892 + * @return packingClass - 包装分类
  893 + */
  894 + public String getPackingClass() {
  895 + return packingClass;
  896 + }
  897 +
  898 + /**
  899 + * 设置包装分类
  900 + *
  901 + * @param packingClass 包装分类
  902 + */
  903 + public void setPackingClass(String packingClass) {
  904 + this.packingClass = packingClass;
  905 + }
  906 +
  907 + public Integer getStatus() {
  908 + return status;
  909 + }
  910 +
  911 + public void setStatus(Integer status) {
  912 + this.status = status;
  913 + }
  914 +
  915 + /**
  916 + * 获取波次号
  917 + *
  918 + * @return waveId - 波次号
  919 + */
  920 + public Integer getWaveId() {
  921 + return waveId;
  922 + }
  923 +
  924 + /**
  925 + * 设置波次号
  926 + *
  927 + * @param waveId 波次号
  928 + */
  929 + public void setWaveId(Integer waveId) {
  930 + this.waveId = waveId;
  931 + }
  932 +
  933 + /**
  934 + * 获取创建时间
  935 + *
  936 + * @return created - 创建时间
  937 + */
  938 + public Date getCreated() {
  939 + return created;
  940 + }
  941 +
  942 + /**
  943 + * 设置创建时间
  944 + *
  945 + * @param created 创建时间
  946 + */
  947 + public void setCreated(Date created) {
  948 + this.created = created;
  949 + }
  950 +
  951 + /**
  952 + * 获取创建用户
  953 + *
  954 + * @return createdBy - 创建用户
  955 + */
  956 + public String getCreatedBy() {
  957 + return createdBy;
  958 + }
  959 +
  960 + /**
  961 + * 设置创建用户
  962 + *
  963 + * @param createdBy 创建用户
  964 + */
  965 + public void setCreatedBy(String createdBy) {
  966 + this.createdBy = createdBy;
  967 + }
  968 +
  969 + /**
  970 + * 获取创建时间
  971 + *
  972 + * @return lastUpdated - 创建时间
  973 + */
  974 + public Date getLastUpdated() {
  975 + return lastUpdated;
  976 + }
  977 +
  978 + /**
  979 + * 设置创建时间
  980 + *
  981 + * @param lastUpdated 创建时间
  982 + */
  983 + public void setLastUpdated(Date lastUpdated) {
  984 + this.lastUpdated = lastUpdated;
  985 + }
  986 +
  987 + /**
  988 + * 获取更新用户
  989 + *
  990 + * @return lastUpdatedBy - 更新用户
  991 + */
  992 + public String getLastUpdatedBy() {
  993 + return lastUpdatedBy;
  994 + }
  995 +
  996 + /**
  997 + * 设置更新用户
  998 + *
  999 + * @param lastUpdatedBy 更新用户
  1000 + */
  1001 + public void setLastUpdatedBy(String lastUpdatedBy) {
  1002 + this.lastUpdatedBy = lastUpdatedBy;
  1003 + }
  1004 +
  1005 + /**
  1006 + * 获取数据版本
  1007 + *
  1008 + * @return version - 数据版本
  1009 + */
  1010 + public Integer getVersion() {
  1011 + return version;
  1012 + }
  1013 +
  1014 + /**
  1015 + * 设置数据版本
  1016 + *
  1017 + * @param version 数据版本
  1018 + */
  1019 + public void setVersion(Integer version) {
  1020 + this.version = version;
  1021 + }
  1022 +
  1023 + /**
  1024 + * 获取自定义字段1
  1025 + *
  1026 + * @return userDef1 - 自定义字段1
  1027 + */
  1028 + public String getUserDef1() {
  1029 + return userDef1;
  1030 + }
  1031 +
  1032 + /**
  1033 + * 设置自定义字段1
  1034 + *
  1035 + * @param userDef1 自定义字段1
  1036 + */
  1037 + public void setUserDef1(String userDef1) {
  1038 + this.userDef1 = userDef1;
  1039 + }
  1040 +
  1041 + /**
  1042 + * 获取自定义字段2
  1043 + *
  1044 + * @return userDef2 - 自定义字段2
  1045 + */
  1046 + public String getUserDef2() {
  1047 + return userDef2;
  1048 + }
  1049 +
  1050 + /**
  1051 + * 设置自定义字段2
  1052 + *
  1053 + * @param userDef2 自定义字段2
  1054 + */
  1055 + public void setUserDef2(String userDef2) {
  1056 + this.userDef2 = userDef2;
  1057 + }
  1058 +
  1059 + /**
  1060 + * 获取自定义字段3
  1061 + *
  1062 + * @return userDef3 - 自定义字段3
  1063 + */
  1064 + public String getUserDef3() {
  1065 + return userDef3;
  1066 + }
  1067 +
  1068 + /**
  1069 + * 设置自定义字段3
  1070 + *
  1071 + * @param userDef3 自定义字段3
  1072 + */
  1073 + public void setUserDef3(String userDef3) {
  1074 + this.userDef3 = userDef3;
  1075 + }
  1076 +
  1077 +
  1078 + /**
  1079 + * 获取处理标记
  1080 + *
  1081 + * @return processStamp - 处理标记
  1082 + */
  1083 + public String getProcessStamp() {
  1084 + return processStamp;
  1085 + }
  1086 +
  1087 + /**
  1088 + * 设置处理标记
  1089 + *
  1090 + * @param processStamp 处理标记
  1091 + */
  1092 + public void setProcessStamp(String processStamp) {
  1093 + this.processStamp = processStamp;
  1094 + }
  1095 +}
0 \ No newline at end of file 1096 \ No newline at end of file
src/main/java/com/huaheng/pc/shipment/shipmentDetailHistory/mapper/ShipmentDetailHistoryMapper.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentDetailHistory.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  5 +
  6 +import java.util.List;
  7 +import java.util.Map;
  8 +
  9 +
  10 +public interface ShipmentDetailHistoryMapper extends BaseMapper<ShipmentDetailHistory> {
  11 +
  12 +
  13 + List<Map<String,Integer>> SelectFirstStatus(String ids);
  14 +
  15 + Integer batchDelete(String[] ids);
  16 +
  17 + Map<String,String> StatisticalByReceiptId(Integer headerId);
  18 +
  19 +}
0 \ No newline at end of file 20 \ No newline at end of file
src/main/java/com/huaheng/pc/shipment/shipmentDetailHistory/service/ShipmentDetailHistoryService.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentDetailHistory.service;
  2 +
  3 +import com.baomidou.mybatisplus.extension.service.IService;
  4 +import com.huaheng.framework.web.domain.AjaxResult;
  5 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  6 +
  7 +public interface ShipmentDetailHistoryService extends IService<ShipmentDetailHistory>{
  8 +
  9 + AjaxResult deleteDetail(String id);
  10 +
  11 +
  12 +}
src/main/java/com/huaheng/pc/shipment/shipmentDetailHistory/service/ShipmentDetailHistoryServiceImpl.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentDetailHistory.service;
  2 +
  3 +
  4 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  5 +import com.huaheng.common.utils.DataUtils;
  6 +import com.huaheng.common.utils.StringUtils;
  7 +import com.huaheng.framework.web.domain.AjaxResult;
  8 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  9 +import com.huaheng.pc.shipment.shipmentDetailHistory.mapper.ShipmentDetailHistoryMapper;
  10 +import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;
  11 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  12 +import com.huaheng.pc.shipment.shipmentHeaderHistory.service.ShipmentHeaderHistoryService;
  13 +import org.springframework.beans.factory.annotation.Autowired;
  14 +import org.springframework.stereotype.Service;
  15 +import org.springframework.transaction.annotation.Transactional;
  16 +
  17 +import javax.annotation.Resource;
  18 +import java.util.List;
  19 +import java.util.Map;
  20 +
  21 +@Service
  22 +public class ShipmentDetailHistoryServiceImpl extends ServiceImpl<ShipmentDetailHistoryMapper, ShipmentDetailHistory> implements ShipmentDetailHistoryService {
  23 +
  24 +
  25 + @Resource
  26 + private ShipmentDetailHistoryMapper shipmentDetailHistoryMapper;
  27 + @Autowired
  28 + private ShipmentHeaderHistoryService shipmentHeaderHistoryService;
  29 +
  30 + /**
  31 + * 删除出库单据明细
  32 + *
  33 + * @param id
  34 + * @return
  35 + */
  36 + @Override
  37 + @Transactional
  38 + public AjaxResult deleteDetail(String id) {
  39 + if (StringUtils.isEmpty(id))
  40 + return AjaxResult.error("id不能为空");
  41 + String[] ids = id.split(",");
  42 + List<Map<String,Integer>> list = shipmentDetailHistoryMapper.SelectFirstStatus(id);
  43 + if (list.size() < 1) {
  44 + return AjaxResult.error("找不到主单据!");
  45 + }
  46 + if (list.size() > 1) {
  47 + return AjaxResult.error("有多个主单据,不能一起删除!");
  48 + }
  49 + if (list.get(0).get("firstStatus") > 100) {
  50 + return AjaxResult.error("单据状进入订单池,不允许删除明细");
  51 + }
  52 + Integer result = shipmentDetailHistoryMapper.batchDelete(ids);
  53 + if (result > 0) {
  54 + Integer headerId=list.get(0).get("id");
  55 + Map<String,String> map= shipmentDetailHistoryMapper.StatisticalByReceiptId(headerId);
  56 + if(DataUtils.getInteger(map.get("totalLines")) <= 0) {
  57 + shipmentHeaderHistoryService.removeById(headerId);
  58 + }
  59 + else {
  60 + //更新表头的总行数和总数量统计
  61 + ShipmentHeaderHistory shipmentHeaderHistory = new ShipmentHeaderHistory();
  62 + shipmentHeaderHistory.setId(headerId);
  63 + shipmentHeaderHistory.setTotalLines(DataUtils.getInteger(map.get("totalLines")));
  64 + shipmentHeaderHistory.setTotalQty(DataUtils.getBigDecimal(map.get("totalQty")));
  65 + shipmentHeaderHistoryService.saveOrUpdate(shipmentHeaderHistory);
  66 + }
  67 + return AjaxResult.success("删除单据明细成功");
  68 + }
  69 + else
  70 + return AjaxResult.error("删除单据明细失败");
  71 + }
  72 +}
src/main/java/com/huaheng/pc/shipment/shipmentHeader/controller/ShipmentHeaderController.java
@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; @@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4 import com.baomidou.mybatisplus.core.metadata.IPage; 4 import com.baomidou.mybatisplus.core.metadata.IPage;
5 import com.baomidou.mybatisplus.core.toolkit.Wrappers; 5 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
6 import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 6 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
  7 +import com.huaheng.common.exception.service.ServiceException;
7 import com.huaheng.common.support.Convert; 8 import com.huaheng.common.support.Convert;
8 import com.huaheng.common.utils.StringUtils; 9 import com.huaheng.common.utils.StringUtils;
9 import com.huaheng.common.utils.security.ShiroUtils; 10 import com.huaheng.common.utils.security.ShiroUtils;
@@ -11,7 +12,6 @@ import com.huaheng.framework.aspectj.lang.annotation.Log; @@ -11,7 +12,6 @@ import com.huaheng.framework.aspectj.lang.annotation.Log;
11 import com.huaheng.framework.aspectj.lang.constant.BusinessType; 12 import com.huaheng.framework.aspectj.lang.constant.BusinessType;
12 import com.huaheng.framework.web.controller.BaseController; 13 import com.huaheng.framework.web.controller.BaseController;
13 import com.huaheng.framework.web.domain.AjaxResult; 14 import com.huaheng.framework.web.domain.AjaxResult;
14 -import com.huaheng.framework.web.domain.RetCode;  
15 import com.huaheng.framework.web.page.PageDomain; 15 import com.huaheng.framework.web.page.PageDomain;
16 import com.huaheng.framework.web.page.TableDataInfo; 16 import com.huaheng.framework.web.page.TableDataInfo;
17 import com.huaheng.framework.web.page.TableSupport; 17 import com.huaheng.framework.web.page.TableSupport;
@@ -22,9 +22,11 @@ import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService; @@ -22,9 +22,11 @@ import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService;
22 import org.apache.shiro.authz.annotation.RequiresPermissions; 22 import org.apache.shiro.authz.annotation.RequiresPermissions;
23 import org.springframework.beans.factory.annotation.Autowired; 23 import org.springframework.beans.factory.annotation.Autowired;
24 import org.springframework.stereotype.Controller; 24 import org.springframework.stereotype.Controller;
  25 +import org.springframework.transaction.annotation.Transactional;
25 import org.springframework.ui.ModelMap; 26 import org.springframework.ui.ModelMap;
26 import org.springframework.web.bind.annotation.*; 27 import org.springframework.web.bind.annotation.*;
27 28
  29 +import java.lang.reflect.InvocationTargetException;
28 import java.util.List; 30 import java.util.List;
29 31
30 32
@@ -44,7 +46,6 @@ public class ShipmentHeaderController extends BaseController @@ -44,7 +46,6 @@ public class ShipmentHeaderController extends BaseController
44 private ShipmentHeaderService shipmentHeaderService; 46 private ShipmentHeaderService shipmentHeaderService;
45 @Autowired 47 @Autowired
46 private ShipmentDetailService shipmentDetailService; 48 private ShipmentDetailService shipmentDetailService;
47 -  
48 49
49 @RequiresPermissions("shipment:bill:view") 50 @RequiresPermissions("shipment:bill:view")
50 @GetMapping() 51 @GetMapping()
@@ -155,18 +156,25 @@ public class ShipmentHeaderController extends BaseController @@ -155,18 +156,25 @@ public class ShipmentHeaderController extends BaseController
155 @Log(title = "出库-出库单", operating="删除出库主单", action = BusinessType.DELETE) 156 @Log(title = "出库-出库单", operating="删除出库主单", action = BusinessType.DELETE)
156 @PostMapping( "/remove") 157 @PostMapping( "/remove")
157 @ResponseBody 158 @ResponseBody
158 - public AjaxResult remove(String ids) { 159 + @Transactional
  160 + public AjaxResult remove(String ids) throws InvocationTargetException, IllegalAccessException {
159 if (StringUtils.isEmpty(ids)) 161 if (StringUtils.isEmpty(ids))
160 return AjaxResult.error("id不能为空"); 162 return AjaxResult.error("id不能为空");
161 for (Integer id : Convert.toIntArray(ids)) 163 for (Integer id : Convert.toIntArray(ids))
162 { 164 {
163 - ShipmentHeader shipmentHeader=new ShipmentHeader();  
164 - shipmentHeader.setId(id); 165 + ShipmentHeader shipmentHeader=shipmentHeaderService.getById(id);
  166 +
  167 + //出库单设定为历史出库单,并删除出库单
  168 + shipmentHeaderService.addHistory(shipmentHeader);
165 shipmentHeader.setDeleted(true); 169 shipmentHeader.setDeleted(true);
166 - boolean result=shipmentHeaderService.updateById(shipmentHeader); 170 + boolean result=shipmentHeaderService.removeById(id);
167 if(result==false){ 171 if(result==false){
168 - return AjaxResult.error("删除失败"); 172 + throw new ServiceException("删除失败");
169 } 173 }
  174 + LambdaQueryWrapper<ShipmentDetail> shipmentDetailLambdaQueryWrapper=Wrappers.lambdaQuery();
  175 + shipmentDetailLambdaQueryWrapper.eq(ShipmentDetail::getShipmentCode,shipmentHeader.getCode())
  176 + .eq(ShipmentDetail::getWarehouseCode,shipmentHeader.getWarehouseCode());
  177 + shipmentDetailService.remove(shipmentDetailLambdaQueryWrapper);
170 } 178 }
171 return AjaxResult.success("删除成功!"); 179 return AjaxResult.success("删除成功!");
172 } 180 }
src/main/java/com/huaheng/pc/shipment/shipmentHeader/service/ShipmentHeaderService.java
@@ -3,6 +3,9 @@ package com.huaheng.pc.shipment.shipmentHeader.service; @@ -3,6 +3,9 @@ package com.huaheng.pc.shipment.shipmentHeader.service;
3 import com.huaheng.framework.web.domain.AjaxResult; 3 import com.huaheng.framework.web.domain.AjaxResult;
4 import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader; 4 import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;
5 import com.baomidou.mybatisplus.extension.service.IService; 5 import com.baomidou.mybatisplus.extension.service.IService;
  6 +
  7 +import java.lang.reflect.InvocationTargetException;
  8 +
6 public interface ShipmentHeaderService extends IService<ShipmentHeader>{ 9 public interface ShipmentHeaderService extends IService<ShipmentHeader>{
7 10
8 //新增出库主单 11 //新增出库主单
@@ -15,4 +18,6 @@ public interface ShipmentHeaderService extends IService&lt;ShipmentHeader&gt;{ @@ -15,4 +18,6 @@ public interface ShipmentHeaderService extends IService&lt;ShipmentHeader&gt;{
15 //根据Id更新这个单据的首尾状态 18 //根据Id更新这个单据的首尾状态
16 AjaxResult updateShipmentStatus(int shipmentId); 19 AjaxResult updateShipmentStatus(int shipmentId);
17 20
  21 + AjaxResult addHistory(ShipmentHeader shipmentHeader) throws InvocationTargetException, IllegalAccessException;
  22 +
18 } 23 }
src/main/java/com/huaheng/pc/shipment/shipmentHeader/service/ShipmentHeaderServiceImpl.java
1 package com.huaheng.pc.shipment.shipmentHeader.service; 1 package com.huaheng.pc.shipment.shipmentHeader.service;
2 2
  3 +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
  4 +import com.baomidou.mybatisplus.core.toolkit.Wrappers;
  5 +import com.huaheng.common.exception.service.ServiceException;
3 import com.huaheng.common.utils.security.ShiroUtils; 6 import com.huaheng.common.utils.security.ShiroUtils;
4 import com.huaheng.framework.web.domain.AjaxResult; 7 import com.huaheng.framework.web.domain.AjaxResult;
5 import com.huaheng.pc.shipment.shipmentContainerHeader.service.ShipmentContainerHeaderService; 8 import com.huaheng.pc.shipment.shipmentContainerHeader.service.ShipmentContainerHeaderService;
  9 +import com.huaheng.pc.shipment.shipmentDetail.domain.ShipmentDetail;
6 import com.huaheng.pc.shipment.shipmentDetail.service.ShipmentDetailService; 10 import com.huaheng.pc.shipment.shipmentDetail.service.ShipmentDetailService;
  11 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  12 +import com.huaheng.pc.shipment.shipmentDetailHistory.service.ShipmentDetailHistoryService;
  13 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  14 +import com.huaheng.pc.shipment.shipmentHeaderHistory.service.ShipmentHeaderHistoryService;
7 import com.huaheng.pc.system.dict.service.IDictDataService; 15 import com.huaheng.pc.system.dict.service.IDictDataService;
  16 +import org.apache.commons.beanutils.BeanUtils;
8 import org.springframework.beans.factory.annotation.Autowired; 17 import org.springframework.beans.factory.annotation.Autowired;
9 import org.springframework.stereotype.Service; 18 import org.springframework.stereotype.Service;
10 import javax.annotation.Resource; 19 import javax.annotation.Resource;
  20 +import java.lang.reflect.InvocationTargetException;
11 import java.text.SimpleDateFormat; 21 import java.text.SimpleDateFormat;
  22 +import java.util.ArrayList;
12 import java.util.Date; 23 import java.util.Date;
13 import java.util.List; 24 import java.util.List;
14 import java.util.Map; 25 import java.util.Map;
@@ -17,6 +28,8 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; @@ -17,6 +28,8 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
17 import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader; 28 import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;
18 import com.huaheng.pc.shipment.shipmentHeader.mapper.ShipmentHeaderMapper; 29 import com.huaheng.pc.shipment.shipmentHeader.mapper.ShipmentHeaderMapper;
19 import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService; 30 import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService;
  31 +import org.springframework.transaction.annotation.Transactional;
  32 +
20 @Service 33 @Service
21 public class ShipmentHeaderServiceImpl extends ServiceImpl<ShipmentHeaderMapper, ShipmentHeader> implements ShipmentHeaderService{ 34 public class ShipmentHeaderServiceImpl extends ServiceImpl<ShipmentHeaderMapper, ShipmentHeader> implements ShipmentHeaderService{
22 35
@@ -28,6 +41,11 @@ public class ShipmentHeaderServiceImpl extends ServiceImpl&lt;ShipmentHeaderMapper, @@ -28,6 +41,11 @@ public class ShipmentHeaderServiceImpl extends ServiceImpl&lt;ShipmentHeaderMapper,
28 private ShipmentDetailService shipmentDetailService; 41 private ShipmentDetailService shipmentDetailService;
29 @Autowired 42 @Autowired
30 private ShipmentContainerHeaderService shipmentContainerHeaderService; 43 private ShipmentContainerHeaderService shipmentContainerHeaderService;
  44 + @Autowired
  45 + private ShipmentHeaderHistoryService shipmentHeaderHistoryService;
  46 + @Autowired
  47 + private ShipmentDetailHistoryService shipmentDetailHistoryService;
  48 +
31 49
32 50
33 //新增出库主单 51 //新增出库主单
@@ -122,4 +140,33 @@ public class ShipmentHeaderServiceImpl extends ServiceImpl&lt;ShipmentHeaderMapper, @@ -122,4 +140,33 @@ public class ShipmentHeaderServiceImpl extends ServiceImpl&lt;ShipmentHeaderMapper,
122 return AjaxResult.success(""); 140 return AjaxResult.success("");
123 141
124 } 142 }
  143 +
  144 + //出库单字段变为历史出库单
  145 + @Override
  146 + @Transactional
  147 + public AjaxResult addHistory(ShipmentHeader shipmentHeader) throws InvocationTargetException, IllegalAccessException {
  148 + //历史出库主单
  149 + ShipmentHeaderHistory shipmentHeaderHistory=new ShipmentHeaderHistory();
  150 + BeanUtils.copyProperties(shipmentHeaderHistory,shipmentHeader);
  151 + if(shipmentHeaderHistoryService.save(shipmentHeaderHistory)==false){
  152 + throw new ServiceException("存入历史出库主单失败");
  153 + }
  154 + LambdaQueryWrapper<ShipmentDetail> lambdaQueryWrapper=Wrappers.lambdaQuery();
  155 + lambdaQueryWrapper.eq(ShipmentDetail::getWarehouseCode,shipmentHeader.getWarehouseCode())
  156 + .eq(ShipmentDetail::getShipmentCode,shipmentHeader.getCode());
  157 + List<ShipmentDetail> shipmentDetails=shipmentDetailService.list(lambdaQueryWrapper);
  158 +
  159 + //历史出库子单
  160 + List<ShipmentDetailHistory> shipmentDetailHistories=new ArrayList<>();
  161 + for(ShipmentDetail item:shipmentDetails){
  162 + ShipmentDetailHistory shipmentDetailHistory=new ShipmentDetailHistory();
  163 + BeanUtils.copyProperties(shipmentDetailHistory,item);
  164 + shipmentDetailHistories.add(shipmentDetailHistory);
  165 + }
  166 + Boolean flag=shipmentDetailHistoryService.saveBatch(shipmentDetailHistories);
  167 + if(flag==false){
  168 + throw new ServiceException("存入历史出库子单失败");
  169 + }
  170 + return null;
  171 + }
125 } 172 }
src/main/java/com/huaheng/pc/shipment/shipmentHeaderHistory/controller/ShipmentHeaderHistoryController.java
@@ -14,10 +14,10 @@ import com.huaheng.framework.web.domain.AjaxResult; @@ -14,10 +14,10 @@ import com.huaheng.framework.web.domain.AjaxResult;
14 import com.huaheng.framework.web.page.PageDomain; 14 import com.huaheng.framework.web.page.PageDomain;
15 import com.huaheng.framework.web.page.TableDataInfo; 15 import com.huaheng.framework.web.page.TableDataInfo;
16 import com.huaheng.framework.web.page.TableSupport; 16 import com.huaheng.framework.web.page.TableSupport;
17 -import com.huaheng.pc.shipment.shipmentDetail.domain.ShipmentDetail;  
18 -import com.huaheng.pc.shipment.shipmentDetail.service.ShipmentDetailService;  
19 -import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;  
20 -import com.huaheng.pc.shipment.shipmentHeader.service.ShipmentHeaderService; 17 +import com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory;
  18 +import com.huaheng.pc.shipment.shipmentDetailHistory.service.ShipmentDetailHistoryService;
  19 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  20 +import com.huaheng.pc.shipment.shipmentHeaderHistory.service.ShipmentHeaderHistoryService;
21 import org.apache.shiro.authz.annotation.RequiresPermissions; 21 import org.apache.shiro.authz.annotation.RequiresPermissions;
22 import org.springframework.beans.factory.annotation.Autowired; 22 import org.springframework.beans.factory.annotation.Autowired;
23 import org.springframework.stereotype.Controller; 23 import org.springframework.stereotype.Controller;
@@ -40,14 +40,14 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -40,14 +40,14 @@ public class ShipmentHeaderHistoryController extends BaseController
40 private String prefix = "shipment/shipmentHeaderHistory"; 40 private String prefix = "shipment/shipmentHeaderHistory";
41 41
42 @Autowired 42 @Autowired
43 - private ShipmentHeaderService shipmentHeaderService; 43 + private ShipmentHeaderHistoryService shipmentHeaderHistoryService;
44 @Autowired 44 @Autowired
45 - private ShipmentDetailService shipmentDetailService; 45 + private ShipmentDetailHistoryService shipmentDetailHistoryService;
46 46
47 47
48 @RequiresPermissions("shipment:bill:view") 48 @RequiresPermissions("shipment:bill:view")
49 @GetMapping() 49 @GetMapping()
50 - public String shipmentHeader() 50 + public String shipmentHeaderHistory()
51 { 51 {
52 return prefix + "/shipmentHeaderHistory"; 52 return prefix + "/shipmentHeaderHistory";
53 } 53 }
@@ -56,38 +56,38 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -56,38 +56,38 @@ public class ShipmentHeaderHistoryController extends BaseController
56 * 查询出库单主列表 56 * 查询出库单主列表
57 */ 57 */
58 @RequiresPermissions("shipment:bill:list") 58 @RequiresPermissions("shipment:bill:list")
59 - @Log(title = "出库-出库单", operating="查看出库主单", action = BusinessType.GRANT) 59 + @Log(title = "出库-出库单历史", operating="查看历史出库主单", action = BusinessType.GRANT)
60 @PostMapping("/list") 60 @PostMapping("/list")
61 @ResponseBody 61 @ResponseBody
62 - public TableDataInfo list(ShipmentHeader shipmentHeader,String createdBegin, String createdEnd) 62 + public TableDataInfo list(ShipmentHeaderHistory shipmentHeaderHistory, String createdBegin, String createdEnd)
63 { 63 {
64 - LambdaQueryWrapper<ShipmentHeader> lambdaQueryWrapper = Wrappers.lambdaQuery(); 64 + LambdaQueryWrapper<ShipmentHeaderHistory> lambdaQueryWrapper = Wrappers.lambdaQuery();
65 PageDomain pageDomain = TableSupport.buildPageRequest(); 65 PageDomain pageDomain = TableSupport.buildPageRequest();
66 Integer pageNum = pageDomain.getPageNum(); 66 Integer pageNum = pageDomain.getPageNum();
67 Integer pageSize = pageDomain.getPageSize(); 67 Integer pageSize = pageDomain.getPageSize();
68 68
69 - lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin),ShipmentHeader::getCreated, createdBegin)  
70 - .le(StringUtils.isNotEmpty(createdEnd), ShipmentHeader::getCreated, createdEnd)  
71 - .eq(ShipmentHeader::getWarehouseCode,ShiroUtils.getWarehouseCode())  
72 - .eq(ShipmentHeader::getDeleted,true)  
73 - .in(ShipmentHeader::getCompanyCode,ShiroUtils.getCompanyCodeList())  
74 - .eq(StringUtils.isNotEmpty(shipmentHeader.getCode()),ShipmentHeader::getCode,shipmentHeader.getCode())  
75 - .eq(StringUtils.isNotEmpty(shipmentHeader.getShipmentType()),ShipmentHeader::getShipmentType,shipmentHeader.getShipmentType())  
76 - .eq(StringUtils.isNotEmpty(shipmentHeader.getReferCode()), ShipmentHeader::getReferCode, shipmentHeader.getReferCode())  
77 - .eq(StringUtils.isNotEmpty(shipmentHeader.getReferCodeType()), ShipmentHeader::getReferCodeType, shipmentHeader.getReferCodeType())  
78 - .eq(shipmentHeader.getFirstStatus()!=null, ShipmentHeader::getFirstStatus, shipmentHeader.getFirstStatus())  
79 - .eq(shipmentHeader.getLastStatus()!=null, ShipmentHeader::getLastStatus, shipmentHeader.getLastStatus())  
80 - .orderByDesc(ShipmentHeader::getId); 69 + lambdaQueryWrapper.ge(StringUtils.isNotEmpty(createdBegin),ShipmentHeaderHistory::getCreated, createdBegin)
  70 + .le(StringUtils.isNotEmpty(createdEnd), ShipmentHeaderHistory::getCreated, createdEnd)
  71 + .eq(ShipmentHeaderHistory::getWarehouseCode,ShiroUtils.getWarehouseCode())
  72 + .eq(ShipmentHeaderHistory::getDeleted,false)
  73 + .in(ShipmentHeaderHistory::getCompanyCode,ShiroUtils.getCompanyCodeList())
  74 + .eq(StringUtils.isNotEmpty(shipmentHeaderHistory.getCode()),ShipmentHeaderHistory::getCode,shipmentHeaderHistory.getCode())
  75 + .eq(StringUtils.isNotEmpty(shipmentHeaderHistory.getShipmentType()),ShipmentHeaderHistory::getShipmentType,shipmentHeaderHistory.getShipmentType())
  76 + .eq(StringUtils.isNotEmpty(shipmentHeaderHistory.getReferCode()), ShipmentHeaderHistory::getReferCode, shipmentHeaderHistory.getReferCode())
  77 + .eq(StringUtils.isNotEmpty(shipmentHeaderHistory.getReferCodeType()), ShipmentHeaderHistory::getReferCodeType, shipmentHeaderHistory.getReferCodeType())
  78 + .eq(shipmentHeaderHistory.getFirstStatus()!=null, ShipmentHeaderHistory::getFirstStatus, shipmentHeaderHistory.getFirstStatus())
  79 + .eq(shipmentHeaderHistory.getLastStatus()!=null, ShipmentHeaderHistory::getLastStatus, shipmentHeaderHistory.getLastStatus())
  80 + .orderByDesc(ShipmentHeaderHistory::getId);
81 81
82 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){ 82 if (StringUtils.isNotNull(pageNum) && StringUtils.isNotNull(pageSize)){
83 /** 83 /**
84 * 使用分页查询 84 * 使用分页查询
85 */ 85 */
86 - Page<ShipmentHeader> page = new Page<>(pageNum, pageSize);  
87 - IPage<ShipmentHeader> iPage = shipmentHeaderService.page(page, lambdaQueryWrapper); 86 + Page<ShipmentHeaderHistory> page = new Page<>(pageNum, pageSize);
  87 + IPage<ShipmentHeaderHistory> iPage = shipmentHeaderHistoryService.page(page, lambdaQueryWrapper);
88 return getMpDataTable(iPage.getRecords(),iPage.getTotal()); 88 return getMpDataTable(iPage.getRecords(),iPage.getTotal());
89 } else { 89 } else {
90 - List<ShipmentHeader> list = shipmentHeaderService.list(lambdaQueryWrapper); 90 + List<ShipmentHeaderHistory> list = shipmentHeaderHistoryService.list(lambdaQueryWrapper);
91 return getDataTable(list); 91 return getDataTable(list);
92 } 92 }
93 } 93 }
@@ -97,7 +97,7 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -97,7 +97,7 @@ public class ShipmentHeaderHistoryController extends BaseController
97 * 删除出库单主 97 * 删除出库单主
98 */ 98 */
99 @RequiresPermissions("shipment:bill:remove") 99 @RequiresPermissions("shipment:bill:remove")
100 - @Log(title = "出库-出库单", operating="删除出库主单", action = BusinessType.DELETE) 100 + @Log(title = "出库-历史出库单", operating="删除历史出库主单", action = BusinessType.DELETE)
101 @PostMapping( "/remove") 101 @PostMapping( "/remove")
102 @ResponseBody 102 @ResponseBody
103 public AjaxResult remove(String ids) { 103 public AjaxResult remove(String ids) {
@@ -105,12 +105,12 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -105,12 +105,12 @@ public class ShipmentHeaderHistoryController extends BaseController
105 return AjaxResult.error("id不能为空"); 105 return AjaxResult.error("id不能为空");
106 for (Integer id : Convert.toIntArray(ids)) 106 for (Integer id : Convert.toIntArray(ids))
107 { 107 {
108 - boolean result=shipmentHeaderService.removeById(id);  
109 - LambdaQueryWrapper<ShipmentDetail> lambdaQueryWrapper=Wrappers.lambdaQuery();  
110 - lambdaQueryWrapper.eq(ShipmentDetail::getShipmentId,id)  
111 - .eq(ShipmentDetail::getWarehouseCode,ShiroUtils.getWarehouseCode()); 108 + boolean result=shipmentHeaderHistoryService.removeById(id);
  109 + LambdaQueryWrapper<ShipmentDetailHistory> lambdaQueryWrapper=Wrappers.lambdaQuery();
  110 + lambdaQueryWrapper.eq(ShipmentDetailHistory::getShipmentId,id)
  111 + .eq(ShipmentDetailHistory::getWarehouseCode,ShiroUtils.getWarehouseCode());
112 Boolean flag=true; 112 Boolean flag=true;
113 - flag=shipmentDetailService.remove(lambdaQueryWrapper); 113 + flag=shipmentDetailHistoryService.remove(lambdaQueryWrapper);
114 if(flag==false){ 114 if(flag==false){
115 return AjaxResult.error("删除失败"); 115 return AjaxResult.error("删除失败");
116 } 116 }
@@ -126,17 +126,17 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -126,17 +126,17 @@ public class ShipmentHeaderHistoryController extends BaseController
126 * @return 126 * @return
127 */ 127 */
128 @RequiresPermissions("shipment:bill:report") 128 @RequiresPermissions("shipment:bill:report")
129 - @Log(title = "出库-出库单", operating="打印出库单报表", action = BusinessType.OTHER) 129 + @Log(title = "出库-历史出库单", operating="打印历史出库单报表", action = BusinessType.OTHER)
130 @GetMapping("/report/{id}") 130 @GetMapping("/report/{id}")
131 public String report(@PathVariable("id") Integer id, ModelMap mmap) 131 public String report(@PathVariable("id") Integer id, ModelMap mmap)
132 { 132 {
133 - ShipmentHeader shipmentHeader = shipmentHeaderService.getById(id);  
134 - mmap.put("shipmentHeader", shipmentHeader); 133 + ShipmentHeaderHistory shipmentHeaderHistory = shipmentHeaderHistoryService.getById(id);
  134 + mmap.put("shipmentHeader", shipmentHeaderHistory);
135 135
136 - LambdaQueryWrapper<ShipmentDetail> lambdaQueryWrapper = Wrappers.lambdaQuery();  
137 - lambdaQueryWrapper.eq(ShipmentDetail::getShipmentId,id)  
138 - .eq(ShipmentDetail::getWarehouseCode,ShiroUtils.getWarehouseCode());  
139 - List<ShipmentDetail> details = shipmentDetailService.list(lambdaQueryWrapper); 136 + LambdaQueryWrapper<ShipmentDetailHistory> lambdaQueryWrapper = Wrappers.lambdaQuery();
  137 + lambdaQueryWrapper.eq(ShipmentDetailHistory::getShipmentId,id)
  138 + .eq(ShipmentDetailHistory::getWarehouseCode,ShiroUtils.getWarehouseCode());
  139 + List<ShipmentDetailHistory> details = shipmentDetailHistoryService.list(lambdaQueryWrapper);
140 mmap.put("details", details); 140 mmap.put("details", details);
141 141
142 return prefix + "/report"; 142 return prefix + "/report";
@@ -144,8 +144,8 @@ public class ShipmentHeaderHistoryController extends BaseController @@ -144,8 +144,8 @@ public class ShipmentHeaderHistoryController extends BaseController
144 144
145 @PostMapping("/getShipmentHeader") 145 @PostMapping("/getShipmentHeader")
146 @ResponseBody 146 @ResponseBody
147 - public AjaxResult<ShipmentHeader> getShipmentHeader(int id){  
148 - return AjaxResult.success(shipmentHeaderService.getById(id)); 147 + public AjaxResult<ShipmentHeaderHistory> getShipmentHeader(int id){
  148 + return AjaxResult.success(shipmentHeaderHistoryService.getById(id));
149 } 149 }
150 150
151 151
src/main/java/com/huaheng/pc/shipment/shipmentHeaderHistory/domain/ShipmentHeaderHistory.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentHeaderHistory.domain;
  2 +
  3 +import com.baomidou.mybatisplus.annotation.IdType;
  4 +import com.baomidou.mybatisplus.annotation.TableField;
  5 +import com.baomidou.mybatisplus.annotation.TableId;
  6 +import com.baomidou.mybatisplus.annotation.TableName;
  7 +import io.swagger.annotations.ApiModel;
  8 +import io.swagger.annotations.ApiModelProperty;
  9 +import lombok.Data;
  10 +
  11 +import java.io.Serializable;
  12 +import java.math.BigDecimal;
  13 +import java.util.Date;
  14 +
  15 +@ApiModel(value = "com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory")
  16 +@Data
  17 +@TableName(value = "shipment_header_history")
  18 +public class ShipmentHeaderHistory implements Serializable {
  19 + /**
  20 + * 出库单内部号
  21 + */
  22 + @TableId(value = "id", type = IdType.AUTO)
  23 + @ApiModelProperty(value = "出库单内部号")
  24 + private Integer id;
  25 +
  26 + /**
  27 + * 仓库
  28 + */
  29 + @TableField(value = "warehouseCode")
  30 + @ApiModelProperty(value = "仓库")
  31 + private String warehouseCode;
  32 +
  33 + /**
  34 + * 货主
  35 + */
  36 + @TableField(value = "companyCode")
  37 + @ApiModelProperty(value = "货主")
  38 + private String companyCode;
  39 +
  40 +
  41 +
  42 + /**
  43 + * 出库单号
  44 + */
  45 + @TableField(value = "code")
  46 + @ApiModelProperty(value = "出库单号")
  47 + private String code;
  48 +
  49 + /**
  50 + * erp订单号
  51 + */
  52 + @TableField(value = "referCode")
  53 + @ApiModelProperty(value = "erp订单号")
  54 + private String referCode;
  55 +
  56 + /**
  57 + * erp订单类型
  58 + */
  59 + @TableField(value = "referCodeType")
  60 + @ApiModelProperty(value = "erp订单类型")
  61 + private String referCodeType;
  62 +
  63 + /**
  64 + * erp订单内部号
  65 + */
  66 + @TableField(value = "referId")
  67 + @ApiModelProperty(value = "erp订单内部号")
  68 + private Integer referId;
  69 +
  70 + /**
  71 + * 订单平台
  72 + */
  73 + @TableField(value = "referPlatform")
  74 + @ApiModelProperty(value = "订单平台")
  75 + private Integer referPlatform;
  76 +
  77 + /**
  78 + * 主状态
  79 + */
  80 + @TableField(value = "firstStatus")
  81 + @ApiModelProperty(value = "主状态")
  82 + private Integer firstStatus;
  83 +
  84 + /**
  85 + * 拖状态
  86 + */
  87 + @TableField(value = "lastStatus")
  88 + @ApiModelProperty(value = "拖状态")
  89 + private Integer lastStatus;
  90 +
  91 + /**
  92 + * 出库单类型
  93 + */
  94 + @TableField(value = "shipmentType")
  95 + @ApiModelProperty(value = "出库单类型")
  96 + private String shipmentType;
  97 +
  98 + /**
  99 + * 路线
  100 + */
  101 + @TableField(value = "route")
  102 + @ApiModelProperty(value = "路线")
  103 + private String route;
  104 +
  105 + /**
  106 + * 客户编号
  107 + */
  108 + @TableField(value = "customerCode")
  109 + @ApiModelProperty(value = "客户编号")
  110 + private String customerCode;
  111 +
  112 + /**
  113 + * 客户名称
  114 + */
  115 + @TableField(value = "customerName")
  116 + @ApiModelProperty(value = "客户名称")
  117 + private String customerName;
  118 +
  119 + /**
  120 + * 优先级
  121 + */
  122 + @TableField(value = "priority")
  123 + @ApiModelProperty(value = "优先级")
  124 + private Integer priority;
  125 +
  126 + /**
  127 + * 要求到货时间
  128 + */
  129 + @TableField(value = "requestedDeliveryDate")
  130 + @ApiModelProperty(value = "要求到货时间")
  131 + private Date requestedDeliveryDate;
  132 +
  133 +
  134 +
  135 + /**
  136 + * 计划发车日期
  137 + */
  138 + @TableField(value = "scheduledShipDate")
  139 + @ApiModelProperty(value = "计划发车日期")
  140 + private Date scheduledShipDate;
  141 +
  142 + /**
  143 + * 实际发车时间
  144 + */
  145 + @TableField(value = "actualShipDateTime")
  146 + @ApiModelProperty(value = "实际发车时间")
  147 + private Date actualShipDateTime;
  148 +
  149 + /**
  150 + * 实际到货时间
  151 + */
  152 + @TableField(value = "actualDeliveryDate")
  153 + @ApiModelProperty(value = "实际到货时间")
  154 + private Date actualDeliveryDate;
  155 +
  156 + /**
  157 + * 配送要求
  158 + */
  159 + @TableField(value = "deliveryNote")
  160 + @ApiModelProperty(value = "配送要求")
  161 + private String deliveryNote;
  162 +
  163 + /**
  164 + * 失败原因
  165 + */
  166 + @TableField(value = "rejectionNote")
  167 + @ApiModelProperty(value = "失败原因")
  168 + private String rejectionNote;
  169 +
  170 + /**
  171 + * 波次号
  172 + */
  173 + @TableField(value = "waveId")
  174 + @ApiModelProperty(value = "波次号")
  175 + private Integer waveId;
  176 +
  177 + /**
  178 + * 发货月台
  179 + */
  180 + @TableField(value = "shipDock")
  181 + @ApiModelProperty(value = "发货月台")
  182 + private String shipDock;
  183 +
  184 + /**
  185 + * 分配完成
  186 + */
  187 + @TableField(value = "allocateComplete")
  188 + @ApiModelProperty(value = "分配完成")
  189 + private Integer allocateComplete;
  190 +
  191 + /**
  192 + * 总重量
  193 + */
  194 + @TableField(value = "totalWeight")
  195 + @ApiModelProperty(value = "总重量")
  196 + private BigDecimal totalWeight;
  197 +
  198 + /**
  199 + * 总数量
  200 + */
  201 + @TableField(value = "totalQty")
  202 + @ApiModelProperty(value = "总数量")
  203 + private BigDecimal totalQty;
  204 +
  205 + /**
  206 + * 总体积
  207 + */
  208 + @TableField(value = "totalVolume")
  209 + @ApiModelProperty(value = "总体积")
  210 + private BigDecimal totalVolume;
  211 +
  212 + /**
  213 + * 总行数
  214 + */
  215 + @TableField(value = "totalLines")
  216 + @ApiModelProperty(value = "总行数")
  217 + private Integer totalLines;
  218 +
  219 +
  220 +
  221 + /**
  222 + * 处理类型
  223 + */
  224 + @TableField(value = "processType")
  225 + @ApiModelProperty(value = "处理类型")
  226 + private String processType;
  227 +
  228 + /**
  229 + * 上次波次号
  230 + */
  231 + @TableField(value = "lastWaveId")
  232 + @ApiModelProperty(value = "上次波次号")
  233 + private Integer lastWaveId;
  234 +
  235 + /**
  236 + * 特征值
  237 + */
  238 + @TableField(value = "signValue")
  239 + @ApiModelProperty(value = "特征值")
  240 + private String signValue;
  241 +
  242 + /**
  243 + * 承运人
  244 + */
  245 + @TableField(value = "carrierCode")
  246 + @ApiModelProperty(value = "承运人")
  247 + private String carrierCode;
  248 +
  249 + /**
  250 + * 承运人服务商
  251 + */
  252 + @TableField(value = "carrierService")
  253 + @ApiModelProperty(value = "承运人服务商")
  254 + private String carrierService;
  255 +
  256 + /**
  257 + * 订单备注
  258 + */
  259 + @TableField(value = "shipmentNote")
  260 + @ApiModelProperty(value = "订单备注")
  261 + private String shipmentNote;
  262 +
  263 + /**
  264 + * 承运商编码
  265 + */
  266 + @TableField(value = "carrierServer")
  267 + @ApiModelProperty(value = "承运商编码")
  268 + private String carrierServer;
  269 +
  270 + /**
  271 + * 承运商名称
  272 + */
  273 + @TableField(value = "carrierServerName")
  274 + @ApiModelProperty(value = "承运商名称")
  275 + private String carrierServerName;
  276 +
  277 + /**
  278 + * 车牌号
  279 + */
  280 + @TableField(value = "plateNumber")
  281 + @ApiModelProperty(value = "车牌号")
  282 + private String plateNumber;
  283 +
  284 + /**
  285 + * 车型
  286 + */
  287 + @TableField(value = "carModel")
  288 + @ApiModelProperty(value = "车型")
  289 + private String carModel;
  290 +
  291 + /**
  292 + * 司机名称
  293 + */
  294 + @TableField(value = "driverName")
  295 + @ApiModelProperty(value = "司机名称")
  296 + private String driverName;
  297 +
  298 + /**
  299 + * 司机联系方式
  300 + */
  301 + @TableField(value = "driverTel")
  302 + @ApiModelProperty(value = "司机联系方式")
  303 + private String driverTel;
  304 +
  305 + /**
  306 + * 创建时间
  307 + */
  308 + @TableField(value = "created")
  309 + @ApiModelProperty(value = "创建时间")
  310 + private Date created;
  311 +
  312 + /**
  313 + * 创建用户
  314 + */
  315 + @TableField(value = "createdBy")
  316 + @ApiModelProperty(value = "创建用户")
  317 + private String createdBy;
  318 +
  319 + /**
  320 + * 创建时间
  321 + */
  322 + @TableField(value = "lastUpdated")
  323 + @ApiModelProperty(value = "创建时间")
  324 + private Date lastUpdated;
  325 +
  326 + /**
  327 + * 更新用户
  328 + */
  329 + @TableField(value = "lastUpdatedBy")
  330 + @ApiModelProperty(value = "更新用户")
  331 + private String lastUpdatedBy;
  332 +
  333 + /**
  334 + * 数据版本
  335 + */
  336 + @TableField(value = "version")
  337 + @ApiModelProperty(value = "数据版本")
  338 + private Integer version;
  339 +
  340 + /**
  341 + * 自定义字段1
  342 + */
  343 + @TableField(value = "userDef1")
  344 + @ApiModelProperty(value = "自定义字段1")
  345 + private String userDef1;
  346 +
  347 + /**
  348 + * 自定义字段2
  349 + */
  350 + @TableField(value = "userDef2")
  351 + @ApiModelProperty(value = "自定义字段2")
  352 + private String userDef2;
  353 +
  354 + /**
  355 + * 自定义字段3
  356 + */
  357 + @TableField(value = "userDef3")
  358 + @ApiModelProperty(value = "自定义字段3")
  359 + private String userDef3;
  360 + /**
  361 + * 处理标记
  362 + */
  363 + @TableField(value = "processStamp")
  364 + @ApiModelProperty(value = "处理标记")
  365 + private String processStamp;
  366 +
  367 + /**
  368 + * 是否删除
  369 + */
  370 + @TableField(value = "deleted")
  371 + @ApiModelProperty(value = "是否删除")
  372 + private Boolean deleted;
  373 +
  374 + private static final long serialVersionUID = 1L;
  375 +
  376 + public static final String COL_WAREHOUSECODE = "warehouseCode";
  377 +
  378 + public static final String COL_COMPANYCODE = "companyCode";
  379 +
  380 + public static final String COL_CODE = "code";
  381 +
  382 + public static final String COL_REFERCODE = "referCode";
  383 +
  384 + public static final String COL_REFERCODETYPE = "referCodeType";
  385 +
  386 + public static final String COL_REFERID = "referId";
  387 +
  388 + public static final String COL_REFERPLATFORM = "referPlatform";
  389 +
  390 + public static final String COL_FIRSTSTATUS = "firstStatus";
  391 +
  392 + public static final String COL_LASTSTATUS = "lastStatus";
  393 +
  394 + public static final String COL_SHIPMENTTYPE = "shipmentType";
  395 +
  396 + public static final String COL_ROUTE = "route";
  397 +
  398 + public static final String COL_CUSTOMERCODE = "customerCode";
  399 +
  400 + public static final String COL_CUSTOMERNAME = "customerName";
  401 +
  402 + public static final String COL_PRIORITY = "priority";
  403 +
  404 + public static final String COL_REQUESTEDDELIVERYDATE = "requestedDeliveryDate";
  405 +
  406 + public static final String COL_SCHEDULEDSHIPDATE = "scheduledShipDate";
  407 +
  408 + public static final String COL_ACTUALSHIPDATETIME = "actualShipDateTime";
  409 +
  410 + public static final String COL_ACTUALDELIVERYDATE = "actualDeliveryDate";
  411 +
  412 + public static final String COL_DELIVERYNOTE = "deliveryNote";
  413 +
  414 + public static final String COL_REJECTIONNOTE = "rejectionNote";
  415 +
  416 + public static final String COL_WAVEID = "waveId";
  417 +
  418 + public static final String COL_SHIPDOCK = "shipDock";
  419 +
  420 + public static final String COL_ALLOCATECOMPLETE = "allocateComplete";
  421 +
  422 + public static final String COL_TOTALWEIGHT = "totalWeight";
  423 +
  424 + public static final String COL_TOTALQTY = "totalQty";
  425 +
  426 + public static final String COL_TOTALVOLUME = "totalVolume";
  427 +
  428 + public static final String COL_TOTALLINES = "totalLines";
  429 +
  430 + public static final String COL_PROCESSTYPE = "processType";
  431 +
  432 + public static final String COL_LASTWAVEID = "lastWaveId";
  433 +
  434 + public static final String COL_SIGNVALUE = "signValue";
  435 +
  436 + public static final String COL_CARRIERCODE = "carrierCode";
  437 +
  438 + public static final String COL_CARRIERSERVICE = "carrierService";
  439 +
  440 + public static final String COL_SHIPMENTNOTE = "shipmentNote";
  441 +
  442 + public static final String COL_CARRIERSERVER = "carrierServer";
  443 +
  444 + public static final String COL_CARRIERSERVERNAME = "carrierServerName";
  445 +
  446 + public static final String COL_PLATENUMBER = "plateNumber";
  447 +
  448 + public static final String COL_CARMODEL = "carModel";
  449 +
  450 + public static final String COL_DRIVERNAME = "driverName";
  451 +
  452 + public static final String COL_DRIVERTEL = "driverTel";
  453 +
  454 + public static final String COL_CREATED = "created";
  455 +
  456 + public static final String COL_CREATEDBY = "createdBy";
  457 +
  458 + public static final String COL_LASTUPDATED = "lastUpdated";
  459 +
  460 + public static final String COL_LASTUPDATEDBY = "lastUpdatedBy";
  461 +
  462 + public static final String COL_VERSION = "version";
  463 +
  464 + public static final String COL_USERDEF1 = "userDef1";
  465 +
  466 + public static final String COL_USERDEF2 = "userDef2";
  467 +
  468 + public static final String COL_USERDEF3 = "userDef3";
  469 +
  470 + public static final String COL_PROCESSSTAMP = "processStamp";
  471 +
  472 + public static final String COL_DELETED = "deleted";
  473 +}
0 \ No newline at end of file 474 \ No newline at end of file
src/main/java/com/huaheng/pc/shipment/shipmentHeaderHistory/mapper/ShipmentHeaderHistoryMapper.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentHeaderHistory.mapper;
  2 +
  3 +import com.baomidou.mybatisplus.core.mapper.BaseMapper;
  4 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  5 +
  6 +public interface ShipmentHeaderHistoryMapper extends BaseMapper<ShipmentHeaderHistory> {
  7 +
  8 +
  9 +
  10 +}
0 \ No newline at end of file 11 \ No newline at end of file
src/main/java/com/huaheng/pc/shipment/shipmentHeaderHistory/service/ShipmentHeaderHistoryService.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentHeaderHistory.service;
  2 +
  3 +import com.baomidou.mybatisplus.extension.service.IService;
  4 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  5 +
  6 +public interface ShipmentHeaderHistoryService extends IService<ShipmentHeaderHistory>{
  7 +
  8 +
  9 +}
src/main/java/com/huaheng/pc/shipment/shipmentHeaderHistory/service/ShipmentHeaderHistoryServiceImpl.java 0 → 100644
  1 +package com.huaheng.pc.shipment.shipmentHeaderHistory.service;
  2 +
  3 +
  4 +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
  5 +import com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory;
  6 +import com.huaheng.pc.shipment.shipmentHeaderHistory.mapper.ShipmentHeaderHistoryMapper;
  7 +import org.springframework.stereotype.Service;
  8 +
  9 +
  10 +@Service
  11 +public class ShipmentHeaderHistoryServiceImpl extends ServiceImpl<ShipmentHeaderHistoryMapper, ShipmentHeaderHistory> implements ShipmentHeaderHistoryService {
  12 +
  13 +}
src/main/resources/mybatis/config/MaterialTypeMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.config.materialType.mapper.MaterialTypeMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.config.materialType.domain.MaterialType">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="code" jdbcType="VARCHAR" property="code" />
  8 + <result column="name" jdbcType="VARCHAR" property="name" />
  9 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  10 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  11 + <result column="abcClass" jdbcType="VARCHAR" property="abcClass" />
  12 + <result column="daysToExpire" jdbcType="INTEGER" property="daysToExpire" />
  13 + <result column="receivingFlow" jdbcType="VARCHAR" property="receivingFlow" />
  14 + <result column="shippingFlow" jdbcType="VARCHAR" property="shippingFlow" />
  15 + <result column="locatingRule" jdbcType="VARCHAR" property="locatingRule" />
  16 + <result column="allocationRule" jdbcType="VARCHAR" property="allocationRule" />
  17 + <result column="replenishmentRule" jdbcType="VARCHAR" property="replenishmentRule" />
  18 + <result column="emptyLocRule" jdbcType="VARCHAR" property="emptyLocRule" />
  19 + <result column="pickingRule" jdbcType="VARCHAR" property="pickingRule" />
  20 + <result column="attributeTemplateCode" jdbcType="VARCHAR" property="attributeTemplateCode" />
  21 + <result column="trackSerialNum" jdbcType="INTEGER" property="trackSerialNum" />
  22 + <result column="autoGenSerialNum" jdbcType="INTEGER" property="autoGenSerialNum" />
  23 + <result column="autoGenSerialNumFormat" jdbcType="VARCHAR" property="autoGenSerialNumFormat" />
  24 + <result column="snTemplateCode" jdbcType="VARCHAR" property="snTemplateCode" />
  25 + <result column="expiringDays" jdbcType="INTEGER" property="expiringDays" />
  26 + <result column="minShelfLifeDays" jdbcType="INTEGER" property="minShelfLifeDays" />
  27 + <result column="enable" jdbcType="INTEGER" property="enable" />
  28 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  29 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  30 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  31 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  32 + <result column="version" jdbcType="INTEGER" property="version" />
  33 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  34 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  35 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  36 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  37 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  38 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  39 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  40 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  41 + </resultMap>
  42 + <sql id="Base_Column_List">
  43 + <!--@mbg.generated-->
  44 + id, code, `name`, companyCode, warehouseCode, abcClass, daysToExpire, receivingFlow,
  45 + shippingFlow, locatingRule, allocationRule, replenishmentRule, emptyLocRule, pickingRule,
  46 + attributeTemplateCode, trackSerialNum, autoGenSerialNum, autoGenSerialNumFormat,
  47 + snTemplateCode, expiringDays, minShelfLifeDays, `enable`, created, createdBy, lastUpdated,
  48 + lastUpdatedBy, version, userDef1, userDef2, userDef3, userDef4, userDef5, userDef6,
  49 + userDef7, userDef8
  50 + </sql>
  51 +</mapper>
0 \ No newline at end of file 52 \ No newline at end of file
src/main/resources/mybatis/inventory/AdjustDetailMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.inventory.adjustDetail.mapper.AdjustDetailMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.inventory.adjustDetail.domain.AdjustDetail">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="adjustCode" jdbcType="VARCHAR" property="adjustCode" />
  8 + <result column="cycleCountCode" jdbcType="VARCHAR" property="cycleCountCode" />
  9 + <result column="cycleDetailId" jdbcType="INTEGER" property="cycleDetailId" />
  10 + <result column="checkCode" jdbcType="VARCHAR" property="checkCode" />
  11 + <result column="checkDetailId" jdbcType="VARCHAR" property="checkDetailId" />
  12 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  13 + <result column="referDetailId" jdbcType="INTEGER" property="referDetailId" />
  14 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  15 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  16 + <result column="materialCode" jdbcType="VARCHAR" property="materialCode" />
  17 + <result column="materialName" jdbcType="VARCHAR" property="materialName" />
  18 + <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" />
  19 + <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" />
  20 + <result column="problemType" jdbcType="VARCHAR" property="problemType" />
  21 + <result column="attributeId" jdbcType="INTEGER" property="attributeId" />
  22 + <result column="fromInventorySts" jdbcType="VARCHAR" property="fromInventorySts" />
  23 + <result column="toInventorySts" jdbcType="VARCHAR" property="toInventorySts" />
  24 + <result column="fromQty" jdbcType="INTEGER" property="fromQty" />
  25 + <result column="toQty" jdbcType="INTEGER" property="toQty" />
  26 + <result column="gapQty" jdbcType="INTEGER" property="gapQty" />
  27 + <result column="status" jdbcType="INTEGER" property="status" />
  28 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  29 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  30 + <result column="agreeBy" jdbcType="VARCHAR" property="agreeBy" />
  31 + <result column="agreeTime" jdbcType="TIMESTAMP" property="agreeTime" />
  32 + <result column="Remark" jdbcType="VARCHAR" property="remark" />
  33 + <result column="version" jdbcType="INTEGER" property="version" />
  34 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  35 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  36 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  37 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  38 + </resultMap>
  39 + <sql id="Base_Column_List">
  40 + <!--@mbg.generated-->
  41 + id, adjustCode, cycleCountCode, cycleDetailId, checkCode, checkDetailId, referCode,
  42 + referDetailId, warehouseCode, companyCode, materialCode, materialName,
  43 + materialSpec, materialUnit, problemType, attributeId, fromInventorySts, toInventorySts,
  44 + fromQty, toQty, gapQty, `status`, created, createdBy, agreeTime, Remark,
  45 + version, userDef1, userDef2, userDef3, processStamp
  46 + </sql>
  47 +</mapper>
0 \ No newline at end of file 48 \ No newline at end of file
src/main/resources/mybatis/inventory/AdjustHeaderMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.inventory.adjustHeader.mapper.AdjustHeaderMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.inventory.adjustHeader.domain.AdjustHeader">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="code" jdbcType="VARCHAR" property="code" />
  8 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  9 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  10 + <result column="problemType" jdbcType="VARCHAR" property="problemType" />
  11 + <result column="cycleCountCode" jdbcType="VARCHAR" property="cycleCountCode" />
  12 + <result column="checkCode" jdbcType="VARCHAR" property="checkCode" />
  13 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  14 + <result column="referReason" jdbcType="VARCHAR" property="referReason" />
  15 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  16 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  17 + <result column="version" jdbcType="INTEGER" property="version" />
  18 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  19 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  20 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  21 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  22 + </resultMap>
  23 + <sql id="Base_Column_List">
  24 + <!--@mbg.generated-->
  25 + id, code, warehouseCode, companyCode, problemType, cycleCountCode, checkCode,
  26 + referCode, referReason, createdBy, created, version, userDef1, userDef2, userDef3, processStamp
  27 + </sql>
  28 +</mapper>
0 \ No newline at end of file 29 \ No newline at end of file
src/main/resources/mybatis/inventory/CycleCountDetailMapper.xml
@@ -20,7 +20,7 @@ @@ -20,7 +20,7 @@
20 <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" /> 20 <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" />
21 <result column="systemQty" jdbcType="DECIMAL" property="systemQty" /> 21 <result column="systemQty" jdbcType="DECIMAL" property="systemQty" />
22 <result column="countedQty" jdbcType="DECIMAL" property="countedQty" /> 22 <result column="countedQty" jdbcType="DECIMAL" property="countedQty" />
23 - <result column="adjustQty" jdbcType="DECIMAL" property="adjustQty" /> 23 + <result column="gapQty" jdbcType="DECIMAL" property="gapQty" />
24 <result column="rejectionNote" jdbcType="VARCHAR" property="rejectionNote" /> 24 <result column="rejectionNote" jdbcType="VARCHAR" property="rejectionNote" />
25 <result column="countedBy" jdbcType="VARCHAR" property="countedBy" /> 25 <result column="countedBy" jdbcType="VARCHAR" property="countedBy" />
26 <result column="countedAt" jdbcType="TIMESTAMP" property="countedAt" /> 26 <result column="countedAt" jdbcType="TIMESTAMP" property="countedAt" />
@@ -46,7 +46,7 @@ @@ -46,7 +46,7 @@
46 <!--@mbg.generated--> 46 <!--@mbg.generated-->
47 id, countId, round, taskHeaderId, taskDetailId, warehouseCode, inventoryDetailId, 47 id, countId, round, taskHeaderId, taskDetailId, warehouseCode, inventoryDetailId,
48 locationCode, containerCode, materialCode, materialName, materialSpec, materialUnit, 48 locationCode, containerCode, materialCode, materialName, materialSpec, materialUnit,
49 - companyCode, inventorySts, systemQty, countedQty, adjustQty, rejectionNote, countedBy, 49 + companyCode, inventorySts, systemQty, countedQty, gapQty, rejectionNote, countedBy,
50 countedAt, assignedTo, assignedAt, completedBy, completedAt, enableStatus, created, 50 countedAt, assignedTo, assignedAt, completedBy, completedAt, enableStatus, created,
51 createdBy, lastUpdated, lastUpdatedBy, version, userDef1, userDef2, userDef3, processStamp, 51 createdBy, lastUpdated, lastUpdatedBy, version, userDef1, userDef2, userDef3, processStamp,
52 batch, lot, projectNo 52 batch, lot, projectNo
src/main/resources/mybatis/inventory/InventoryTransactionMapper.xml
@@ -13,10 +13,10 @@ @@ -13,10 +13,10 @@
13 <result column="materialName" jdbcType="VARCHAR" property="materialName" /> 13 <result column="materialName" jdbcType="VARCHAR" property="materialName" />
14 <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" /> 14 <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" />
15 <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" /> 15 <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" />
16 - <result column="qty" jdbcType="INTEGER" property="qty" /> 16 + <result column="taskQty" jdbcType="INTEGER" property="taskQty" />
17 <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" /> 17 <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" />
18 <result column="referCode" jdbcType="VARCHAR" property="referCode" /> 18 <result column="referCode" jdbcType="VARCHAR" property="referCode" />
19 - <result column="referId" jdbcType="VARCHAR" property="referId" /> 19 + <result column="referDetailId" jdbcType="VARCHAR" property="referDetailId" />
20 <result column="referDetailId" jdbcType="VARCHAR" property="referDetailId" /> 20 <result column="referDetailId" jdbcType="VARCHAR" property="referDetailId" />
21 <result column="batch" jdbcType="VARCHAR" property="batch" /> 21 <result column="batch" jdbcType="VARCHAR" property="batch" />
22 <result column="lot" jdbcType="VARCHAR" property="lot" /> 22 <result column="lot" jdbcType="VARCHAR" property="lot" />
@@ -30,31 +30,22 @@ @@ -30,31 +30,22 @@
30 <result column="attribute1" jdbcType="VARCHAR" property="attribute1" /> 30 <result column="attribute1" jdbcType="VARCHAR" property="attribute1" />
31 <result column="attribute2" jdbcType="VARCHAR" property="attribute2" /> 31 <result column="attribute2" jdbcType="VARCHAR" property="attribute2" />
32 <result column="attribute3" jdbcType="VARCHAR" property="attribute3" /> 32 <result column="attribute3" jdbcType="VARCHAR" property="attribute3" />
33 - <result column="attribute4" jdbcType="VARCHAR" property="attribute4" />  
34 <result column="lockCode" jdbcType="VARCHAR" property="lockCode" /> 33 <result column="lockCode" jdbcType="VARCHAR" property="lockCode" />
35 - <result column="lastCycleCountDate" jdbcType="TIMESTAMP" property="lastCycleCountDate" />  
36 <result column="created" jdbcType="TIMESTAMP" property="created" /> 34 <result column="created" jdbcType="TIMESTAMP" property="created" />
37 <result column="createdBy" jdbcType="VARCHAR" property="createdBy" /> 35 <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
38 - <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />  
39 - <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />  
40 <result column="version" jdbcType="INTEGER" property="version" /> 36 <result column="version" jdbcType="INTEGER" property="version" />
41 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" /> 37 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
42 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" /> 38 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
43 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" /> 39 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
44 - <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />  
45 - <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />  
46 - <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />  
47 - <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />  
48 - <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />  
49 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" /> 40 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
50 </resultMap> 41 </resultMap>
51 <sql id="Base_Column_List"> 42 <sql id="Base_Column_List">
52 <!--@mbg.generated--> 43 <!--@mbg.generated-->
53 id, warehouseCode, companyCode, locationCode, containerCode, transactionType, materialCode, 44 id, warehouseCode, companyCode, locationCode, containerCode, transactionType, materialCode,
54 - materialName, materialSpec, materialUnit, qty, inventorySts, referCode, referId, 45 + materialName, materialSpec, materialUnit, taskQty, inventorySts, referCode, referDetailId,
55 referDetailId, batch, lot, projectNo, qcCheck, weight, manufactureDate, expirationDate, 46 referDetailId, batch, lot, projectNo, qcCheck, weight, manufactureDate, expirationDate,
56 - agingDate, attributeId, attribute1, attribute2, attribute3, attribute4, lockCode,  
57 - lastCycleCountDate, created, createdBy, lastUpdated, lastUpdatedBy, version, userDef1,  
58 - userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8, processStamp 47 + agingDate, attributeId, attribute1, attribute2, attribute3, lockCode,
  48 + created, createdBy, version, userDef1,
  49 + userDef2, userDef3, processStamp
59 </sql> 50 </sql>
60 </mapper> 51 </mapper>
61 \ No newline at end of file 52 \ No newline at end of file
src/main/resources/mybatis/receipt/ReceiptDetailHistoryMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.receipt.receiptDetailHistory.mapper.ReceiptDetailHistoryMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.receipt.receiptDetailHistory.domain.ReceiptDetailHistory">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="receiptId" jdbcType="INTEGER" property="receiptId" />
  8 + <result column="receiptCode" jdbcType="VARCHAR" property="receiptCode" />
  9 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  10 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  11 + <result column="materialCode" jdbcType="VARCHAR" property="materialCode" />
  12 + <result column="materialName" jdbcType="VARCHAR" property="materialName" />
  13 + <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" />
  14 + <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" />
  15 + <result column="supplierCode" jdbcType="VARCHAR" property="supplierCode" />
  16 + <result column="batch" jdbcType="VARCHAR" property="batch" />
  17 + <result column="lot" jdbcType="VARCHAR" property="lot" />
  18 + <result column="qcCheck" jdbcType="VARCHAR" property="qcCheck" />
  19 + <result column="projectNo" jdbcType="VARCHAR" property="projectNo" />
  20 + <result column="manufactureDate" jdbcType="DATE" property="manufactureDate" />
  21 + <result column="expirationDate" jdbcType="DATE" property="expirationDate" />
  22 + <result column="agingDate" jdbcType="DATE" property="agingDate" />
  23 + <result column="attributeTemplateCode" jdbcType="VARCHAR" property="attributeTemplateCode" />
  24 + <result column="attribute1" jdbcType="VARCHAR" property="attribute1" />
  25 + <result column="attribute2" jdbcType="VARCHAR" property="attribute2" />
  26 + <result column="attribute3" jdbcType="VARCHAR" property="attribute3" />
  27 + <result column="attribute4" jdbcType="VARCHAR" property="attribute4" />
  28 + <result column="totalQty" jdbcType="INTEGER" property="totalQty" />
  29 + <result column="openQty" jdbcType="INTEGER" property="openQty" />
  30 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  31 + <result column="referId" jdbcType="INTEGER" property="referId" />
  32 + <result column="referLineNum" jdbcType="VARCHAR" property="referLineNum" />
  33 + <result column="locatingRule" jdbcType="VARCHAR" property="locatingRule" />
  34 + <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" />
  35 + <result column="itemListPrice" jdbcType="DECIMAL" property="itemListPrice" />
  36 + <result column="itemNetPrice" jdbcType="DECIMAL" property="itemNetPrice" />
  37 + <result column="isVirtualBom" jdbcType="INTEGER" property="isVirtualBom" />
  38 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  39 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  40 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  41 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  42 + <result column="version" jdbcType="INTEGER" property="version" />
  43 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  44 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  45 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  46 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  47 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  48 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  49 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  50 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  51 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  52 + <result column="deleted" jdbcType="BIT" property="deleted" />
  53 + </resultMap>
  54 + <sql id="Base_Column_List">
  55 + <!--@mbg.generated-->
  56 + id, receiptId, receiptCode, warehouseCode, companyCode, materialCode, materialName,
  57 + materialSpec, materialUnit, supplierCode, batch, lot, qcCheck, projectNo, manufactureDate,
  58 + expirationDate, agingDate, attributeTemplateCode, attribute1, attribute2, attribute3,
  59 + attribute4, totalQty, openQty, referCode, referId, referLineNum, locatingRule, inventorySts,
  60 + itemListPrice, itemNetPrice, isVirtualBom, created, createdBy, lastUpdated, lastUpdatedBy,
  61 + version, userDef1, userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8,
  62 + processStamp, deleted
  63 + </sql>
  64 +</mapper>
0 \ No newline at end of file 65 \ No newline at end of file
src/main/resources/mybatis/receipt/ReceiptHeaderHistoryMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.receipt.receiptHeaderHistory.mapper.ReceiptHeaderHistoryMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.receipt.receiptHeaderHistory.domain.ReceiptHeaderHistory">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  8 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  9 + <result column="code" jdbcType="VARCHAR" property="code" />
  10 + <result column="receiptType" jdbcType="VARCHAR" property="receiptType" />
  11 + <result column="firstStatus" jdbcType="INTEGER" property="firstStatus" />
  12 + <result column="lastStatus" jdbcType="INTEGER" property="lastStatus" />
  13 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  14 + <result column="referId" jdbcType="INTEGER" property="referId" />
  15 + <result column="referType" jdbcType="VARCHAR" property="referType" />
  16 + <result column="scheduledArriveDate" jdbcType="DATE" property="scheduledArriveDate" />
  17 + <result column="actualArriveDate" jdbcType="DATE" property="actualArriveDate" />
  18 + <result column="recvDock" jdbcType="VARCHAR" property="recvDock" />
  19 + <result column="closedAt" jdbcType="DATE" property="closedAt" />
  20 + <result column="closedBy" jdbcType="VARCHAR" property="closedBy" />
  21 + <result column="startCheckinDatetime" jdbcType="TIMESTAMP" property="startCheckinDatetime" />
  22 + <result column="endCheckinDatetime" jdbcType="TIMESTAMP" property="endCheckinDatetime" />
  23 + <result column="totalQty" jdbcType="INTEGER" property="totalQty" />
  24 + <result column="totalLines" jdbcType="INTEGER" property="totalLines" />
  25 + <result column="toalCases" jdbcType="INTEGER" property="toalCases" />
  26 + <result column="totalWeight" jdbcType="DECIMAL" property="totalWeight" />
  27 + <result column="totalVolume" jdbcType="DECIMAL" property="totalVolume" />
  28 + <result column="receiptNote" jdbcType="VARCHAR" property="receiptNote" />
  29 + <result column="locked" jdbcType="INTEGER" property="locked" />
  30 + <result column="lockedBy" jdbcType="VARCHAR" property="lockedBy" />
  31 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  32 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  33 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  34 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  35 + <result column="version" jdbcType="INTEGER" property="version" />
  36 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  37 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  38 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  39 + <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />
  40 + <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />
  41 + <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />
  42 + <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />
  43 + <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />
  44 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  45 + <result column="deleted" jdbcType="BIT" property="deleted" />
  46 + </resultMap>
  47 + <sql id="Base_Column_List">
  48 + <!--@mbg.generated-->
  49 + id, warehouseCode, companyCode, code, receiptType, firstStatus, lastStatus, referCode,
  50 + referId, referType, scheduledArriveDate, actualArriveDate, recvDock, closedAt, closedBy,
  51 + startCheckinDatetime, endCheckinDatetime, totalQty, totalLines, toalCases, totalWeight,
  52 + totalVolume, receiptNote, locked, lockedBy, created, createdBy, lastUpdated, lastUpdatedBy,
  53 + version, userDef1, userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8,
  54 + processStamp, deleted
  55 + </sql>
  56 +</mapper>
0 \ No newline at end of file 57 \ No newline at end of file
src/main/resources/mybatis/shipment/ShipmentDetailHistoryMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.shipment.shipmentDetailHistory.mapper.ShipmentDetailHistoryMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.shipment.shipmentDetailHistory.domain.ShipmentDetailHistory">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="shipmentId" jdbcType="INTEGER" property="shipmentId" />
  8 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  9 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  10 + <result column="shipmentCode" jdbcType="VARCHAR" property="shipmentCode" />
  11 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  12 + <result column="referId" jdbcType="INTEGER" property="referId" />
  13 + <result column="referLineNum" jdbcType="VARCHAR" property="referLineNum" />
  14 + <result column="materialCode" jdbcType="VARCHAR" property="materialCode" />
  15 + <result column="materialName" jdbcType="VARCHAR" property="materialName" />
  16 + <result column="materialSpec" jdbcType="VARCHAR" property="materialSpec" />
  17 + <result column="materialUnit" jdbcType="VARCHAR" property="materialUnit" />
  18 + <result column="shipQty" jdbcType="INTEGER" property="shipQty" />
  19 + <result column="requestQty" jdbcType="INTEGER" property="requestQty" />
  20 + <result column="allocationRule" jdbcType="VARCHAR" property="allocationRule" />
  21 + <result column="replenishmentRule" jdbcType="VARCHAR" property="replenishmentRule" />
  22 + <result column="pickLocs" jdbcType="VARCHAR" property="pickLocs" />
  23 + <result column="attribute1" jdbcType="VARCHAR" property="attribute1" />
  24 + <result column="attribute2" jdbcType="VARCHAR" property="attribute2" />
  25 + <result column="attribute3" jdbcType="VARCHAR" property="attribute3" />
  26 + <result column="attribute4" jdbcType="VARCHAR" property="attribute4" />
  27 + <result column="batch" jdbcType="VARCHAR" property="batch" />
  28 + <result column="lot" jdbcType="VARCHAR" property="lot" />
  29 + <result column="projectNo" jdbcType="VARCHAR" property="projectNo" />
  30 + <result column="manufactureDate" jdbcType="DATE" property="manufactureDate" />
  31 + <result column="expirationDate" jdbcType="DATE" property="expirationDate" />
  32 + <result column="agingDate" jdbcType="DATE" property="agingDate" />
  33 + <result column="inventorySts" jdbcType="VARCHAR" property="inventorySts" />
  34 + <result column="dockLoc" jdbcType="VARCHAR" property="dockLoc" />
  35 + <result column="packingClass" jdbcType="VARCHAR" property="packingClass" />
  36 + <result column="status" jdbcType="INTEGER" property="status" />
  37 + <result column="waveId" jdbcType="INTEGER" property="waveId" />
  38 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  39 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  40 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  41 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  42 + <result column="version" jdbcType="INTEGER" property="version" />
  43 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  44 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  45 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  46 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  47 + </resultMap>
  48 + <sql id="Base_Column_List">
  49 + <!--@mbg.generated-->
  50 + id, shipmentId, warehouseCode, companyCode, shipmentCode, referCode, referId, referLineNum,
  51 + materialCode, materialName, materialSpec, materialUnit, shipQty, requestQty, allocationRule,
  52 + replenishmentRule, pickLocs, attribute1, attribute2, attribute3, attribute4, batch,
  53 + lot, projectNo, manufactureDate, expirationDate, agingDate, inventorySts, dockLoc,
  54 + packingClass, `enable`, waveId, created, createdBy, lastUpdated, lastUpdatedBy, version,
  55 + userDef1, userDef2, userDef3,processStamp
  56 + </sql>
  57 +
  58 + <select id="SelectFirstStatus" resultType="java.util.Map">
  59 + SELECT h.id, h.firstStatus
  60 + FROM shipment_header_history h
  61 + INNER JOIN shipment_detail_history d ON h.id = d.shipmentId AND d.id IN (#{ids})
  62 + GROUP BY h.id,firstStatus
  63 + </select>
  64 +
  65 + <delete id="batchDelete">
  66 + DELETE FROM shipment_detail_history WHERE id IN
  67 + <foreach item="idItem" collection="array" open="(" separator="," close=")">
  68 + #{idItem}
  69 + </foreach>
  70 + </delete>
  71 +
  72 + <select id="StatisticalByReceiptId" resultType="java.util.Map">
  73 + SELECT count(*) as 'totalLines',sum(shipQty) as 'totalQty'
  74 + FROM shipment_detail_history
  75 + WHERE shipmentId=#{headerId}
  76 + </select>
  77 +
  78 +</mapper>
0 \ No newline at end of file 79 \ No newline at end of file
src/main/resources/mybatis/shipment/ShipmentDetailMapper.xml
@@ -43,11 +43,6 @@ @@ -43,11 +43,6 @@
43 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" /> 43 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
44 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" /> 44 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
45 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" /> 45 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
46 - <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />  
47 - <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />  
48 - <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />  
49 - <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />  
50 - <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />  
51 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" /> 46 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
52 </resultMap> 47 </resultMap>
53 <sql id="Base_Column_List"> 48 <sql id="Base_Column_List">
@@ -57,7 +52,7 @@ @@ -57,7 +52,7 @@
57 replenishmentRule, pickLocs, attribute1, attribute2, attribute3, attribute4, batch, 52 replenishmentRule, pickLocs, attribute1, attribute2, attribute3, attribute4, batch,
58 lot, projectNo, manufactureDate, expirationDate, agingDate, inventorySts, dockLoc, 53 lot, projectNo, manufactureDate, expirationDate, agingDate, inventorySts, dockLoc,
59 packingClass, `enable`, waveId, created, createdBy, lastUpdated, lastUpdatedBy, version, 54 packingClass, `enable`, waveId, created, createdBy, lastUpdated, lastUpdatedBy, version,
60 - userDef1, userDef2, userDef3, userDef4, userDef5, userDef6, userDef7, userDef8, processStamp 55 + userDef1, userDef2, userDef3,processStamp
61 </sql> 56 </sql>
62 57
63 58
src/main/resources/mybatis/shipment/ShipmentHeaderHistoryMapper.xml 0 → 100644
  1 +<?xml version="1.0" encoding="UTF-8"?>
  2 +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3 +<mapper namespace="com.huaheng.pc.shipment.shipmentHeaderHistory.mapper.ShipmentHeaderHistoryMapper">
  4 + <resultMap id="BaseResultMap" type="com.huaheng.pc.shipment.shipmentHeaderHistory.domain.ShipmentHeaderHistory">
  5 + <!--@mbg.generated-->
  6 + <id column="id" jdbcType="INTEGER" property="id" />
  7 + <result column="warehouseCode" jdbcType="VARCHAR" property="warehouseCode" />
  8 + <result column="companyCode" jdbcType="VARCHAR" property="companyCode" />
  9 + <result column="code" jdbcType="VARCHAR" property="code" />
  10 + <result column="referCode" jdbcType="VARCHAR" property="referCode" />
  11 + <result column="referCodeType" jdbcType="VARCHAR" property="referCodeType" />
  12 + <result column="referId" jdbcType="INTEGER" property="referId" />
  13 + <result column="referPlatform" jdbcType="INTEGER" property="referPlatform" />
  14 + <result column="firstStatus" jdbcType="INTEGER" property="firstStatus" />
  15 + <result column="lastStatus" jdbcType="INTEGER" property="lastStatus" />
  16 + <result column="shipmentType" jdbcType="VARCHAR" property="shipmentType" />
  17 + <result column="route" jdbcType="VARCHAR" property="route" />
  18 + <result column="customerCode" jdbcType="VARCHAR" property="customerCode" />
  19 + <result column="customerName" jdbcType="VARCHAR" property="customerName" />
  20 + <result column="priority" jdbcType="INTEGER" property="priority" />
  21 + <result column="requestedDeliveryDate" jdbcType="DATE" property="requestedDeliveryDate" />
  22 + <result column="scheduledShipDate" jdbcType="DATE" property="scheduledShipDate" />
  23 + <result column="actualShipDateTime" jdbcType="TIMESTAMP" property="actualShipDateTime" />
  24 + <result column="actualDeliveryDate" jdbcType="DATE" property="actualDeliveryDate" />
  25 + <result column="deliveryNote" jdbcType="VARCHAR" property="deliveryNote" />
  26 + <result column="rejectionNote" jdbcType="VARCHAR" property="rejectionNote" />
  27 + <result column="waveId" jdbcType="INTEGER" property="waveId" />
  28 + <result column="shipDock" jdbcType="VARCHAR" property="shipDock" />
  29 + <result column="allocateComplete" jdbcType="INTEGER" property="allocateComplete" />
  30 + <result column="totalWeight" jdbcType="DECIMAL" property="totalWeight" />
  31 + <result column="totalQty" jdbcType="INTEGER" property="totalQty" />
  32 + <result column="totalVolume" jdbcType="DECIMAL" property="totalVolume" />
  33 + <result column="totalLines" jdbcType="INTEGER" property="totalLines" />
  34 + <result column="processType" jdbcType="VARCHAR" property="processType" />
  35 + <result column="lastWaveId" jdbcType="INTEGER" property="lastWaveId" />
  36 + <result column="signValue" jdbcType="VARCHAR" property="signValue" />
  37 + <result column="carrierCode" jdbcType="VARCHAR" property="carrierCode" />
  38 + <result column="carrierService" jdbcType="VARCHAR" property="carrierService" />
  39 + <result column="shipmentNote" jdbcType="VARCHAR" property="shipmentNote" />
  40 + <result column="carrierServer" jdbcType="VARCHAR" property="carrierServer" />
  41 + <result column="carrierServerName" jdbcType="VARCHAR" property="carrierServerName" />
  42 + <result column="plateNumber" jdbcType="VARCHAR" property="plateNumber" />
  43 + <result column="carModel" jdbcType="VARCHAR" property="carModel" />
  44 + <result column="driverName" jdbcType="VARCHAR" property="driverName" />
  45 + <result column="driverTel" jdbcType="VARCHAR" property="driverTel" />
  46 + <result column="created" jdbcType="TIMESTAMP" property="created" />
  47 + <result column="createdBy" jdbcType="VARCHAR" property="createdBy" />
  48 + <result column="lastUpdated" jdbcType="TIMESTAMP" property="lastUpdated" />
  49 + <result column="lastUpdatedBy" jdbcType="VARCHAR" property="lastUpdatedBy" />
  50 + <result column="version" jdbcType="INTEGER" property="version" />
  51 + <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
  52 + <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
  53 + <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
  54 + <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
  55 + <result column="deleted" jdbcType="BIT" property="deleted" />
  56 + </resultMap>
  57 + <sql id="Base_Column_List">
  58 + <!--@mbg.generated-->
  59 + id, warehouseCode, companyCode, code, referCode, referCodeType, referId,
  60 + referPlatform, firstStatus, lastStatus, shipmentType, route, customerCode, customerName,
  61 + priority, requestedDeliveryDate, scheduledShipDate, actualShipDateTime,
  62 + actualDeliveryDate, deliveryNote, rejectionNote, waveId, shipDock, allocateComplete,
  63 + totalWeight, totalQty, totalVolume, totalLines,
  64 + processType, lastWaveId, signValue, carrierCode, carrierService, shipmentNote, carrierServer,
  65 + carrierServerName, plateNumber, carModel, driverName, driverTel, created, createdBy,
  66 + lastUpdated, lastUpdatedBy, version, userDef1, userDef2, userDef3,processStamp, deleted
  67 + </sql>
  68 +
  69 +
  70 +</mapper>
0 \ No newline at end of file 71 \ No newline at end of file
src/main/resources/mybatis/shipment/ShipmentHeaderMapper.xml
@@ -51,11 +51,6 @@ @@ -51,11 +51,6 @@
51 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" /> 51 <result column="userDef1" jdbcType="VARCHAR" property="userDef1" />
52 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" /> 52 <result column="userDef2" jdbcType="VARCHAR" property="userDef2" />
53 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" /> 53 <result column="userDef3" jdbcType="VARCHAR" property="userDef3" />
54 - <result column="userDef4" jdbcType="VARCHAR" property="userDef4" />  
55 - <result column="userDef5" jdbcType="VARCHAR" property="userDef5" />  
56 - <result column="userDef6" jdbcType="VARCHAR" property="userDef6" />  
57 - <result column="userDef7" jdbcType="VARCHAR" property="userDef7" />  
58 - <result column="userDef8" jdbcType="VARCHAR" property="userDef8" />  
59 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" /> 54 <result column="processStamp" jdbcType="VARCHAR" property="processStamp" />
60 <result column="deleted" jdbcType="BIT" property="deleted" /> 55 <result column="deleted" jdbcType="BIT" property="deleted" />
61 </resultMap> 56 </resultMap>
@@ -68,8 +63,7 @@ @@ -68,8 +63,7 @@
68 totalWeight, totalQty, totalVolume, totalLines, 63 totalWeight, totalQty, totalVolume, totalLines,
69 processType, lastWaveId, signValue, carrierCode, carrierService, shipmentNote, carrierServer, 64 processType, lastWaveId, signValue, carrierCode, carrierService, shipmentNote, carrierServer,
70 carrierServerName, plateNumber, carModel, driverName, driverTel, created, createdBy, 65 carrierServerName, plateNumber, carModel, driverName, driverTel, created, createdBy,
71 - lastUpdated, lastUpdatedBy, version, userDef1, userDef2, userDef3, userDef4, userDef5,  
72 - userDef6, userDef7, userDef8, processStamp, deleted 66 + lastUpdated, lastUpdatedBy, version, userDef1, userDef2, userDef3,processStamp, deleted
73 </sql> 67 </sql>
74 68
75 <select id="createCode" resultType="java.lang.String"> 69 <select id="createCode" resultType="java.lang.String">
src/main/resources/templates/config/receiptType/add.html
@@ -46,7 +46,9 @@ @@ -46,7 +46,9 @@
46 <div class="form-group"> 46 <div class="form-group">
47 <label class="col-sm-3 control-label">入库流程:</label> 47 <label class="col-sm-3 control-label">入库流程:</label>
48 <div class="col-sm-8"> 48 <div class="col-sm-8">
49 - <input id="receiptFlow" name="receiptFlow" class="form-control" type="text"> 49 + <select id="receiptFlow" name="receiptFlow" class="form-control" th:with="statusFlowList=${@StatusFlow.flowList()}">
  50 + <option th:each="flow : ${statusFlowList}" th:text="${flow['name']}" th:value="${flow['code']}"></option>
  51 + </select>
50 </div> 52 </div>
51 </div> 53 </div>
52 <!--<div class="form-group"> 54 <!--<div class="form-group">
@@ -167,6 +169,7 @@ @@ -167,6 +169,7 @@
167 // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize()); 169 // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize());
168 var tableValue = $.common.getTableValue("#form-receiptType-add"); 170 var tableValue = $.common.getTableValue("#form-receiptType-add");
169 tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val()); 171 tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val());
  172 + tableValue = formValueReplace(tableValue, "receiptFlow", $("#receiptFlow option:selected").val());
170 tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked')); 173 tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));
171 $.operate.save(prefix + "/add", tableValue); 174 $.operate.save(prefix + "/add", tableValue);
172 } 175 }
src/main/resources/templates/config/receiptType/edit.html
@@ -48,7 +48,9 @@ @@ -48,7 +48,9 @@
48 <div class="form-group"> 48 <div class="form-group">
49 <label class="col-sm-3 control-label">入库流程:</label> 49 <label class="col-sm-3 control-label">入库流程:</label>
50 <div class="col-sm-8"> 50 <div class="col-sm-8">
51 - <input id="receiptFlow" name="receiptFlow" class="form-control" type="text" th:field="*{receiptFlow}"> 51 + <select id="receiptFlow" name="receiptFlow" class="form-control" th:with="statusFlowList=${@StatusFlow.flowList()}" th:field="*{receiptFlow}">
  52 + <option th:each="flow : ${statusFlowList}" th:text="${flow['name']}" th:value="${flow['code']}"></option>
  53 + </select>
52 </div> 54 </div>
53 </div> 55 </div>
54 <!--<div class="form-group"> 56 <!--<div class="form-group">
@@ -169,6 +171,8 @@ @@ -169,6 +171,8 @@
169 // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize()); 171 // $.operate.save(prefix + "/add", $('#form-locationType-add').serialize());
170 var tableValue = $.common.getTableValue("#form-receiptType-edit"); 172 var tableValue = $.common.getTableValue("#form-receiptType-edit");
171 tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val()); 173 tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val());
  174 + tableValue = formValueReplace(tableValue, "receiptFlow", $("#receiptFlow option:selected").val());
  175 + tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));
172 $.operate.save(prefix + "/edit", tableValue); 176 $.operate.save(prefix + "/edit", tableValue);
173 } 177 }
174 }); 178 });
src/main/resources/templates/config/statusFlowDetail/add.html
@@ -6,6 +6,7 @@ @@ -6,6 +6,7 @@
6 <div class="wrapper wrapper-content animated fadeInRight ibox-content"> 6 <div class="wrapper wrapper-content animated fadeInRight ibox-content">
7 <form class="form-horizontal m" id="form-statusFlowDetails-add"> 7 <form class="form-horizontal m" id="form-statusFlowDetails-add">
8 <input name="headerId" type="hidden" th:value="${headerId}"> 8 <input name="headerId" type="hidden" th:value="${headerId}">
  9 + <input name="headerCode" type="hidden" th:value="${headerCode}">
9 <div class="form-group"> 10 <div class="form-group">
10 <label class="col-sm-3 control-label">状态流:</label> 11 <label class="col-sm-3 control-label">状态流:</label>
11 <div class="col-sm-8"> 12 <div class="col-sm-8">
src/main/resources/templates/config/statusFlowDetail/edit.html
@@ -16,7 +16,7 @@ @@ -16,7 +16,7 @@
16 <div class="form-group"> 16 <div class="form-group">
17 <label class="col-sm-3 control-label">模块:</label> 17 <label class="col-sm-3 control-label">模块:</label>
18 <div class="col-sm-8"> 18 <div class="col-sm-8">
19 - <input id="moduleType" name="moduleType" class="form-control" type="text" th:field="*{modlueType}"> 19 + <input id="moduleType" name="moduleType" class="form-control" type="text" th:field="*{moduleType}">
20 </div> 20 </div>
21 </div> 21 </div>
22 <div class="form-group"> 22 <div class="form-group">
@@ -26,7 +26,7 @@ @@ -26,7 +26,7 @@
26 </div> 26 </div>
27 </div> 27 </div>
28 <div class="form-group"> 28 <div class="form-group">
29 - <label class="col-sm-3 control-label">类型:</label> 29 + <label class="col-sm-3 control-label">序号:</label>
30 <div class="col-sm-8"> 30 <div class="col-sm-8">
31 <input id="sequence" name="sequence" class="form-control" type="text" th:field="*{sequence}"> 31 <input id="sequence" name="sequence" class="form-control" type="text" th:field="*{sequence}">
32 </div> 32 </div>
@@ -53,11 +53,11 @@ @@ -53,11 +53,11 @@
53 <!-- </div>--> 53 <!-- </div>-->
54 <!--</div>--> 54 <!--</div>-->
55 <div class="form-group"> 55 <div class="form-group">
56 - <label class="col-sm-3 control-label">是否启用:</label> 56 + <label class="col-sm-3 control-label">是否有效:</label>
57 <div class="col-sm-8"> 57 <div class="col-sm-8">
  58 + <!--<input id="enable" name="enable" th:field="*{enable}" class="form-control" type="text">-->
58 <div class="onoffswitch"> 59 <div class="onoffswitch">
59 - <input type="checkbox" th:checked="true" class="onoffswitch-checkbox"  
60 - id="enable" name="enable" th:field="*{enable}"> 60 + <input type="checkbox" th:checked="*{enable}" class="onoffswitch-checkbox" id="enable" name="enable">
61 <label class="onoffswitch-label" for="enable"> 61 <label class="onoffswitch-label" for="enable">
62 <span class="onoffswitch-inner"></span> 62 <span class="onoffswitch-inner"></span>
63 <span class="onoffswitch-switch"></span> 63 <span class="onoffswitch-switch"></span>
@@ -75,7 +75,7 @@ @@ -75,7 +75,7 @@
75 </div> 75 </div>
76 <div th:include="include::footer"></div> 76 <div th:include="include::footer"></div>
77 <script type="text/javascript"> 77 <script type="text/javascript">
78 - var prefix = ctx + "config/statusFlowDetails"; 78 + var prefix = ctx + "config/statusFlowDetail";
79 $("#form-statusFlowDetails-edit").validate({ 79 $("#form-statusFlowDetails-edit").validate({
80 rules:{ 80 rules:{
81 flowCode:{ 81 flowCode:{
@@ -96,7 +96,7 @@ @@ -96,7 +96,7 @@
96 var tableValue = $.common.getTableValue("#form-statusFlowDetails-edit"); 96 var tableValue = $.common.getTableValue("#form-statusFlowDetails-edit");
97 tableValue = formValueReplace(tableValue, "nessary", $("#nessary option:selected").val()); 97 tableValue = formValueReplace(tableValue, "nessary", $("#nessary option:selected").val());
98 tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked')); 98 tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));
99 - $.operate.save(prefix + "/add", tableValue); 99 + $.operate.save(prefix + "/edit", tableValue);
100 } 100 }
101 }); 101 });
102 </script> 102 </script>
src/main/resources/templates/config/statusFlowDetail/statusFlowDetail.html
@@ -23,6 +23,7 @@ @@ -23,6 +23,7 @@
23 var editFlag = [[${@permission.hasPermi('config:statusFlowDetails:edit')}]]; 23 var editFlag = [[${@permission.hasPermi('config:statusFlowDetails:edit')}]];
24 var removeFlag = [[${@permission.hasPermi('config:statusFlowDetails:remove')}]]; 24 var removeFlag = [[${@permission.hasPermi('config:statusFlowDetails:remove')}]];
25 var datas = [[${@dict.getType('sys_normal_disable')}]]; 25 var datas = [[${@dict.getType('sys_normal_disable')}]];
  26 + var nessaryDatas = [[${@dict.getType('nessary')}]];
26 $(function() { 27 $(function() {
27 var options = { 28 var options = {
28 url: prefix + "/list", 29 url: prefix + "/list",
@@ -81,7 +82,7 @@ @@ -81,7 +82,7 @@
81 title : '是否是必须流程', 82 title : '是否是必须流程',
82 align: 'center', 83 align: 'center',
83 formatter: function(value, row, index) { 84 formatter: function(value, row, index) {
84 - return $.table.selectDictLabel(datas, value); 85 + return $.table.selectDictLabel(nessaryDatas, value);
85 } 86 }
86 }, 87 },
87 { 88 {
src/main/resources/templates/config/statusFlowHeader/add.html
@@ -6,13 +6,13 @@ @@ -6,13 +6,13 @@
6 <div class="wrapper wrapper-content animated fadeInRight ibox-content"> 6 <div class="wrapper wrapper-content animated fadeInRight ibox-content">
7 <form class="form-horizontal m" id="form-statusFlowHeader-add"> 7 <form class="form-horizontal m" id="form-statusFlowHeader-add">
8 <div class="form-group"> 8 <div class="form-group">
9 - <label class="col-sm-3 control-label">状态流:</label> 9 + <label class="col-sm-3 control-label">编码:</label>
10 <div class="col-sm-8"> 10 <div class="col-sm-8">
11 <input id="code" name="code" class="form-control" type="text"> 11 <input id="code" name="code" class="form-control" type="text">
12 </div> 12 </div>
13 </div> 13 </div>
14 <div class="form-group"> 14 <div class="form-group">
15 - <label class="col-sm-3 control-label">状态流名称:</label> 15 + <label class="col-sm-3 control-label">名称:</label>
16 <div class="col-sm-8"> 16 <div class="col-sm-8">
17 <input id="name" name="name" class="form-control" type="text"> 17 <input id="name" name="name" class="form-control" type="text">
18 </div> 18 </div>
src/main/resources/templates/config/statusFlowHeader/edit.html
@@ -7,13 +7,13 @@ @@ -7,13 +7,13 @@
7 <form class="form-horizontal m" id="form-statusFlowHeader-edit" th:object="${statusFlowHeader}"> 7 <form class="form-horizontal m" id="form-statusFlowHeader-edit" th:object="${statusFlowHeader}">
8 <input name="id" th:field="*{id}" type="hidden"> 8 <input name="id" th:field="*{id}" type="hidden">
9 <div class="form-group"> 9 <div class="form-group">
10 - <label class="col-sm-3 control-label">状态流:</label> 10 + <label class="col-sm-3 control-label">编码:</label>
11 <div class="col-sm-8"> 11 <div class="col-sm-8">
12 <input id="code" name="code" class="form-control" type="text" th:field="*{code}"> 12 <input id="code" name="code" class="form-control" type="text" th:field="*{code}">
13 </div> 13 </div>
14 </div> 14 </div>
15 <div class="form-group"> 15 <div class="form-group">
16 - <label class="col-sm-3 control-label">状态流名称:</label> 16 + <label class="col-sm-3 control-label">名称:</label>
17 <div class="col-sm-8"> 17 <div class="col-sm-8">
18 <input id="name" name="name" class="form-control" type="text" th:field="*{name}"> 18 <input id="name" name="name" class="form-control" type="text" th:field="*{name}">
19 </div> 19 </div>
@@ -43,11 +43,11 @@ @@ -43,11 +43,11 @@
43 <!-- </div>--> 43 <!-- </div>-->
44 <!--</div>--> 44 <!--</div>-->
45 <div class="form-group"> 45 <div class="form-group">
46 - <label class="col-sm-3 control-label">是否启用:</label> 46 + <label class="col-sm-3 control-label">是否有效:</label>
47 <div class="col-sm-8"> 47 <div class="col-sm-8">
  48 + <!--<input id="enable" name="enable" th:field="*{enable}" class="form-control" type="text">-->
48 <div class="onoffswitch"> 49 <div class="onoffswitch">
49 - <input type="checkbox" th:checked="true" class="onoffswitch-checkbox" id="enable" name="enable"  
50 - th:field="*{enable}"> 50 + <input type="checkbox" th:checked="*{enable}" class="onoffswitch-checkbox" id="enable" name="enable">
51 <label class="onoffswitch-label" for="enable"> 51 <label class="onoffswitch-label" for="enable">
52 <span class="onoffswitch-inner"></span> 52 <span class="onoffswitch-inner"></span>
53 <span class="onoffswitch-switch"></span> 53 <span class="onoffswitch-switch"></span>
@@ -65,7 +65,7 @@ @@ -65,7 +65,7 @@
65 </div> 65 </div>
66 <div th:include="include::footer"></div> 66 <div th:include="include::footer"></div>
67 <script type="text/javascript"> 67 <script type="text/javascript">
68 - var prefix = ctx + "config/receiptType"; 68 + var prefix = ctx + "config/statusFlowHeader";
69 $("#form-statusFlowHeader-edit").validate({ 69 $("#form-statusFlowHeader-edit").validate({
70 rules:{ 70 rules:{
71 code:{ 71 code:{
src/main/resources/templates/config/statusFlowHeader/statusFlowHeader.html
@@ -75,6 +75,8 @@ @@ -75,6 +75,8 @@
75 var prefix1 = ctx + "config/statusFlowDetail"; 75 var prefix1 = ctx + "config/statusFlowDetail";
76 var editFlag = [[${@permission.hasPermi('config:statusFlowHeader:edit')}]]; 76 var editFlag = [[${@permission.hasPermi('config:statusFlowHeader:edit')}]];
77 var removeFlag = [[${@permission.hasPermi('config:statusFlowHeader:remove')}]]; 77 var removeFlag = [[${@permission.hasPermi('config:statusFlowHeader:remove')}]];
  78 + var datas = [[${@dict.getType('sys_normal_disable')}]];
  79 +
78 $(function() { 80 $(function() {
79 var options = { 81 var options = {
80 url: prefix + "/list", 82 url: prefix + "/list",
@@ -94,11 +96,11 @@ @@ -94,11 +96,11 @@
94 }, 96 },
95 { 97 {
96 field : 'code', 98 field : 'code',
97 - title : '状态流' 99 + title : '编码'
98 }, 100 },
99 { 101 {
100 field : 'name', 102 field : 'name',
101 - title : '状态流名称' 103 + title : '名称'
102 }, 104 },
103 { 105 {
104 field : 'warehouseCode', 106 field : 'warehouseCode',
@@ -113,6 +115,14 @@ @@ -113,6 +115,14 @@
113 title : '类型' 115 title : '类型'
114 }, 116 },
115 { 117 {
  118 + field : 'enable',
  119 + title : '是否有效' ,
  120 + align: 'center',
  121 + formatter: function(value, row, index) {
  122 + return $.table.selectDictLabel(datas, value);
  123 + }
  124 + },
  125 + {
116 field : 'version', 126 field : 'version',
117 title : '数据版本', 127 title : '数据版本',
118 visible : false 128 visible : false
src/main/resources/templates/inventory/cyclecountAdjustDetail/addAdjust.html renamed to src/main/resources/templates/inventory/adjustDetail/addAdjust.html
src/main/resources/templates/inventory/cyclecountAdjustDetail/cyclecountAdjustDetail.html renamed to src/main/resources/templates/inventory/adjustDetail/adjustDetail.html
@@ -6,54 +6,43 @@ @@ -6,54 +6,43 @@
6 <div class="row"> 6 <div class="row">
7 <div class="col-sm-12"> 7 <div class="col-sm-12">
8 <div class="col-sm-12 select-info"> 8 <div class="col-sm-12 select-info">
9 - <div class="select-list" th:object="${header}"> 9 + <div class="select-list" >
10 <ul> 10 <ul>
11 <li> 11 <li>
12 <form id="cycleHeader-form"> 12 <form id="cycleHeader-form">
13 - 差异单ID:<input type="text" id="cyclecountAdjustId" name="cyclecountAdjustId" th:value="*{id}" readonly="readonly"> 13 + 调整单编码:<input type="text" id="cyclecountAdjustId" name="cyclecountAdjustId" />
14 </form> 14 </form>
15 </li> 15 </li>
16 <li> 16 <li>
17 - 货主编码:<input id="companyCode" type="text" name="companyCode" th:value="*{companyCode}" readonly="readonly"/> 17 + 货主编码:<input id="companyCode" type="text" name="companyCode" />
18 </li> 18 </li>
19 <li> 19 <li>
20 - 调整单编码:<input id="code" type="text" name="code" th:value="*{code}" readonly="readonly"/> 20 + 调整单编码:<input id="code" type="text" name="code" />
21 </li> 21 </li>
22 <li> 22 <li>
23 - 源盘点单号:<input id="sourceCode" type="text" name="sourceCode" th:value="*{sourceCode}" readonly="readonly"> 23 + 盘点单号:<input id="sourceCode" type="text" name="sourceCode" />
24 </li> 24 </li>
25 - <!-- <li>  
26 - &lt;!&ndash;头 状 态:<input type="text" name="firstStatus"/>&ndash;&gt;  
27 - 状态:<input id = "status" type="text" name="status" th:value="*{statusLabel}" readonly="readonly">  
28 - </li>-->  
29 <li> 25 <li>
30 - 调整单状态:<input id = "status" type="text" name="status" th:value="*{statusLabel}" readonly="readonly"> 26 + 调整单状态:<input id = "status" type="text" name="status" />
31 </li> 27 </li>
32 <li> 28 <li>
33 - 创建时间:<input id="created" type="text" name="created" th:value="*{created}" readonly="readonly"> 29 + 创建时间:<input id="created" type="text" name="created" />
34 30
35 </li> 31 </li>
36 <li> 32 <li>
37 - 创建人:<input id="createdBy" type="text" name="createdBy" th:value="*{createdBy}" readonly="readonly"> 33 + 创建人:<input id="createdBy" type="text" name="createdBy" />
38 </li> 34 </li>
39 <li> 35 <li>
40 - 最后更新时间:<input id="lastUpdated" type="text" name="lastUpdated" th:value="*{lastUpdated}" readonly="readonly">  
41 -  
42 - </li>  
43 - <li>  
44 - 最后更新人:<input id="lastUpdatedBy" type="text" name="lastUpdatedBy" th:value="*{lastUpdatedBy}" readonly="readonly"> 36 + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
  37 + class="fa fa-search"></i>&nbsp;搜索</a>
45 </li> 38 </li>
46 - <!--<li>-->  
47 - <!--<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i-->  
48 - <!--class="fa fa-search"></i>&nbsp;搜索</a>-->  
49 - <!--</li>-->  
50 </ul> 39 </ul>
51 </div> 40 </div>
52 </div> 41 </div>
53 <div class="btn-group hidden-xs" id="toolbar" role="group"> 42 <div class="btn-group hidden-xs" id="toolbar" role="group">
54 43
55 - <a class="btn btn-outline btn-danger btn-rounded" onclick="addAdjust()"  
56 - shiro:hasPermission="inventory:cyclecountAdjustDetail:addAdjust"> 44 + <a class="btn btn-outline btn-danger btn-rounded" onclick="addAdjust()" />
  45 + <!--shiro:hasPermission="inventory:cyclecountAdjustDetail:addAdjust"-->
57 <i class="fa fa-vcard"></i>差异调整 46 <i class="fa fa-vcard"></i>差异调整
58 </a> 47 </a>
59 <!--<a class="btn btn-outline btn-danger btn-rounded" onclick="createCyclecountWithGapQty()" 48 <!--<a class="btn btn-outline btn-danger btn-rounded" onclick="createCyclecountWithGapQty()"
@@ -73,21 +62,19 @@ @@ -73,21 +62,19 @@
73 </div> 62 </div>
74 <div th:include="include :: footer"></div> 63 <div th:include="include :: footer"></div>
75 <script th:inline="javascript"> 64 <script th:inline="javascript">
76 - var prefix = ctx + "inventory/cyclecountAdjustDetail";  
77 - var prefix_head = ctx + "inventory/cyclecountAdjust"; 65 + var prefix = ctx + "inventory/adjustDetail";
  66 + var prefix_head = ctx + "inventory/adjustHeader";
78 var datas = [[${@dict.getType('adjustType')}]]; 67 var datas = [[${@dict.getType('adjustType')}]];
79 var inventoryStatus=[[${@dict.getType('inventoryStatus')}]]; 68 var inventoryStatus=[[${@dict.getType('inventoryStatus')}]];
80 -  
81 var created ; 69 var created ;
82 70
83 -  
84 $(function () { 71 $(function () {
85 var options = { 72 var options = {
86 // url: prefix + "/list", 73 // url: prefix + "/list",
87 /* createUrl: prefix + "/add", 74 /* createUrl: prefix + "/add",
88 updateUrl: prefix + "/edit/{id}", 75 updateUrl: prefix + "/edit/{id}",
89 removeUrl: prefix + "/remove",*/ 76 removeUrl: prefix + "/remove",*/
90 - modalName: "差异单明细", 77 + modalName: "调整单明细",
91 sortName: "id", 78 sortName: "id",
92 sortOrder: "desc", 79 sortOrder: "desc",
93 showRefresh:false, 80 showRefresh:false,
src/main/resources/templates/inventory/cyclecountAdjustDetail/adjustEdit.html renamed to src/main/resources/templates/inventory/adjustDetail/adjustEdit.html
src/main/resources/templates/inventory/cyclecountAdjust/cyclecountAdjust.html renamed to src/main/resources/templates/inventory/adjustHeader/adjustHeader.html
1 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 -<html lang="zh" xmlns:th="http://www.thymeleaf.org"> 2 +<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
3 <meta charset="utf-8"> 3 <meta charset="utf-8">
4 <head th:include="include :: header"></head> 4 <head th:include="include :: header"></head>
5 <style> 5 <style>
6 - #toolbar1{ 6 + #toolbar1 {
7 display: inline-block; 7 display: inline-block;
8 /*position: absolute; 8 /*position: absolute;
9 margin: 10px auto;*/ 9 margin: 10px auto;*/
@@ -11,235 +11,216 @@ @@ -11,235 +11,216 @@
11 } 11 }
12 </style> 12 </style>
13 <body class="gray-bg"> 13 <body class="gray-bg">
14 - <div class="container-div">  
15 - <div class="row">  
16 - <div class="col-sm-12 select-info">  
17 - <ul id="myTab" class="nav nav-tabs">  
18 - <li class="active"><a href="#tabHeader" data-toggle="tab">主表</a></li>  
19 - <li><a href="#tabDetail" data-toggle="tab">明细</a></li>  
20 - </ul>  
21 - <div id="myTabContent" class="tab-content">  
22 - <div class="tab-pane fade in active" id="tabHeader">  
23 - <div class="col-sm-12 select-info">  
24 - <form id="cycleHeader-form">  
25 - <div class="select-list">  
26 - <ul>  
27 - <li>  
28 - 差异单编号:<input type="text" name="code"/>  
29 - </li>  
30 - <li>  
31 - 源盘点单号:<input type="text" name="sourceCode"/>  
32 - </li>  
33 - <li>  
34 - 差异单状态:<select name="status"  
35 - th:with="lastStatus=${@dict.getType('adjustType')}">  
36 - <option value="">所有</option>  
37 - <option th:each="e : ${lastStatus}" th:text="${e['dictLabel']}"  
38 - th:value="${e['dictValue']}"></option>  
39 - </select>  
40 - </li>  
41 - <li class="time">  
42 - <label>创建时间: </label>  
43 - <input type="text" class="time-input" id="startTime" placeholder="开始时间"  
44 - name="params[createdBegin]"/>  
45 - <span>-</span>  
46 - <input type="text" class="time-input" id="endTime" placeholder="结束时间"  
47 - name="params[createdEnd]"/>  
48 - </li>  
49 - <li>  
50 - 货主编码:<input type="text" name="companyCode"/>  
51 - </li>  
52 - <li>  
53 - 创建人:<input type="text" name="createdBy"/>  
54 - </li>  
55 - <li>  
56 - 更新人:<input type="text" name="lastUpdatedBy"/>  
57 - </li>  
58 - <li>  
59 - <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i  
60 - class="fa fa-search"></i>&nbsp;搜索</a>  
61 - </li>  
62 - </ul>  
63 - </div>  
64 - </form>  
65 - </div>  
66 - <!--<div class="btn-group hidden-xs" id="toolbar" role="group">  
67 - <a class="btn btn-outline btn-success btn-rounded" onclick="$.operate.add()" shiro:hasPermission="inventoryHeader:cycleCount:insert">  
68 - <i class="fa fa-plus"></i> 新增  
69 - </a>  
70 - </div>-->  
71 - <table id="bootstrap-table" data-mobile-responsive="true" class="table table-bordered table-hover"></table>  
72 - </div>  
73 - <div class="tab-pane fade" id="tabDetail"></div>  
74 - </div>  
75 - </div> 14 +<div class="container-div">
  15 + <div class="row">
  16 + <div class="col-sm-12 select-info">
  17 + <ul id="myTab" class="nav nav-tabs">
  18 + <li class="active"><a href="#tabHeader" data-toggle="tab">主表</a></li>
  19 + <li><a href="#tabDetail" data-toggle="tab">明细</a></li>
  20 + </ul>
  21 + <div id="myTabContent" class="tab-content">
  22 + <div class="tab-pane fade in active" id="tabHeader">
  23 + <div class="col-sm-12 select-info">
  24 + <form id="cycleHeader-form">
  25 + <div class="select-list">
  26 + <ul>
  27 + <li>
  28 + 调整单编号:<input type="text" name="code"/>
  29 + </li>
  30 + <li>
  31 + 盘点单号:<input type="text" name="sourceCode"/>
  32 + </li>
  33 + <li>
  34 + 盘点类型:<select name="problemType"
  35 + th:with="problemType=${@dict.getType('adjustType')}">
  36 + <option value="">所有</option>
  37 + <option th:each="e : ${problemType}" th:text="${e['dictLabel']}"
  38 + th:value="${e['dictValue']}"></option>
  39 + </select>
  40 + </li>
  41 + <li>
  42 + 质检单号:<input type="text" name="checkCode"/>
  43 + </li>
  44 + <li>
  45 + 上游单编码:<input type="text" name="referCode"/>
  46 + </li>
  47 + <li>
  48 + 货主编码:<input type="text" name="companyCode"/>
  49 + </li>
  50 + <li>
  51 + 创建人:<input type="text" name="createdBy"/>
  52 + </li>
76 53
77 - </div>  
78 - </div>  
79 - <div th:include="include :: footer"></div>  
80 - <script th:inline="javascript">  
81 - var prefix = ctx + "inventory/cyclecountAdjust";  
82 - var upload = [[${@permission.hasPermi('inventoryHeader:cyclecountAdjust:upload')}]];  
83 - var report =[[${@permission.hasPermi('inventoryHeader:cyclecountAdjust:report')}]];  
84 - var datas = [[${@dict.getType('sys_normal_disable')}]];  
85 - var status2 = [[${@dict.getType('adjustType')}]]; 54 + <li class="time">
  55 + <label>创建时间: </label>
  56 + <input type="text" class="time-input" id="startTime" placeholder="开始时间"
  57 + name="createdBegin"/>
  58 + <span>-</span>
  59 + <input type="text" class="time-input" id="endTime" placeholder="结束时间"
  60 + name="createdEnd"/>
  61 + </li>
  62 + <li>
  63 + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
  64 + class="fa fa-search"></i>&nbsp;搜索</a>
  65 + </li>
  66 + </ul>
  67 + </div>
  68 + </form>
  69 + </div>
  70 + <table id="bootstrap-table" data-mobile-responsive="true"
  71 + class="table table-bordered table-hover"></table>
  72 + </div>
  73 + <div class="tab-pane fade" id="tabDetail"></div>
  74 + </div>
  75 + </div>
86 76
87 - $(function() {  
88 - var options = {  
89 - url: prefix + "/list",  
90 - createUrl: prefix + "/add",  
91 - updateUrl: prefix + "/edit/{id}",  
92 - removeUrl: prefix + "/remove",  
93 - modalName: "盘点差异调整单主",  
94 - sortName: "id",  
95 - sortOrder: "desc",  
96 - search: false,  
97 - // onDblClickRow: function (row) {  
98 - // showDetail(row.id,row.code);  
99 - // },  
100 - columns: [{  
101 - checkbox: true  
102 - },  
103 - {  
104 - field : 'id',  
105 - title : '差异单id'  
106 - },  
107 - {  
108 - field : 'code',  
109 - title : '差异单编码'  
110 - },  
111 - {  
112 - field : 'cyclecountHeadId',  
113 - title : '源盘点单id',  
114 - visible: false 77 + </div>
  78 +</div>
  79 +<div th:include="include :: footer"></div>
  80 +<script th:inline="javascript">
  81 + var prefix = ctx + "inventory/adjustHeader";
  82 + var upload = [[${@permission.hasPermi('inventoryHeader:adjustHeader:upload')}]];
  83 + var report = [[${@permission.hasPermi('inventoryHeader:adjustHeader:report')}]];
  84 + var datas = [[${@dict.getType('sys_normal_disable')}]];
  85 + var status2 = [[${@dict.getType('adjustType')}]];
115 86
  87 + $(function () {
  88 + var options = {
  89 + url: prefix + "/list",
  90 + createUrl: prefix + "/add",
  91 + updateUrl: prefix + "/edit/{id}",
  92 + removeUrl: prefix + "/remove",
  93 + modalName: "调整主单",
  94 + sortName: "id",
  95 + sortOrder: "desc",
  96 + search: false,
  97 + // onDblClickRow: function (row) {
  98 + // showDetail(row.id,row.code);
  99 + // },
  100 + columns: [{
  101 + checkbox: true
  102 + },
  103 + {
  104 + field: 'id',
  105 + title: '主单ID'
  106 + },
  107 + {
  108 + field: 'code',
  109 + title: '调整单编码'
  110 + },
  111 + {
  112 + field: 'warehouseCode',
  113 + title: '仓库编码',
  114 + visible: true
  115 + },
  116 + {
  117 + field: 'companyCode',
  118 + title: '货主编码'
  119 + },
  120 + {
  121 + field: 'cycleCountCode',
  122 + title: '盘点单号'
  123 + },
  124 + {
  125 + field: 'problemType',
  126 + title: '调整类型'
  127 + },
  128 + {
  129 + field: 'referCode',
  130 + title: '关联上游单编码'
  131 + },
  132 + {
  133 + field: 'referReason',
  134 + title: '关联上游说明'
  135 + },
  136 + {
  137 + field: 'problemType',
  138 + title: '调整类型',
  139 + align: 'center',
  140 + formatter: function (value, row, index) {
  141 + return $.table.selectDictLabel(status2, value);
116 }, 142 },
117 - {  
118 - field : 'sourceCode',  
119 - title : '源盘点单号'  
120 - },  
121 - {  
122 - field : 'warehouseCode',  
123 - title : '仓库编码'  
124 - },  
125 - {  
126 - field : 'companyCode',  
127 - title : '货主编码'  
128 - },  
129 - {  
130 - field: 'status',  
131 - title: '差异单状态',  
132 - align: 'center',  
133 - formatter: function(value, row, index) {  
134 - return $.table.selectDictLabel(status2, value);  
135 - },  
136 - sortable:true  
137 - }, 143 + sortable: true
  144 + },
138 145
139 - {  
140 - field : 'created',  
141 - title : '创建时间',  
142 - formatter : function(created, row, index) { //去除时间中间的T 146 + {
  147 + field: 'created',
  148 + title: '创建时间',
  149 + formatter: function (created, row, index) { //去除时间中间的T
143 return created.replace("T", " "); 150 return created.replace("T", " ");
144 } 151 }
145 - },  
146 - {  
147 - field : 'createdBy',  
148 - title : '创建用户'  
149 - },  
150 - {  
151 - field : 'lastUpdated',  
152 - title : '更新时间',  
153 - formatter : function(lastUpdated, row, index) { //去除时间中间的T  
154 - return lastUpdated.replace("T", " "); 152 + },
  153 + {
  154 + field: 'createdBy',
  155 + title: '创建用户'
  156 + },
  157 + /*{
  158 + field: 'enable',
  159 + title: '是否有效',
  160 + align: 'center',
  161 + formatter: function (value, row, index) {
  162 + return $.table.selectDictLabel(datas, value);
155 } 163 }
156 - },  
157 - {  
158 - field : 'lastUpdatedBy',  
159 - title : '更新用户'  
160 - },  
161 - {  
162 - field : 'uploadTime',  
163 - title : '上传时间'  
164 - },  
165 - /*{  
166 - field : 'enable',  
167 - title : '是否有效' ,  
168 - align: 'center',  
169 - formatter: function(value, row, index) {  
170 - return $.table.selectDictLabel(datas, value);  
171 - }  
172 - },*/  
173 - {  
174 - field : 'verifyBy',  
175 - title : '审核人'  
176 - },  
177 - {  
178 - field: 'enable',  
179 - title: '是否有效',  
180 - align: 'center',  
181 - formatter: function (value, row, index) {  
182 - return $.table.selectDictLabel(datas, value);  
183 - }  
184 - }, 164 + },*/
185 165
186 - {  
187 - title: '操作',  
188 - align: 'center',  
189 - formatter: function(value, row, index) {  
190 - var actions = []; 166 + {
  167 + title: '操作',
  168 + align: 'center',
  169 + formatter: function (value, row, index) {
  170 + var actions = [];
191 actions.push('<a class="btn btn-success btn-xs ' + report + '" href="#" onclick="cyclecountPrint(\'' + row.id + '\')"><i class="fa fa-print"></i>打印</a> '); 171 actions.push('<a class="btn btn-success btn-xs ' + report + '" href="#" onclick="cyclecountPrint(\'' + row.id + '\')"><i class="fa fa-print"></i>打印</a> ');
192 - actions.push('<a class="btn btn-info btn-xs ' + upload + ' " href="#" onclick="upLoad(\'' + row.code + '\',\''+row.sourceCode+'\')"><i class="fa fa-edit"></i>上传</a> ');  
193 - /* actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a> ');*/ 172 + actions.push('<a class="btn btn-info btn-xs ' + upload + ' " href="#" onclick="upLoad(\'' + row.code + '\',\'' + row.sourceCode + '\')"><i class="fa fa-edit"></i>上传</a> ');
  173 + /* actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a> ');*/
194 actions.push('<a style="background: #b5bdc0" class="btn btn-default btn-xs " href="#" onclick="detail(\'' + row.id + '\',\'' + row.code + '\')"><i class="fa fa-list-ul"></i>明细</a>'); 174 actions.push('<a style="background: #b5bdc0" class="btn btn-default btn-xs " href="#" onclick="detail(\'' + row.id + '\',\'' + row.code + '\')"><i class="fa fa-list-ul"></i>明细</a>');
195 - return actions.join('');  
196 - }  
197 - }]  
198 - };  
199 - $.table.init(options);  
200 - $("#myTab li:eq(1)").one('click',(function () {  
201 - var cyc_id=$("#bootstrap-table tr:eq(1) td:eq(1)").text();  
202 - var cyc_code=$("#bootstrap-table tr:eq(1) td:eq(2)").text();  
203 - detail(cyc_id,cyc_code);  
204 - }));  
205 - }); 175 + return actions.join('');
  176 + }
  177 + }]
  178 + };
  179 + $.table.init(options);
  180 + $("#myTab li:eq(1)").one('click', (function () {
  181 + var cyc_id = $("#bootstrap-table tr:eq(1) td:eq(1)").text();
  182 + var cyc_code = $("#bootstrap-table tr:eq(1) td:eq(2)").text();
  183 + detail(cyc_id, cyc_code);
  184 + }));
  185 + });
206 186
207 - function detail(id,code) {  
208 - var url = ctx +"inventory/cyclecountAdjustDetail?code="+code;  
209 - $("#tabDetail").children().remove();  
210 - $("#myTab li").removeClass("active");  
211 - var height = $(document).height()-100 + 'px';  
212 - var str = '<iframe class="huaheng_iframe" name="iframe" width="100%" height="' + height + '" src="' + url + '" frameborder="0" data-id="' + url + '" seamless></iframe>';  
213 - $("#tabDetail").empty();  
214 - $("#tabDetail").append(str);  
215 - $(".tab-pane").removeClass("in active");  
216 - $("#myTab li:eq(1)").addClass("active");  
217 - $("#tabDetail").addClass("in active");  
218 - } 187 + function detail(id, code) {
  188 + var url = ctx + "inventory/adjustDetail?adjustCode=" + code;
  189 + $("#tabDetail").children().remove();
  190 + $("#myTab li").removeClass("active");
  191 + var height = $(document).height() - 100 + 'px';
  192 + var str = '<iframe class="huaheng_iframe" name="iframe" width="100%" height="' + height + '" src="' + url + '" frameborder="0" data-id="' + url + '" seamless></iframe>';
  193 + $("#tabDetail").empty();
  194 + $("#tabDetail").append(str);
  195 + $(".tab-pane").removeClass("in active");
  196 + $("#myTab li:eq(1)").addClass("active");
  197 + $("#tabDetail").addClass("in active");
  198 + }
219 199
220 - function cyclecountPrint(id) {  
221 - var url = prefix + "/report/" + id;  
222 - $.modal.open("差异单打印" , url);  
223 - } 200 + function cyclecountPrint(id) {
  201 + var url = prefix + "/report/" + id;
  202 + $.modal.open("差异单打印", url);
  203 + }
224 204
225 - function upLoad(code,sourceCode) {  
226 - $.ajax({  
227 - url:ctx+'/api/icsCyclecount/cycleCountDiff',  
228 - type:'post',  
229 - data:{  
230 - code:code,  
231 - sourceCode:sourceCode  
232 - },  
233 - success:function (res) {  
234 - if (res.code === 200) {  
235 - $.modal.msgSuccess();  
236 - }  
237 - else {  
238 - $.modal.msgError(res.msg);  
239 - } 205 +
  206 + //上传API接口
  207 + function upLoad(code, sourceCode) {
  208 + $.ajax({
  209 + url: ctx + '/api/icsCyclecount/cycleCountDiff',
  210 + type: 'post',
  211 + data: {
  212 + code: code,
  213 + sourceCode: sourceCode
  214 + },
  215 + success: function (res) {
  216 + if (res.code === 200) {
  217 + $.modal.msgSuccess();
  218 + } else {
  219 + $.modal.msgError(res.msg);
240 } 220 }
241 - })  
242 - }  
243 - </script> 221 + }
  222 + })
  223 + }
  224 +</script>
244 </body> 225 </body>
245 </html> 226 </html>
246 \ No newline at end of file 227 \ No newline at end of file
src/main/resources/templates/inventory/cyclecountAdjust/report.html renamed to src/main/resources/templates/inventory/adjustHeader/report.html
@@ -54,7 +54,7 @@ @@ -54,7 +54,7 @@
54 <script type="text/javascript" src="../../../js/barcode/JsBarcode.all.js"></script> 54 <script type="text/javascript" src="../../../js/barcode/JsBarcode.all.js"></script>
55 <script th:inline="javascript"> 55 <script th:inline="javascript">
56 56
57 - var res=[[${cyclecountAdjust.created}]]; 57 + var res=[[${adjustHeader.created}]];
58 res=res.replace("T"," "); 58 res=res.replace("T"," ");
59 res=res.substr(0,19); 59 res=res.substr(0,19);
60 $(".time_c").text(res); 60 $(".time_c").text(res);
src/main/resources/templates/inventory/cycleCountDetail/cycleCountDetail.html
@@ -6,48 +6,80 @@ @@ -6,48 +6,80 @@
6 <div class="row"> 6 <div class="row">
7 <div class="col-sm-12"> 7 <div class="col-sm-12">
8 <div class="col-sm-12 select-info"> 8 <div class="col-sm-12 select-info">
9 - <div class="select-list" th:object="${header}"> 9 + <div class="select-list">
10 <ul> 10 <ul>
11 <li> 11 <li>
12 <form id="cycleHeader-form"> 12 <form id="cycleHeader-form">
13 - 盘点单id:<input type="text" id="headId" name="headId" th:value="*{id}" readonly="readonly"> 13 + 盘点主ID:<input type="text" id="cycleCountHeadId" name="cycleCountHeadId" />
14 </form> 14 </form>
15 </li> 15 </li>
16 <li> 16 <li>
17 - 货主编码:<input id="companyCode" type="text" name="companyCode" th:value="*{companyCode}" readonly="readonly"/> 17 + 货主编码:<input id="companyCode" type="text" name="companyCode" />
18 </li> 18 </li>
19 <li> 19 <li>
20 - 盘点单编码:<input id="code" type="text" name="code" th:value="*{code}" readonly="readonly"/> 20 + 库位:<input id="locationCode" type="text" name="locationCode" />
21 </li> 21 </li>
22 <li> 22 <li>
23 - 源盘点单号:<input id="sourceCode" type="text" name="type" th:value="*{sourceCode}" readonly="readonly"> 23 + 容器:<input id="containerCode" type="text" name="containerCode" />
24 </li> 24 </li>
25 <li> 25 <li>
26 - <!--入库类型:<input type="text" name="sourceCode"/>-->  
27 - 盘点类型:<input id="type" type="text" name="type" th:value="*{typeLabel}" readonly="readonly"> 26 + 库存明细ID:<input id = "inventoryDetailId" type="text" name="inventoryDetailId" />
28 </li> 27 </li>
29 <li> 28 <li>
30 - <!--头 状 态:<input type="text" name="firstStatus"/>-->  
31 - 状态:<input id = "status" type="text" name="status" th:value="*{statusLabel}" readonly="readonly"> 29 + 物料编码:<input id="materialCode" type="text" name="materialCode" />
32 </li> 30 </li>
33 <li> 31 <li>
34 - 创建时间:<input id="created" type="text" name="created" th:value="*{created}" readonly="readonly">  
35 - 32 + 物料名称:<input id="materialName" type="text" name="materialName" />
36 </li> 33 </li>
37 <li> 34 <li>
38 - 创建人:<input id="createdBy" type="text" name="createdBy" th:value="*{createdBy}" readonly="readonly"> 35 + 物料规格:<input id="materialSpec" type="text" name="materialSpec" />
39 </li> 36 </li>
40 <li> 37 <li>
41 - 最后更新时间:<input id="lastUpdated" type="text" name="lastUpdated" th:value="*{lastUpdated}" readonly="readonly">  
42 - 38 + 任务主表:<input id="taskHeaderId" type="text" name="taskHeaderId" />
  39 + </li>
  40 + <li>
  41 + 库存状态:
  42 + <select name="inventorySts" th:with="inventoryStatus=${@dict.getType('inventoryStatus')}">
  43 + <option value="">所有</option>
  44 + <option th:each="e : ${inventoryStatus}" th:text="${e['dictLabel']}"
  45 + th:value="${e['dictValue']}"></option>
  46 + </select>
  47 + </li>
  48 + <li>
  49 + 盘点明细状态:<select name="enableStatus"
  50 + th:with="lastStatus=${@dict.getType('cyclecountStatus')}">
  51 + <option value="">所有</option>
  52 + <option th:each="e : ${lastStatus}" th:text="${e['dictLabel']}"
  53 + th:value="${e['dictValue']}"></option>
  54 + </select>
  55 + </li>
  56 + <li>
  57 + 批次:<input id="batch" type="text" name="batch" />
  58 + </li>
  59 + <li>
  60 + 批号:<input id="lot" type="text" name="lot" />
  61 + </li>
  62 + <li>
  63 + 项目号:<input id="projectNo" type="text" name="projectNo" />
  64 + </li>
  65 + <li class="time">
  66 + <label>创建时间: </label>
  67 + <input type="text" class="time-input" id="startTime" placeholder="开始时间"
  68 + name="params[createdBegin]"/>
  69 + <span>-</span>
  70 + <input type="text" class="time-input" id="endTime" placeholder="结束时间"
  71 + name="params[createdEnd]"/>
  72 + </li>
  73 + <li>
  74 + 创建人:<input id="createdBy" type="text" name="createdBy" />
  75 + </li>
  76 + <li>
  77 + 完成人:<input id="completedBy" type="text" name="completedBy"/>
43 </li> 78 </li>
44 <li> 79 <li>
45 - 最后更新人:<input id="lastUpdatedBy" type="text" name="lastUpdatedBy" th:value="*{lastUpdatedBy}" readonly="readonly"> 80 + <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
  81 + class="fa fa-search"></i>&nbsp;搜索</a>
46 </li> 82 </li>
47 - <!--<li>-->  
48 - <!--<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i-->  
49 - <!--class="fa fa-search"></i>&nbsp;搜索</a>-->  
50 - <!--</li>-->  
51 </ul> 83 </ul>
52 </div> 84 </div>
53 </div> 85 </div>
@@ -56,14 +88,6 @@ @@ -56,14 +88,6 @@
56 shiro:hasPermission="inventory:cycleCountDetail:add"> 88 shiro:hasPermission="inventory:cycleCountDetail:add">
57 <i class="fa fa-plus"></i> 新增 89 <i class="fa fa-plus"></i> 新增
58 </a> 90 </a>
59 - <!--<a class="btn btn-outline btn-danger btn-rounded" onclick="comfirmAllWithNoGapQty()"  
60 - shiro:hasPermission="inventoryHeader:cycleCountDetail:confirmAll">  
61 - <i class="fa fa-vcard"></i> 全部无差异确认  
62 - </a>  
63 - <a class="btn btn-outline btn-danger btn-rounded" onclick="comfirmRemainWithNoGapQty()"  
64 - shiro:hasPermission="inventoryHeader:cycleCountDetail:confirmRemain">  
65 - <i class="fa fa-vcard"></i> 剩余无差异确认  
66 - </a>-->  
67 <a class="btn btn-outline btn-danger btn-rounded" onclick="createCyclecountWithGapQty()" 91 <a class="btn btn-outline btn-danger btn-rounded" onclick="createCyclecountWithGapQty()"
68 shiro:hasPermission="inventory:cyclecountDetail:cyclecountRepeat"> 92 shiro:hasPermission="inventory:cyclecountDetail:cyclecountRepeat">
69 <i class="fa fa-vcard"></i> 差异复盘 93 <i class="fa fa-vcard"></i> 差异复盘
@@ -89,10 +113,10 @@ @@ -89,10 +113,10 @@
89 var removeFlag = [[${@permission.hasPermi('inventoryHeader:cycleCountDetail:remove')}]]; 113 var removeFlag = [[${@permission.hasPermi('inventoryHeader:cycleCountDetail:remove')}]];
90 var confirmFlag=[[${@permission.hasPermi('inventoryHeader:cycleCountDetail:confirm')}]]; 114 var confirmFlag=[[${@permission.hasPermi('inventoryHeader:cycleCountDetail:confirm')}]];
91 var createTaskFalg=[[${@permission.hasPermi('inventoryHeader:cycleCountDetail:createTask')}]]; 115 var createTaskFalg=[[${@permission.hasPermi('inventoryHeader:cycleCountDetail:createTask')}]];
92 - var prefix = ctx + "inventory/cyclecountDetail";  
93 - var prefix_head = ctx + "inventory/cyclecountHeader"; 116 + var prefix = ctx + "inventory/cycleCountDetail";
  117 + var prefix_head = ctx + "inventory/cycleCountHeader";
94 var remove_url= prefix + "/remove"; 118 var remove_url= prefix + "/remove";
95 - var datas = [[${@dict.getType('cyclecountDetailStatus')}]]; 119 + var datas = [[${@dict.getType('cyclecountStatus')}]];
96 var inventoryStatus=[[${@dict.getType('inventoryStatus')}]]; 120 var inventoryStatus=[[${@dict.getType('inventoryStatus')}]];
97 var created ; 121 var created ;
98 122
@@ -115,63 +139,67 @@ @@ -115,63 +139,67 @@
115 }, 139 },
116 { 140 {
117 field: 'id', 141 field: 'id',
118 - title: 'id', 142 + title: '明细ID',
119 sortable:true 143 sortable:true
120 }, 144 },
121 { 145 {
122 - field: 'code',  
123 - title: '盘点单编码',  
124 - sortable:false 146 + field: 'cycleCountHeadId',
  147 + title: '盘点主单ID',
  148 + },
  149 + {
  150 + field: 'warehouseCode',
  151 + title: '仓库',
  152 + },
  153 + {
  154 + field: 'countId',
  155 + title: '盘点内部号',
  156 + visible: false
  157 + },
  158 + {
  159 + field: 'round',
  160 + title: '盘点次数',
  161 + visible: false
  162 + },
  163 + {
  164 + field: 'taskHeaderId',
  165 + title: '任务ID',
  166 + visible: false
  167 + },
  168 + {
  169 + field: 'taskDetailId',
  170 + title: '任务明细ID',
  171 + visible: false
125 }, 172 },
126 { 173 {
127 field: 'companyCode', 174 field: 'companyCode',
128 - title: '货主' 175 + title: '货主',
  176 + visible: true
129 }, 177 },
130 - // {  
131 - // field: 'locationId',  
132 - // title: '库位id'  
133 - // },  
134 { 178 {
135 field: 'locationCode', 179 field: 'locationCode',
136 title: '库位编码', 180 title: '库位编码',
137 - sortable:true  
138 }, 181 },
139 { 182 {
140 field: 'containerCode', 183 field: 'containerCode',
141 title: '容器编号', 184 title: '容器编号',
142 - sortable:true 185 +
143 }, 186 },
144 - // {  
145 - // field: 'materialId',  
146 - // title: '物料Id'  
147 - // },  
148 - /*{ 187 + {
149 field: 'materialCode', 188 field: 'materialCode',
150 - title: '存货编码',  
151 - sortable:true  
152 - },*/ 189 + title: '物料编码',
  190 + },
153 { 191 {
154 field: 'materialName', 192 field: 'materialName',
155 title: '物料名称', 193 title: '物料名称',
156 - sortable:true  
157 }, 194 },
158 { 195 {
159 - field: 'materialSpecification', 196 + field: 'materialSpec',
160 title: '物料规格', 197 title: '物料规格',
161 - sortable:true  
162 }, 198 },
163 { 199 {
164 - field: 'receiptCode',  
165 - title: '入库单编码' 200 + field: 'materialUnit',
  201 + title: '物料单位',
166 }, 202 },
167 - // {  
168 - // field: 'receiptId',  
169 - // title: '入库单id'  
170 - // },  
171 - // {  
172 - // field: 'receiptDetailId',  
173 - // title: '入库单明细id'  
174 - // },  
175 { 203 {
176 field: 'batch', 204 field: 'batch',
177 title: '批次', 205 title: '批次',
@@ -183,25 +211,18 @@ @@ -183,25 +211,18 @@
183 sortable:true 211 sortable:true
184 }, 212 },
185 { 213 {
186 - field: 'project', 214 + field: 'projectNo',
187 title: '项目号', 215 title: '项目号',
188 sortable:true 216 sortable:true
189 }, 217 },
  218 +
190 { 219 {
191 - field: 'manufactureDate',  
192 - title: '生产日期'  
193 - },  
194 - {  
195 - field: 'expirationDate',  
196 - title: '失效日期'  
197 - },  
198 - {  
199 - field: 'inventoryStatus', 220 + field: 'inventorySts',
200 title: '库存状态', 221 title: '库存状态',
201 formatter: function(value, row, index) { 222 formatter: function(value, row, index) {
202 return $.table.selectDictLabel(inventoryStatus, value); 223 return $.table.selectDictLabel(inventoryStatus, value);
203 }, 224 },
204 - sortable:true 225 +
205 }, 226 },
206 { 227 {
207 field: 'systemQty', 228 field: 'systemQty',
@@ -216,6 +237,34 @@ @@ -216,6 +237,34 @@
216 field: 'gapQty' 237 field: 'gapQty'
217 }, 238 },
218 { 239 {
  240 + field: 'rejectionNote',
  241 + title: '失败原因'
  242 + },
  243 + {
  244 + field: 'countedBy',
  245 + title: '盘点创建人'
  246 + },
  247 + {
  248 + field: 'countedAt',
  249 + title: '盘点创建日期'
  250 + },
  251 + {
  252 + field: 'assignedTo',
  253 + title: '指派用户'
  254 + },
  255 + {
  256 + field: 'assignedAt',
  257 + title: '指派时间'
  258 + },
  259 + {
  260 + field: 'completedBy',
  261 + title: '完成用户'
  262 + },
  263 + {
  264 + field: 'completedAt',
  265 + title: '完成时间'
  266 + },
  267 + {
219 field: 'created', 268 field: 'created',
220 title: '创建时间' 269 title: '创建时间'
221 }, 270 },
@@ -232,11 +281,7 @@ @@ -232,11 +281,7 @@
232 title: '更新用户' 281 title: '更新用户'
233 }, 282 },
234 { 283 {
235 - field: 'fromSource',  
236 - title: '来源'  
237 - },  
238 - {  
239 - field: 'status', 284 + field: 'enableStatus',
240 title: '盘点明细状态', 285 title: '盘点明细状态',
241 formatter: function(value, row, index) { 286 formatter: function(value, row, index) {
242 return $.table.selectDictLabel(datas, value); 287 return $.table.selectDictLabel(datas, value);
@@ -244,9 +289,14 @@ @@ -244,9 +289,14 @@
244 sortable:true 289 sortable:true
245 }, 290 },
246 { 291 {
247 - field: 'isCreateTask',  
248 - title: '盘点任务' 292 + field: 'processStamp',
  293 + title: '处理标记'
  294 + },
  295 + {
  296 + field: 'version',
  297 + title: '数据版本'
249 }, 298 },
  299 +
250 // { 300 // {
251 // field: 'userDef1', 301 // field: 'userDef1',
252 // title: '自定义字段1' 302 // title: '自定义字段1'
@@ -280,15 +330,15 @@ @@ -280,15 +330,15 @@
280 }); 330 });
281 331
282 function update() { 332 function update() {
283 - var url = location.search; //获取url中"?"符后的字串 333 + let url = location.search; //获取url中"?"符后的字串
284 if (url.indexOf("?") != -1) { //判断是否有参数 334 if (url.indexOf("?") != -1) { //判断是否有参数
285 - var str = url.substr(1); //从第一个字符开始 因为第0个是?号 获取所有除问号的所有符串  
286 - strs = str.split("="); //用等号进行分隔 (因为知道只有一个参数 所以直接用等号进分隔 如果有多个参数 要用&号分隔 再用等号进行分隔) 335 + let str = url.substr(1); //从第一个字符开始 因为第0个是?号 获取所有除问号的所有符串
  336 + let strs = str.split("="); //用等号进行分隔 (因为知道只有一个参数 所以直接用等号进分隔 如果有多个参数 要用&号分隔 再用等号进行分隔)
287 $.ajax({ 337 $.ajax({
288 url: prefix + "/list", 338 url: prefix + "/list",
289 type:"post", 339 type:"post",
290 data:{ 340 data:{
291 - code:strs[1] 341 + cycleCountHeadId:strs[1]
292 }, 342 },
293 success:function (res) { 343 success:function (res) {
294 $("#bootstrap-table").bootstrapTable('removeAll'); 344 $("#bootstrap-table").bootstrapTable('removeAll');
@@ -297,36 +347,27 @@ @@ -297,36 +347,27 @@
297 $("#bootstrap-table").bootstrapTable('insertRow', {index:i,row:res.data[i]}); 347 $("#bootstrap-table").bootstrapTable('insertRow', {index:i,row:res.data[i]});
298 } 348 }
299 } 349 }
300 - }) 350 + });
  351 + return false
301 } 352 }
302 $.ajax({ 353 $.ajax({
303 - url:prefix_head+ "/getHeader", 354 + url: prefix + "/list",
304 type:"post", 355 type:"post",
305 - data:{  
306 - id:$('#headId').val()  
307 - },  
308 - success:function (value) {  
309 - if (value.data) {  
310 - $('#code').val(value.data.code);  
311 - $('#type').val(value.data.typeLabel);  
312 - $('#status').val(value.data.statusLabel);  
313 - $('#created').val(value.data.created);  
314 - var text_val=$('#created').val();  
315 - $('#created').val(text_val.replace("T"," "));  
316 - $('#createdBy').val(value.data.createdBy);  
317 - $('#lastUpdated').val(value.data.lastUpdated);  
318 - var text_val_t=$('#lastUpdated').val();  
319 - $('#lastUpdated').val(text_val_t.replace("T"," "));  
320 - $('#lastUpdatedBy').val(value.data.lastUpdatedBy); 356 + data:{},
  357 + success:function (res) {
  358 + $("#bootstrap-table").bootstrapTable('removeAll');
  359 + // $("#bootstrap-table").bootstrapTable('append', res.data);
  360 + for (var i = 0; i < res.data.length; i++) {
  361 + $("#bootstrap-table").bootstrapTable('insertRow', {index:i,row:res.data[i]});
321 } 362 }
322 } 363 }
323 }) 364 })
324 } 365 }
325 function add() { 366 function add() {
326 - var headId = $('#headId').val(); 367 + var cycleCountHeadId = $('#cycleCountHeadId').val();
327 var companyCode = $('#companyCode').val(); 368 var companyCode = $('#companyCode').val();
328 - if(headId !=null && headId!="" && headId!=undefined && companyCode !=null && companyCode!="" && companyCode!=undefined ){  
329 - open("添加盘点明细", prefix+"/add?headId=" + headId + "&companyCode=" + companyCode); 369 + if(cycleCountHeadId !=null && cycleCountHeadId!="" && cycleCountHeadId!=undefined && companyCode !=null && companyCode!="" && companyCode!=undefined ){
  370 + open("添加盘点明细", prefix+"/add?cycleCountHeadId=" + cycleCountHeadId + "&companyCode=" + companyCode);
330 } 371 }
331 } 372 }
332 function remove(id) { 373 function remove(id) {
@@ -351,11 +392,11 @@ @@ -351,11 +392,11 @@
351 } 392 }
352 /**盘点补货*/ 393 /**盘点补货*/
353 function addGoods() { 394 function addGoods() {
354 - var headId = $('#headId').val(); 395 + var headId = $('#cycleCountHeadId').val();
355 var companyCode = $('#companyCode').val(); 396 var companyCode = $('#companyCode').val();
356 - var code = $('#code').val(); 397 + //var code = $('#code').val();
357 // var url = prefix+"/addGoods"; 398 // var url = prefix+"/addGoods";
358 - $.modal.open("盘点补货",prefix+"/addGoods?headId=" + headId + "&companyCode=" + companyCode + "&code=" + code); 399 + $.modal.open("盘点补货",prefix+"/addGoods?headId=" + cycleCountHeadId + "&companyCode=" + companyCode );
359 } 400 }
360 // 401 //
361 402
@@ -520,7 +561,7 @@ @@ -520,7 +561,7 @@
520 function comfirmAllWithNoGapQty() { 561 function comfirmAllWithNoGapQty() {
521 $.modal.confirm("确认全部无差异登记么?注意这会覆盖先前登记的信息。", function() { 562 $.modal.confirm("确认全部无差异登记么?注意这会覆盖先前登记的信息。", function() {
522 var url = prefix + "/comfirmAllWithNoGapQty"; 563 var url = prefix + "/comfirmAllWithNoGapQty";
523 - var data = { "headId": $('#headId').val() }; 564 + var data = { "cycleCountHeadId": $('#cycleCountHeadId').val() };
524 postInner(url, data); 565 postInner(url, data);
525 }); 566 });
526 } 567 }
@@ -531,7 +572,7 @@ @@ -531,7 +572,7 @@
531 function comfirmRemainWithNoGapQty() { 572 function comfirmRemainWithNoGapQty() {
532 $.modal.confirm("确认剩余无差异登记么?", function() { 573 $.modal.confirm("确认剩余无差异登记么?", function() {
533 var url = prefix + "/comfirmRemainWithNoGapQty"; 574 var url = prefix + "/comfirmRemainWithNoGapQty";
534 - var data = { "headId": $('#headId').val() }; 575 + var data = { "cycleCountHeadId": $('#cycleCountHeadId').val() };
535 postInner(url, data); 576 postInner(url, data);
536 }); 577 });
537 } 578 }
@@ -549,7 +590,7 @@ @@ -549,7 +590,7 @@
549 function createCyclecountWithGapQty() { 590 function createCyclecountWithGapQty() {
550 $.modal.confirm("确认进行差异复盘么?该操作会将有差异的明细重新生成一个新的盘点单。", function() { 591 $.modal.confirm("确认进行差异复盘么?该操作会将有差异的明细重新生成一个新的盘点单。", function() {
551 var url = prefix + "/createCyclecountWithGapQty"; 592 var url = prefix + "/createCyclecountWithGapQty";
552 - var data = { "headId": $('#headId').val() }; 593 + var data = { "cycleCountHeadId": $('#cycleCountHeadId').val() };
553 postInner(url, data); 594 postInner(url, data);
554 }); 595 });
555 } 596 }
@@ -558,7 +599,7 @@ @@ -558,7 +599,7 @@
558 function adjust() { 599 function adjust() {
559 $.modal.confirm("注意:该操作将更改库存,当实盘数量为0且库位上只剩空容器时,请手动执行空托出库任务,容器上有货则无需其他操作!", function() { 600 $.modal.confirm("注意:该操作将更改库存,当实盘数量为0且库位上只剩空容器时,请手动执行空托出库任务,容器上有货则无需其他操作!", function() {
560 var url = prefix + "/adjust"; 601 var url = prefix + "/adjust";
561 - var data = { "headId": $('#headId').val() }; 602 + var data = { "cycleCountHeadId": $('#cycleCountHeadId').val() };
562 postInner(url,data); 603 postInner(url,data);
563 }); 604 });
564 } 605 }
@@ -592,7 +633,7 @@ @@ -592,7 +633,7 @@
592 function outcheckAll() { 633 function outcheckAll() {
593 $.modal.confirm("确认进行盘点任务生成么?注意,这将会使未生成盘点任务的明细生成盘点任务!", function() { 634 $.modal.confirm("确认进行盘点任务生成么?注意,这将会使未生成盘点任务的明细生成盘点任务!", function() {
594 var url = prefix + "/createCyccountTaskByHeadId"; 635 var url = prefix + "/createCyccountTaskByHeadId";
595 - var data = { "headId": $('#headId').val() }; 636 + var data = { "cycleCountHeadId": $('#cycleCountHeadId').val() };
596 postInner(url,data); 637 postInner(url,data);
597 }); 638 });
598 } 639 }
src/main/resources/templates/inventory/cycleCountHeader/cycleCountHeader.html
@@ -25,14 +25,19 @@ @@ -25,14 +25,19 @@
25 <div class="select-list"> 25 <div class="select-list">
26 <ul> 26 <ul>
27 <li> 27 <li>
28 - 盘点单号:<input type="text" name="code"/> 28 + 盘点主单ID:<input type="text" name="id"/>
29 </li> 29 </li>
30 <li> 30 <li>
31 源盘点单号:<input type="text" name="sourceCode"/> 31 源盘点单号:<input type="text" name="sourceCode"/>
32 </li> 32 </li>
33 <li> 33 <li>
34 - <!--头 状 态:<input type="text" name="firstStatus"/>-->  
35 - 盘点单类型:<select name="type" 34 + 盘点主表编号:<input type="text" name="masterCode"/>
  35 + </li>
  36 + <li>
  37 + 原始盘点ID:<input type="text" name="countOrderId"/>
  38 + </li>
  39 + <li>
  40 + 盘点单类型:<select name="countType"
36 th:with="firstStatus=${@dict.getType('cyclecountType')}"> 41 th:with="firstStatus=${@dict.getType('cyclecountType')}">
37 <option value="">所有</option> 42 <option value="">所有</option>
38 <option th:each="e : ${firstStatus}" th:text="${e['dictLabel']}" 43 <option th:each="e : ${firstStatus}" th:text="${e['dictLabel']}"
@@ -40,8 +45,7 @@ @@ -40,8 +45,7 @@
40 </select> 45 </select>
41 </li> 46 </li>
42 <li> 47 <li>
43 - <!--尾 状 态:<input type="text" name="lastStatus"/>-->  
44 - 盘点单状态:<select name="status" 48 + 盘点单状态:<select name="statusCyc"
45 th:with="lastStatus=${@dict.getType('cyclecountStatus')}"> 49 th:with="lastStatus=${@dict.getType('cyclecountStatus')}">
46 <option value="">所有</option> 50 <option value="">所有</option>
47 <option th:each="e : ${lastStatus}" th:text="${e['dictLabel']}" 51 <option th:each="e : ${lastStatus}" th:text="${e['dictLabel']}"
@@ -270,15 +274,18 @@ @@ -270,15 +274,18 @@
270 }] 274 }]
271 }; 275 };
272 $.table.init(options); 276 $.table.init(options);
273 - $("#myTab li:eq(1)").one('click', (function () {  
274 - var cyc_id = $("#bootstrap-table tr:eq(1) td:eq(1)").text();  
275 - var cyc_code = $("#bootstrap-table tr:eq(1) td:eq(2)").text();  
276 - detail(cyc_id, cyc_code);  
277 - })); 277 + $("#myTab li:eq(1)").click(function () {
  278 + // var cyc_id = $("#bootstrap-table tr:eq(1) td:eq(1)").text();
  279 + // var cyc_code = $("#bootstrap-table tr:eq(1) td:eq(2)").text();
  280 + detail();
  281 + });
278 }); 282 });
279 283
280 - function detail(id, code) {  
281 - var url = ctx + "inventory/cycleCountDetail?code=" + code; 284 + function detail(id) {
  285 + let url = ctx + "inventory/cycleCountDetail";
  286 + if (id) {
  287 + url = ctx + "inventory/cycleCountDetail?id=" + id;
  288 + }
282 $("#tabDetail").children().remove(); 289 $("#tabDetail").children().remove();
283 $("#myTab li").removeClass("active"); 290 $("#myTab li").removeClass("active");
284 var height = $(document).height() - 100 + 'px'; 291 var height = $(document).height() - 100 + 'px';
src/main/resources/templates/inventory/inventoryHeader/inventoryHeader.html
@@ -73,7 +73,7 @@ @@ -73,7 +73,7 @@
73 <div th:include="include :: footer"></div> 73 <div th:include="include :: footer"></div>
74 <script th:inline="javascript"> 74 <script th:inline="javascript">
75 var prefix = ctx + "inventory/inventoryHeader"; 75 var prefix = ctx + "inventory/inventoryHeader";
76 - var report = [[${@permission.hasPermi('inventoryHeader:cyclecountAdjust:report')}]]; 76 + var report = [[${@permission.hasPermi('inventoryHeader:adjustHeader:report')}]];
77 var datas = [[${@dict.getType('sys_normal_disable')}]]; 77 var datas = [[${@dict.getType('sys_normal_disable')}]];
78 var status2 = [[${@dict.getType('adjustType')}]]; 78 var status2 = [[${@dict.getType('adjustType')}]];
79 79
src/main/resources/templates/inventory/inventoryTransaction/inventoryTransaction.html
@@ -274,10 +274,6 @@ @@ -274,10 +274,6 @@
274 visible:false 274 visible:false
275 }, 275 },
276 { 276 {
277 - field : 'lastCycleCountDate',  
278 - title : '上次盘点日期'  
279 - },  
280 - {  
281 field : 'processStamp', 277 field : 'processStamp',
282 title : '处理标记', 278 title : '处理标记',
283 visible:false 279 visible:false
src/main/resources/templates/login.html
@@ -74,11 +74,11 @@ @@ -74,11 +74,11 @@
74 </select> 74 </select>
75 </div> 75 </div>
76 </div> 76 </div>
77 - <!--<div class="row" style="padding:0 10px;">-->  
78 - <!--<div class="col-lg-3"></div>-->  
79 - <!--<div class="col-lg-9" style="padding:10px 0 0 5px;"><input class="i-checks" type="checkbox" name="rememberme" style="background: #fff"/>&nbsp;&nbsp;记住我-->  
80 - <!--</div>-->  
81 - <!--</div>--> 77 + <div class="row" style="padding:0 10px;">
  78 + <div class="col-lg-3"></div>
  79 + <div class="col-lg-9" style="padding:10px 0 0 5px;"><input class="i-checks" type="checkbox" name="rememberme" style="background: #fff"/>&nbsp;&nbsp;记住我
  80 + </div>
  81 + </div>
82 <button style="margin-top: 20px" class="btn btn-success btn-block" id="btnSubmit" data-loading="正在验证登录,请稍后...">登录</button> 82 <button style="margin-top: 20px" class="btn btn-success btn-block" id="btnSubmit" data-loading="正在验证登录,请稍后...">登录</button>
83 </form> 83 </form>
84 </div> 84 </div>
src/main/resources/templates/receipt/receiptDetail/add.html
@@ -18,12 +18,6 @@ @@ -18,12 +18,6 @@
18 <input id="receiptCode" name="receiptCode" class="form-control" type="text" th:value="${receiptCode}" readonly="readonly"> 18 <input id="receiptCode" name="receiptCode" class="form-control" type="text" th:value="${receiptCode}" readonly="readonly">
19 </div> 19 </div>
20 </div> 20 </div>
21 -<!-- <div class="form-group">-->  
22 -<!-- <label class="col-sm-3 control-label">上游系统行号:</label>-->  
23 -<!-- <div class="col-sm-8">-->  
24 -<!-- <input id="sourceLine" name="sourceLine" class="form-control" type="text" onkeyup=" this.value=this.value.replace(/^\s+|\s+$/g,'')">-->  
25 -<!-- </div>-->  
26 -<!-- </div>-->  
27 <div class="form-group"> 21 <div class="form-group">
28 <label class="col-sm-3 control-label">物料编码:</label> 22 <label class="col-sm-3 control-label">物料编码:</label>
29 <div class="col-sm-8"> 23 <div class="col-sm-8">
@@ -52,7 +46,7 @@ @@ -52,7 +46,7 @@
52 <div class="form-group"> 46 <div class="form-group">
53 <label class="col-sm-3 control-label">项目号:</label> 47 <label class="col-sm-3 control-label">项目号:</label>
54 <div class="col-sm-8"> 48 <div class="col-sm-8">
55 - <input id="project" name="project" class="form-control" type="text"> 49 + <input id="projectNo" name="projectNo" class="form-control" type="text">
56 </div> 50 </div>
57 </div> 51 </div>
58 <div class="form-group"> 52 <div class="form-group">
@@ -76,7 +70,7 @@ @@ -76,7 +70,7 @@
76 <div class="form-group"> 70 <div class="form-group">
77 <label class="col-sm-3 control-label">库存状态:</label> 71 <label class="col-sm-3 control-label">库存状态:</label>
78 <div class="col-sm-8"> 72 <div class="col-sm-8">
79 - <select id="inventoryStatus" name="inventoryStatus" class="form-control" th:with="inventoryStatus=${@dict.getType('inventoryStatus')}"> 73 + <select id="inventorySts" name="inventorySts" class="form-control" th:with="inventoryStatus=${@dict.getType('inventoryStatus')}">
80 <option th:each="dict : ${inventoryStatus}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}"></option> 74 <option th:each="dict : ${inventoryStatus}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}"></option>
81 </select> 75 </select>
82 </div> 76 </div>
@@ -148,8 +142,7 @@ @@ -148,8 +142,7 @@
148 }, 142 },
149 submitHandler: function(form) { 143 submitHandler: function(form) {
150 var tableValue = $("#form-receiptDetail-add").serialize(); 144 var tableValue = $("#form-receiptDetail-add").serialize();
151 - tableValue = formValueReplace(tableValue, "companyCode", $("#companyCode option:selected").val())  
152 - tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked')); 145 + tableValue = formValueReplace(tableValue, "inventorySts", $("#inventorySts option:selected").val());
153 $.operate.save(prefix + "/add", tableValue); 146 $.operate.save(prefix + "/add", tableValue);
154 } 147 }
155 }); 148 });
src/main/resources/templates/receipt/receiptDetail/edit.html
@@ -3,142 +3,132 @@ @@ -3,142 +3,132 @@
3 <meta charset="utf-8"> 3 <meta charset="utf-8">
4 <head th:include="include :: header"></head> 4 <head th:include="include :: header"></head>
5 <body class="white-bg"> 5 <body class="white-bg">
6 - <div class="wrapper wrapper-content animated fadeInRight ibox-content">  
7 - <form class="form-horizontal m" id="form-receiptDetail-edit" th:object="${receiptDetail}">  
8 - <input id="id" name="id" th:field="*{id}" type="hidden">  
9 - <div class="form-group">  
10 - <label class="col-sm-3 control-label">上游系统行号:</label>  
11 - <div class="col-sm-8">  
12 - <input id="sourceLine" name="sourceLine" th:field="*{sourceLine}" class="form-control" type="text">  
13 - </div>  
14 - </div>  
15 - <div class="form-group">  
16 - <label class="col-sm-3 control-label">入库单id:</label>  
17 - <div class="col-sm-8">  
18 - <input id="receiptId" name="receiptId" th:field="*{receiptId}" class="form-control" type="text" readonly="readonly" >  
19 - </div>  
20 - </div>  
21 - <div class="form-group">  
22 - <label class="col-sm-3 control-label">入库单编码:</label>  
23 - <div class="col-sm-8">  
24 - <input id="receiptCode" name="receiptCode" th:field="*{receiptCode}" class="form-control" type="text" readonly="readonly" >  
25 - </div>  
26 - </div>  
27 - <div class="form-group">  
28 - <label class="col-sm-3 control-label">存货编码:</label>  
29 - <div class="col-sm-8">  
30 - <input id="materialCode" name="materialCode" th:field="*{materialCode}" class="form-control" type="text">  
31 - </div>  
32 - </div>  
33 - <div class="form-group">  
34 - <label class="col-sm-3 control-label">批次:</label>  
35 - <div class="col-sm-8">  
36 - <input id="batch" name="batch" th:field="*{batch}" class="form-control" type="text">  
37 - </div>  
38 - </div>  
39 - <div class="form-group">  
40 - <label class="col-sm-3 control-label">批号:</label>  
41 - <div class="col-sm-8">  
42 - <input id="lot" name="lot" th:field="*{lot}" class="form-control" type="text">  
43 - </div>  
44 - </div>  
45 - <div class="form-group">  
46 - <label class="col-sm-3 control-label">项目号:</label>  
47 - <div class="col-sm-8">  
48 - <input id="project" name="project" th:field="*{project}" class="form-control" type="text">  
49 - </div>  
50 - </div>  
51 - <div class="form-group">  
52 - <label class="col-sm-3 control-label">生产日期:</label>  
53 - <div class="col-sm-8">  
54 - <input id="manufactureDate" name="manufactureDate" th:field="*{manufactureDate}" class="form-control" type="text">  
55 - </div>  
56 - </div>  
57 - <div class="form-group">  
58 - <label class="col-sm-3 control-label">失效日期:</label>  
59 - <div class="col-sm-8">  
60 - <input id="expirationDate" name="expirationDate" th:field="*{expirationDate}" class="form-control" type="text">  
61 - </div>  
62 - </div>  
63 - <div class="form-group">  
64 - <label class="col-sm-3 control-label">库存状态:</label>  
65 - <div class="col-sm-8">  
66 - <select id="inventoryStatus" name="inventoryStatus" class="form-control" th:with="inventoryStatus=${@dict.getType('inventoryStatus')}" th:field="*{inventoryStatus}">  
67 - <option th:each="dict : ${inventoryStatus}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}"></option>  
68 - </select>  
69 - </div>  
70 - </div>  
71 - <div class="form-group">  
72 - <label class="col-sm-3 control-label">数量:</label>  
73 - <div class="col-sm-8">  
74 - <input id="qty" name="qty" th:field="*{qty}" class="form-control" type="text">  
75 - </div>  
76 - </div>  
77 - <div class="form-group">  
78 - <label class="col-sm-3 control-label">已收数量:</label>  
79 - <div class="col-sm-8">  
80 - <input id="qtyCompleted" name="qtyCompleted" th:field="*{qtyCompleted}" class="form-control" type="text" readonly="readonly">  
81 - </div>  
82 - </div>  
83 - <div class="form-group">  
84 - <label class="col-sm-3 control-label">单价:</label>  
85 - <div class="col-sm-8">  
86 - <input id="price" name="price" th:field="*{price}" class="form-control" type="text">  
87 - </div>  
88 - </div>  
89 - <!--<div class="form-group"> -->  
90 - <!--<label class="col-sm-3 control-label">创建时间:</label>-->  
91 - <!--<div class="col-sm-8">-->  
92 - <!--<input id="created" name="created" th:field="*{created}" class="form-control" type="text">-->  
93 - <!--</div>-->  
94 - <!--</div>-->  
95 - <!--<div class="form-group"> -->  
96 - <!--<label class="col-sm-3 control-label">创建用户:</label>-->  
97 - <!--<div class="col-sm-8">-->  
98 - <!--<input id="createdBy" name="createdBy" th:field="*{createdBy}" class="form-control" type="text">-->  
99 - <!--</div>-->  
100 - <!--</div>-->  
101 - <!--<div class="form-group"> -->  
102 - <!--<label class="col-sm-3 control-label">最后修改时间:</label>-->  
103 - <!--<div class="col-sm-8">-->  
104 - <!--<input id="lastUpdated" name="lastUpdated" th:field="*{lastUpdated}" class="form-control" type="text">-->  
105 - <!--</div>-->  
106 - <!--</div>-->  
107 - <!--<div class="form-group"> -->  
108 - <!--<label class="col-sm-3 control-label">更新用户:</label>-->  
109 - <!--<div class="col-sm-8">-->  
110 - <!--<input id="lastUpdatedBy" name="lastUpdatedBy" th:field="*{lastUpdatedBy}" class="form-control" type="text">-->  
111 - <!--</div>-->  
112 - <!--</div>-->  
113 - <!--<div class="form-group"> -->  
114 - <!--<label class="col-sm-3 control-label">自定义字段1:</label>-->  
115 - <!--<div class="col-sm-8">-->  
116 - <!--<input id="userDef1" name="userDef1" th:field="*{userDef1}" class="form-control" type="text">-->  
117 - <!--</div>-->  
118 - <!--</div>-->  
119 - <!--<div class="form-group"> -->  
120 - <!--<label class="col-sm-3 control-label">自定义字段2:</label>-->  
121 - <!--<div class="col-sm-8">-->  
122 - <!--<input id="userDef2" name="userDef2" th:field="*{userDef2}" class="form-control" type="text">-->  
123 - <!--</div>-->  
124 - <!--</div>-->  
125 - <!--<div class="form-group"> -->  
126 - <!--<label class="col-sm-3 control-label">自定义字段3:</label>-->  
127 - <!--<div class="col-sm-8">-->  
128 - <!--<input id="userDef3" name="userDef3" th:field="*{userDef3}" class="form-control" type="text">-->  
129 - <!--</div>-->  
130 - <!--</div>-->  
131 - <div class="form-group">  
132 - <div class="form-control-static col-sm-offset-9">  
133 - <button type="submit" class="btn btn-primary">提交</button>  
134 - <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>  
135 - </div>  
136 - </div>  
137 - </form>  
138 - </div>  
139 - <div th:include="include::footer"></div>  
140 -</body>  
141 -<script> 6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-receiptDetail-edit" th:object="${receiptDetail}">
  8 + <input id="id" name="id" hidden th:field="*{id}">
  9 + <div class="form-group">
  10 + <label class="col-sm-3 control-label">入库单id:</label>
  11 + <div class="col-sm-8">
  12 + <input id="receiptId" name="receiptId" class="form-control" type="text" th:value="${receiptId}" readonly="readonly" th:field="*{receiptId}">
  13 + <input id="companyCode" name="companyCode" type="hidden" th:value="${companyCode}" th:field="*{companyCode}">
  14 + </div>
  15 + </div>
  16 + <div class="form-group">
  17 + <label class="col-sm-3 control-label">入库单号:</label>
  18 + <div class="col-sm-8">
  19 + <input id="receiptCode" name="receiptCode" class="form-control" type="text" th:value="${receiptCode}" readonly="readonly" th:field="*{receiptCode}">
  20 + </div>
  21 + </div>
  22 + <div class="form-group">
  23 + <label class="col-sm-3 control-label">物料编码:</label>
  24 + <div class="col-sm-8">
  25 + <input id="materialCode" name="materialCode" class="form-control" type="text" onkeyup=" this.value=this.value.replace(/^\s+|\s+$/g,'')" th:field="*{materialCode}">
  26 + </div>
  27 + </div>
  28 + <div class="form-group">
  29 + <label class="col-sm-3 control-label">供应商编码:</label>
  30 + <div class="col-sm-8">
  31 + <input id="supplierCode" name="supplierCode" class="form-control" type="text" th:field="*{supplierCode}">
  32 + </div>
  33 + </div>
  34 + <div class="form-group">
  35 + <label class="col-sm-3 control-label">批次:</label>
  36 + <div class="col-sm-8">
  37 + <input id="batch" name="batch" class="form-control" type="text" th:field="*{batch}">
  38 + </div>
  39 + </div>
  40 +
  41 + <div class="form-group">
  42 + <label class="col-sm-3 control-label">批号:</label>
  43 + <div class="col-sm-8">
  44 + <input id="lot" name="lot" class="form-control" type="text" th:field="*{lot}">
  45 + </div>
  46 + </div>
  47 + <div class="form-group">
  48 + <label class="col-sm-3 control-label">项目号:</label>
  49 + <div class="col-sm-8">
  50 + <input id="projectNo" name="projectNo" class="form-control" type="text" th:field="*{projectNo}">
  51 + </div>
  52 + </div>
  53 + <div class="form-group">
  54 + <label class="col-sm-3 control-label">是否质检:</label>
  55 + <div class="col-sm-8">
  56 + <input id="qcCheck" name="qcCheck" class="form-control" type="text" th:field="*{qcCheck}">
  57 + </div>
  58 + </div>
  59 + <div class="form-group">
  60 + <label class="col-sm-3 control-label">生产日期:</label>
  61 + <div class="col-sm-8">
  62 + <input id="manufactureDate" name="manufactureDate" class="form-control" type="text" th:field="*{manufactureDate}">
  63 + </div>
  64 + </div>
  65 + <div class="form-group">
  66 + <label class="col-sm-3 control-label">失效日期:</label>
  67 + <div class="col-sm-8">
  68 + <input id="expirationDate" name="expirationDate" class="form-control" type="text" th:field="*{expirationDate}">
  69 + </div>
  70 + </div>
  71 + <div class="form-group">
  72 + <label class="col-sm-3 control-label">库存状态:</label>
  73 + <div class="col-sm-8">
  74 + <select id="inventorySts" name="inventorySts" class="form-control"
  75 + th:with="inventoryStatus=${@dict.getType('inventoryStatus')}" th:field="*{inventorySts}">
  76 + <option th:each="dict : ${inventoryStatus}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}"></option>
  77 + </select>
  78 + </div>
  79 + </div>
  80 + <div class="form-group">
  81 + <label class="col-sm-3 control-label">总数量:</label>
  82 + <div class="col-sm-8">
  83 + <input id="totalQty" name="totalQty" class="form-control" type="text" th:field="*{totalQty}">
  84 + </div>
  85 + </div>
  86 + <div class="form-group">
  87 + <label class="col-sm-3 control-label">定位规则:</label>
  88 + <div class="col-sm-8">
  89 + <input id="locatingRule" name="locatingRule" class="form-control" type="text" th:field="*{locatingRule}">
  90 + </div>
  91 + </div>
  92 + <div class="form-group">
  93 + <label class="col-sm-3 control-label">标价:</label>
  94 + <div class="col-sm-8">
  95 + <input id="itemListPrice" name="itemListPrice" class="form-control" type="text" th:field="*{itemListPrice}">
  96 + </div>
  97 + </div>
  98 + <div class="form-group">
  99 + <label class="col-sm-3 control-label">净价:</label>
  100 + <div class="col-sm-8">
  101 + <input id="itemNetPrice" name="itemNetPrice" class="form-control" type="text" th:field="*{itemNetPrice}">
  102 + </div>
  103 + </div>
  104 + <!--<div class="form-group">-->
  105 + <!--<label class="col-sm-3 control-label">自定义字段1:</label>-->
  106 + <!--<div class="col-sm-8">-->
  107 + <!--<input id="userDef1" name="userDef1" class="form-control" type="text">-->
  108 + <!--</div>-->
  109 + <!--</div>-->
  110 + <!--<div class="form-group"> -->
  111 + <!--<label class="col-sm-3 control-label">自定义字段2:</label>-->
  112 + <!--<div class="col-sm-8">-->
  113 + <!--<input id="userDef2" name="userDef2" class="form-control" type="text">-->
  114 + <!--</div>-->
  115 + <!--</div>-->
  116 + <!--<div class="form-group"> -->
  117 + <!--<label class="col-sm-3 control-label">自定义字段3:</label>-->
  118 + <!--<div class="col-sm-8">-->
  119 + <!--<input id="userDef3" name="userDef3" class="form-control" type="text">-->
  120 + <!--</div>-->
  121 + <!--</div>-->
  122 + <div class="form-group">
  123 + <div class="form-control-static col-sm-offset-9">
  124 + <button type="submit" class="btn btn-primary">提交</button>
  125 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
  126 + </div>
  127 + </div>
  128 + </form>
  129 +</div>
  130 +<div th:include="include::footer"></div>
  131 +<script type="text/javascript">
142 var prefix = ctx + "receipt/receiptDetail"; 132 var prefix = ctx + "receipt/receiptDetail";
143 $("#form-receiptDetail-edit").validate({ 133 $("#form-receiptDetail-edit").validate({
144 rules:{ 134 rules:{
@@ -151,70 +141,14 @@ @@ -151,70 +141,14 @@
151 materialCode:{ 141 materialCode:{
152 required:true 142 required:true
153 }, 143 },
154 - sourceLine:{  
155 - required:false,  
156 - digits:true  
157 - },  
158 - qty:{  
159 - required:true,  
160 - min:0  
161 - },  
162 - price:{  
163 - required:false,  
164 - min:0  
165 - }  
166 }, 144 },
167 submitHandler: function(form) { 145 submitHandler: function(form) {
168 - $.ajax({  
169 - cache : true,  
170 - type : "POST",  
171 - url : prefix + "/edit",  
172 - data : {  
173 - "id": $("input[name='id']").val(),  
174 - "receiptId": $("input[name='receiptId']").val(),  
175 - "receiptCode": $("input[name='receiptCode']").val(),  
176 - "sourceLine": $("input[name='sourceLine']").val(),  
177 - // "materialId": $("input[name='materialId']").val(),  
178 - "materialCode": $("input[name='materialCode']").val(),  
179 - "batch": $("input[name='batch']").val(),  
180 - "lot": $("input[name='lot']").val(),  
181 - "project": $("input[name='project']").val(),  
182 - "manufactureDate": $("input[name='manufactureDate']").val(),  
183 - "expirationDate": $("input[name='expirationDate']").val(),  
184 - "inventoryStatus": $("#inventoryStatus option:selected").val(),  
185 - "qty": $("input[name='qty']").val(),  
186 - "price": $("input[name='price']").val()  
187 - // "userDef1": $("input[name='userDef1']").val(),  
188 - // "userDef2": $("input[name='userDef2']").val(),  
189 - // "userDef3": $("input[name='userDef3']").val()  
190 - },  
191 - async : false,  
192 - error : function(request) {  
193 - $.modal.alertError("请求失败!");  
194 - },  
195 - success : function(data) {  
196 - // $.operate.saveSuccess(data);  
197 - // console.log(data);  
198 - ajaxSuccess(data);  
199 - }  
200 - }); 146 + var tableValue = $("#form-receiptDetail-edit").serialize();
  147 + tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));
  148 + $.operate.save(prefix + "/edit", tableValue);
201 } 149 }
202 }); 150 });
203 151
204 - function ajaxSuccess(result) {  
205 - if (result.code == web_status.SUCCESS) {  
206 - $.modal.msgSuccess(result.msg);  
207 - var index = parent.layer.getFrameIndex(window.name);  
208 - parent.layer.close(index);  
209 - window.parent.loadDetail(id,code);  
210 - } else {  
211 - $.modal.alertError(result.msg);  
212 - }  
213 - $.modal.closeLoading();  
214 - }  
215 -  
216 - var id=$("input[name='receiptId']").val();  
217 - var code=$("input[name='receiptCode']").val();  
218 $(function () { 152 $(function () {
219 layui.use('laydate', function() { 153 layui.use('laydate', function() {
220 var laydate = layui.laydate; 154 var laydate = layui.laydate;
@@ -223,6 +157,6 @@ @@ -223,6 +157,6 @@
223 }); 157 });
224 }); 158 });
225 159
226 -  
227 </script> 160 </script>
  161 +</body>
228 </html> 162 </html>
src/main/resources/templates/receipt/receiptDetail/receiptDetail.html
@@ -51,6 +51,7 @@ @@ -51,6 +51,7 @@
51 <script th:inline="javascript"> 51 <script th:inline="javascript">
52 var editFlag = [[${@permission.hasPermi('receipt:receiptDetail:edit')}]]; 52 var editFlag = [[${@permission.hasPermi('receipt:receiptDetail:edit')}]];
53 var removeFlag = [[${@permission.hasPermi('receipt:receiptDetail:remove')}]]; 53 var removeFlag = [[${@permission.hasPermi('receipt:receiptDetail:remove')}]];
  54 + var approvalFlag = [[${@permission.hasPermi('receipt:receiptHeader:approval')}]]
54 var prefix = ctx + "receipt/receiptDetail"; 55 var prefix = ctx + "receipt/receiptDetail";
55 var datas = [[${@dict.getType('isVirtualBom')}]]; 56 var datas = [[${@dict.getType('isVirtualBom')}]];
56 $(function() { 57 $(function() {
@@ -218,6 +219,11 @@ @@ -218,6 +219,11 @@
218 align: 'center', 219 align: 'center',
219 formatter: function(value, row, index) { 220 formatter: function(value, row, index) {
220 var actions = []; 221 var actions = [];
  222 + if (row.processStamp == 5){
  223 + actions.push('<a class="btn btn-success btn-xs ' + approvalFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')">审核通过</a> ');
  224 + actions.push('<a class="btn btn-warning btn-xs ' + approvalFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')">驳回</a>');
  225 + actions.push('<a class="btn btn-danger btn-xs ' + approvalFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')">作废</a>');
  226 + }
221 actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> '); 227 actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="#" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
222 actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a>'); 228 actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="#" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-trash-o"></i>删除</a>');
223 return actions.join(''); 229 return actions.join('');
src/main/resources/templates/receipt/receiptHeader/add.html
@@ -64,7 +64,7 @@ @@ -64,7 +64,7 @@
64 url : prefix + "/add", 64 url : prefix + "/add",
65 data : { 65 data : {
66 "receiptType": $("#receiptType option:selected").val(), 66 "receiptType": $("#receiptType option:selected").val(),
67 - "companyCode": $("#company option:selected").attr("code"), 67 + "companyCode": $("#company option:selected").val(),
68 "receiptNote": $("input[name='receiptNote']").val(), 68 "receiptNote": $("input[name='receiptNote']").val(),
69 "scheduledArriveDate": $("input[name='scheduledArriveDate']").val(), 69 "scheduledArriveDate": $("input[name='scheduledArriveDate']").val(),
70 }, 70 },
src/main/resources/templates/receipt/receiptHeader/edit.html
@@ -2,196 +2,93 @@ @@ -2,196 +2,93 @@
2 <html lang="zh" xmlns:th="http://www.thymeleaf.org"> 2 <html lang="zh" xmlns:th="http://www.thymeleaf.org">
3 <meta charset="utf-8"> 3 <meta charset="utf-8">
4 <head th:include="include :: header"></head> 4 <head th:include="include :: header"></head>
5 -  
6 <body class="white-bg"> 5 <body class="white-bg">
7 - <div class="wrapper wrapper-content animated fadeInRight ibox-content">  
8 - <form class="form-horizontal m" id="form-receiptHeader-edit" th:object="${receiptHeader}">  
9 - <input id="id" name="id" th:field="*{id}" type="hidden">  
10 - <div class="form-group">  
11 - <label class="col-sm-3 control-label">入库单号:</label>  
12 - <div class="col-sm-8">  
13 - <input id="code" name="code" th:field="*{code}" class="form-control" type="text" readonly="readonly">  
14 - </div>  
15 - </div>  
16 - <div class="form-group">  
17 - <label class="col-sm-3 control-label">货主:</label>  
18 - <div class="col-sm-8">  
19 - <select id="company" name="company" class="form-control" th:with="list=${@company.selectCompanyByCurrentUserId()}" th:field="*{companyId}" readonly="true" disabled="disabled">  
20 - <option th:each="item : ${list}" th:text="${item['name']}" th:value="${item['id']}" th:attr="code = ${item['code']}"></option>  
21 - </select>  
22 - </div>  
23 - </div>  
24 - <div class="form-group">  
25 - <label class="col-sm-3 control-label">入库类型:</label>  
26 - <div class="col-sm-8">  
27 - <select id="type" name="type" class="form-control" th:with="receiptHeaderType=${@receiptTypeService.getType()}" th:field="*{receiptType}">  
28 - <option th:each="dict : ${receiptHeaderType}" th:text="${dict['name']}" th:value="${dict['code']}"></option>  
29 - </select>  
30 - </div>  
31 - </div>  
32 - <div class="form-group">  
33 - <label class="col-sm-3 control-label">上游系统单号:</label>  
34 - <div class="col-sm-8">  
35 - <input id="sourceCode" name="sourceCode" th:field="*{sourceCode}" class="form-control" type="text">  
36 - </div> 6 +<div class="wrapper wrapper-content animated fadeInRight ibox-content">
  7 + <form class="form-horizontal m" id="form-receiptHeader-edit" th:object="${receiptHeader}">
  8 + <input id="id" name="id" type="hidden" th:field="*{id}">
  9 + <div class="form-group">
  10 + <label class="col-sm-3 control-label">入库类型:</label>
  11 + <div class="col-sm-8">
  12 + <select id="receiptType" name="receiptType" class="form-control"
  13 + th:with="receiptHeaderType=${@receiptTypeService.getType()}" th:field="*{receiptType}">
  14 + <option th:each="dict : ${receiptHeaderType}" th:text="${dict['name']}" th:value="${dict['code']}"></option>
  15 + </select>
37 </div> 16 </div>
38 - <div class="form-group">  
39 - <label class="col-sm-3 control-label">上游平台:</label>  
40 - <div class="col-sm-8">  
41 - <input id="sourcePlatform" name="sourcePlatform" th:field="*{sourcePlatform}" class="form-control" type="text">  
42 - </div> 17 + </div>
  18 + <div class="form-group">
  19 + <label class="col-sm-3 control-label">货主:</label>
  20 + <div class="col-sm-8">
  21 + <select id="companyCode" name="companyCode" class="form-control" th:with="list=${@companyService.getCode()}" th:field="*{companyCode}">
  22 + <option th:each="item : ${list}" th:text="${item['name']}" th:value="${item['id']}" th:attr = " code = ${item['code']}"></option>
  23 + </select>
43 </div> 24 </div>
44 - <div class="form-group">  
45 - <label class="col-sm-3 control-label">供应商编码:</label>  
46 - <div class="col-sm-8">  
47 - <select id="supplierCode" name="supplierCode" class="form-control" th:with="supplier=${@Supplier.getSupplierCode()}" th:field="*{supplierCode}">  
48 - <option th:each="dict : ${supplier}" th:text="${dict['name']}" th:value="${dict['code']}"></option>  
49 - </select>  
50 - </div> 25 + </div>
  26 + <div class="form-group">
  27 + <label class="col-sm-3 control-label">入库单备注:</label>
  28 + <div class="col-sm-8">
  29 + <input id="receiptNote" name="receiptNote" class="form-control" type="text" th:field="*{receiptType}">
51 </div> 30 </div>
52 - <!--<div class="form-group">-->  
53 - <!--<label class="col-sm-3 control-label">总数量:</label>-->  
54 - <!--<div class="col-sm-8">-->  
55 - <!--<input id="totalQty" name="totalQty" th:field="*{totalQty}" class="form-control" type="text">-->  
56 - <!--</div>-->  
57 - <!--</div>-->  
58 - <!--<div class="form-group"> -->  
59 - <!--<label class="col-sm-3 control-label">总行数:</label>-->  
60 - <!--<div class="col-sm-8">-->  
61 - <!--<input id="totalLines" name="totalLines" th:field="*{totalLines}" class="form-control" type="text">-->  
62 - <!--</div>-->  
63 - <!--</div>-->  
64 - <div class="form-group">  
65 - <label class="col-sm-3 control-label">入库单备注:</label>  
66 - <div class="col-sm-8">  
67 - <input id="remark" name="remark" th:field="*{remark}" class="form-control" type="text">  
68 - </div> 31 + </div>
  32 + <div class="form-group">
  33 + <label class="col-sm-3 control-label">预计到达时间:</label>
  34 + <div class="col-sm-8">
  35 + <input id="scheduledArriveDate" name="scheduledArriveDate" class="form-control" type="text" th:field="*{scheduledArriveDate}">
69 </div> 36 </div>
70 - <!--<div class="form-group"> -->  
71 - <!--<label class="col-sm-3 control-label">upload状态:</label>-->  
72 - <!--<div class="col-sm-8">-->  
73 - <!--<input id="uploadStatus" name="uploadStatus" th:field="*{uploadStatus}" class="form-control" type="text" readonly="true">-->  
74 - <!--</div>-->  
75 - <!--</div>-->  
76 - <!--<div class="form-group"> -->  
77 - <!--<label class="col-sm-3 control-label">上传备注:</label>-->  
78 - <!--<div class="col-sm-8">-->  
79 - <!--<input id="uploadremark" name="uploadremark" th:field="*{uploadremark}" class="form-control" type="text" readonly="true">-->  
80 - <!--</div>-->  
81 - <!--</div>-->  
82 - <!--<div class="form-group"> -->  
83 - <!--<label class="col-sm-3 control-label">上传时间:</label>-->  
84 - <!--<div class="col-sm-8">-->  
85 - <!--<input id="uploadTime" name="uploadTime" th:field="*{uploadTime}" class="time-input" type="text" readonly="true">-->  
86 - <!--</div>-->  
87 - <!--</div>-->  
88 - <div class="form-group">  
89 - <label class="col-sm-3 control-label">入库预约时间:</label>  
90 - <div class="col-sm-8">  
91 - <input id="appointmentTime" name="appointmentTime" th:field="*{appointmentTime}" class="form-control" type="text">  
92 - </div> 37 + </div>
  38 + <div class="form-group">
  39 + <div class="form-control-static col-sm-offset-9">
  40 + <button type="submit" class="btn btn-primary">提交</button>
  41 + <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>
93 </div> 42 </div>
94 - <!--<div class="form-group"> -->  
95 - <!--<label class="col-sm-3 control-label">单据头状态:</label>-->  
96 - <!--<div class="col-sm-8">-->  
97 - <!--&lt;!&ndash;<input id="firstStatus" name="firstStatus" th:field="*{firstStatus}" class="form-control" type="text" readonly="true">&ndash;&gt;-->  
98 - <!--<select id="firstStatus" class="form-control m-b" th:with="status=${@dict.getType('receiptHeaderStatus')}">-->  
99 - <!--<option th:each="dict : ${status}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}" th:field="*{firstStatus}"></option>-->  
100 - <!--</select>-->  
101 - <!--</div>-->  
102 - <!--</div>-->  
103 - <!--<div class="form-group"> -->  
104 - <!--<label class="col-sm-3 control-label">单据尾状态:</label>-->  
105 - <!--<div class="col-sm-8">-->  
106 - <!--&lt;!&ndash;<input id="lastStatus" name="lastStatus" th:field="*{lastStatus}" class="form-control" type="text" readonly="true">&ndash;&gt;-->  
107 - <!--<select id="lastStatus" class="form-control m-b" th:with="status=${@dict.getType('receiptHeaderStatus')}">-->  
108 - <!--<option th:each="dict : ${status}" th:text="${dict['dictLabel']}" th:value="${dict['dictValue']}" th:field="*{lastStatus}"></option>-->  
109 - <!--</select>-->  
110 - <!--</div>-->  
111 - <!--</div>-->  
112 - <!--<div class="form-group"> -->  
113 - <!--<label class="col-sm-3 control-label">创建时间:</label>-->  
114 - <!--<div class="col-sm-8">-->  
115 - <!--<input id="created" name="created" th:field="*{created}" class="time-input" type="text" readonly="true">-->  
116 - <!--</div>-->  
117 - <!--</div>-->  
118 - <!--<div class="form-group"> -->  
119 - <!--<label class="col-sm-3 control-label">创建用户:</label>-->  
120 - <!--<div class="col-sm-8">-->  
121 - <!--<input id="createdBy" name="createdBy" th:field="*{createdBy}" class="form-control" type="text" readonly="true">-->  
122 - <!--</div>-->  
123 - <!--</div>-->  
124 - <!--<div class="form-group"> -->  
125 - <!--<label class="col-sm-3 control-label">最后修改时间:</label>-->  
126 - <!--<div class="col-sm-8">-->  
127 - <!--<input id="lastUpdated" name="lastUpdated" th:field="*{lastUpdated}" class="time-input" type="text" readonly="true">-->  
128 - <!--</div>-->  
129 - <!--</div>-->  
130 - <!--<div class="form-group"> -->  
131 - <!--<label class="col-sm-3 control-label">更新用户:</label>-->  
132 - <!--<div class="col-sm-8">-->  
133 - <!--<input id="lastUpdatedBy" name="lastUpdatedBy" th:field="*{lastUpdatedBy}" class="form-control" type="text" readonly="true">-->  
134 - <!--</div>-->  
135 - <!--</div>-->  
136 - <div class="form-group">  
137 - <label class="col-sm-3 control-label">是否有效:</label>  
138 - <div class="col-sm-8">  
139 - <div class="onoffswitch">  
140 - <input type="checkbox" th:checked="*{enable}" class="onoffswitch-checkbox" id="enable" name="enable">  
141 - <label class="onoffswitch-label" for="enable">  
142 - <span class="onoffswitch-inner"></span>  
143 - <span class="onoffswitch-switch"></span>  
144 - </label>  
145 - </div>  
146 - </div>  
147 - </div>  
148 - <!--<div class="form-group"> -->  
149 - <!--<label class="col-sm-3 control-label">自定义字段1:</label>-->  
150 - <!--<div class="col-sm-8">-->  
151 - <!--<input id="userDef1" name="userDef1" th:field="*{userDef1}" class="form-control" type="text">-->  
152 - <!--</div>-->  
153 - <!--</div>-->  
154 - <!--<div class="form-group"> -->  
155 - <!--<label class="col-sm-3 control-label">自定义字段2:</label>-->  
156 - <!--<div class="col-sm-8">-->  
157 - <!--<input id="userDef2" name="userDef2" th:field="*{userDef2}" class="form-control" type="text">-->  
158 - <!--</div>-->  
159 - <!--</div>-->  
160 - <!--<div class="form-group"> -->  
161 - <!--<label class="col-sm-3 control-label">自定义字段3:</label>-->  
162 - <!--<div class="col-sm-8">-->  
163 - <!--<input id="userDef3" name="userDef3" th:field="*{userDef3}" class="form-control" type="text">-->  
164 - <!--</div>-->  
165 - <!--</div>-->  
166 - <div class="form-group">  
167 - <div class="form-control-static col-sm-offset-9">  
168 - <button type="submit" class="btn btn-primary">提交</button>  
169 - <button onclick="$.modal.close()" class="btn btn-danger" type="button">关闭</button>  
170 - </div>  
171 - </div>  
172 - </form>  
173 - </div>  
174 - <div th:include="include::footer"></div>  
175 - <script type="text/javascript">  
176 - var prefix = ctx + "receipt/receiptHeader";  
177 -  
178 - $("#form-receiptHeader-edit").validate({  
179 - submitHandler: function(form) {  
180 - // var tableValue = $.common.getTableValue("#form-receiptHeader-edit");  
181 - var tableValue = $("#form-receiptHeader-edit").serialize();  
182 - tableValue = formValueReplace(tableValue, "enable", $("input[name='enable']").is(':checked'));  
183 - tableValue = formValueReplace(tableValue, "companyId", $("#company option:selected").val());  
184 - tableValue = formValueReplace(tableValue, "companyCode", $("#company option:selected").attr("code"));  
185 - $.operate.save(prefix + "/edit", tableValue);  
186 - }  
187 - }); 43 + </div>
  44 + </form>
  45 +</div>
  46 +<div th:include="include::footer"></div>
  47 +<script type="text/javascript">
  48 + var prefix = ctx + "receipt/receiptHeader";
188 49
189 - $(function () {  
190 - layui.use('laydate', function() {  
191 - var laydate = layui.laydate;  
192 - laydate.render({ elem: '#appointmentTime', min:0 ,theme: 'molv', format: 'yyyy-MM-dd HH:mm:ss'}); 50 + $("#form-receiptHeader-edit").validate({
  51 + rules:{
  52 + receiptType:{
  53 + required:true,
  54 + },
  55 + companyCode:{
  56 + required:true,
  57 + },
  58 + scheduledArriveDate:{
  59 + required:true,
  60 + }
  61 + },
  62 + submitHandler: function(form) {
  63 + $.ajax({
  64 + cache : true,
  65 + type : "POST",
  66 + url : prefix + "/edit",
  67 + data : {
  68 + "id": $("#id").val(),
  69 + "receiptType": $("#receiptType option:selected").val(),
  70 + "companyCode": $("#company option:selected").attr("code"),
  71 + "receiptNote": $("input[name='receiptNote']").val(),
  72 + "scheduledArriveDate": $("input[name='scheduledArriveDate']").val(),
  73 + },
  74 + async : false,
  75 + error : function(request) {
  76 + $.modal.alertError("请求失败!");
  77 + },
  78 + success : function(data) {
  79 + $.operate.saveSuccess(data);
  80 + }
193 }); 81 });
194 - })  
195 - </script> 82 + }
  83 + });
  84 +
  85 + $(function () {
  86 + layui.use('laydate', function() {
  87 + var laydate = layui.laydate;
  88 + laydate.render({ elem: '#scheduledArriveDate',min: 0, theme: 'molv', format: 'yyyy-MM-dd HH:mm:ss'});
  89 + });
  90 + })
  91 +
  92 +</script>
196 </body> 93 </body>
197 </html> 94 </html>
src/main/resources/templates/shipment/shipmentHeaderHistory/shipmentHeaderHistory.html
@@ -20,7 +20,7 @@ @@ -20,7 +20,7 @@
20 <div id="myTabContent" class="tab-content"> 20 <div id="myTabContent" class="tab-content">
21 <div class="tab-pane fade in active" id="tabHeader"> 21 <div class="tab-pane fade in active" id="tabHeader">
22 <div class="col-sm-12 select-info"> 22 <div class="col-sm-12 select-info">
23 - <form id="receiptHeader-form"> 23 + <form id="shipmentHeaderHistory-form">
24 <div class="select-list"> 24 <div class="select-list">
25 <ul> 25 <ul>
26 <li> 26 <li>
src/main/resources/templates/system/dict/data/add.html
@@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
5 <body class="white-bg"> 5 <body class="white-bg">
6 <div class="wrapper wrapper-content animated fadeInRight ibox-content"> 6 <div class="wrapper wrapper-content animated fadeInRight ibox-content">
7 <form class="form-horizontal m" id="form-dict-add"> 7 <form class="form-horizontal m" id="form-dict-add">
8 - <input class="form-control" type="text" name="headerId" id="headerId" th:value="${dictType.id}" /> 8 + <input class="form-control" type="hidden" name="headerId" id="headerId" th:value="${dictType.id}" />
9 <div class="form-group"> 9 <div class="form-group">
10 <label class="col-sm-3 control-label ">字典标签:</label> 10 <label class="col-sm-3 control-label ">字典标签:</label>
11 <div class="col-sm-8"> 11 <div class="col-sm-8">
src/test/java/com.huaheng.test/CreateCode.java
@@ -1155,8 +1155,8 @@ public class CreateCode { @@ -1155,8 +1155,8 @@ public class CreateCode {
1155 packages.put("container","com.huaheng.pc.config.container.Container"); 1155 packages.put("container","com.huaheng.pc.config.container.Container");
1156 packages.put("container_type","com.huaheng.pc.config.containerType.ContainerType"); 1156 packages.put("container_type","com.huaheng.pc.config.containerType.ContainerType");
1157 packages.put("customer","com.huaheng.pc.general.customer.Customer"); 1157 packages.put("customer","com.huaheng.pc.general.customer.Customer");
1158 - packages.put("cyclecount_adjust","com.huaheng.pc.inventoryHeader.cyclecountAdjust.CyclecountAdjust");  
1159 - packages.put("cyclecount_adjustdetail","com.huaheng.pc.inventoryHeader.cyclecountAdjustDetail.CyclecountAdjustDetail"); 1158 + packages.put("cyclecount_adjust","com.huaheng.pc.inventoryHeader.adjustHeader.CyclecountAdjust");
  1159 + packages.put("cyclecount_adjustdetail","com.huaheng.pc.inventoryHeader.adjustDetail.CyclecountAdjustDetail");
1160 packages.put("cyclecount_detail","com.huaheng.pc.inventoryHeader.cycleCountDetail.CycleCountDetail"); 1160 packages.put("cyclecount_detail","com.huaheng.pc.inventoryHeader.cycleCountDetail.CycleCountDetail");
1161 packages.put("cyclecount_header","com.huaheng.pc.inventoryHeader.cycleCountHeader.CycleCountHeader"); 1161 packages.put("cyclecount_header","com.huaheng.pc.inventoryHeader.cycleCountHeader.CycleCountHeader");
1162 packages.put("inventory","com.huaheng.pc.inventoryHeader.inventoryHeader.Inventory"); 1162 packages.put("inventory","com.huaheng.pc.inventoryHeader.inventoryHeader.Inventory");