出入库商品添加库存警告线
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
package cn.ysk.cashier.vo;
|
||||
|
||||
import org.springframework.data.domain.PageImpl;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class StockPageImpl<T> extends PageImpl<T> {
|
||||
private Integer warnLine;
|
||||
|
||||
public StockPageImpl(List<T> content, Pageable pageable, long total) {
|
||||
super(content, pageable, total);
|
||||
}
|
||||
|
||||
public StockPageImpl(List<T> content) {
|
||||
super(content);
|
||||
}
|
||||
|
||||
public Integer getWarnLine() {
|
||||
return warnLine;
|
||||
}
|
||||
|
||||
public void setWarnLine(Integer warnLine) {
|
||||
this.warnLine = warnLine;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
package cn.ysk.cashier.vo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Data
|
||||
public class StockUpdateWarnLineVO {
|
||||
private String shopId;
|
||||
private Integer warnLine;
|
||||
}
|
||||
@@ -22,6 +22,7 @@ public class StockV2Vo {
|
||||
private Integer isDistribute;
|
||||
private Integer isPauseSale;
|
||||
private Object number;
|
||||
private Integer warnLine;
|
||||
|
||||
public StockV2Vo(Integer proId, Integer skuId, String name, String unitName,String specSnap, Object number,Object stockNumber, Integer isDistribute) {
|
||||
this.proId = proId;
|
||||
@@ -55,6 +56,28 @@ public class StockV2Vo {
|
||||
this.isPauseSale = isPauseSale;
|
||||
}
|
||||
|
||||
public StockV2Vo(Integer id, Integer proId,String img,String name,String unitName, String type, String specSnap,
|
||||
Object isStock, Object number, Integer isDistribute, Integer isPauseSale, boolean isPro, Integer warnLine) {
|
||||
this.id = id.toString() + "-" + proId.toString();
|
||||
if (isPro) {
|
||||
this.id += proId;
|
||||
} else {
|
||||
this.id += id;
|
||||
}
|
||||
this.skuId = id;
|
||||
this.proId = proId;
|
||||
this.img = img;
|
||||
this.name = name;
|
||||
this.unitName = unitName;
|
||||
setType(type);
|
||||
this.specSnap = specSnap;
|
||||
this.isStock = isStock;
|
||||
this.stockNumber = number;
|
||||
this.isDistribute = isDistribute;
|
||||
this.isPauseSale = isPauseSale;
|
||||
this.warnLine = warnLine;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
switch (type) {
|
||||
case "normal":
|
||||
|
||||
Reference in New Issue
Block a user