|
@@ -49,7 +49,7 @@ public class VendorIntroductionServiceImpl implements VendorIntroductionService
|
|
|
Integer total = getTotalCount(enUU, keyword);
|
|
Integer total = getTotalCount(enUU, keyword);
|
|
|
// 查询企业
|
|
// 查询企业
|
|
|
List<VendorIntroduction> vendorIntroductions = getEnterpriseWithCondition(enUU, keyword, page, size);
|
|
List<VendorIntroduction> vendorIntroductions = getEnterpriseWithCondition(enUU, keyword, page, size);
|
|
|
- System.out.println("查找完企业UU" + (System.currentTimeMillis() - start));
|
|
|
|
|
|
|
+// System.out.println("查找完企业UU" + (System.currentTimeMillis() - start));
|
|
|
return new Page<VendorIntroduction>(page, size, vendorIntroductions, total);
|
|
return new Page<VendorIntroduction>(page, size, vendorIntroductions, total);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -75,16 +75,16 @@ public class VendorIntroductionServiceImpl implements VendorIntroductionService
|
|
|
long start = System.currentTimeMillis();
|
|
long start = System.currentTimeMillis();
|
|
|
// and Pr_Title not like '%测试%' and lower(Pr_Title) not like '%test%' and Pr_code not like '%测试%' and lower(Pr_code) not like '%test%'
|
|
// and Pr_Title not like '%测试%' and lower(Pr_Title) not like '%test%' and Pr_code not like '%测试%' and lower(Pr_code) not like '%test%'
|
|
|
String prodSql = "select a.* from (select pr_id id, pr_code prodNum, pr_title prodName, pr_spec spec, pr_cmpcode cmpCode, pr_unit unit, pr_kind kind, "
|
|
String prodSql = "select a.* from (select pr_id id, pr_code prodNum, pr_title prodName, pr_spec spec, pr_cmpcode cmpCode, pr_unit unit, pr_kind kind, "
|
|
|
- + " pr_brand brand, pr_pbranden pbranden, pr_standard standard from v$product$private where ifnull(pr_b2cenabled, 1) <> 0 and pr_enuu = "
|
|
|
|
|
- + vendUU + " and pr_issale = 1 and pr_pbranden is not null and pr_pcmpcode is not null and " + whereCondition
|
|
|
|
|
- + " order by pr_issale desc, pr_standard desc, pr_id desc) a limit " + (page - 1) * size + "," + size;
|
|
|
|
|
- System.out.println("prod:" + prodSql);
|
|
|
|
|
|
|
+ + " pr_brand brand, pr_pbranden pbranden, pr_standard standard from v$product$private where pr_enuu = "
|
|
|
|
|
+ + vendUU + " and " + whereCondition + " and pr_pbranden is not null and pr_pcmpcode is not null and ifnull(pr_b2cenabled, 1) <> 0 order by pr_standard desc, pr_id desc) a limit " + (page - 1) * size + "," + size;
|
|
|
|
|
+// System.out.println("prod:" + prodSql);
|
|
|
// and Pr_Title not like '%测试%' and lower(Pr_Title) not like '%test%' and Pr_code not like '%测试%' and lower(Pr_code) not like '%test%'
|
|
// and Pr_Title not like '%测试%' and lower(Pr_Title) not like '%test%' and Pr_code not like '%测试%' and lower(Pr_code) not like '%test%'
|
|
|
- String countSql = "select count(1) from v$product$private where pr_enuu = " + vendUU
|
|
|
|
|
- + " and pr_issale = 1 and pr_pbranden is not null and pr_pcmpcode is not null and ifnull(pr_b2cenabled, 1) <> 0 and " + whereCondition;
|
|
|
|
|
|
|
+ String countSql = "select count(1) from v$product$private where pr_enuu = " + vendUU + " and " + whereCondition
|
|
|
|
|
+ + " and pr_pbranden is not null and pr_pcmpcode is not null and ifnull(pr_b2cenabled, 1) <> 0";
|
|
|
Integer count = commonDao.queryForObject(countSql, Integer.class);
|
|
Integer count = commonDao.queryForObject(countSql, Integer.class);
|
|
|
|
|
+// System.out.println("count:" + countSql);
|
|
|
List<V_ProductPrivate> products = commonDao.query(prodSql, V_ProductPrivate.class);
|
|
List<V_ProductPrivate> products = commonDao.query(prodSql, V_ProductPrivate.class);
|
|
|
- System.out.println("耗时" + (System.currentTimeMillis() - start));
|
|
|
|
|
|
|
+// System.out.println("耗时" + (System.currentTimeMillis() - start));
|
|
|
return new Page<>(page, size, products, count);
|
|
return new Page<>(page, size, products, count);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -143,7 +143,7 @@ public class VendorIntroductionServiceImpl implements VendorIntroductionService
|
|
|
+ enterpriseSql + rownumSql;
|
|
+ enterpriseSql + rownumSql;
|
|
|
// String vendorIntroductionUusSql = "select s.*,( " + prodInfoSql + ") productInfo, (" + storeSql +
|
|
// String vendorIntroductionUusSql = "select s.*,( " + prodInfoSql + ") productInfo, (" + storeSql +
|
|
|
// ") isStore from (select t.*,rownum as r1 from (" + enterpriseSql + rownumSql;
|
|
// ") isStore from (select t.*,rownum as r1 from (" + enterpriseSql + rownumSql;
|
|
|
- System.out.println("ens:" + vendorIntroductionUusSql);
|
|
|
|
|
|
|
+// System.out.println("ens:" + vendorIntroductionUusSql);
|
|
|
return commonDao.query(vendorIntroductionUusSql, VendorIntroduction.class);
|
|
return commonDao.query(vendorIntroductionUusSql, VendorIntroduction.class);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -164,7 +164,7 @@ public class VendorIntroductionServiceImpl implements VendorIntroductionService
|
|
|
" and en_name not like '%test%' and (length(en_businesscode) > 12 or en_name like '%香港%' or en_name like '%HONG KONG%' or en_area like '%香港%') and en_uu <> ").append(enUU);
|
|
" and en_name not like '%test%' and (length(en_businesscode) > 12 or en_name like '%香港%' or en_name like '%HONG KONG%' or en_area like '%香港%') and en_uu <> ").append(enUU);
|
|
|
}
|
|
}
|
|
|
enCountSql.append(" group by en_uu )a");
|
|
enCountSql.append(" group by en_uu )a");
|
|
|
- System.out.println("en_count:" + enCountSql.toString());
|
|
|
|
|
|
|
+// System.out.println("en_count:" + enCountSql.toString());
|
|
|
return commonDao.queryForObject(enCountSql.toString(), Integer.class);
|
|
return commonDao.queryForObject(enCountSql.toString(), Integer.class);
|
|
|
}
|
|
}
|
|
|
|
|
|