msg_received_home.jsp
资源名称:NetOffice.rar [点击查看]
上传用户:guhaomin
上传日期:2007-06-10
资源大小:23203k
文件大小:7k
源码类别:
电子政务应用
开发平台:
Java
- <%@ page import = "com.vnex.intranet.pub.BaseJdbcDAO"%>
- <%@ taglib uri="/vnex.tld" prefix="vnex" %>
- <%@ taglib uri="/vnex_communication.tld" prefix="comm" %>
- <%@ page errorPage="/vnex/ErrorPage.jsp" %>
- <jsp:useBean id="BusinessName" scope="session" class="com.vnex.intranet.pub.BusinessSession" />
- <%
- BaseJdbcDAO jdbcDAO =new BaseJdbcDAO();
- String condition = " where emp_id="+BusinessName.getEmpId();
- String pageTo = "/mainctrl/msg/receivedHome?a";
- String searchCondition = "";
- if(request.getParameter("ss") != null)
- {
- condition += " and sender_id in (select emp_id from t_emp where name like '%"+
- jdbcDAO.changeCode(request.getParameter("s_text"))+"%')";
- pageTo += "&ss&s_text="+request.getParameter("s_text");
- searchCondition = "查询条件为:发送人姓名中包含有'"+request.getParameter("s_text")+"'的消息";
- }
- %>
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
- <HTML>
- <jsp:include page="/vnex/page/FORM_HEAD.jsp" />
- <BODY text=#000000 vLink=#000000 aLink=#000000 link=#000000 bgColor=#ffffff topMargin=20 leftmargin="0" marginwidth="0" marginheight="0">
- <script language="JavaScript1.2" src="/vnex/menu/dockmenu_communicate.js"></script>
- <script language="JavaScript1.2" src="/vnex/menu/dockmenu.js"></script>
- <script language="JavaScript" src="/vnex/util/strUtil.js"></script>
- <script language=JavaScript>
- function checkChar(str)
- {
- var i,j,strTemp;
- strTemp=""<>/\'";
- for (i=0;i<str.length;i++)
- {
- j=strTemp.indexOf(str.charAt(i));
- if (j!=-1)
- {
- return false;
- }
- }
- return true;
- }
- function SelectAll(form)
- {
- for (var i=0;i<form.elements.length;i++)
- {
- var e = form.elements[i];
- if (e.name != 'C1')
- e.checked = form.C1.checked;
- }
- }
- function deleteReceivedMsgs(form)
- {
- if(form.msgIds == null)
- {
- alert("目前尚未有数据可供删除");
- return;
- }
- if(!isChecked(form.msgIds))
- {
- alert("请至少选择一条消息再进行删除");
- return;
- }
- if(confirm("是否删除所选信息?"))
- {
- form.action="/mainctrl/msg/deleteReceivedMsgs";
- form.submit();
- }
- }
- function doSearch(form)
- {
- if(checkChar(form.s_text.value))
- {
- form.action="/mainctrl/msg/receivedHome?ss";
- form.submit();
- }
- else
- alert("不要在查询条件中加入"<>/\'之类的字符");
- }
- </script>
- <DIV align=center>
- <form name="form1" method="post">
- <TABLE class=outter cellSpacing=0 cellPadding=0 width=600 border=0>
- <TBODY>
- <jsp:include page="/vnex/page/TTOA_TABLE_TOP.jsp" />
- <TR>
- <TD colSpan=3 align="center" class="iframestyle" valign="top"><br>
- <table width="600" border="1" cellspacing="1" bordercolor="#666666">
- <tr valign="top">
- <td bgcolor="#fafafa" >
- <table width="600" border="0" cellspacing="0" cellpadding="0">
- <tr valign="top" bgcolor="#cccccc">
- <td>
- <table width="600" border="0" cellpadding="2" cellspacing="0">
- <tr bgcolor="#666666">
- <td><font class="strongw"><a href="/mainctrl/home/index"><font color="#ffffff">首页</font></a>>><a href="/mainctrl/communication/main"><font color="#ffffff">通信</font></a>>><a href="/mainctrl/msg/receivedHome"><font color="#ffffff">消息板</font></a>>>已接收的信息</font>
- </td>
- </tr>
- <tr bgcolor="#fafafa" height="30">
- <td><strong> 发送人:</strong>
- <input type="text" name="s_text" size="20" class="text">
- <input type="button" value="查询" name="B12" onClick="doSearch(this.form)" class="text">
-
- <input type="button" value="发送的消息" name="B13" class="text" onclick="location='/mainctrl/msg/sentHome'" style="width:70px">
- </td>
- </tr>
- </table>
- <table width="600" border="0" cellspacing="1" cellpadding="2">
- <tr bgcolor="#fafafa" height="30">
- <td colspan="6">
- <input type="button" name="delete_msg" class="text" value="删除" onclick="deleteReceivedMsgs(this.form)">
- </td>
- </tr>
- <tr align="center">
- <td width="7%"><font class="strong">选择</font></td>
- <td width="21%"><font class="strong">标题</font></td>
- <td width="16%"><font class="strong">发送人</font></td>
- <td width="18%"><font class="strong">发送部门</font></td>
- <td width="12%"><font class="strong">状态</font></td>
- <td width="25%"><font class="strong">发送日期</font></td>
- </tr>
- <comm:msgList queryStr="<%=condition%>" searchWhat="received">
- <vnex:items paging="true">
- <tr bgcolor="<vnex:itemsColor />" align="center">
- <td width="7%">
- <input type="checkbox" name="msgIds" value="<comm:msgAttribute attribute="id" />">
- </td>
- <td width="21%"><a href="/mainctrl/msg/receivedDetail?msgId=<comm:msgAttribute attribute="id" />&empId=<%=BusinessName.getEmpId()%>"><comm:msgAttribute attribute="msg_title" /></a></td>
- <td width="16%"><comm:msgAttribute attribute="sender_name" /></td>
- <td width="18%"><comm:msgAttribute attribute="dept_name" /></td>
- <td width="12%"><comm:msgAttribute attribute="status" /></td>
- <td width="25%"><comm:msgAttribute attribute="send_date" /></td>
- </tr>
- </vnex:items>
- <tr bgcolor="#e0e0e0">
- <td width="7%" align="center">
- <input type="checkbox" name="C1" onclick="SelectAll(this.form)">
- </td>
- <td colspan="5">
- 全选
- </td>
- </tr>
- <tr>
- <td colspan="6" bgcolor="#fafafa"> <vnex:pagingTag pageName="<%=pageTo%>" />
- </td>
- </tr>
- </comm:msgList>
- </table>
- </td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- <jsp:include page="/vnex/page/TTOA_HELP.jsp" />
- </TD>
- </TR>
- <jsp:include page="/vnex/page/TTOA_TABLE_BOTTOM.jsp" />
- </TBODY>
- </TABLE>
- <BR>
- <jsp:include page="/vnex/page/TTOA_PRODUCER_LOGO.jsp" />
- </form>
- </DIV>
- </BODY>
- </HTML>