|
|
@@ -2982,7 +2982,11 @@ public class GoodsServiceImpl implements GoodsService {
|
|
|
productPrivate = new ProductPrivate();
|
|
|
}
|
|
|
Integer count = productPrivate.getBatchCount();
|
|
|
- productPrivate.setBatchCount(--count);
|
|
|
+ if (null == count){
|
|
|
+ productPrivate.setBatchCount(0);
|
|
|
+ }else {
|
|
|
+ productPrivate.setBatchCount(--count);
|
|
|
+ }
|
|
|
productPrivateDao.save(productPrivate);
|
|
|
products.add(product);
|
|
|
}
|