yun-zuoyi
gcj 6 years ago
commit 4c2d922ed9

@ -338,9 +338,10 @@ public class AndonManageQueue extends BaseManageQueue {
* @param confirmTime * @param confirmTime
* @param resetTime * @param resetTime
*/ */
public AndonManageQueue(String organizeCode,String workCenterNameRdd,String workCellNameRdd,String resetUser,String alarmCode,String callTime, String confirmTime,String resetTime){ public AndonManageQueue(String organizeCode,String workCenterNameRdd,String workCellCode,String workCellNameRdd,String resetUser,String alarmCode,String callTime, String confirmTime,String resetTime){
this.organizeCode = organizeCode; this.organizeCode = organizeCode;
this.workCenterNameRdd = workCenterNameRdd; this.workCenterNameRdd = workCenterNameRdd;
this.workCellCode = workCellCode;
this.workCellNameRdd = workCellNameRdd; this.workCellNameRdd = workCellNameRdd;
this.resetUser = resetUser; this.resetUser = resetUser;
this.alarmCode = alarmCode; this.alarmCode = alarmCode;

@ -67,6 +67,6 @@ public class MesWorkCell extends BaseBean {
private String workCellType; private String workCellType;
public String getName(){ public String getName(){
return this.workCellName; return this.workCellCode;
} }
} }

@ -276,7 +276,8 @@ public class MesEnumUtil {
DEFECT_CAUSE("DEFECT_CAUSE", "缺陷原因"), DEFECT_CAUSE("DEFECT_CAUSE", "缺陷原因"),
REPAIR("REPAIR", "处理措施"), REPAIR("REPAIR", "处理措施"),
SCRAP("SCRAP", "报废原因"), SCRAP("SCRAP", "报废原因"),
QC_CHECK_STAND("QC_CHECK_STAND", "质量检测标准"); QC_CHECK_STAND("QC_CHECK_STAND", "质量检测标准"),
WC_CHECK("WC_CHECK", "开线检查项");
private String value; private String value;
private String description; private String description;
@ -1461,7 +1462,9 @@ public class MesEnumUtil {
MES_PART_OJBECT(340, "物料对象"), MES_PART_OJBECT(340, "物料对象"),
MES_ROUTE_PROCESS_WORK_CELL(350, "工序工作单元"), MES_ROUTE_PROCESS_WORK_CELL(350, "工序工作单元"),
MES_DATASOURCE(360, "DB地址清单"), MES_DATASOURCE(360, "DB地址清单"),
MES_EQU_TASK_NOTIFY_CFG(370, "设备通知配置"); MES_EQU_TASK_NOTIFY_CFG(370, "设备通知配置"),
MES_EQU_NOTIFY_OBJECT_CFG(380, "设备通知对象"),
MES_PLC(390, "PLC地址清单");
private int value; private int value;
private String description; private String description;

@ -214,7 +214,45 @@ public class MesPcnEnumUtil {
} }
} }
/**
* MES_TYPE_CFG
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum MES_TYPE_CFG {
DEFECT("DEFECT", "缺陷"),
DEFECT_CAUSE("DEFECT_CAUSE", "缺陷原因"),
REPAIR("REPAIR", "处理措施"),
SCRAP("SCRAP", "报废原因"),
QC_CHECK_STAND("QC_CHECK_STAND", "质量检测标准"),
WC_CHECK("WC_CHECK", "开线检查项");
private String value;
private String description;
MES_TYPE_CFG(String value, String description) {
this.value = value;
this.description = description;
}
public String getValue() {
return value;
}
public String getDescription() {
return description;
}
public static String valueOfDescription(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value.equals(val)) {
tmp = values()[i].description;
}
}
return tmp;
}
}
/** /**
* MesProdBindRecord * MesProdBindRecord
*/ */

@ -3023,6 +3023,8 @@ public class WmsEnumUtil {
} }
} }
/** /**
* *
*/ */
@ -4566,4 +4568,145 @@ public class WmsEnumUtil {
} }
} }
/**
*
* 2
*/
public enum IS_VALUABLE {
TRUE(1, "贵重物料"), FALSE(2, "非贵重物料");
private int value;
private String description;
IS_VALUABLE(int value, String description) {
this.value = value;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public static String valueOfDescription(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].description;
}
}
return tmp;
}
}
/**
*
* 10
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum PULL_TASK_DETAILS_STATUS {
BE_HANDLE(10,"BE_HANDLE", "待处理"),
CANCELLATION(20,"CANCELLATION", "已处理");
private int value;
private String code;
private String description;
PULL_TASK_DETAILS_STATUS(int value, String code, String description) {
this.value = value;
this.code = code;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public String getCode() {
return code;
}
public static String valueOf(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].description;
}
}
return tmp;
}
public static int descOf(String desc) {
int tmp = 1;
for (int i = 0; i < values().length; i++) {
if (values()[i].description.equals(desc)) {
tmp = values()[i].value;
}
}
return tmp;
}
}
/**
*
* 10
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum PULL_TASK_MASTER_STATUS {
CREATE(10,"CREATE", "创建"),
ENABLED(20,"ENABLED", "已启动"),
COMPLETE(30,"COMPLETE", "已完成"),
CLOSE(40,"CLOSE", "已关闭");
private int value;
private String code;
private String description;
PULL_TASK_MASTER_STATUS(int value, String code, String description) {
this.value = value;
this.code = code;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public String getCode() {
return code;
}
public static String valueOf(int val) {
String tmp = null;
for (int i = 0; i < values().length; i++) {
if (values()[i].value == val) {
tmp = values()[i].description;
}
}
return tmp;
}
public static int descOf(String desc) {
int tmp = 1;
for (int i = 0; i < values().length; i++) {
if (values()[i].description.equals(desc)) {
tmp = values()[i].value;
}
}
return tmp;
}
}
} }

@ -3,7 +3,11 @@ package cn.estsh.i3plus.pojo.base.util;
import java.lang.reflect.Field; import java.lang.reflect.Field;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class StringUtil { public class StringUtil {
@ -65,4 +69,22 @@ public class StringUtil {
return null; return null;
} }
} }
private static Pattern linePattern = Pattern.compile("_(\\w)");
/** 驼峰转下划线 */
public static Map<String, Object> humpToLine(Map<String, Object> map) {
Map<String, Object> resultMap = new HashMap<>();
for (String str : map.keySet()) {
str = str.toLowerCase();
Matcher matcher = linePattern.matcher(str);
StringBuffer sb = new StringBuffer();
while (matcher.find()) {
matcher.appendReplacement(sb, matcher.group(1).toUpperCase());
}
matcher.appendTail(sb);
resultMap.put(sb.toString(), map.get(str));
}
return resultMap;
}
} }

