|
@@ -81,13 +81,13 @@ public class SearchProductServiceImpl implements SearchProductService {
|
|
|
if (promotionFlag == 1) {
|
|
|
filterList.add("p_promotions_id > 0");
|
|
|
}
|
|
|
- log.info("brandIds = "+ brandIds+"------------------------------------------------------------------------");
|
|
|
+ log.info("brandIds = " + brandIds + "------------------------------------------------------------------------");
|
|
|
if (!StringUtils.isEmpty(brandIds) && !"null".equals(brandIds)) {
|
|
|
StringBuffer brandBuilder = new StringBuffer();
|
|
|
if (brandIds.contains(",")) {
|
|
|
String[] split = brandIds.split(",");
|
|
|
for (int i = 0; i < split.length; i++) {
|
|
|
- if (i == 0) {
|
|
|
+ if (i == 0 && "null" != split[i] && split[i] != null) {
|
|
|
brandBuilder.append("p_brand_id=").append(split[i]);
|
|
|
} else {
|
|
|
brandBuilder.append(" OR p_brand_id=").append(split[i]);
|
|
@@ -241,13 +241,13 @@ public class SearchProductServiceImpl implements SearchProductService {
|
|
|
if (promotionFlag == 1) {
|
|
|
filterList.add("p_promotions_id > 0");
|
|
|
}
|
|
|
- log.info("brandIds = "+ brandIds+"------------------------------------------------------------------------");
|
|
|
+ log.info("brandIds = " + brandIds + "------------------------------------------------------------------------");
|
|
|
if (!StringUtils.isEmpty(brandIds) && !"null".equals(brandIds)) {
|
|
|
StringBuffer brandBuilder = new StringBuffer();
|
|
|
if (brandIds.contains(",")) {
|
|
|
String[] split = brandIds.split(",");
|
|
|
for (int i = 0; i < split.length; i++) {
|
|
|
- if (i == 0) {
|
|
|
+ if (i == 0 && "null" != split[i] && split[i] != null) {
|
|
|
brandBuilder.append("p_brand_id=").append(split[i]);
|
|
|
} else {
|
|
|
brandBuilder.append(" OR p_brand_id=").append(split[i]);
|