|
@@ -64,11 +64,14 @@ public class DbUtil {
|
|
|
public static RetData conditionRenderTable(String condition, String searchType, String indicators, String ttype, String sdate)
|
|
|
{
|
|
|
Map<String, String> ezMap = initZnEnMap();
|
|
|
-
|
|
|
- String sql = "select a.cellname,a.city,a.quxian,a.vendor,b.* from \n(select eci,cellname,city,quxian,vendor from pm_parse.per_cfg_cell where " + searchType + " in (" + condition + ")) a\ninner join \n(select eci," + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate='" + sdate + "') b\non a.eci=b.eci";
|
|
|
- if (indicators.contains("eci")) {
|
|
|
- sql = "select a.cellname,a.city,a.quxian,a.vendor,b.* from \n(select eci,cellname,city,quxian,vendor from pm_parse.per_cfg_cell where " + searchType + " in (" + condition + ")) a\ninner join \n(select " + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate='" + sdate + "') b\non a.eci=b.eci";
|
|
|
+ String[] timeArray = sdate.split(" - ");
|
|
|
+ String startTime = timeArray[0];
|
|
|
+ String endTime = timeArray[1];
|
|
|
+ String sql = "select a.cellname,a.city,a.quxian,a.vendor,b.* from \n(select eci,cellname,city,quxian,vendor from pm_parse.per_cfg_cell where " + searchType + " in (" + condition + ")) a\ninner join \n(select " + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate>='" + startTime + "' and sdate <= '" + endTime + "') b\n" + "on a.eci=b.eci";
|
|
|
+ if ("all".equals(searchType)) {
|
|
|
+ sql = "select a.cellname,a.city,a.quxian,a.vendor,b.* from pm_parse.per_cfg_cell a\ninner join \n(select " + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate>='" + startTime + "' and sdate <= '" + endTime + "') b\n" + "on a.eci=b.eci";
|
|
|
}
|
|
|
+
|
|
|
List<Map<String, String>> datas = new ArrayList();
|
|
|
List<Col> cols = new ArrayList();
|
|
|
try
|
|
@@ -109,6 +112,8 @@ public class DbUtil {
|
|
|
log.debug("indicators: {}", indicators);
|
|
|
log.debug("citys: {}", citys);
|
|
|
log.debug("quxians: {}", quxians);
|
|
|
+ log.debug("ttype: {}", ttype);
|
|
|
+ log.debug("sdate: {}", sdate);
|
|
|
// 获取城市数组
|
|
|
String[] cityArrays = StringUtils.delete(citys, "'").split(",");
|
|
|
// 获取拥有的城市权限
|
|
@@ -123,17 +128,25 @@ public class DbUtil {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ String[] timeArray = sdate.split(" - ");
|
|
|
+ String startTime = timeArray[0];
|
|
|
+ String endTime = timeArray[1];
|
|
|
+
|
|
|
String sql = "select b.* from \n" +
|
|
|
"(select eci from pm_parse.per_cfg_cell where quxian in (" + quxians + ")) a\n" +
|
|
|
"inner join \n" +
|
|
|
- "(select eci," + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate='" + sdate + "') b\n" +
|
|
|
+ "(select eci," + indicators + " from pm_parse.pm_4g_" + ttype +
|
|
|
+ " where sdate>='" + startTime +
|
|
|
+ "' and sdate <= '" + endTime + "') b\n" +
|
|
|
"on a.eci=b.eci";
|
|
|
|
|
|
if(indicators.contains("eci")){
|
|
|
sql="select b.* from \n" +
|
|
|
"(select eci from pm_parse.per_cfg_cell where quxian in (" + quxians + ")) a\n" +
|
|
|
"inner join \n" +
|
|
|
- "(select " + indicators + " from pm_parse.pm_4g_" + ttype + " where sdate='" + sdate + "') b\n" +
|
|
|
+ "(select " + indicators + " from pm_parse.pm_4g_" + ttype +
|
|
|
+ " where sdate>='" + startTime +
|
|
|
+ "' and sdate <= '" + endTime + "') b\n" +
|
|
|
"on a.eci=b.eci";
|
|
|
}
|
|
|
List<Map<String, String>> datas = new ArrayList<>();
|