合并dev分支代码

yun-zuoyi
钮海涛 5 years ago
commit 9878547daa

@ -15,6 +15,7 @@ import org.springframework.data.mongodb.core.index.Indexed;
import javax.persistence.*;
import java.io.Serializable;
import java.util.LinkedHashMap;
/**
* @Description :
@ -142,24 +143,41 @@ public abstract class BaseBean implements Serializable {
public transient Integer ascOrDesc = 1;
public int getIsValidVal() {
return this.isValid == null ? 0 : this.isValid.intValue();
return this.isValid == null ? 0 : this.isValid;
}
public int getIsDeletedVal() {
return this.isDeleted == null ? 0 : this.isDeleted.intValue();
return this.isDeleted == null ? 0 : this.isDeleted;
}
@Transient
@ApiParam(value = "多列排序")
@AnnoOutputColumn(hidden = true)
public LinkedHashMap<String,Integer> sortParamMap;
//排序方式
public String orderBy(){
String result = "";
if (orderByParam!=null&&orderByParam.trim().length()>0) {
result = " order by " + orderByParam;
if(ascOrDesc == CommonEnumUtil.ASC_OR_DESC.ASC.getValue()) {
result += " asc";
}else{
result += " desc";
StringBuffer result = new StringBuffer(" order by ");
if (sortParamMap != null && sortParamMap.size() != 0) {
for (String key : sortParamMap.keySet()) {
packOrderByHql(result,orderByParam,ascOrDesc);
}
} else if (orderByParam != null && orderByParam.trim().length() > 0) {
packOrderByHql(result,orderByParam,ascOrDesc);
}else{
return "";
}
return result;
return result.subSequence(0, result.length() - 1).toString();
}
private void packOrderByHql(StringBuffer stringBuffer, String orderByParam, Integer ascOrDesc) {
stringBuffer.append(" ").append(orderByParam);
if (ascOrDesc == null || ascOrDesc == CommonEnumUtil.ASC_OR_DESC.ASC.getValue()) {
stringBuffer.append(" asc");
} else {
stringBuffer.append(" desc,");
}
}
}

@ -6246,19 +6246,21 @@ public class WmsEnumUtil {
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum WEEK_TYPE {
MONDAY(20, "星期一"),
TUESDAY(30, "星期二"),
WEDNESDAY(40, "星期三"),
THURSDAY(50, "星期四"),
FRIDAY(60, "星期五"),
SATURDAY(70, "星期六"),
SUNDAY(10, "星期日");
MONDAY(20, 1, "星期一"),
TUESDAY(30, 2, "星期二"),
WEDNESDAY(40, 3, "星期三"),
THURSDAY(50, 4, "星期四"),
FRIDAY(60, 5, "星期五"),
SATURDAY(70, 6, "星期六"),
SUNDAY(10, 0, "星期日");
private final int value;
private final int code;
private final String description;
WEEK_TYPE(int value, String description) {
WEEK_TYPE(int value, int code, String description) {
this.value = value;
this.code = code;
this.description = description;
}
@ -6266,6 +6268,10 @@ public class WmsEnumUtil {
return value;
}
public int getCode() {
return code;
}
public String getDescription() {
return description;
}
@ -6288,6 +6294,15 @@ public class WmsEnumUtil {
}
return tmp;
}
public static int getValByCode(int code) {
for (int i = 0; i < values().length; i++) {
if (values()[i].code == code) {
return values()[i].value;
}
}
return 0;
}
}
/**
@ -8854,6 +8869,52 @@ public class WmsEnumUtil {
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum RC_BOARD_STATUS {
FINISH(10, "已完成(绿色)"),
OVER_TIME(20, "已超时(红色)"),
UNRECEIVED(30, "未收货(蓝色)"),
VARIANT(40, "有差异(黄色)");
private int value;
private String description;
RC_BOARD_STATUS(int value, String description) {
this.value = value;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
public static RC_BOARD_STATUS codeOf(int value) {
for (int i = 0; i < values().length; i++) {
if (values()[i].value == value) {
return values()[i];
}
}
return null;
}
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;
}
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)

@ -90,6 +90,10 @@ public class SysLogTaskTime extends BaseBean {
@AnnoOutputColumn(refClass = CommonEnumUtil.TRUE_OR_FALSE.class, refForeignKey = "value", value = "description")
private Integer taskStatus;
public int getTaskStatusVal() {
return taskStatus == null ? CommonEnumUtil.TRUE_OR_FALSE.TRUE.getValue() : taskStatus;
}
@Column(name="TASK_LOG_ERROR")
@ApiParam(value ="任务异常日志")
private String taskLogError;

@ -161,6 +161,18 @@ public class WmsPOMaster extends BaseBean {
private String planDateEnd;
@Transient
@ApiParam("计划日期")
private String planDate;
@Transient
@ApiParam("计划时间")
private String planTime;
@Transient
@ApiParam("看板状态")
private Integer boardStatus;
@Transient
private List<String> orderNoList;
@Column(name = "DOCK", columnDefinition = "varchar(50) default ''")
@ -197,6 +209,15 @@ public class WmsPOMaster extends BaseBean {
this.createDatetime = createDateTime;
this.createDateTimeStart = receiveDateTime;
}
public WmsPOMaster(String orderNo, Integer poStatus, String vendorNo,
String dockCode, String planDate, String planTime) {
this.orderNo = orderNo;
this.poStatus = poStatus;
this.vendorNo = vendorNo;
this.dock = dockCode;
this.planDate = planDate;
this.planTime = planTime;
}
public int getPoStatusVal() {
return this.poStatus == null ? 0 : this.poStatus;

@ -128,6 +128,10 @@ public class WmsPOMasterDetails extends BaseBean {
@ApiParam(value = "是否免费", example = "1")
private Integer isFree;
@Column(name = "REMARK")
@ApiParam("备注")
private String remark;
@Transient
@ApiParam(value = "散件收货输入数量", example = "0")
private Double inputRcQty;
@ -185,9 +189,6 @@ public class WmsPOMasterDetails extends BaseBean {
@ApiParam("结束时间")
private String planEndDate;
@Column(name = "REMARK")
@ApiParam("备注")
private String remark;
public Double getSnpVal() {
return snp;
@ -245,4 +246,14 @@ public class WmsPOMasterDetails extends BaseBean {
this.modifyDatetime = modifyDatetime;
this.remark = remark;
}
public WmsPOMasterDetails(String partNo,String partNameRdd,String planDate,
Double snp,Long totalBoxes,Double qty){
this.partNo = partNo;
this.partNameRdd = partNameRdd;
this.planDate = planDate;//批次号yyyyMMdd
this.snp=snp;
this.totalBoxes = totalBoxes.intValue();
this.qty = qty;
}
}

@ -14,6 +14,7 @@ import org.hibernate.annotations.DynamicUpdate;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;
/**
* @Description :
@ -87,4 +88,24 @@ public class WmsZonePart extends BaseBean{
@ApiParam(value = "安全量", example = "0")
@DynamicField(webFieldType = CommonEnumUtil.FIELD_TYPE.NUMBER, isRequire = 2)
private Double safetyQty;
@Transient
@ApiParam(value = "总件数")
private Double totalSnQty ;
@Transient
@ApiParam(value = "库存是否正常")
private Integer isNormal ;
public WmsZonePart() {
}
public WmsZonePart(String zoneNo, String partNo, String partNameRdd, Double min, Double max, Double totalSnQty) {
this.zoneNo = zoneNo;
this.partNo = partNo;
this.partNameRdd = partNameRdd;
this.min = min;
this.max = max;
this.totalSnQty = totalSnQty;
}
}

@ -572,7 +572,7 @@ public class WmsHqlPack {
DdlPreparedPack.getNumEqualPack(wmsLocate.getLocateType(), "locateType", result);
DdlPreparedPack.getStringEqualPack(wmsLocate.getWhNo(), "whNo", result);
if (wmsLocate.getZoneNo() != null) {
DdlPreparedPack.getInPack(StringUtils.join(new ArrayList<String>(Arrays.asList(wmsLocate.getZoneNo().split(","))), ","), "zoneNo", result);
DdlPreparedPack.getInPackArray(wmsLocate.getZoneNo().split(","), "zoneNo", result);
}
if (wmsLocate.getLocateNoArr() != null) {
DdlPreparedPack.getInPackArray(wmsLocate.getLocateNoArr(), "locateNo", result);

Loading…
Cancel
Save