From c6155344d71b8eca6dd9fc04477b9885c2ac5648 Mon Sep 17 00:00:00 2001 From: leijun Date: Fri, 31 Aug 2018 19:02:25 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9E=E6=97=B6=E6=8A=A5=E8=A1=A8=20?= =?UTF-8?q?=E6=97=B6=E9=97=B4=E6=A3=80=E7=B4=A2=E6=9D=A1=E4=BB=B6=E4=BC=98?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/webapp/WEB-INF/views/report/list.jsp | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/main/webapp/WEB-INF/views/report/list.jsp b/src/main/webapp/WEB-INF/views/report/list.jsp index 6b256a1e8..fe18ec221 100644 --- a/src/main/webapp/WEB-INF/views/report/list.jsp +++ b/src/main/webapp/WEB-INF/views/report/list.jsp @@ -93,6 +93,12 @@ function changeReportType(reportType) { $("#intype").remove(); var reportTime = "${bean.reportTime }"; + var time=getNowFormatDate(); + if(reportTime.length==4){ + reportTime = reportTime+"-"+time.substring(5,10); + }else if(reportTime.length==7){ + reportTime = reportTime+"-"+time.substring(8,10); + } if(reportType == 1){//需删除元素后重新添加,直接更改onclick会出现缓存问题 $("#reportTypeDiv").append(''); } else if(reportType == 2){ @@ -101,6 +107,24 @@ $("#reportTypeDiv").append(''); } } + +//获取当前时间 + function getNowFormatDate() { + var date = new Date(); + var seperator1 = "-"; + var year = date.getFullYear(); + var month = date.getMonth() + 1; + var strDate = date.getDate(); + if (month >= 1 && month <= 9) { + month = "0" + month; + } + if (strDate >= 0 && strDate <= 9) { + strDate = "0" + strDate; + } + var currentdate = year + seperator1 + month + seperator1 + strDate; + return currentdate; + } + var ajaxServiceLogTotal=function(){ var services=[]; var objs=[];