Merge remote-tracking branch 'origin/master'

yun-zuoyi
yunhao.wang 7 years ago
commit 2abfc97d8e

@ -12,6 +12,109 @@ import com.fasterxml.jackson.annotation.JsonFormat;
public class WmsEnumUtil {
/**
* PO
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum PO_ORDER_TYPE {
REG(1, "REG", "原物料采购"),
SUB(2, "SUB", "委外采购"),
TAR(3, "TAR", "多角贸易采购"),
TAP(4, "TAP", "多角代采购");
private int value;
private String code;
private String description;
private PO_ORDER_TYPE(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;
}
}
/**
* PO
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum PO_ORDER_STATUS {
CREATE(0, "新建"),
RECEIPT(10, "收货中"),
RECEIPT_FINISH(20, "收货完成"),
WAREHOUSING(30, "入库中"),
WAREHOUSING_FINISH(40, "入库完成"),
CLOSED(90, "已关闭"),
CANCELLED(91, "已取消");
private int value;
private String description;
private PO_ORDER_STATUS(int value, String description) {
this.value = value;
this.description = description;
}
public int getValue() {
return value;
}
public String getDescription() {
return description;
}
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;
}
}
/**
*
*/
public enum TRANS_STATUS {

@ -33,8 +33,8 @@ public class WmsPOMaster extends BaseBean {
public String orderNo;
/**
* :REG=,
* SUB=,TAR=,TAP=
* :1 REG=,
* 2 SUB=,3 TAR=,4 TAP=
*/
@Column(name="TYPE")
@ApiParam("单据类型")

@ -11,6 +11,27 @@ import cn.estsh.i3plus.pojo.wms.bean.*;
* @Modify:
**/
public class WmsHqlPack {
/**
* PO
*
* @param wmsPOMaster
* @return
*/
public static String packHqlWmsPOMaster(WmsPOMaster wmsPOMaster) {
StringBuffer result = new StringBuffer();
//查询参数封装
HqlPack.getStringLikerPack(wmsPOMaster.getOrderNo(), "orderNo", result);
HqlPack.getStringLikerPack(wmsPOMaster.getType(), "type", result);
HqlPack.getNumEqualPack(wmsPOMaster.getStatus(), "status", result);
HqlPack.getStringLikerPack(wmsPOMaster.getVendorNo(), "vendorNo", result);
HqlPack.getStringLikerPack(wmsPOMaster.getSrc(), "src", result);
HqlPack.getNumEqualPack(wmsPOMaster.getIsValid(), "isValid", result);
return result.toString();
}
/**
* 线
*

Loading…
Cancel
Save