- <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Notice.aspx.cs" Inherits="SysManage_Notice" %>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml" >
- <head runat="server">
- <link href="style/gridStyle.css" rel="stylesheet" type="text/css" />
- <script src="../js/calendar2.js" type="text/javascript"></script>
- <script type="text/javascript" language="javascript" src="../js/default.js"></script>
- <script type="text/javascript" >
- function modelesswin(url,mwidth,mheight)
- {
- window.showModalDialog(url,"","help:0;dialogWidth=" +mwidth +"px;dialogHeight=" +mheight +"px;scroll=no;");
- window.location.replace(window.location.href);
- }
- </script>
- <title>无标题页</title>
- </head>
- <body>
- <form id="form1" runat="server">
- <TABLE width="100%" border="0" cellPadding="0" cellSpacing="0" >
- <tr>
- <td bgColor="#f7f7f7" width="100%" height="25px">
- <strong> 公 告 管 理 </strong>
- </td>
- </tr>
- <tr>
- <td background="../Images/toolbarbg.jpg" height="25">
- <table border="0" cellpadding="0" cellspacing="0" style="width: 100%">
- <tr>
- <td align="left" style="height: 25px">
- <img src="../Images/add.gif" height="15" align="absmiddle">
- <a href="javascript: modelesswin('NoticeAdd.aspx',500,300)">新建公告</a>
- </td>
- <td align="right" style="height: 25px">
- 时间段批量删除:<asp:TextBox ID="TB_start" runat="server" onfocus="fPopUpCalendarDlg()" ></asp:TextBox>
- <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="*" ValidationGroup="DelButton" ControlToValidate="TB_start" Display="Dynamic"></asp:RequiredFieldValidator>
- <asp:TextBox ID="TB_end" runat="server" onfocus="fPopUpCalendarDlg()"></asp:TextBox>
- <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ErrorMessage="*" ValidationGroup="DelButton" ControlToValidate="TB_end" Display="Dynamic"></asp:RequiredFieldValidator>
- <asp:ImageButton ID="pSDel" runat="server" ImageUrl="~/Images/s-del.gif" ValidationGroup="DelButton" OnClick="pSDel_Click" />
-
- </td>
- </tr>
- </table>
- </td>
- </tr>
- <tr>
- <td width="100%" valign="top">
- <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataKeyNames="NoticeID" BackColor="#CDCDCF" BorderWidth="0px"
- CssClass="Grid" SelectedRowStyle-CssClass="SelectedRow" HeaderStyle-CssClass="GridHeader" RowStyle-CssClass="HeadingCellText"
- FooterStyle-CssClass="GridFooter" ShowFooter="True" CellSpacing="1" CellPadding="0" Width="100%"
- HeaderStyle-ForeColor="black" HeaderStyle-Font-Size="12px" HeaderStyle-Font-Underline="false" AllowPaging="True" AllowSorting="True" OnPageIndexChanging="GridView1_PageIndexChanging"
- OnRowDataBound="GridView1_RowDataBound" OnRowDeleting="GridView1_RowDeleting" OnRowEditing="GridView1_RowEditing" OnSorting="GridView1_Sorting" >
- <AlternatingRowStyle BackColor="#F0F0F0" />
- <RowStyle BackColor="#F9FAFC" CssClass="HeadingCellText" />
- <Columns>
- <asp:BoundField DataField="NoticeID" HeaderText="公告编号" Visible="False">
- </asp:BoundField>
- <asp:BoundField DataField="NoticeTitle" HeaderText="公告标题">
- <HeaderStyle Width="15%" />
- </asp:BoundField>
- <asp:BoundField DataField="NoticeContent" HeaderText="公告内容">
- <HeaderStyle Width="25%" />
- </asp:BoundField>
- <asp:BoundField DataField="InvaidDate" HeaderText="失效时间" SortExpression="InvaidDate">
- <HeaderStyle Width="15%" />
- </asp:BoundField>
- <asp:BoundField DataField="NoticeDate" HeaderText="公告时间" SortExpression="NoticeDate" >
- <HeaderStyle Width="15%" />
- </asp:BoundField>
- <asp:BoundField DataField="EmpName" HeaderText="创建者" >
- <HeaderStyle Width="15%" />
- </asp:BoundField>
- <asp:BoundField DataField="CreateUserID" HeaderText="创建者ID" Visible="False" >
- </asp:BoundField>
- <asp:BoundField DataField="AssRoleID" HeaderText="接受角色" Visible="False"> </asp:BoundField>
- <asp:BoundField DataField="AssUserID" HeaderText="接受者" Visible="False"> </asp:BoundField>
- <asp:TemplateField HeaderText=" 操 作">
- <ItemTemplate>
- <asp:ImageButton ID="IB_Edit" ToolTip="编辑" runat="server" CommandName="edit" ImageUrl="~/Images/s_edit.gif"/>
- <asp:ImageButton ToolTip="删除" ID="IB_Del" runat="server" CommandName="Delete" ImageUrl="~/Images/s-del.gif"
- OnClientClick='<%#"return confirm("确认删除标题为『"+Eval("NoticeTitle")+"』的公告吗?");" %>'/>
- </ItemTemplate>
- <HeaderStyle Width="12%" HorizontalAlign="center" BorderWidth="0px"/>
- <ItemStyle HorizontalAlign="Left" BorderWidth="0px"/>
- </asp:TemplateField>
- </Columns>
- <FooterStyle CssClass="GridFooter" />
- <PagerStyle CssClass="GridPage" />
- <PagerTemplate>
- <asp:Label ID="LabelCurrentPage" runat="server">当前页:<%# ((GridView)Container.NamingContainer).PageIndex + 1 %></asp:Label>
- <asp:Label ID="LabelPageCount" runat="server" >总页数:<%# ((GridView)Container.NamingContainer).PageCount %></asp:Label>
- <asp:LinkButton ID="LinkButtonFirstPage" runat="server" CommandArgument="First" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>">首页</asp:LinkButton>
- <asp:LinkButton ID="LinkButtonPreviousPage" runat="server" CommandArgument="Prev" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>">上一页</asp:LinkButton>
- <asp:LinkButton ID="LinkButtonNextPage" runat="server" CommandArgument="Next" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">下一页</asp:LinkButton>
- <asp:LinkButton ID="LinkButtonLastPage" runat="server" CommandArgument="Last" CommandName="Page" Enable="<%# ((GridView)Container.NamingContainer).PageIndex != ((GridView)Container.NamingContainer).PageCount - 1 %>">尾页</asp:LinkButton>
- 转到第:<asp:TextBox ID="LinkTextBoxNewPage" runat="server" Width="20px" Text='<%# ((GridView)Container.Parent.Parent).PageIndex + 1 %>'></asp:TextBox>页
- <asp:RangeValidator ID="RangeValidator1" runat="server" ErrorMessage="0-99999" ValidationGroup="goto" ControlToValidate="LinkTextBoxNewPage"
- MaximumValue="99999" MinimumValue="0" Display="Dynamic" ></asp:RangeValidator>
- <asp:linkbutton id="btnGo" runat="server" causesvalidation="False" commandargument="-1" commandname="Page" text="GO" ValidationGroup="goto" />
- </PagerTemplate>
- <EmptyDataTemplate>
- <center class="EmpetyData"> 系统提示:没有公告可以显示,可以新增公告。</center>
- </EmptyDataTemplate>
- <HeaderStyle Font-Size="12px" Font-Underline="False" ForeColor="Black" BackColor="#DFDFDF" CssClass="GridHeader" Height="25px" />
- <SelectedRowStyle CssClass="SelectedRow" />
- </asp:GridView>
- </td>
- </tr>
- </TABLE>
- </form>
- </body>
- </html>