Sweb更新到订单明细修改历史记录查询

yun-zuoyi
yihang.lv 6 years ago
parent 1c1e9fdcbc
commit 709c018fb4

@ -0,0 +1,110 @@
package cn.estsh.i3plus.pojo.base.enumutil;
import com.fasterxml.jackson.annotation.JsonFormat;
/**
* @Description : sweb
* @Reference :
* @Author : jack.lv
* @CreateDate : 2019-04-02 20:21
* @Modify:
**/
public class SwebEnumUtil {
/**
* (ASN,PO,MOVE,QC)
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum ORDER_MASTER_STATUS {
CREATE(10, "新建"),
RECEIPT(20, "已发布"),
RECEIPT_FINISH(30, "已确认"),
CLOSED(40, "已打印"),
CANCELLED(50, "已发货");
private int value;
private String description;
ORDER_MASTER_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;
}
}
/**
*
*/
@JsonFormat(shape = JsonFormat.Shape.OBJECT)
public enum ORDER_DETAILS_STATUS {
CREATE(10, "新建"),
RECEIPT(20, "已发布"),
RECEIPT_FINISH(30, "已确认"),
CLOSED(40, "已打印"),
CANCELLED(50, "已发货");
private int value;
private String description;
ORDER_DETAILS_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;
}
}
}

@ -29,9 +29,13 @@ import javax.persistence.Table;
@Api("订单修改日志记录表")
public class SwebPurchaseChangeLog extends BaseBean {
@Column(name = "ORDER_ITEM_NO")
@Column(name = "ORDER_NO")
@ApiParam("单据明细编号")
public String orderItemNo;
public String orderNo;
@ApiParam(value = "零件号")
@Column(name = "PART_NO")
private String partNo;
@ApiParam(value = "订单当前状态")
@Column(name = "ITEM_STATUS")

@ -81,7 +81,7 @@ public class SwebPurchaseOrder extends BaseBean {
public String deliveryTime;
@Column(name = "REC_TIME")
@ApiParam(value = "货时间")
@ApiParam(value = "货时间")
public String recTime;
@Column(name = "IS_SYN")

@ -155,9 +155,9 @@ public class SwebPurchaseOrderDetails extends BaseBean {
@ApiParam(value = "行号", example = "0")
private Integer itemNo;
@Column(name = "COMFIRM_TIME")
@Column(name = "CONFIRM_TIME")
@ApiParam(value = "确认时间")
public String comfirmTime;
public String confirmTime;
@Column(name = "DELIVERY_TIME")
@ApiParam(value = "交货时间")

@ -0,0 +1,39 @@
package cn.estsh.i3plus.pojo.sweb.modelbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.bean.ListPager;
import cn.estsh.i3plus.pojo.sweb.bean.SwebPurchaseChangeLog;
import io.swagger.annotations.ApiParam;
import lombok.Data;
/**
* @Description :
* @Reference :
* @Author : jack.lv
* @CreateDate : 2019-04-02 13:13
* @Modify:
**/
@Data
public class SwebPODetailsUpdateHistoryModel extends BaseBean {
@ApiParam("单据号")
private String orderNo;
@ApiParam("供应商编号")
private String vendorCode;
@ApiParam(value = "零件号")
private String partNo;
@ApiParam(value = "零件名称")
private String partName;
@ApiParam(value = "订单数量")
private Double refQty;
@ApiParam(value = "确认到货数量")
private Double confirmQty;
@ApiParam(value = "变更列表")
private ListPager<SwebPurchaseChangeLog> history;
}

@ -0,0 +1,34 @@
package cn.estsh.i3plus.pojo.sweb.modelbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import io.swagger.annotations.ApiParam;
import lombok.Data;
/**
* @Description :
* @Reference :
* @Author : jack.lv
* @CreateDate : 2019-04-02 13:13
* @Modify:
**/
@Data
public class SwebPOForPubListEnterModel extends BaseBean {
@ApiParam("单据号")
private String orderNo;
@ApiParam("供应商编号")
private String vendorCode;
@ApiParam(value = "订单类型", example = "1")
public Integer orderType;
@ApiParam(value = "预计到货日期开始日期")
public String recTimeStart;
@ApiParam(value = "预计到货日期结束日期")
public String recTimeEnd;
@ApiParam(value = "零件号")
private String partNo;
}

@ -0,0 +1,48 @@
package cn.estsh.i3plus.pojo.sweb.modelbean;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import org.hibernate.annotations.ColumnDefault;
import javax.persistence.Column;
import java.util.List;
import java.util.Map;
/**
* @Description :
* @Reference :
* @Author : jack.lv
* @CreateDate : 2019-04-02 13:13
* @Modify:
**/
@Data
public class SwebPOForPubListResultModel extends BaseBean {
@Column(name = "ORDER_NO")
@ApiParam("单据号")
public String orderNo;
@Column(name = "PART_NO")
@ApiParam(value = "零件号")
private String partNo;
@Column(name = "PART_NAME")
@ApiParam(value = "零件名称")
private String partName;
@ApiParam(value = "单位")
@Column(name = "UNIT")
private String unit;
@ApiParam(value = "订单状态", example = "1")
@Column(name = "ITEM_STATUS")
private Integer itemStatus;
@ApiParam(value = "订单类型", example = "1")
@Column(name = "ORDER_TYPE")
public Integer orderType;
@ApiParam(value = "时间数量列表", example = "1")
public List<Map<String,Double>> timeList;
}

@ -1,14 +0,0 @@
package cn.estsh.i3plus.pojo.sweb.modelbean;
import lombok.Data;
/**
* @Description :
* @Reference :
* @Author : jack.lv
* @CreateDate : 2019-04-02 13:13
* @Modify:
**/
@Data
public class SwebPurchaseForPubListModel {
}

@ -30,7 +30,13 @@ public class SwebHqlPack {
}
// 封装有效状态和删除状态
SqlPack.getNumEqualPack(bean.getIsValid(), "isValid", hqlStr);
Integer isValid = bean.getIsValid();
//默认查有效数据
if (isValid != null && isValid != 0) {
SqlPack.getNumEqualPack(isValid, "isValid", hqlStr);
} else {
SqlPack.getNumEqualPack(CommonEnumUtil.IS_VAILD.VAILD.getValue(), "isValid", hqlStr);
}
SqlPack.getNumEqualPack(CommonEnumUtil.TRUE_OR_FALSE.FALSE.getValue(), "isDeleted", hqlStr);
return hqlStr.toString();
}
@ -70,4 +76,10 @@ public class SwebHqlPack {
HqlPack.getStringLikerPack(vendorRel.getPlannerCode(), "plannerCode", result);
return buildHql(vendorRel, result);
}
/*public static String getPurchaseOrderDetailsWhereHql(SwebPurchaseOrderDetails swebPurchaseOrderDetails) {
StringBuffer result = new StringBuffer();
HqlPack.getStringLikerPack(swebPurchaseOrderDetails.getOrderNo(), "orderNo", result);
return buildHql(swebPurchaseOrderDetails, result);
}*/
}

Loading…
Cancel
Save