📄 visit.jsp
字号:
<%@ page import="com.doone.uurm.UserFactory,
com.doone.data.*,
com.doone.uurm.WebAuth,
com.doone.fj1w.fjmgr.statana.*,
com.doone.uurm.IOrgInfo"%>
<%@ page contentType="text/html; charset=GBK" %>
<%request.setCharacterEncoding("GBK");%>
<%String sPurvICode="NGB004003";%>
<%
WebAuth auth = WebAuth.getInstance(request);
if ( ! auth.IsAuthed() ) {
out.write("<script language=\"javascript\">self.parent.location.replace(\"" + request.getContextPath() + "/view/login/login.jsp" + "\");</script>");
return;
}
else if ( ! auth.CheckPurv(sPurvICode) ) {
out.write("<script language=javascript src=\"../../common/script/RightForbidden.js\"></script>");
return;
}
String itemvalue=request.getParameter("Item");
if(itemvalue==null)itemvalue="1";
%>
<html>
<head>
<title>系统访问量汇总表</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<link href="../../common/style/main.css" rel="stylesheet" type="text/css" />
<link href="../../common/style/Sty01.css" rel="stylesheet" type="text/css" />
<script language="JavaScript">
function fn_onload() {
cltScript_Toolbar();
}
function cltScript_Toolbar() {
if ( self.parent != self ){
var pel = parent.document.all.tags("frame");
for ( i=0; i< pel.length; i++)
{
if ( pel(i).name == "main") {
divTop.style.width = pel(i).width;
divMain.style.width = pel(i).width;
divMain.style.height = pel(i).height - divTop.clientHeight;
}
}
}
}
</script>
</head>
<body onload="fn_onload();">
<script language="javascript">
function changeItem(no)
{
if(no==0)document.all.sbtnw2.disabled=true;
else {document.all.sbtnw.disabled=false;
document.all.sbtnw2.disabled=false;}
}
function updateCity()
{
if(document.all.starttime.value==""){alert("请选择开始时间!");return false;}
if(document.all.Item.value=="1" && document.all.endtime.value=="" ){alert("请选择结束时间!");return false;}
if(document.all.Item.value=="1" && document.all.starttime.value>=document.all.endtime.value){alert("开始时间不能比结束时间晚!");return false;}
window.open("visit.jsp?starttime="+document.all.starttime.value+"&endtime="+document.all.endtime.value+"&Item="+document.all.Item.value,"_self");
}
function changePageNo(no)
{
window.open("VisitList.jsp?starttime="+document.all.starttime.value+"&endtime="+document.all.endtime.value+"&pageNo="+document.all.pageList.value+"&Item="+document.all.Item.value,"_self");
}
</script>
<div onresize="cltScript_Toolbar();" style="width: 100%">
<div id="divTop" style="overflow: hidden">
<table id="ibtnPanel" style="font-size: 9pt; border-bottom: #efefef 1px outset" cellspacing="0"
cellpadding="0" width="100%" border="0">
<tr bgcolor="#efefef" height="33">
<td> </td>
</tr>
</table>
<jsp:include page="../../common/inc_top.jsp" >
<jsp:param name="purvCode" value="<%=sPurvICode%>"/>
</jsp:include>
</div>
<div id="divMain" style="overflow: auto">
<table style="font-size: 9pt; border-bottom: #efefef 1px outset" cellspacing="0"
cellpadding="0" width="100%" border="0" class="OuterTable">
<tr>
<td height="19" colspan="7" class="OuterHead">
<table width="100%" border="0" cellspacing="0" cellpadding="1">
<tr>
<td nowrap="nowrap" style="text-align:left"> <p><span id="ItemTitle"><font face="webdings">8</font>系统访问汇总表</span></p></td>
<td align="right" nowrap> </td>
</tr>
</table></td>
</tr>
<tr class="OuterHead">
<td class="title_td" align="center" width="10%"><b>办理类别</b></td>
<td class="title_td" align="center" width="20%"><b>客户权限级别</b></td>
<td class="title_td" align="center" width="21%"><b>查询时间</b></td>
<td class="title_td" align="center" width="25%"><b>访问量</b></td>
</tr>
<%
//String itemvalue=request.getParameter("Item");
String start=request.getParameter("starttime");
String end=request.getParameter("endtime");
int pageNo=1;
String pageStr=request.getParameter("pageList");
try{pageNo=Integer.parseInt(pageStr);}catch(Exception ex){pageNo=1;}
try
{
java.util.StringTokenizer st=new java.util.StringTokenizer(start,"-");
String temp="";
for(int i=0;i<st.countTokens();i++)
{temp=temp+st.nextToken();}
start=temp+st.nextToken();}
catch(Exception ex)
{start="";}
try{
String temp="";
java.util.StringTokenizer nt=new java.util.StringTokenizer(end,"-");
for(int i=0;i<nt.countTokens();i++)
{temp=temp+nt.nextToken();}
end=temp+nt.nextToken();}
catch(Exception ex)
{end="";}
TogetherBean tb=new TogetherBean();
DataTable dt=null;
if(start.equals("")||start==null){start="20050101";}
if(end.equals("")||end==null){end="30080110";}
try{dt=tb.queryVisit(start,end,pageNo);}catch(Exception ex){ex.printStackTrace();}
if(dt != null){
for(int i=0;i<dt.getRows().getCount();i++)
{
%>
<tr class="InnerMain" style="color: black">
<td class="body_td" align="left" width="10%" nowrap><%=dt.getRow(i).getString("siteid")%></td>
<td class="body_td" align="left" width="20%" nowrap><%if(dt.getRow(i).getString("logintype").equals("0")){out.print("游客");}else if(dt.getRow(i).getString("logintype").equals("1")){out.print("注册帐号");} else if (dt.getRow(i).getString("logintype").equals("2")){out.print("产品登陆");}%></td>
<td class="body_td" align="left" width="21%" nowrap><%if(itemvalue.equals("0")){out.print(start.substring(0,4));out.print("年");out.print(start.substring(4,6));out.print("月");out.print(start.substring(6,8));out.print("日");}
else {out.print(start.substring(0,4));out.print("年");out.print(start.substring(4,6));out.print("月");out.print(start.substring(6,8));out.print("日");
out.print("--");
out.print(end.substring(0,4));out.print("年");out.print(end.substring(4,6));out.print("月");out.print(end.substring(6,8));out.print("日");}%></td>
<td class="body_td" align="left" width="25%" nowrap><%=dt.getRow(i).getString("cnt")%></td>
</tr>
<%
}}
%>
</table>
<form name="form1" method="post" action="">
<table cellpadding="0" cellspacing="0" border="0" width="100%" class="OuterTable">
<!-- <tr class="OuterFoot">
<td align="left" class="foot_td" nowrap width="20%">
<%
out.print("本页共有"+dt.getRows().getCount()+"条记录!");
%>
</td>
<td align="right" class="foot_td" nowrap width="2%">
共<%= tb.getPageCount("tl_clientlogin",start,end) %>页
</td>
</tr>
<tr class="OuterFoot">
<td align="left" class="foot_td" nowrap width="100%" colspan="4">第
<select name="pageList" onChange="changePageNo(this.value)">
<%out.print(tb.buildPageOptions(tb.getPageCount("tl_clientlogin",start,end),pageNo));%>
</select>页
</td>
</tr>-->
<tr class="OuterFoot">
<td align="left" class="foot_td" nowrap width="100%" colspan="4">时间方式
<select name="Item" style="width:70"onChange="changeItem(this.value)" >
<option value="0">某天 </option>
<option value="1"> 某段时间</option>
</select>
</td>
</tr>
<tr class="OuterFoot">
<td align="left" class="foot_td" nowrap width="100%" colspan="4">开始时间
<div id=popCal style="BORDER-RIGHT: 2px ridge; BORDER-TOP: 2px ridge; Z-INDEX: 100; VISIBILITY: hidden; BORDER-LEFT: 2px ridge; BORDER-BOTTOM: 2px ridge; POSITION: absolute">
<iframe name=popFrame src="PopCalendar.htm" frameborder=0 width=380 scrolling=no height=188></iframe>
</div>
<input name="starttime" type="text" id="starttime" readonly="true">
<input onClick="popFrame.fPopCalendar(starttime,starttime,popCal);return false" type=button value=日期 name=sbtnw class="BUTTN-FIX1">
</td>
</tr>
<tr class="OuterFoot">
<td align="left" class="foot_td" nowrap width="100%" colspan="4">
结束时间
<input name="endtime" type="text" id="endtime" readonly="true" >
<input onClick="popFrame.fPopCalendar(endtime,endtime,popCal);return false" type=button value=日期 name=sbtnw2 class="BUTTN-FIX1" disabled="true">
<font color="#009900">(如果查询时间方式选择了一段时间,请选择结束时间)</font><br>
<div align="left">
<input type="button" name="Submit" value="查询" onClick="return updateCity()">
</div>
</td>
</tr>
</table>
</form>
</div>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -