流量统计app趋势及apptop100增加isp运营商查询条件

(cherry picked from commit 2d4a1a6685)
This commit is contained in:
zhanghongqing
2019-01-18 08:34:58 +00:00
committed by 王鑫
parent b1ee15772b
commit d225b81903
7 changed files with 122 additions and 43 deletions

View File

@@ -47,6 +47,7 @@ import com.nis.util.DateUtil;
import com.nis.util.DateUtils;
import com.nis.util.DictUtils;
import com.nis.util.StringUtil;
import com.nis.util.StringUtils;
import com.nis.util.httpclient.HttpClientUtil;
import com.nis.web.controller.BaseController;
import com.nis.web.dao.dashboard.codedic.CodeResult;
@@ -469,7 +470,7 @@ public class TrafficStatisticsInfoController extends BaseController {
}
@RequestMapping("ajaxAppTrend")
@ResponseBody
public Map ajaxAppTrend(String beginDate,String endDate,Integer appType,Integer entranceId,Model model){
public Map ajaxAppTrend(String beginDate,String endDate,Integer appType,Integer entranceId,Integer[] searchIspCode,Model model){
Map<String, Object> fromJsonList = new HashMap<String, Object>();
Map list = new HashMap();
try {
@@ -484,6 +485,10 @@ public class TrafficStatisticsInfoController extends BaseController {
if(entranceId!=null){
url=url+"&searchEntranceId="+entranceId;
}
if(searchIspCode!=null&&searchIspCode.length>0){
String str=StringUtils.join(searchIspCode,",");
url=url+"&searchIspCode="+str;
}
String string = HttpClientUtil.get(url);
Gson gson = new GsonBuilder().create();
fromJsonList = gson.fromJson(string, new TypeToken<Map<String, Object>>(){}.getType());
@@ -499,7 +504,7 @@ public class TrafficStatisticsInfoController extends BaseController {
}
@RequestMapping("ajaxAppTopList")
@ResponseBody
public List ajaxAppTopList(String beginDate,String endDate,Integer appType,Integer entranceId,Integer searchQuota,Model model){
public List ajaxAppTopList(String beginDate,String endDate,Integer appType,Integer entranceId,Integer searchQuota,Integer[] searchIspCode,Model model){
Map<String, Object> fromJsonList = new HashMap<String, Object>();
List<Map> list = new ArrayList<Map>();
try {
@@ -519,6 +524,10 @@ public class TrafficStatisticsInfoController extends BaseController {
}else{
url=url+"&searchQuota="+1; // 默认是按照link 排序
}
if(searchIspCode!=null&&searchIspCode.length>0){
String str=StringUtils.join(searchIspCode,",");
url=url+"&searchIspCode="+str;
}
String string = HttpClientUtil.get(url);
Gson gson = new GsonBuilder().create();
fromJsonList = gson.fromJson(string, new TypeToken<Map<String, Object>>(){}.getType());