调整商品图片的原图路径接口
This commit is contained in:
@@ -260,9 +260,11 @@ public class DepotItemController {
|
|||||||
item.put("remark", diEx.getRemark());
|
item.put("remark", diEx.getRemark());
|
||||||
item.put("imgName", diEx.getImgName());
|
item.put("imgName", diEx.getImgName());
|
||||||
if(fileUploadType == 2) {
|
if(fileUploadType == 2) {
|
||||||
item.put("imgType", "small");
|
item.put("imgSmall", "small");
|
||||||
|
item.put("imgLarge", "large");
|
||||||
} else {
|
} else {
|
||||||
item.put("imgType", "");
|
item.put("imgSmall", "");
|
||||||
|
item.put("imgLarge", "");
|
||||||
}
|
}
|
||||||
item.put("linkId", diEx.getLinkId());
|
item.put("linkId", diEx.getLinkId());
|
||||||
item.put("depotId", diEx.getDepotId() == null ? "" : diEx.getDepotId());
|
item.put("depotId", diEx.getDepotId() == null ? "" : diEx.getDepotId());
|
||||||
|
|||||||
@@ -268,9 +268,11 @@ public class MaterialController {
|
|||||||
item.put("expand", materialService.getMaterialOtherByParam(mpArr, material));
|
item.put("expand", materialService.getMaterialOtherByParam(mpArr, material));
|
||||||
item.put("imgName", material.getImgName());
|
item.put("imgName", material.getImgName());
|
||||||
if(fileUploadType == 2) {
|
if(fileUploadType == 2) {
|
||||||
item.put("imgType", "small");
|
item.put("imgSmall", "small");
|
||||||
|
item.put("imgLarge", "large");
|
||||||
} else {
|
} else {
|
||||||
item.put("imgType", "");
|
item.put("imgSmall", "");
|
||||||
|
item.put("imgLarge", "");
|
||||||
}
|
}
|
||||||
dataArray.add(item);
|
dataArray.add(item);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -47,7 +47,9 @@ public class MaterialVo4Unit extends Material{
|
|||||||
*/
|
*/
|
||||||
private String bigUnitStock;
|
private String bigUnitStock;
|
||||||
|
|
||||||
private String imgType;
|
private String imgSmall;
|
||||||
|
|
||||||
|
private String imgLarge;
|
||||||
|
|
||||||
public String getUnitName() {
|
public String getUnitName() {
|
||||||
return unitName;
|
return unitName;
|
||||||
@@ -209,11 +211,19 @@ public class MaterialVo4Unit extends Material{
|
|||||||
this.bigUnitStock = bigUnitStock;
|
this.bigUnitStock = bigUnitStock;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getImgType() {
|
public String getImgSmall() {
|
||||||
return imgType;
|
return imgSmall;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setImgType(String imgType) {
|
public void setImgSmall(String imgSmall) {
|
||||||
this.imgType = imgType;
|
this.imgSmall = imgSmall;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getImgLarge() {
|
||||||
|
return imgLarge;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setImgLarge(String imgLarge) {
|
||||||
|
this.imgLarge = imgLarge;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -136,7 +136,8 @@ public class MaterialService {
|
|||||||
Map<Long,BigDecimal> currentStockMap = getCurrentStockMapByMaterialList(list);
|
Map<Long,BigDecimal> currentStockMap = getCurrentStockMapByMaterialList(list);
|
||||||
for (MaterialVo4Unit m : list) {
|
for (MaterialVo4Unit m : list) {
|
||||||
if(fileUploadType == 2) {
|
if(fileUploadType == 2) {
|
||||||
m.setImgType("small");
|
m.setImgSmall("small");
|
||||||
|
m.setImgLarge("large");
|
||||||
}
|
}
|
||||||
m.setMaterialOther(getMaterialOtherByParam(mpArr, m));
|
m.setMaterialOther(getMaterialOtherByParam(mpArr, m));
|
||||||
m.setStock(currentStockMap.get(m.getId())!=null? currentStockMap.get(m.getId()): BigDecimal.ZERO);
|
m.setStock(currentStockMap.get(m.getId())!=null? currentStockMap.get(m.getId()): BigDecimal.ZERO);
|
||||||
|
|||||||
Reference in New Issue
Block a user