Merge branches 'master' and 'test' of http://git.estsh.com/i3-IMPP/i3plus-pojo

yun-zuoyi
许心洁 6 years ago
commit 51180363f3

@ -1,5 +1,7 @@
package cn.estsh.i3plus.pojo.aps.annotation; package cn.estsh.i3plus.pojo.aps.annotation;
import cn.estsh.i3plus.pojo.aps.enums.EDIT_TYPE;
import java.lang.annotation.ElementType; import java.lang.annotation.ElementType;
import java.lang.annotation.Retention; import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy; import java.lang.annotation.RetentionPolicy;
@ -22,4 +24,6 @@ public @interface FieldAnnotation {
boolean mainkey() default false; // 是否为主键 boolean mainkey() default false; // 是否为主键
String defaultValue() default ""; // 字段的默认值 String defaultValue() default ""; // 字段的默认值
boolean popSearch() default false; // 弹出选择对象时是否显示 boolean popSearch() default false; // 弹出选择对象时是否显示
EDIT_TYPE editType() default EDIT_TYPE.NONE; // 定义字段的编辑类型
String typeName() default ""; // 定义字段类型的简单名称,对于多选关联对象时有用。
} }

@ -32,6 +32,7 @@ public class BaseOrder extends BaseCode {
@Column(name="PRIORITY") @Column(name="PRIORITY")
@ApiParam(value ="优先级") @ApiParam(value ="优先级")
@FieldAnnotation(defaultValue = "10")
private Integer priority; private Integer priority;
@Column(name="LET") @Column(name="LET")
@ -40,18 +41,22 @@ public class BaseOrder extends BaseCode {
@Column(name="CALC_EST") @Column(name="CALC_EST")
@ApiParam(value ="最早开始时刻计算值") @ApiParam(value ="最早开始时刻计算值")
@FieldAnnotation(modify = false)
private Date calcEst; private Date calcEst;
@Column(name="CALC_LET") @Column(name="CALC_LET")
@ApiParam(value ="最晚结束时刻计算值") @ApiParam(value ="最晚结束时刻计算值")
@FieldAnnotation(modify = false)
private Date calcLet; private Date calcLet;
@Column(name="PLAN_BEGIN") @Column(name="PLAN_BEGIN")
@ApiParam(value ="计划开始") @ApiParam(value ="计划开始")
@FieldAnnotation(modify = false)
private Date planBegin; private Date planBegin;
@Column(name="PLAN_END") @Column(name="PLAN_END")
@ApiParam(value ="计划结束") @ApiParam(value ="计划结束")
@FieldAnnotation(modify = false)
private Date planEnd; private Date planEnd;
@Column(name="RECEIVE_DATE") @Column(name="RECEIVE_DATE")

@ -1,6 +1,7 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.common.BaseCode; import cn.estsh.i3plus.pojo.aps.common.BaseCode;
import cn.estsh.i3plus.pojo.aps.enums.EDIT_TYPE;
import cn.estsh.i3plus.pojo.aps.enums.FIELD_TYPE; import cn.estsh.i3plus.pojo.aps.enums.FIELD_TYPE;
import cn.estsh.i3plus.pojo.base.bean.BaseBean; import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
@ -92,6 +93,10 @@ public class FieldInfo extends BaseCode {
@ApiParam(value ="弹出选择时是否显示") @ApiParam(value ="弹出选择时是否显示")
private Boolean popSearch; private Boolean popSearch;
@Column(name="EDIT_TYPE")
@ApiParam(value ="字段编辑类型")
private EDIT_TYPE editType;
@ApiParam(value ="枚举项内容") @ApiParam(value ="枚举项内容")
private transient Enum<?>[] enumItems; private transient Enum<?>[] enumItems;

@ -1,5 +1,6 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation; import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder; import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
@ -33,10 +34,12 @@ public class Inventory extends BaseOrder {
@Column(name="ASSIGN_COUNT") @Column(name="ASSIGN_COUNT")
@ApiParam(value ="已分配量") @ApiParam(value ="已分配量")
@FieldAnnotation(modify = false)
private Double assignCount; private Double assignCount;
@Column(name="EXCESS_COUNT") @Column(name="EXCESS_COUNT")
@ApiParam(value ="多余量") @ApiParam(value ="多余量")
@FieldAnnotation(modify = false)
private Double excessCount; private Double excessCount;
@JsonIgnore @JsonIgnore

@ -70,7 +70,7 @@ public class Material extends BaseCode {
@Column(name="LEVEL") @Column(name="LEVEL")
@ApiParam(value ="低阶码") @ApiParam(value ="低阶码")
@RippleAnnotation(dependence = {"OperOutputs.Operation.ProductRouting.Material"}, method = "calcLevel") @RippleAnnotation(dependence = {"OperInputs.Operation.ProductRouting.Material.level"}, method = "calcLevel")
@FieldAnnotation(modify = false) @FieldAnnotation(modify = false)
private Integer level; private Integer level;

@ -77,14 +77,17 @@ public class ProductOrder extends BaseOrder {
@Column(name="CALC_LEAD_TIME") @Column(name="CALC_LEAD_TIME")
@ApiParam(value ="提前期计算值") @ApiParam(value ="提前期计算值")
@FieldAnnotation(modify = false)
private String calcLeadTime; private String calcLeadTime;
@Column(name="EXCESS_COUNT") @Column(name="EXCESS_COUNT")
@ApiParam(value ="多余量") @ApiParam(value ="多余量")
@FieldAnnotation(modify = false)
private Double excessCount; private Double excessCount;
@Column(name="LACK_COUNT") @Column(name="LACK_COUNT")
@ApiParam(value ="缺少量") @ApiParam(value ="缺少量")
@FieldAnnotation(modify = false)
private Double lackCount; private Double lackCount;
@Column(name="AUTO_SUPPLY") @Column(name="AUTO_SUPPLY")

@ -1,5 +1,6 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation; import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder; import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
@ -41,10 +42,12 @@ public class PurchaseOrder extends BaseOrder {
@Column(name="CALC_LEAD_TIME") @Column(name="CALC_LEAD_TIME")
@ApiParam(value ="提前期计算值") @ApiParam(value ="提前期计算值")
@FieldAnnotation(modify = false)
private String calcLeadTime; private String calcLeadTime;
@Column(name="EXCESS_COUNT") @Column(name="EXCESS_COUNT")
@ApiParam(value ="多余量") @ApiParam(value ="多余量")
@FieldAnnotation(modify = false)
private Double excessCount; private Double excessCount;
@Column(name="AUTO_SUPPLY") @Column(name="AUTO_SUPPLY")

@ -1,7 +1,9 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BaseAPS; import cn.estsh.i3plus.pojo.aps.common.BaseAPS;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation; import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.enums.EDIT_TYPE;
import cn.estsh.i3plus.pojo.aps.holders.EResCalendar; import cn.estsh.i3plus.pojo.aps.holders.EResCalendar;
import com.fasterxml.jackson.annotation.JsonBackReference; import com.fasterxml.jackson.annotation.JsonBackReference;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
@ -27,6 +29,7 @@ import java.util.List;
public class ResCalendar extends BaseAPS { public class ResCalendar extends BaseAPS {
@Column(name="RES_CODES") @Column(name="RES_CODES")
@ApiParam(value ="资源代码") @ApiParam(value ="资源代码")
@FieldAnnotation(editType = EDIT_TYPE.MULTI_OBJECT, typeName = "Resource")
private String resCodes; private String resCodes;
@Column(name="WEEKS") @Column(name="WEEKS")

@ -1,5 +1,6 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation; import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder; import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
@ -42,6 +43,7 @@ public class SalesOrder extends BaseOrder {
@Column(name="CALC_LEAD_TIME") @Column(name="CALC_LEAD_TIME")
@ApiParam(value ="提前期计算值") @ApiParam(value ="提前期计算值")
@FieldAnnotation(modify = false)
private String calcLeadTime; private String calcLeadTime;
@JsonIgnore @JsonIgnore

@ -2,6 +2,7 @@ package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation; import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BaseAPS; import cn.estsh.i3plus.pojo.aps.common.BaseAPS;
import cn.estsh.i3plus.pojo.aps.enums.ROUTING_VALID_TYPE;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam; import io.swagger.annotations.ApiParam;
import lombok.Data; import lombok.Data;
@ -31,6 +32,10 @@ public class SysParam extends BaseAPS {
@ApiParam(value ="最大中断次数") @ApiParam(value ="最大中断次数")
private Integer maxInterruptCount; private Integer maxInterruptCount;
@Column(name="TYPE")
@ApiParam(value ="工艺路径有效判断类型")
private ROUTING_VALID_TYPE type;
@Column(name="RULE_GROUP_ID") @Column(name="RULE_GROUP_ID")
@ApiParam(value ="规则组id") @ApiParam(value ="规则组id")
@FieldAnnotation(display = false) @FieldAnnotation(display = false)

@ -31,10 +31,12 @@ import java.util.List;
public class Work extends BaseCode { public class Work extends BaseCode {
@Column(name="WORK_TYPE") @Column(name="WORK_TYPE")
@ApiParam(value ="工作类型") @ApiParam(value ="工作类型")
@FieldAnnotation(modify = false)
private WORK_TYPE workType; private WORK_TYPE workType;
@Column(name="count") @Column(name="count")
@ApiParam(value ="数量") @ApiParam(value ="数量")
@FieldAnnotation(modify = false)
private Double count; private Double count;
@Column(name="SPECIFY_COUNT") @Column(name="SPECIFY_COUNT")
@ -75,10 +77,12 @@ public class Work extends BaseCode {
@Column(name="CALC_EST") @Column(name="CALC_EST")
@ApiParam(value ="最早开始时间计算值") @ApiParam(value ="最早开始时间计算值")
@FieldAnnotation(modify = false)
private Date calcEst; private Date calcEst;
@Column(name="CALC_LET") @Column(name="CALC_LET")
@ApiParam(value ="最晚结束时间计算值") @ApiParam(value ="最晚结束时间计算值")
@FieldAnnotation(modify = false)
private Date calcLet; private Date calcLet;
@Column(name="WORK_STATUS") @Column(name="WORK_STATUS")
@ -87,14 +91,17 @@ public class Work extends BaseCode {
@Column(name="PLAN_BEGIN") @Column(name="PLAN_BEGIN")
@ApiParam(value ="计划开始时间") @ApiParam(value ="计划开始时间")
@FieldAnnotation(modify = false)
private Date planBegin; private Date planBegin;
@Column(name="PLAN_END") @Column(name="PLAN_END")
@ApiParam(value ="计划结束时间") @ApiParam(value ="计划结束时间")
@FieldAnnotation(modify = false)
private Date planEnd; private Date planEnd;
@Column(name="PLAN_RESOURCE") @Column(name="PLAN_RESOURCE")
@ApiParam(value ="计划主资源") @ApiParam(value ="计划主资源")
@FieldAnnotation(modify = false)
private String planResource; private String planResource;
@Column(name="FIX_SPLIT") @Column(name="FIX_SPLIT")
@ -103,14 +110,17 @@ public class Work extends BaseCode {
@Column(name="NEED_PREV_COUNT") @Column(name="NEED_PREV_COUNT")
@ApiParam(value ="需要的前工作数量") @ApiParam(value ="需要的前工作数量")
@FieldAnnotation(display = false, modify = false)
private Double needPrevCount; private Double needPrevCount;
@Column(name="SCH_FAILED") @Column(name="SCH_FAILED")
@ApiParam(value ="是否排程失败") @ApiParam(value ="是否排程失败")
@FieldAnnotation(modify = false)
private Boolean schFailed; private Boolean schFailed;
@Column(name="FAILED_REASON") @Column(name="FAILED_REASON")
@ApiParam(value ="排程失败原因") @ApiParam(value ="排程失败原因")
@FieldAnnotation(modify = false)
private String failedReason; private String failedReason;
@Column(name="ORDER_ID") @Column(name="ORDER_ID")

@ -29,14 +29,17 @@ import java.util.List;
public class WorkInput extends BaseAPS { public class WorkInput extends BaseAPS {
@Column(name="INPUT_TIME") @Column(name="INPUT_TIME")
@ApiParam(value ="输入时间") @ApiParam(value ="输入时间")
@FieldAnnotation(modify = false)
private Date inputTime; private Date inputTime;
@Column(name="INPUT_COUNT") @Column(name="INPUT_COUNT")
@ApiParam(value ="输入数量") @ApiParam(value ="输入数量")
@FieldAnnotation(modify = false)
private Double inputCount; private Double inputCount;
@Column(name="SHORT_COUNT") @Column(name="SHORT_COUNT")
@ApiParam(value ="短缺数量") @ApiParam(value ="短缺数量")
@FieldAnnotation(modify = false)
private Double shortCount; private Double shortCount;
@Column(name="WORK_ID") @Column(name="WORK_ID")

@ -30,14 +30,17 @@ import java.util.List;
public class WorkOutput extends BaseAPS { public class WorkOutput extends BaseAPS {
@Column(name="OUTPUT_TIME") @Column(name="OUTPUT_TIME")
@ApiParam(value ="输出时间") @ApiParam(value ="输出时间")
@FieldAnnotation(modify = false)
private Date outputTime; private Date outputTime;
@Column(name="OUTPUT_COUNT") @Column(name="OUTPUT_COUNT")
@ApiParam(value ="输出数量") @ApiParam(value ="输出数量")
@FieldAnnotation(modify = false)
private Double outputCount; private Double outputCount;
@Column(name="REMAIN_COUNT") @Column(name="REMAIN_COUNT")
@ApiParam(value ="多余数量") @ApiParam(value ="多余数量")
@FieldAnnotation(modify = false)
private Double remainCount; private Double remainCount;
@Column(name="WORK_ID") @Column(name="WORK_ID")

@ -1,5 +1,6 @@
package cn.estsh.i3plus.pojo.aps.bean; package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BaseAPS; import cn.estsh.i3plus.pojo.aps.common.BaseAPS;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation; import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EWorkPlan; import cn.estsh.i3plus.pojo.aps.holders.EWorkPlan;
@ -34,66 +35,82 @@ import java.util.List;
public class WorkPlan extends BaseAPS { public class WorkPlan extends BaseAPS {
@Column(name="PREV_SET_BEGIN") @Column(name="PREV_SET_BEGIN")
@ApiParam(value ="前设置开始时间") @ApiParam(value ="前设置开始时间")
@FieldAnnotation(modify = false)
private Date prevSetBegin; private Date prevSetBegin;
@Column(name="PREV_SET_END") @Column(name="PREV_SET_END")
@ApiParam(value ="前设置结束时间") @ApiParam(value ="前设置结束时间")
@FieldAnnotation(modify = false)
private Date prevSetEnd; private Date prevSetEnd;
@Column(name="PREV_SET_TIME") @Column(name="PREV_SET_TIME")
@ApiParam(value ="前设置时间") @ApiParam(value ="前设置时间")
@FieldAnnotation(modify = false)
private Integer prevSetTime; private Integer prevSetTime;
@Column(name="PRODUCE_BEGIN") @Column(name="PRODUCE_BEGIN")
@ApiParam(value ="生产开始时间") @ApiParam(value ="生产开始时间")
@FieldAnnotation(modify = false)
private Date produceBegin; private Date produceBegin;
@Column(name="PRODUCE_END") @Column(name="PRODUCE_END")
@ApiParam(value ="生产结束时间") @ApiParam(value ="生产结束时间")
@FieldAnnotation(modify = false)
private Date produceEnd; private Date produceEnd;
@Column(name="PRODUCE_TIME") @Column(name="PRODUCE_TIME")
@ApiParam(value ="生产时间") @ApiParam(value ="生产时间")
@FieldAnnotation(modify = false)
private Integer produceTime; private Integer produceTime;
@Column(name="POST_SET_BEGIN") @Column(name="POST_SET_BEGIN")
@ApiParam(value ="后设置开始时间") @ApiParam(value ="后设置开始时间")
@FieldAnnotation(modify = false)
private Date postSetBegin; private Date postSetBegin;
@Column(name="POST_SET_END") @Column(name="POST_SET_END")
@ApiParam(value ="后设置结束时间") @ApiParam(value ="后设置结束时间")
@FieldAnnotation(modify = false)
private Date postSetEnd; private Date postSetEnd;
@Column(name="POST_SET_TIME") @Column(name="POST_SET_TIME")
@ApiParam(value ="后设置时间") @ApiParam(value ="后设置时间")
@FieldAnnotation(modify = false)
private Integer postSetTime; private Integer postSetTime;
@Column(name="LOCK_BEGIN") @Column(name="LOCK_BEGIN")
@ApiParam(value ="锁定开始时间") @ApiParam(value ="锁定开始时间")
@FieldAnnotation(modify = false)
private Date lockBegin; private Date lockBegin;
@Column(name="LOCK_END") @Column(name="LOCK_END")
@ApiParam(value ="锁定结束时间") @ApiParam(value ="锁定结束时间")
@FieldAnnotation(modify = false)
private Date lockEnd; private Date lockEnd;
@Column(name="LOCK_TIME") @Column(name="LOCK_TIME")
@ApiParam(value ="锁定时间") @ApiParam(value ="锁定时间")
@FieldAnnotation(modify = false)
private Integer lockTime; private Integer lockTime;
@Column(name="WORK_ID") @Column(name="WORK_ID")
@ApiParam(value ="工作对象id") @ApiParam(value ="工作对象id")
@FieldAnnotation(property = false)
private Long workId; private Long workId;
@Column(name="RESOURCE_ID") @Column(name="RESOURCE_ID")
@ApiParam(value ="资源对象id") @ApiParam(value ="资源对象id")
@FieldAnnotation(property = false)
private Long resourceId; private Long resourceId;
@Column(name="WORK_RESOURCE_ID") @Column(name="WORK_RESOURCE_ID")
@ApiParam(value ="工作资源对象id") @ApiParam(value ="工作资源对象id")
@FieldAnnotation(property = false)
private Long workResourceId; private Long workResourceId;
@Column(name="MAIN_PLAN_ID") @Column(name="MAIN_PLAN_ID")
@ApiParam(value ="主计划对象id") @ApiParam(value ="主计划对象id")
@FieldAnnotation(property = false)
private Long mainPlanId; private Long mainPlanId;
public Work getWork() { return BeanRelation.get(this, EWorkPlan.Work); } public Work getWork() { return BeanRelation.get(this, EWorkPlan.Work); }

@ -29,22 +29,27 @@ import javax.persistence.Table;
public class WorkRelation extends BaseAPS { public class WorkRelation extends BaseAPS {
@Column(name="TYPE") @Column(name="TYPE")
@ApiParam(value ="关联类型") @ApiParam(value ="关联类型")
@FieldAnnotation(modify = false)
private WORK_RELATION_TYPE type; private WORK_RELATION_TYPE type;
@Column(name="CONS_TYPE") @Column(name="CONS_TYPE")
@ApiParam(value ="接续方式") @ApiParam(value ="接续方式")
@FieldAnnotation(modify = false)
private CONSTRAINT_TYPE consType; private CONSTRAINT_TYPE consType;
@Column(name="MAX_SPACE_TIME") @Column(name="MAX_SPACE_TIME")
@ApiParam(value ="最大间隔时间") @ApiParam(value ="最大间隔时间")
@FieldAnnotation(modify = false)
private String maxSpaceTime; private String maxSpaceTime;
@Column(name="MIN_SPACE_TIME") @Column(name="MIN_SPACE_TIME")
@ApiParam(value ="最小间隔时间") @ApiParam(value ="最小间隔时间")
@FieldAnnotation(modify = false)
private String minSpaceTime; private String minSpaceTime;
@Column(name="COUNT") @Column(name="COUNT")
@ApiParam(value ="关联数量") @ApiParam(value ="关联数量")
@FieldAnnotation(modify = false)
private Double count; private Double count;
@Column(name="FIX_RELATION") @Column(name="FIX_RELATION")

@ -28,38 +28,47 @@ import javax.persistence.Table;
public class WorkResource extends BaseAPS { public class WorkResource extends BaseAPS {
@Column(name="USE_TYPE") @Column(name="USE_TYPE")
@ApiParam(value ="使用类型") @ApiParam(value ="使用类型")
@FieldAnnotation(modify = false)
private USE_TYPE useType; private USE_TYPE useType;
@Column(name="PREV_TIME") @Column(name="PREV_TIME")
@ApiParam(value ="前设置时间") @ApiParam(value ="前设置时间")
@FieldAnnotation(modify = false)
private Long prevTime; private Long prevTime;
@Column(name="PRODUCE_TIME") @Column(name="PRODUCE_TIME")
@ApiParam(value ="制造时间") @ApiParam(value ="制造时间")
@FieldAnnotation(modify = false)
private Long produceTime; private Long produceTime;
@Column(name="POST_TIME") @Column(name="POST_TIME")
@ApiParam(value ="后设置时间") @ApiParam(value ="后设置时间")
@FieldAnnotation(modify = false)
private Long postTime; private Long postTime;
@Column(name="PRIORITY") @Column(name="PRIORITY")
@ApiParam(value ="优先级") @ApiParam(value ="优先级")
@FieldAnnotation(modify = false)
private Integer priority; private Integer priority;
@Column(name="MAX_PREV_SD_TIME") @Column(name="MAX_PREV_SD_TIME")
@ApiParam(value ="最大前设置中断时间") @ApiParam(value ="最大前设置中断时间")
@FieldAnnotation(modify = false)
private String maxPrevSdTime; private String maxPrevSdTime;
@Column(name="MAX_PRODUCE_SD_TIME") @Column(name="MAX_PRODUCE_SD_TIME")
@ApiParam(value ="最大制造中断时间") @ApiParam(value ="最大制造中断时间")
@FieldAnnotation(modify = false)
private String maxProduceSdTime; private String maxProduceSdTime;
@Column(name="MAX_POST_SD_TIME") @Column(name="MAX_POST_SD_TIME")
@ApiParam(value ="最大后设置中断时间") @ApiParam(value ="最大后设置中断时间")
@FieldAnnotation(modify = false)
private String maxPostSdTime; private String maxPostSdTime;
@Column(name="USER_MATCH_NUMBER") @Column(name="USER_MATCH_NUMBER")
@ApiParam(value ="资源使用配套号") @ApiParam(value ="资源使用配套号")
@FieldAnnotation(modify = false)
private String userMatchNumber; private String userMatchNumber;
@Column(name="WORK_ID") @Column(name="WORK_ID")

@ -1,10 +1,14 @@
package cn.estsh.i3plus.pojo.aps.common; package cn.estsh.i3plus.pojo.aps.common;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.base.bean.BaseBean; import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiParam;
import lombok.Data; import lombok.Data;
import javax.persistence.Column;
import javax.persistence.MappedSuperclass; import javax.persistence.MappedSuperclass;
import javax.persistence.Transient;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
@ -22,6 +26,12 @@ public abstract class BaseAPS extends BaseBean {
@JsonIgnore @JsonIgnore
private transient Map<String, Object> customFields = new HashMap<>(); private transient Map<String, Object> customFields = new HashMap<>();
@Column(name="KEY")
@ApiParam(value ="主键值")
@FieldAnnotation(display = false, modify = false)
@Transient
private String key;
public Object getCustomField(String code) { public Object getCustomField(String code) {
return customFields.get(code); return customFields.get(code);
} }

@ -19,7 +19,7 @@ import javax.persistence.MappedSuperclass;
public abstract class BaseCode extends BaseAPS { public abstract class BaseCode extends BaseAPS {
@Column(name="CODE") @Column(name="CODE")
@ApiParam(value ="编码") @ApiParam(value ="编码")
@FieldAnnotation(popSearch = true) @FieldAnnotation(popSearch = true, mainkey = true)
private String code; private String code;
@Column(name="NAME") @Column(name="NAME")

@ -2,10 +2,7 @@ package cn.estsh.i3plus.pojo.aps.common;
import cn.estsh.i3plus.pojo.base.bean.BaseBean; import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import java.util.ArrayList; import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentHashMap;
import java.util.function.Predicate; import java.util.function.Predicate;
@ -235,6 +232,34 @@ public class BeanRelation {
return index == 0 && bNotLast; return index == 0 && bNotLast;
} }
/**
*
* @param bean
* @param holder
* @param args
* @param <T>
* @return List
*/
public static <T extends BaseBean> Set<T> listUnique(BaseBean bean, Enum<?> holder, Enum<?>... args) {
Set<T> result = new HashSet<>();
List<BaseBean> nextBeans = list(bean, holder);
for (BaseBean nextBean : nextBeans) {
listUniqueImpl(result, nextBean, args, 0);
}
result.remove(bean);
return result;
}
private static <T extends BaseBean> void listUniqueImpl(Set<T> result, BaseBean bean, Enum<?>[] holders, int index) {
if (index >= holders.length) {
result.add((T)bean);
} else {
List<BaseBean> nextBeans = list(bean, holders[index]);
for (BaseBean nextBean : nextBeans) {
listUniqueImpl(result, nextBean, holders, index + 1);
}
}
}
/** /**
@ -400,4 +425,38 @@ public class BeanRelation {
recursionImpl(relaBean, fun, holders, index + 1); recursionImpl(relaBean, fun, holders, index + 1);
} }
} }
/**
* targetbeanholders
* @param bean
* @param target
* @param holders
* @return
*/
public static boolean recursionContains(BaseBean bean, BaseBean target, Enum<?>... holders) {
if (holders.length == 0) {
return false;
}
return recursionContainsImpl(bean, target, holders, 0);
}
private final static boolean recursionContainsImpl(BaseBean bean, BaseBean target,
Enum<?>[] holders, int index) {
if (index >= holders.length) {
if (target == bean) {
return true;
}
index = 0;
}
List<BaseBean> relaBeans = list(bean, holders[index]);
for (BaseBean relaBean : relaBeans) {
if (recursionContainsImpl(relaBean, target, holders, index + 1)) {
return true;
}
}
return false;
}
} }

@ -25,7 +25,7 @@ public class DateDuration {
public static final double PRECISION = 0.00001; public static final double PRECISION = 0.00001;
private String value; private String value;
private long time = 0; private int time = 0;
private double rate = 0.0; private double rate = 0.0;
private boolean bValid = false; private boolean bValid = false;
@ -60,7 +60,7 @@ public class DateDuration {
* 0 * 0
* @return * @return
*/ */
public long getTime() { public int getTime() {
return this.time; return this.time;
} }
@ -68,7 +68,7 @@ public class DateDuration {
* *
* @return * @return
*/ */
public void setTime(long time) { public void setTime(int time) {
this.time = time; this.time = time;
} }

@ -0,0 +1,28 @@
package cn.estsh.i3plus.pojo.aps.enums;
/**
* @Description :
* @Reference :
* @Author : jason.niu
* @CreateDate : 2019-09-17
* @Modify:
**/
public enum EDIT_TYPE {
NONE,
BOOLEAN, // 布尔, 开关编辑
CHAR, // 字符, 文本框编辑
SHORT, // 短整型, 数字编辑
INTEGER, // 整型, 数字编辑
LONG, // 长整型, 数字编辑
DOUBLE, // 浮点型, 文本框编辑
DATE, // 日期类型(2019-09-16)
TIME, // 时间类型(17:35:30)
DATE_TIME, // 日期时间类型(2019-09-16 17:35:30)
DURATION, // 时间段(1H),文本框编辑
ENUM, // 枚举,下拉选择
MULTI_ENUM, // 多选枚举, 下拉多选
STRING, // 字符串,文本框编辑
OBJECT, // 关联对象下来选择关联对象的Code值
LIST, // 对象集合,不可编辑。
MULTI_OBJECT // 多选对象,弹出框选择,可以选择全部对象,以*表示选择全部
}

@ -0,0 +1,14 @@
package cn.estsh.i3plus.pojo.aps.enums;
/**
* @Description :
* @Reference :
* @Author : jason.niu
* @CreateDate : 2019-10-29
* @Modify:
**/
public enum ROUTING_VALID_TYPE {
ORDER_CALC_LET, // 与订单的最晚结束时刻计算值做比较
CALC_LET_LT, // 与最晚结束时刻计算值-提前期做比较
BASE_TIME // 与基准时刻做比较
}

@ -12,6 +12,43 @@ import com.fasterxml.jackson.annotation.JsonFormat;
public class MesEnumUtil { public class MesEnumUtil {
/** /**
* MesScrap
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum SCRAP_TYPE {
SCRAP_TYPE(10, "过期"),
SCRAP_TYPE2(20, "不合格"),
SCRAP_TYPE3(30, "缺失");
private int value;
private String description;
SCRAP_TYPE(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;
}
}
/**
* mes * mes
*/ */
@JsonFormat(shape = JsonFormat.Shape.OBJECT) @JsonFormat(shape = JsonFormat.Shape.OBJECT)

@ -12,6 +12,155 @@ import org.apache.commons.lang3.StringUtils;
**/ **/
public class MesPcnEnumUtil { public class MesPcnEnumUtil {
/**
* MesScrap
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum SCRAP_TYPE {
SCRAP_TYPE(10, "过期"),
SCRAP_TYPE2(20, "不合格"),
SCRAP_TYPE3(30, "缺失");
private int value;
private String description;
SCRAP_TYPE(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;
}
}
/**
* MesProduceSnqcStatus
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum PRODUCE_SN_QC_STATUS {
QUALIFIED(10, "合格"),
DEFECTED(20, "不合格"),
SCRAPED(30, "报废"),
DISMANTLED(40, "已拆解");
private int value;
private String description;
PRODUCE_SN_QC_STATUS(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;
}
}
/**
* mes
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum MES_WORK_CELL_TYPE {
NORMAL(10, "正常"),
REWORK(20, "返修");
private int value;
private String description;
MES_WORK_CELL_TYPE(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;
}
}
/**
* mes
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum MES_PRODUCE_SN_RESULT {
OK(10, "OK");
private int value;
private String description;
MES_PRODUCE_SN_RESULT(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;
}
}
/** /**
* mes * mes
*/ */

@ -53,6 +53,10 @@ public class MesDefectRecord extends BaseBean {
@ApiParam("缺陷位置") @ApiParam("缺陷位置")
private String defectLocation; private String defectLocation;
@Column(name = "SIDE_LOCATION")
@ApiParam("面位")
private String sideLocation;
@Column(name="REPAIR_STATUS") @Column(name="REPAIR_STATUS")
@ApiParam("维修状态") @ApiParam("维修状态")
private Integer repairStatus; private Integer repairStatus;

@ -95,6 +95,14 @@ public class MesProcessBom extends BaseBean {
@ApiParam("显示颜色") @ApiParam("显示颜色")
private String color; private String color;
@Transient
@ApiParam("关键件代码")
private String keyBarCode;
@Transient
@ApiParam("产品条码")
private String serialNumber;
public double getQtyVal() { public double getQtyVal() {
return this.qty == null ? 0.0d : this.qty; return this.qty == null ? 0.0d : this.qty;

@ -73,4 +73,15 @@ public class MesQcCheckStandard extends BaseBean {
@ApiParam("检测值") @ApiParam("检测值")
private String checkValue; private String checkValue;
public MesQcCheckStandard(String partNo, String workCenterCode, String workCellCode, Integer checkType, String checkItem, String checkStandard, String checkGuide, String checkFrequency, String partName) {
this.partNo = partNo;
this.workCenterCode = workCenterCode;
this.workCellCode = workCellCode;
this.checkType = checkType;
this.checkItem = checkItem;
this.checkStandard = checkStandard;
this.checkGuide = checkGuide;
this.checkFrequency = checkFrequency;
this.partName = partName;
}
} }

@ -36,4 +36,8 @@ public class MesScrap extends BaseBean {
@ApiParam("报废名称") @ApiParam("报废名称")
private String scrapName; private String scrapName;
@Column(name = "SCRAP_TYPE")
@ApiParam("报废类型")
private String scrapType;
} }

@ -60,10 +60,6 @@ public class MesScrapRecord extends BaseBean {
@ApiParam("工位") @ApiParam("工位")
private String workCellCode; private String workCellCode;
@Column(name = "SCRAP_REASON")
@ApiParam("报废原因")
private String scrapReason;
@Column(name = "MEMO") @Column(name = "MEMO")
@ApiParam("备注") @ApiParam("备注")
private String memo; private String memo;

@ -36,6 +36,16 @@ public class MesProdBindRecordModel {
private Integer missQty; private Integer missQty;
@ApiParam("报废数") @ApiParam("报废数")
private Integer scrapQty; private Integer scrapQty;
@ApiParam("创建时间")
private String createUser;
@ApiParam("创建时间")
private String createDatetime;
@ApiParam("修改人")
private String modifyUser;
@ApiParam("修改时间")
private String modifyDatetime;
@ApiParam("产品条码")
private String serialNumber;
public MesProdBindRecordModel() { public MesProdBindRecordModel() {
} }
@ -72,4 +82,26 @@ public class MesProdBindRecordModel {
this.parentPartNo = parentPartNo; this.parentPartNo = parentPartNo;
this.parentPartName = parentPartName; this.parentPartName = parentPartName;
} }
public MesProdBindRecordModel(Long id, String itemPartNo, String itemPartName, Double qty, Integer isValid, Integer isDeleted, String organizeCode, Integer isFeed, String workCenterCode, String workCellCode, String kpSn, String parentPartNo, String parentPartName, String createUser, String createDatetime, String modifyUser, String modifyDatetime, String serialNumber) {
this.id = id;
this.itemPartNo = itemPartNo;
this.itemPartName = itemPartName;
this.qty = qty;
this.isValid = isValid;
this.isDeleted = isDeleted;
this.organizeCode = organizeCode;
this.isFeed = isFeed;
this.workCenterCode = workCenterCode;
this.workCellCode = workCellCode;
this.kpSn = kpSn;
this.parentPartNo = parentPartNo;
this.parentPartName = parentPartName;
this.createUser = createUser;
this.createDatetime = createDatetime;
this.modifyUser = modifyUser;
this.modifyDatetime = modifyDatetime;
this.serialNumber = serialNumber;
}
} }

@ -220,4 +220,64 @@ public class MesHqlPack {
return packBean; return packBean;
} }
/**
* MES PCN
*
* @param mesRepair
* @return
*/
public static DdlPackBean getMesRepair(MesRepair mesRepair, String organizeCode) {
DdlPackBean packBean = getAllBaseData(organizeCode);
if (StringUtils.isNotEmpty(mesRepair.getRepairCode())) {
DdlPreparedPack.getStringLikerPack(mesRepair.getRepairCode(), "repairCode", packBean);
}
if (StringUtils.isNotEmpty(mesRepair.getRepairName())) {
DdlPreparedPack.getStringLikerPack(mesRepair.getRepairName(), "repairName", packBean);
}
if (mesRepair.getRepairType() != null) {
DdlPreparedPack.getNumEqualPack(mesRepair.getRepairType(), "repairType", packBean);
}
return packBean;
}
/**
* MES PCN
*
* @param mesScrap
* @return
*/
public static DdlPackBean getMesScrap(MesScrap mesScrap, String organizeCode) {
DdlPackBean packBean = getAllBaseData(organizeCode);
if (StringUtils.isNotEmpty(mesScrap.getScrapCode())) {
DdlPreparedPack.getStringLikerPack(mesScrap.getScrapCode(), "scrapCode", packBean);
}
if (StringUtils.isNotEmpty(mesScrap.getScrapName())) {
DdlPreparedPack.getStringLikerPack(mesScrap.getScrapName(), "scrapName", packBean);
}
if (StringUtils.isNotEmpty(mesScrap.getScrapType())) {
DdlPreparedPack.getStringLikerPack(mesScrap.getScrapType(), "scrapType", packBean);
}
return packBean;
}
/**
* MES PCN
*
* @param mesDefectCause
* @return
*/
public static DdlPackBean getMesDefectCause(MesDefectCause mesDefectCause, String organizeCode) {
DdlPackBean packBean = getAllBaseData(organizeCode);
if (StringUtils.isNotEmpty(mesDefectCause.getDcCode())) {
DdlPreparedPack.getStringLikerPack(mesDefectCause.getDcCode(), "dcCode", packBean);
}
if (StringUtils.isNotEmpty(mesDefectCause.getDcName())) {
DdlPreparedPack.getStringLikerPack(mesDefectCause.getDcName(), "dcName", packBean);
}
if (mesDefectCause.getDcType() != null) {
DdlPreparedPack.getNumEqualPack(mesDefectCause.getDcType(), "dcType", packBean);
}
return packBean;
}
} }

@ -41,6 +41,10 @@ public class MesEquNotifyObjectCfg extends BaseBean {
@ApiParam("对象值") @ApiParam("对象值")
private String notifyObjectValue; private String notifyObjectValue;
@Column(name="NOTIFY_OBJECT_VALUE_RDD")
@ApiParam("对象值")
private String notifyObjectValueRdd;
@Column(name="NOTIFY_OBJECT_TYPE") @Column(name="NOTIFY_OBJECT_TYPE")
@ApiParam("对象类型") @ApiParam("对象类型")
private Integer notifyObjectType; private Integer notifyObjectType;

@ -0,0 +1,23 @@
package cn.estsh.i3plus.pojo.mes.model;
import io.swagger.annotations.ApiParam;
import lombok.Data;
/**
* @Description : Model
* @Reference :
* @Author : jack.jia
* @CreateDate : 2019-10-28
* @Modify:
**/
@Data
public class NormalityModel {
@ApiParam("节点")
double node;
@ApiParam("发生频次")
int times;
@ApiParam("开始节点")
double from;
@ApiParam("结束节点")
double to;
}

@ -0,0 +1,43 @@
package cn.estsh.i3plus.pojo.mes.model;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import java.util.List;
/**
* @Description :
* @Reference :
* @Author : jack.jia
* @CreateDate : 2019-10-28
* @Modify:
**/
@Data
public class XrSampleModel {
@ApiParam("样本数量")
private int sampleCount;
@ApiParam("样本组数")
private int groupCount;
@ApiParam("每组个数")
private int preGroupCount;
@ApiParam("A2值")
private double a2;
@ApiParam("D3值")
private double d3;
@ApiParam("D4值")
private double d4;
@ApiParam("均值平均数")
private double xAver;
@ApiParam("均值控制上限")
private double xUcl;
@ApiParam("均值控制下限")
private double xLcl;
@ApiParam("极差平均数")
private double rAver;
@ApiParam("极差控制上限")
private double rUcl;
@ApiParam("极差控制下限")
private double rLcl;
}

@ -1454,8 +1454,8 @@ public class MesHqlPack {
if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectName())) { if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectName())) {
DdlPreparedPack.getStringLikerPack(mesEquNotifyObjectCfg.getNotifyObjectName(), "notifyObjectName", packBean); DdlPreparedPack.getStringLikerPack(mesEquNotifyObjectCfg.getNotifyObjectName(), "notifyObjectName", packBean);
} }
if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectValue())) { if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectValueRdd())) {
DdlPreparedPack.getStringLikerPack(mesEquNotifyObjectCfg.getNotifyObjectValue(), "notifyObjectValue", packBean); DdlPreparedPack.getStringLikerPack(mesEquNotifyObjectCfg.getNotifyObjectValue(), "notifyObjectValueRdd", packBean);
} }
if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectType())) { if (!StringUtils.isEmpty(mesEquNotifyObjectCfg.getNotifyObjectType())) {
DdlPreparedPack.getNumEqualPack(mesEquNotifyObjectCfg.getNotifyObjectType(), "notifyObjectType", packBean); DdlPreparedPack.getNumEqualPack(mesEquNotifyObjectCfg.getNotifyObjectType(), "notifyObjectType", packBean);

@ -185,6 +185,10 @@ public class WmsMoveDetails extends BaseBean {
@Transient @Transient
private Integer isSnapshot; private Integer isSnapshot;
@Transient
@ApiParam(value = "车号")
private String carNo;
public Integer getIsSnapshot() { public Integer getIsSnapshot() {
return isSnapshot == null ? 0 : isSnapshot.intValue(); return isSnapshot == null ? 0 : isSnapshot.intValue();
} }
@ -225,12 +229,14 @@ public class WmsMoveDetails extends BaseBean {
public Long getFinishedCounts() { public Long getFinishedCounts() {
return finishedCounts == null ? 0L : this.finishedCounts; return finishedCounts == null ? 0L : this.finishedCounts;
} }
public WmsMoveDetails(String partNo, String partNameRdd, String unit, Double transQty) { public WmsMoveDetails(String partNo, String partNameRdd, String unit, Double transQty) {
this.partNo = partNo; this.partNo = partNo;
this.partNameRdd = partNameRdd; this.partNameRdd = partNameRdd;
this.unit = unit; this.unit = unit;
this.transQty = transQty; this.transQty = transQty;
} }
public WmsMoveDetails(String organizeCode, String partNo, String partNameRdd, String workCenterCode, String fPartNo, String fPartName, String unit, Double qty, public WmsMoveDetails(String organizeCode, String partNo, String partNameRdd, String workCenterCode, String fPartNo, String fPartName, String unit, Double qty,
String createDateTime, String sn, String srcZoneNo) { String createDateTime, String sn, String srcZoneNo) {
this.organizeCode = organizeCode; this.organizeCode = organizeCode;

@ -182,11 +182,12 @@ public class WmsPart extends BaseBean {
public WmsPart() { public WmsPart() {
} }
public WmsPart(String partNo, String partName, Double maxQty, Double minQty, Double cqty) { public WmsPart(String partNo, String partName, Double maxQty, Double minQty, Double cqty, String partType) {
this.partNo = partNo; this.partNo = partNo;
this.partName = partName; this.partName = partName;
this.max = maxQty; this.max = maxQty;
this.min = minQty; this.min = minQty;
this.qty = cqty; this.qty = cqty;
this.partType = partType;
} }
} }

Loading…
Cancel
Save