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

yun-zuoyi
puxiao.liao 4 years ago
commit 988c49762b

@ -8,7 +8,7 @@ import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder;
import cn.estsh.i3plus.pojo.aps.validator.InsertGroup;
import cn.estsh.i3plus.pojo.aps.validator.UpdateGroup;
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import cn.estsh.i3plus.pojo.base.enumutil.ApsEnumUtil;
import com.fasterxml.jackson.annotation.JsonBackReference;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
@ -57,10 +57,10 @@ public class BaseOrder extends BaseAPS {
@Min(0)
private Double count;
@Column(name="PRIORITY")
@Column(name="PRIORITY_ID")
@ApiParam(value ="优先级")
@FieldAnnotation(defaultValue = "10")
private Integer priority;
@FieldAnnotation(relation = "Priority")
private Long priorityId;
@Column(name="LET")
@ApiParam(value ="最晚结束时刻")
@ -97,7 +97,7 @@ public class BaseOrder extends BaseAPS {
@Column(name="VALID_ORDER")
@ApiParam(value ="有效订单")
@FieldAnnotation(modify = false)
private Integer validOrder = CommonEnumUtil.VALID;
private ApsEnumUtil.ORDER_VALID_TYPE validOrder = ApsEnumUtil.ORDER_VALID_TYPE.VALID;
@Column(name="DELAY")
@ApiParam(value ="是否延期")
@ -127,4 +127,11 @@ public class BaseOrder extends BaseAPS {
public List<WorkRelation> getPostRelations() {
return BeanRelation.list(this, EBaseOrder.PostRelations);
}
public PriorityType getPriority() { return BeanRelation.get(this, EBaseOrder.Priority); }
public void setPriority(PriorityType priority) {
this.priorityId = priority != null ? priority.getId() : 0;
BeanRelation.set(this, EBaseOrder.Priority, priority);
}
}

@ -54,6 +54,14 @@ public class ImportField extends BaseAPS {
@FieldAnnotation(defaultValue = "255")
private Integer maxLength;
@Column(name="VALIDATOR")
@ApiParam("校验表达式")
private String validator;
@Column(name="VALIDATOR_MESSAGE")
@ApiParam("校验表达式报错")
private String validatorMessage;
@Column(name="RELATION_TABLE")
@ApiParam("关联表名")
private String relationTable;

@ -7,6 +7,7 @@ import cn.estsh.i3plus.pojo.aps.common.BaseAPS;
import cn.estsh.i3plus.pojo.aps.common.BeanRelation;
import cn.estsh.i3plus.pojo.aps.holders.EBaseOrder;
import cn.estsh.i3plus.pojo.aps.holders.EMaterial;
import cn.estsh.i3plus.pojo.aps.holders.EResource;
import cn.estsh.i3plus.pojo.aps.validator.InsertGroup;
import cn.estsh.i3plus.pojo.aps.validator.UpdateGroup;
import cn.estsh.i3plus.pojo.base.enumutil.ApsEnumUtil;
@ -157,6 +158,11 @@ public class Material extends BaseAPS {
@ApiParam(value ="标签颜色")
private String labelColor;
@Column(name="WORK_SHOP_ID")
@ApiParam(value ="车间代码")
@FieldAnnotation(relation = "WorkShop")
private Long workShopId;
public Material getGroup() {
return BeanRelation.get(this, EMaterial.Group);
}
@ -223,4 +229,11 @@ public class Material extends BaseAPS {
public List<ProductOrder> getProductOrders() {
return BeanRelation.listByClass(this, ProductOrder.class, EMaterial.Orders);
}
public WorkShop getWorkShop() { return BeanRelation.get(this, EMaterial.WorkShop); }
public void setWorkShop(WorkShop workShop) {
this.workShopId = workShop != null ? workShop.getId() : 0l;
BeanRelation.set(this, EMaterial.WorkShop, workShop);
}
}

@ -30,13 +30,13 @@ public class OrderFeedback extends BaseAPS {
private static final long serialVersionUID = 7822380202121225936L;
@Column(name="ORDER_ID")
@ApiParam(value ="订单")
@FieldAnnotation(property = false)
@ApiParam(value ="顶层订单")
@FieldAnnotation(relation = "Order", modify = false)
private Long orderId;
@Column(name="DELIVER_RATE")
@ApiParam(value ="发货百分比")
private transient Double deliverRate;
private Double deliverRate;
@Column(name="QUALIFIED_RATE")
@ApiParam(value ="成品合格百分比")
@ -46,14 +46,28 @@ public class OrderFeedback extends BaseAPS {
@ApiParam(value ="库存扣减数量")
private Double inventoryCount;
@Column(name="LAST_OPERATION_COUNT")
@ApiParam(value ="硫化报工数量")
private Double lastOperationCount;
@Column(name="UNQUALIFIED_COUNT")
@ApiParam(value ="不良数量")
private Double unqualifiedCount;
@Column(name="QUALIFIED_COUNT")
@ApiParam(value ="合格数量")
@ApiParam(value ="成品合格数量")
private Double qualifiedCount;
@Column(name="ADD_UNQUALIFIED_COUNT")
@ApiParam(value ="累加不良数量")
@FieldAnnotation(display = false)
private Double addUnqualifiedCount;
@Column(name="ADD_QUALIFIED_COUNT")
@ApiParam(value ="累加合格数量")
@FieldAnnotation(display = false)
private Double addQualifiedCount;
public BaseOrder getOrder() {
return BeanRelation.get(this, EOrderFeedback.Order);
}

@ -0,0 +1,38 @@
package cn.estsh.i3plus.pojo.aps.bean;
import cn.estsh.i3plus.pojo.aps.annotation.FieldAnnotation;
import cn.estsh.i3plus.pojo.aps.common.BaseAPS;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
/**
* @Description :
* @Reference :
* @Author : jason.niu
* @CreateDate : 2021-04-08
* @Modify:
**/
@Data
@EqualsAndHashCode(callSuper = true)
@Entity
@Table(name = "APS_PRIORITY_TYPE")
@Api("优先级")
public class PriorityType extends BaseAPS {
private static final long serialVersionUID = 445577901076659576L;
@Column(name="CODE")
@ApiParam(value ="标识")
@FieldAnnotation(mainkey = true, popSearch = true)
private String code;
@Column(name="VALUE")
@ApiParam(value ="值")
@FieldAnnotation(notEmpty = true, popSearch = true)
private Integer value;
}

@ -33,7 +33,7 @@ public class WorkShop extends BaseAPS {
@Column(name="NAME")
@ApiParam(value ="名称")
@FieldAnnotation(popSearch = true)
@FieldAnnotation(popSearch = true, notEmpty = true)
private String name;

@ -5,4 +5,5 @@ public enum EBaseOrder {
Material,
PrevRelations,
PostRelations,
Priority,
}

@ -9,5 +9,6 @@ public enum EMaterial {
WorkInputs,
WorkOutputs,
WorkRelations,
Orders
Orders,
WorkShop
}

@ -0,0 +1,9 @@
package cn.estsh.i3plus.pojo.aps.repository;
import cn.estsh.i3plus.pojo.aps.bean.PriorityType;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Repository;
@Repository
public interface PriorityTypeRepository extends CrudRepository<PriorityType, Long> {
}

@ -8,4 +8,6 @@
</Relation>
<Relation field="PrevRelations" name="WorkRelation" reverse="PostOrder" type="ONE_TO_MULTI" owner="false">
</Relation>
<Relation field="priority" name="PriorityType" type="MULTI_TO_ONE" owner="false">
</Relation>
</Class>

@ -4,4 +4,6 @@
</Relation>
<Relation field="Childs" name="Material" reverse="Group" type="ONE_TO_MULTI" owner="false">
</Relation>
<Relation field="WorkShop" name="WorkShop" type="MULTI_TO_ONE" owner="false">
</Relation>
</Class>

@ -81,6 +81,31 @@ public class ApsEnumUtil {
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum ORDER_VALID_TYPE {
VALID("VALID", "有效"),
INVALID("INVALID", "无效");
private String value;
private String description;
ORDER_VALID_TYPE(String value, String description) {
this.value = value;
this.description = description;
}
public String getValue() {
return value;
}
public String getDescription() {
return description;
}
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
@ -1228,4 +1253,29 @@ public class ApsEnumUtil {
return description;
}
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum SANLUX_OPERATION_TYPE {
NORMAL("NORMAL", "正常工序"),
FOUR_SULFIDATION("FOUR_SULFIDATION", "四车间硫化");
private String value;
private String description;
SANLUX_OPERATION_TYPE(String value, String description) {
this.value = value;
this.description = description;
}
public String getValue() {
return value;
}
public String getDescription() {
return description;
}
}
}

@ -207,6 +207,10 @@ public class MesPackage extends BaseBean implements Serializable {
@ApiParam("工序名称")
private String processName;
@Transient
@ApiParam("产品条码")
private String productSn;
public MesPackage() {
}

@ -40,6 +40,9 @@ public class MesControlPlanModel {
@ApiParam("是否启用")
private Integer isEnable;
@ApiParam("是否删除")
private Integer isCutOut;
@ApiParam("质量标准数组")
private List<MesQualityStandardModel> standardList;

@ -63,7 +63,7 @@ public class WmsPrintingQueue extends BaseBean{
public WmsPrintingQueue() {
}
public WmsPrintingQueue(Long id) {
this.id = id;
public WmsPrintingQueue(String printIdentification) {
this.printIdentification = printIdentification;
}
}
Loading…
Cancel
Save