@ -36,6 +36,8 @@ public class WcCheckModel {
private List<MesWcCheckRecord> materials; private List<MesWcCheckRecord> materials;
@ApiParam("物料 列") @ApiParam("物料 列")
private Map<String, String> materialsColumn; private Map<String, String> materialsColumn;
@ApiParam("普通列")
private Map<String, String> commonColumn;
@ApiParam("法") @ApiParam("法")
private List<MesWcCheckRecord> routes; private List<MesWcCheckRecord> routes;
@ -66,6 +68,9 @@ public class WcCheckModel {
@ApiParam("需要展示的数据") @ApiParam("需要展示的数据")
private Map<String, String> need2ShowMap; private Map<String, String> need2ShowMap;
@ApiParam("重构map")
private Map<String, List<MesWcCheckRecord>> showMap;
public WcCheckModel initialWcCheckModel() { public WcCheckModel initialWcCheckModel() {
WcCheckModel wcCheckModel = new WcCheckModel(); WcCheckModel wcCheckModel = new WcCheckModel();

@ -37,10 +37,6 @@ public class MesPartObject extends BaseBean {
@ApiParam("对象代码") @ApiParam("对象代码")
private String objectCode; private String objectCode;
@Column(name = "OBJECT_NAME")
@ApiParam("物料名称")
private String objectName;
@Column(name = "WORK_CENTER_CODE") @Column(name = "WORK_CENTER_CODE")
@ApiParam("生产线") @ApiParam("生产线")
private String workCenterCode; private String workCenterCode;
@ -60,4 +56,8 @@ public class MesPartObject extends BaseBean {
@Transient @Transient
@ApiParam("数据组号") @ApiParam("数据组号")
private String groupNo; private String groupNo;
@Transient
@ApiParam("对象名称")
private String objectName;
} }

@ -9,6 +9,7 @@ import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate; import org.hibernate.annotations.DynamicUpdate;
import javax.persistence.*; import javax.persistence.*;
import java.math.BigDecimal;
/** /**
* @Description: * @Description:
@ -154,6 +155,14 @@ public class MesProduceSn extends BaseBean {
@ApiParam("条码类型名称") @ApiParam("条码类型名称")
private String snTypeName; private String snTypeName;
public MesProduceSn() {
}
public MesProduceSn(String partNo, Integer qcStatus, Double qty) {
this.partNo = partNo;
this.qcStatus = qcStatus;
this.qty = qty;
}
public double getQtyVal() { public double getQtyVal() {
return this.qty == null ? 0.0d : this.qty; return this.qty == null ? 0.0d : this.qty;

@ -0,0 +1,67 @@
package cn.estsh.i3plus.pojo.mes.model;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import javax.persistence.Transient;
/**
* @Description:
* @Reference:
* @Author: joke.wang
* @CreateDate: 2019\12\13 14:33
* @Modify:
**/
@Data
public class MesPartObjectModel {
private Long id;
@ApiParam(value ="组织代码")
private String organizeCode;
@ApiParam(value = "创建用户")
private String createUser;
@ApiParam(value = "创建日期")
private String createDatetime;
@ApiParam(value = "修改人")
private String modifyUser;
@ApiParam(value = "修改日期")
private String modifyDatetime;
@ApiParam(value = "有效性",example = "1")
private Integer isValid;
@ApiParam(value = "是否已删除",example = "2")
private Integer isDeleted;
@ApiParam("物料编码")
private String partNo;
@ApiParam("对象代码")
private String objectCode;
@ApiParam("生产线")
private String workCenterCode;
@ApiParam("对象名称")
private String objectName;
public MesPartObjectModel(Long id, String organizeCode, String createUser, String createDatetime, String modifyUser, String modifyDatetime, Integer isValid, Integer isDeleted, String partNo, String objectCode, String workCenterCode, String objectName) {
this.id = id;
this.organizeCode = organizeCode;
this.createUser = createUser;
this.createDatetime = createDatetime;
this.modifyUser = modifyUser;
this.modifyDatetime = modifyDatetime;
this.isValid = isValid;
this.isDeleted = isDeleted;
this.partNo = partNo;
this.objectCode = objectCode;
this.workCenterCode = workCenterCode;
this.objectName = objectName;
}
}

@ -2057,4 +2057,28 @@ public class MesHqlPack {
} }
return packBean; return packBean;
} }
/**
*
*
* @param qualityStandardCfg
* @param organizeCode
* @return
*/
public static DdlPackBean getMesQualityStandardCfg(MesQualityStandardCfg qualityStandardCfg, String organizeCode) {
DdlPackBean packBean = getAllBaseDataByNormalPro(qualityStandardCfg, organizeCode);
if (!StringUtils.isEmpty(qualityStandardCfg.getStandardType())) {
DdlPreparedPack.getNumEqualPack(qualityStandardCfg.getStandardType(), "standardType", packBean);
}
if (!StringUtils.isEmpty(qualityStandardCfg.getObjectKey())) {
DdlPreparedPack.getStringLikerPack(qualityStandardCfg.getObjectKey(), "objectKey", packBean);
}
if (!StringUtils.isEmpty(qualityStandardCfg.getObjectType())) {
DdlPreparedPack.getNumEqualPack(qualityStandardCfg.getObjectType(), "objectType", packBean);
}
if (!StringUtils.isEmpty(qualityStandardCfg.getObjectKeyValue())) {
DdlPreparedPack.getStringLikerPack(qualityStandardCfg.getObjectKeyValue(), "objectKeyValue", packBean);
}
return packBean;
}
} }

