From d2cb36959b65ece32cec7e2db4d6764f5c788b1d Mon Sep 17 00:00:00 2001 From: skyouc Date: 星期三, 30 四月 2025 08:33:24 +0800 Subject: [PATCH] 1. 波次删除判断是否有子任务列表 2. 任务明细添加字段:执行数量,完成数量, 源单据号,源单据ID --- rsf-server/src/main/java/com/vincent/rsf/server/manager/entity/Loc.java | 168 ++++++++++++++++++++++++++++++++++++++------------------ 1 files changed, 114 insertions(+), 54 deletions(-) diff --git a/rsf-server/src/main/java/com/vincent/rsf/server/manager/entity/Loc.java b/rsf-server/src/main/java/com/vincent/rsf/server/manager/entity/Loc.java index 24a47ed..5b1f707 100644 --- a/rsf-server/src/main/java/com/vincent/rsf/server/manager/entity/Loc.java +++ b/rsf-server/src/main/java/com/vincent/rsf/server/manager/entity/Loc.java @@ -1,24 +1,30 @@ package com.vincent.rsf.server.manager.entity; import com.baomidou.mybatisplus.annotation.*; - -import java.text.SimpleDateFormat; -import java.util.Date; -import com.vincent.rsf.server.manager.service.WarehouseAreasService; -import com.vincent.rsf.server.manager.service.WarehouseService; -import lombok.experimental.Accessors; -import org.springframework.format.annotation.DateTimeFormat; -import io.swagger.annotations.ApiModelProperty; -import lombok.Data; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.vincent.rsf.framework.common.Cools; import com.vincent.rsf.framework.common.SpringUtils; -import com.vincent.rsf.server.system.service.UserService; +import com.vincent.rsf.server.manager.service.LocTypeService; +import com.vincent.rsf.server.manager.service.WarehouseAreasService; +import com.vincent.rsf.server.manager.service.WarehouseService; import com.vincent.rsf.server.system.entity.User; +import com.vincent.rsf.server.system.service.UserService; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import lombok.experimental.Accessors; +import org.apache.commons.lang3.StringUtils; +import org.springframework.format.annotation.DateTimeFormat; + import java.io.Serializable; +import java.text.SimpleDateFormat; +import java.util.Arrays; +import java.util.Date; +import java.util.List; +import java.util.stream.Collectors; @Data -@TableName("man_loc") @Accessors(chain = true) +@TableName("man_loc") public class Loc implements Serializable { private static final long serialVersionUID = 1L; @@ -31,28 +37,33 @@ private Long id; /** - * 浠撳簱鏍囪瘑 - */ - @ApiModelProperty(value = "浠撳簱鏍囪瘑") - private Long warehouseId; - /** * 搴撳尯鏍囪瘑 */ @ApiModelProperty(value= "搴撳尯鏍囪瘑") private Long areaId; /** - * 缂栧彿 + * 搴撲綅鍙� */ - @ApiModelProperty(value= "缂栧彿") + @ApiModelProperty(value= "搴撲綅鍙�") private String code; /** - * 搴撲綅绫诲瀷 + * 浠撳簱鏍囪瘑 */ - @ApiModelProperty(value= "搴撲綅绫诲瀷") + @ApiModelProperty(value= "浠撳簱鏍囪瘑") + private Long warehouseId; + + /** + * 搴撲綅绫诲瀷(*) H: 楂樺簱浣� M: 涓簱浣� L: 浣庡簱浣� + */ + @ApiModelProperty(value= "搴撲綅绫诲瀷(*) H: 楂樺簱浣� M: 涓簱浣� L: 浣庡簱浣� ") + @TableField("`type`") private String type; + @ApiModelProperty("搴撲綅绫诲瀷(*)[man_loc_type]") + @TableField(exist = false) + private List<Long> typeIds; /** * 铏氭嫙搴撲綅 @@ -79,31 +90,35 @@ private String unit; /** - * 闀�/瀹�/楂� + * 闀� */ - @ApiModelProperty(value= "闀�/瀹�/楂�") + @ApiModelProperty(value= "闀�") @TableField("`length`") private Double length; /** - * 瀹� - */ - @ApiModelProperty("瀹�") - @TableField("`width`") - private Double width; - - /** * 楂� */ - @ApiModelProperty("楂�") + @ApiModelProperty(value= "楂�") private Double height; + /** + * 瀹� + */ + @ApiModelProperty(value= "瀹�") + private Double width; /** * 鎺� */ @ApiModelProperty(value= "鎺�") @TableField("`row`") private Integer row; + + /** + * 璁惧鍙� + */ + @ApiModelProperty(value= "璁惧鍙�") + private Integer deviceNo; /** * 鍒� @@ -118,15 +133,11 @@ private Integer lev; /** - * 閫氶亾 + * 宸烽亾 */ @ApiModelProperty(value= "宸烽亾") + @TableField("`channel`") private Integer channel; - - /** - * 搴撲綅浣跨敤鐘舵�� - */ - private String useStatus; /** * 鏈�澶ч浂浠舵暟 @@ -139,6 +150,12 @@ */ @ApiModelProperty(value= "鏈�澶у寘瑁呮暟") private Integer maxPack; + + /** + * 搴撲綅浣跨敤鐘舵�� O: 绌哄簱 D: 绌烘澘 R: 棰勭害鍑哄簱 S: 棰勭害鍏ュ簱 X: 绂佺敤 聽 F: 鍦ㄥ簱 + */ + @ApiModelProperty(value= "搴撲綅浣跨敤鐘舵�� O: 绌哄簱 D: 绌烘澘 R: 棰勭害鍑哄簱 S: 棰勭害鍏ュ簱 X: 绂佺敤 聽 F: 鍦ㄥ簱 ") + private String useStatus; /** * 鏄惁鏍囩绠$悊 @@ -156,6 +173,7 @@ * 鐘舵�� 1: 姝e父 0: 鍐荤粨 */ @ApiModelProperty(value= "鐘舵�� 1: 姝e父 0: 鍐荤粨 ") + @TableField("`status`") private Integer status; /** @@ -205,24 +223,25 @@ public Loc() {} - public Loc(Long areaId, Long warehouseId, String code,String type,Short flagLogic,String fucAtrrs,String barcode,String unit,Double size, Double width, Double height,Integer lrow,Integer col,Integer lev,Integer channel,Integer maxParts,Integer maxPack,Short flagLabelMange,String locAttrs,Integer status,Integer deleted,Integer tenantId,Long createBy,Date createTime,Long updateBy,Date updateTime,String memo) { - this.warehouseId = warehouseId; + public Loc(Long areaId, String code, Long warehouseId, String type, Short flagLogic, String fucAtrrs, String barcode, String unit, Double length, Double height, Double width, Integer row, Integer col, Integer lev, Integer channel, Integer maxParts, Integer maxPack, String useStatus, Short flagLabelMange, String locAttrs, Integer status, Integer deleted, Integer tenantId, Long createBy, Date createTime, Long updateBy, Date updateTime, String memo) { this.areaId = areaId; this.code = code; + this.warehouseId = warehouseId; this.type = type; - this.width = width; - this.height = height; this.flagLogic = flagLogic; this.fucAtrrs = fucAtrrs; this.barcode = barcode; this.unit = unit; - this.length = size; - this.row = lrow; + this.length = length; + this.height = height; + this.width = width; + this.row = row; this.col = col; this.lev = lev; this.channel = channel; this.maxParts = maxParts; this.maxPack = maxPack; + this.useStatus = useStatus; this.flagLabelMange = flagLabelMange; this.locAttrs = locAttrs; this.status = status; @@ -237,22 +256,25 @@ // Loc loc = new Loc( // null, // 搴撳尯鏍囪瘑[闈炵┖] -// null, // 缂栧彿[闈炵┖] -// null, // 搴撲綅绫诲瀷[闈炵┖] -// null, // 鍚嶇О +// null, // 搴撲綅鍙� +// null, // 浠撳簱鏍囪瘑[闈炵┖] +// null, // 搴撲綅绫诲瀷(*)[闈炵┖] // null, // 铏氭嫙搴撲綅 // null, // 鍔熻兘灞炴�� // null, // 瀹瑰櫒缂栫爜 // null, // 瀛樻斁鍗曚綅 -// null, // 闀�/瀹�/楂� +// null, // 闀� +// null, // 楂� +// null, // 瀹� // null, // 鎺抂闈炵┖] // null, // 鍒梉闈炵┖] // null, // 灞俒闈炵┖] -// null, // 閫氶亾[闈炵┖] +// null, // 宸烽亾 // null, // 鏈�澶ч浂浠舵暟 // null, // 鏈�澶у寘瑁呮暟 +// null, // 搴撲綅浣跨敤鐘舵�乕闈炵┖] // null, // 鏄惁鏍囩绠$悊 -// null, // 灞炴�闈炵┖] +// null, // 灞炴�� // null, // 鐘舵�乕闈炵┖] // null, // 鏄惁鍒犻櫎[闈炵┖] // null, // 绉熸埛 @@ -263,20 +285,58 @@ // null // 澶囨敞 // ); - public String getWarehouseId$() { + public String getTypeIds$(){ + if (null == this.type){ return null; } + String[] split = this.type.split(","); + List<String> asList = Arrays.asList(split); + if (asList.isEmpty()) { + return null; + } + LocTypeService locTypeService = SpringUtils.getBean(LocTypeService.class); + List<LocType> locTypes = locTypeService.list(new LambdaQueryWrapper<LocType>().in(LocType::getId, asList)); + if (locTypes.isEmpty()) { + return null; + } + List<String> strings = locTypes.stream().map(LocType::getName).collect(Collectors.toList()); + return StringUtils.join(strings, ","); + } + + public String getUseStatus$(){ + if (null == this.useStatus){ return null; } + switch (this.useStatus){ + case "O": + return " 绌哄簱"; + case "D": + return " 绌烘澘"; + case "R": + return " 棰勭害鍑哄簱"; + case "S": + return " 棰勭害鍏ュ簱"; + case "X": + return " 绂佺敤"; + case "F": + return " 鍦ㄥ簱"; + default: + return String.valueOf(this.useStatus); + } + } + + public String getWarehouseId$(){ + if (null == this.warehouseId){ return null; } WarehouseService service = SpringUtils.getBean(WarehouseService.class); Warehouse warehouse = service.getById(this.warehouseId); - if (!Cools.isEmpty(warehouse)) { + if (!Cools.isEmpty(warehouse)){ return String.valueOf(warehouse.getName()); } return null; } - public String gerAreaId$() { + public String getAreaId$(){ + if (null == this.areaId){ return null; } WarehouseAreasService service = SpringUtils.getBean(WarehouseAreasService.class); - WarehouseAreas areas = service.getById(this.areaId); - if (!Cools.isEmpty(areas)) { - return String.valueOf(areas.getName()); + WarehouseAreas warehouseAreas = service.getById(this.areaId); + if (!Cools.isEmpty(warehouseAreas)){ + return String.valueOf(warehouseAreas.getName()); } return null; } -- Gitblit v1.9.1