|
|
@@ -205,7 +205,7 @@ public class ProductServiceImpl implements ProductService {
|
|
|
|
|
|
@Override
|
|
|
public List<Product> getBrands(UpdateByBatchParameter param) {
|
|
|
- String sql = "select distinct p.pr_brand brand from products p where p.pr_cmpuuid is null and p.pr_enuu = "
|
|
|
+ String sql = "select distinct p.pr_brand brand from products p where p.pr_cmpuuid is null and p.pr_brand is not null and p.pr_enuu = "
|
|
|
+ SystemSession.getUser().getEnterprise().getUu();
|
|
|
if (param.getType().equals(UpdateType.sale)) {
|
|
|
sql = sql + " and p.pr_isale = 1";
|
|
|
@@ -218,7 +218,7 @@ public class ProductServiceImpl implements ProductService {
|
|
|
|
|
|
@Override
|
|
|
public List<Product> getTitles(UpdateByBatchParameter param) {
|
|
|
- String sql = "select distinct p.pr_title title from products p where p.pr_cmpuuid is null and p.pr_enuu = "
|
|
|
+ String sql = "select distinct p.pr_title title from products p where p.pr_cmpuuid is null and p.pr_title is not null and p.pr_enuu = "
|
|
|
+ SystemSession.getUser().getEnterprise().getUu();
|
|
|
if (param.getType().equals(UpdateType.sale)) {
|
|
|
sql = sql + " and p.pr_isale = 1";
|
|
|
@@ -290,7 +290,11 @@ public class ProductServiceImpl implements ProductService {
|
|
|
// map.put("error", "暂未查询到当前企业的非标准的物料信息");
|
|
|
// }
|
|
|
String num = productDao.upateResultByEnuu(SystemSession.getUser().getEnterprise().getUu());
|
|
|
- map.put("size", num);
|
|
|
+ if (null == num) {
|
|
|
+ map.put("size", 0);
|
|
|
+ } else {
|
|
|
+ map.put("size", num);
|
|
|
+ }
|
|
|
return map;
|
|
|
}
|
|
|
|