@ -49,6 +49,7 @@ public class SysLocaleResource extends BaseBean {
@Column(name="language_code") @Column(name="language_code")
@ApiParam(value = "语言编码",example = "浏览器语言编码") @ApiParam(value = "语言编码",example = "浏览器语言编码")
@AnnoOutputColumn
private String languageCode; private String languageCode;
@Column(name="language_name_rdd") @Column(name="language_name_rdd")
@ -57,6 +58,7 @@ public class SysLocaleResource extends BaseBean {
@Column(name="resource_key") @Column(name="resource_key")
@ApiParam(value = "资源KEY",example = "格式A.B全部大写参考命名规范开发文档") @ApiParam(value = "资源KEY",example = "格式A.B全部大写参考命名规范开发文档")
@AnnoOutputColumn
private String resourceKey; private String resourceKey;
@Lob @Lob

@ -99,6 +99,7 @@ public class WmsDocMovementMaster extends BaseBean {
public Integer isTask; public Integer isTask;
@Column(name = "PRIORITY") @Column(name = "PRIORITY")
@AnnoOutputColumn(refClass = WmsEnumUtil.PRIORITY.class, refForeignKey = "value", value = "description")
@ApiParam(value = "优先级", example = "1") @ApiParam(value = "优先级", example = "1")
public Integer priority; public Integer priority;

@ -170,6 +170,11 @@ public class WmsPart extends BaseBean {
@ApiParam(value = "待质检比例", example = "1") @ApiParam(value = "待质检比例", example = "1")
private Double proportion; private Double proportion;
@Column(name = "IS_VALUABLE", columnDefinition = "int default 2")
@ApiParam(value = "贵重物料")
@AnnoOutputColumn(refClass = WmsEnumUtil.IS_VALUABLE.class, refForeignKey = "value", value = "description")
private Integer isValuable;
@Transient @Transient
@ApiParam("总数量") @ApiParam("总数量")
private Double qty; private Double qty;

@ -32,7 +32,7 @@ public class WmsPullTaskDetails extends BaseBean{
@Column(name="WROKORDER_NO") @Column(name="WROKORDER_NO")
@ApiParam("工单号") @ApiParam("工单号")
private String woekorderNo; private String wrokorderNo;
@Column(name="ITEM") @Column(name="ITEM")
@ApiParam(value = "行号", example = "0") @ApiParam(value = "行号", example = "0")
@ -47,8 +47,8 @@ public class WmsPullTaskDetails extends BaseBean{
private String locateNo; private String locateNo;
@Column(name="LOCATE_CAPACITY") @Column(name="LOCATE_CAPACITY")
@ApiParam("库位容量") @ApiParam(value = "库位容量", example = "0")
private String locateCapacity; private Integer locateCapacity = 0;
@Column(name="PART_NO") @Column(name="PART_NO")
@ApiParam("零件编号") @ApiParam("零件编号")
@ -58,49 +58,53 @@ public class WmsPullTaskDetails extends BaseBean{
@ApiParam("零件名称") @ApiParam("零件名称")
private String partNameRdd; private String partNameRdd;
@Column(name="PLAN_PACK_QTY")
@ApiParam(value = "计划数量", example = "0d")
private Double planPackQty = 0d;
@Column(name="PLAN_PACK_COUNT") @Column(name="PLAN_PACK_COUNT")
@ApiParam(value = "计划容器数", example = "0") @ApiParam(value = "计划容器数", example = "0d")
private Integer planPackCount = 0; private Double planPackCount = 0d;
@Column(name="FIRST_BATCH_QTY") @Column(name="FIRST_BATCH_QTY")
@ApiParam(value = "首批批量", example = "0") @ApiParam(value = "首批批量", example = "0d")
private Integer firstBatchQty = 0; private Double firstBatchQty = 0d;
@Column(name="FIRST_PACK_COUNT") @Column(name="FIRST_PACK_COUNT")
@ApiParam(value = "首批容器数", example = "0") @ApiParam(value = "首批容器数", example = "0d")
private Integer firstPackCount = 0; private Double firstPackCount = 0d;
@Column(name="REQUEST_QTY") @Column(name="REQUEST_QTY")
@ApiParam(value = "补货批量", example = "0") @ApiParam(value = "补货批量", example = "0d")
private Integer requestQty = 0; private Double requestQty = 0d;
@Column(name="REQUEST_PACK_COUNT") @Column(name="REQUEST_PACK_COUNT")
@ApiParam(value = "补货容器数", example = "0") @ApiParam(value = "补货容器数", example = "0d")
private Integer requestPackCount = 0; private Double requestPackCount = 0d;
@Column(name="REQUEST_LOT_NO") @Column(name="REQUEST_LOT_NO")
@ApiParam(value = "补货批次", example = "0") @ApiParam(value = "补货批次", example = "0d")
private Integer requestLotNo = 0; private Double requestLotNo = 0d;
@Column(name="REQUEST_TOTAL_COUNT") @Column(name="REQUEST_TOTAL_COUNT")
@ApiParam(value = "补货累加次数", example = "0") @ApiParam(value = "补货累加次数", example = "0d")
private Integer requestTotalCount = 0; private Double requestTotalCount = 0d;
@Column(name="LAST_REQUEST_TIME") @Column(name="LAST_REQUEST_TIME")
@ApiParam("上一次补货时间") @ApiParam("上一次补货时间")
private String lastRequestTtime; private String lastRequestTtime;
@Column(name="BOOT_QTY") @Column(name="BOOT_QTY")
@ApiParam(value = "尾箱批量", example = "0") @ApiParam(value = "尾箱批量", example = "0d")
private Integer bootQty = 0; private Double bootQty = 0d;
@Column(name="BOOT_PACK_COUNT") @Column(name="BOOT_PACK_COUNT")
@ApiParam(value = "尾箱容器数", example = "0") @ApiParam(value = "尾箱容器数", example = "0d")
private Integer bootPackCount = 0; private Double bootPackCount = 0d;
@Column(name="BOOT_LOT_NO") @Column(name="BOOT_LOT_NO")
@ApiParam(value = "尾箱批次", example = "0") @ApiParam(value = "尾箱批次", example = "0d")
private Integer bootLotNo = 0; private Double bootLotNo = 0d;
@Column(name="ORDER_STATUS") @Column(name="ORDER_STATUS")
@ApiParam(value = "单据状态", example = "0") @ApiParam(value = "单据状态", example = "0")
@ -110,48 +114,56 @@ public class WmsPullTaskDetails extends BaseBean{
return orderStatus == null ? 0 : this.orderStatus.intValue(); return orderStatus == null ? 0 : this.orderStatus.intValue();
} }
public Integer getBootLotNo() { public Double getBootLotNo() {
return bootLotNo == null ? 0 : this.bootLotNo.intValue(); return bootLotNo == null ? 0d : this.bootLotNo.doubleValue();
} }
public Integer getBootPackCount() { public Double getBootPackCount() {
return bootPackCount == null ? 0 : this.bootPackCount.intValue(); return bootPackCount == null ? 0d : this.bootPackCount.doubleValue();
} }
public Integer getBootQty() { public Double getBootQty() {
return bootQty == null ? 0 : this.bootQty.intValue(); return bootQty == null ? 0d : this.bootQty.doubleValue();
} }
public Integer getRequestTotalCount() { public Double getRequestTotalCount() {
return requestTotalCount == null ? 0 : this.requestTotalCount.intValue(); return requestTotalCount == null ? 0d : this.requestTotalCount.doubleValue();
} }
public Integer getRequestLotNo() { public Double getRequestLotNo() {
return requestLotNo == null ? 0 : this.requestLotNo.intValue(); return requestLotNo == null ? 0d : this.requestLotNo.doubleValue();
} }
public Integer getRequestPackCount() { public Double getRequestPackCount() {
return requestPackCount == null ? 0 : this.requestPackCount.intValue(); return requestPackCount == null ? 0d : this.requestPackCount.doubleValue();
} }
public Integer getRequestQty() { public Double getRequestQty() {
return requestQty == null ? 0 : this.requestQty.intValue(); return requestQty == null ? 0d : this.requestQty.doubleValue();
} }
public Integer getFirstPackCount() { public Double getFirstPackCount() {
return firstPackCount == null ? 0 : this.firstPackCount.intValue(); return firstPackCount == null ? 0d : this.firstPackCount.doubleValue();
} }
public Integer getFirstBatchQty() { public Double getFirstBatchQty() {
return firstBatchQty == null ? 0 : this.firstBatchQty.intValue(); return firstBatchQty == null ? 0d : this.firstBatchQty.doubleValue();
} }
public Integer getPlanPackCount() { public Double getPlanPackCount() {
return planPackCount == null ? 0 : this.planPackCount.intValue(); return planPackCount == null ? 0d : this.planPackCount.doubleValue();
} }
public Integer getItem() { public Integer getItem() {
return item == null ? 0 : this.item.intValue(); return item == null ? 0 : this.item.intValue();
} }
public Double getLocateCapacity() {
return locateCapacity == null ? 0d : this.locateCapacity.doubleValue();
}
public Double getPlanPackQty() {
return planPackQty == null ? 0d : this.planPackQty.doubleValue();
}
} }

@ -2610,4 +2610,39 @@ public class WmsHqlPack {
return result; return result;
} }
/**
*
*
* @param wmsPullTaskMaster
* @return
*/
public static DdlPackBean packHqlWmsPullTaskMaster(WmsPullTaskMaster wmsPullTaskMaster,String statusList) {
DdlPackBean result = new DdlPackBean();
DdlPreparedPack.getInPack(statusList, "orderStatus", result);
DdlPreparedPack.getStringLikerPack(wmsPullTaskMaster.getWoekorderNo(), "woekorderNo", result);
DdlPreparedPack.getStringEqualPack(wmsPullTaskMaster.getPdlineNo(), "pdlineNo", result);
DdlPreparedPack.getStringBiggerPack(wmsPullTaskMaster.getStartProductTime(), "startProductTime", result);
DdlPreparedPack.getStringSmallerPack(wmsPullTaskMaster.getEndProductTime(), "endProductTime", result);
getStringBuilderPack(wmsPullTaskMaster, result);
return result;
}
/**
*
*
* @param wmsPullTaskDetails
* @return
*/
public static DdlPackBean packHqlWmsPullTaskDetails(WmsPullTaskDetails wmsPullTaskDetails) {
DdlPackBean result = new DdlPackBean();
DdlPreparedPack.getStringLikerPack(wmsPullTaskDetails.getWrokorderNo(), "wrokorderNo", result);
DdlPreparedPack.getStringLikerPack(wmsPullTaskDetails.getPartNo(), "partNo", result);
getStringBuilderPack(wmsPullTaskDetails, result);
return result;
}
} }

Loading…
Cancel
Save