域名统计 时间框默认1小时

This commit is contained in:
shangguanyanfei
2019-01-14 11:08:42 +08:00
parent e7c7a4b960
commit 4e41bfcf79

View File

@@ -525,7 +525,7 @@ public class TrafficStatisticsInfoController extends BaseController {
Calendar cal = Calendar. getInstance ();
cal.setTime(new Date());
String now = new SimpleDateFormat( "yyyy-MM-dd HH:mm:00" ).format(cal.getTime());//获取到完整的时间
cal.set(Calendar.HOUR_OF_DAY, cal.get(Calendar.HOUR_OF_DAY) - 12);
cal.set(Calendar.HOUR_OF_DAY, cal.get(Calendar.HOUR_OF_DAY) - 1);
String oneHoursAgo = new SimpleDateFormat( "yyyy-MM-dd HH:mm:00" ).format(cal.getTime());
List<WebsiteDomainTopic> domainList = appCfgService.getDomainDict(new WebsiteDomainTopic());// domain 域名
model.addAttribute("domainList", domainList);