商品导入赋默认值
parent
8a9d0c43be
commit
064aab6993
|
@ -213,6 +213,9 @@ public class MdGoodsController extends BaseController {
|
||||||
try {
|
try {
|
||||||
if(StringUtil.isEmpty(mdGoods.getChlKongZhi()) ){
|
if(StringUtil.isEmpty(mdGoods.getChlKongZhi()) ){
|
||||||
mdGoods.setChlKongZhi("N");
|
mdGoods.setChlKongZhi("N");
|
||||||
|
|
||||||
|
}
|
||||||
|
if(StringUtil.isEmpty(mdGoods.getChlShl())){
|
||||||
mdGoods.setChlShl("1");
|
mdGoods.setChlShl("1");
|
||||||
mdGoods.setJshDanWei(mdGoods.getShlDanWei());
|
mdGoods.setJshDanWei(mdGoods.getShlDanWei());
|
||||||
}
|
}
|
||||||
|
@ -424,7 +427,19 @@ public class MdGoodsController extends BaseController {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
try{
|
||||||
|
|
||||||
|
if(StringUtil.isEmpty(mdGoods.getChlKongZhi()) ){
|
||||||
|
mdGoods.setChlKongZhi("N");
|
||||||
|
|
||||||
|
}
|
||||||
|
if(StringUtil.isEmpty(mdGoods.getChlShl())){
|
||||||
|
mdGoods.setChlShl("1");
|
||||||
|
mdGoods.setJshDanWei(mdGoods.getShlDanWei());
|
||||||
|
}
|
||||||
if(StringUtil.isEmpty(mdGoods.getZhlKgm())){
|
if(StringUtil.isEmpty(mdGoods.getZhlKgm())){
|
||||||
if(!StringUtil.isEmpty(mdGoods.getBzhiQi())){
|
if(!StringUtil.isEmpty(mdGoods.getBzhiQi())){
|
||||||
int bzhiq = Integer.parseInt(mdGoods.getBzhiQi());
|
int bzhiq = Integer.parseInt(mdGoods.getBzhiQi());
|
||||||
|
@ -432,18 +447,7 @@ public class MdGoodsController extends BaseController {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if(StringUtil.isEmpty(mdGoods.getChlKongZhi()) ){
|
}catch (Exception e){
|
||||||
mdGoods.setChlKongZhi("N");
|
|
||||||
|
|
||||||
}
|
|
||||||
if("N".equals(mdGoods.getChlKongZhi())){
|
|
||||||
mdGoods.setChlShl("1");
|
|
||||||
mdGoods.setJshDanWei(mdGoods.getShlDanWei());
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
} catch (Exception e) {
|
|
||||||
// TODO: handle exception
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
mdGoodsService.save(mdGoods);
|
mdGoodsService.save(mdGoods);
|
||||||
|
|
Loading…
Reference in New Issue