zongjie.aspx
上传用户:lishan0805
上传日期:2019-12-08
资源大小:12048k
文件大小:6k
源码类别:

OA系统

开发平台:

C#

  1. <%@ Page Language="C#" AutoEventWireup="true" CodeFile="zongjie.aspx.cs" Inherits="wx_zongjie_zongjie" %>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" >
  4. <head runat="server">
  5.     <title>所有总结</title>
  6.     <style type="text/css">
  7. <!--
  8. .style1 { color: #FFFFFF;
  9. font-weight: bold;
  10. }
  11. .style2 {font-size: 12px}
  12. -->
  13. </style>
  14. <link href="../css/link.css" rel="stylesheet" type="text/css"/>
  15. <style type="text/css">
  16. <!--
  17. .style3 {font-size: 14px}
  18. .style17 {color: #5AAE18}
  19. .style18 {color: #5AAE18; font-size: 12px; }
  20. .style21 {
  21. color: #5EAE19;
  22. font-weight: bold;
  23. }
  24. .style7 {color: #FFFFFF}
  25. .style22 {color: #5AAE18; font-weight: bold; font-size: 12px; }
  26. -->
  27. </style>
  28. <link href="../css/link1.css" rel="stylesheet" type="text/css">
  29. <style type="text/css">
  30. <!--
  31. .style5 {color: #000000}
  32. -->
  33. </style>
  34. </head>
  35. <body style="text-align: center">
  36. <%
  37.                  //取登陆人信息 
  38.                  COM.OA.Entity.users loginuser =Session["loginuser"] as COM.OA.Entity.users;
  39.                  //如果取不到跳转到登陆页
  40.                   if (loginuser == null)
  41.                   {
  42.                       this.Response.Write(string.Format(GetRedirect.ALLREDIRECT, "../login.aspx"));
  43.                   }
  44.  %>
  45.      <form id="form1" runat="server">
  46.     <div style="text-align=center">
  47.         <table style="width: 653px; height: 147px; text-align: center;" bgcolor="#5AAE18" border="0">
  48.             <tr  bgcolor='#FFFFFF'>
  49.                 <td style="width: 175px; text-align: center;background-color:#5AAE18;" colspan="2">
  50.                   <div align="center"><span class="style7"><span class="style1">所 有 工 作 总 结</span></span></div></td>
  51.                               
  52.             </tr>
  53.             <% 
  54.                 //接收第几页
  55.                 string page = this.Request["page"];
  56.                 //声明全局变量
  57.                 System.Collections.Generic.IList<COM.OA.Entity.worksumup> wo;
  58.                 //设置where语句
  59.                 String where = "1=1";
  60.                 
  61.                 wo = COM.OA.BLL.worksumupBLL.Select();
  62.                 //取数据库相关信息总条数
  63.                 int count = wo.Count;
  64.                 //int转换成float类型
  65.                 float countd = count;
  66.                 //调用ceiling方法转换取值并转换成double类型
  67.                 double weiy = Math.Ceiling(countd / 3);
  68.                 //转换成int类型
  69.                 int weiye = Int32.Parse(weiy.ToString());
  70.                 int pages = 1;
  71.                 int shangpage = 0;
  72.                 int xiapage = 0;
  73.                 //判断是否第一次登陆,是就查前3条信息
  74.                 if (page == null)
  75.                 {
  76.                     wo = COM.OA.BLL.worksumupBLL.Select(3,1,where);
  77.                     shangpage = 1;
  78.                     xiapage = 2;
  79.                 }
  80.                 //不是第一次登陆按页数查询
  81.                 else
  82.                 {
  83.                     pages = Int32.Parse(page);
  84.                     shangpage = pages - 1;
  85.                     xiapage = pages + 1;
  86.                     wo = COM.OA.BLL.worksumupBLL.Select(3, pages, where);
  87.                 }
  88.                 //判断查询出的内容是否为空
  89.                 if (wo.Count != 0)
  90.                 {
  91.                     foreach(COM.OA.Entity.worksumup ww in wo){
  92.             %>
  93.               <tr bgcolor='#FFFFFF'>
  94.                 <td style="width: 175px; text-align: center;">
  95.                     月份</td>
  96.                 <td style="width: 470px">
  97.                     <%=ww.ws_year%>年<%=ww.ws_month %>月</td>               
  98.             </tr>
  99.               <tr bgcolor='#FFFFFF'>
  100.                 <td style="width: 175px; height: 21px; text-align: center;">
  101.                     常规工作</td>
  102.                 <td style="height: 21px; width: 470px;">
  103.                     <%=ww.ws_generalwork %></td>               
  104.             </tr>
  105.               <tr bgcolor='#FFFFFF'>
  106.                 <td style="width: 175px; text-align: center;">
  107.                     下周工作计划</td>
  108.                 <td style="width: 470px">
  109.                     <%=ww.ws_nextplan%></td>               
  110.             </tr>
  111.               <tr bgcolor='#FFFFFF'>
  112.                 <td style="width: 175px; height: 21px; text-align: center;">
  113.                     创新,问题反馈,意见与建议</td>
  114.                 <td style="height: 21px; width: 470px;">
  115.                     <%=ww.ws_advice %></td>               
  116.             </tr>
  117.               <tr bgcolor='#FFFFFF'>
  118.                 <td style="width: 175px">
  119.                     &nbsp;&nbsp;
  120.                 </td>
  121.                 <td style="width: 470px">
  122.                     时间:<%=ww.ws_time %></td>               
  123.             </tr>
  124.               <tr bgcolor='#FFFFFF'>
  125.                 <td style="width: 175px; height: 21px; text-align: center;" colspan="2">
  126.                     &nbsp;&nbsp;
  127.                 </td>
  128.                               
  129.             </tr>
  130.              
  131.             <%
  132.                 }
  133. %>
  134.             <tr bgcolor='#FFFFFF'>
  135.                 <td style="width: 175px; height: 21px; text-align: center;" colspan="2">
  136.                     <% if (pages == 1)
  137.                        { %>
  138.                         <a href="zongjie.aspx?page=1">首页</a>                    
  139.                     
  140.                     <%}
  141.                       else
  142.                       { %>
  143.                     <a href="zongjie.aspx?page=<%=shangpage %>">上一页</a><% } %>&nbsp
  144.                      <% if (pages == weiye){  %> <a href="zongjie.aspx?page=<%=weiye %>">尾页</a>
  145.                      <% }else{  %> <a href="zongjie.aspx?page=<%=xiapage %>">下一页</a>
  146.                      <% } %>
  147.                 </td>
  148.                               
  149.             </tr>
  150. <%
  151.             }
  152.            else { 
  153.                     %>
  154.                 <tr>
  155.                 <td style="width: 175px; text-align: center;" colspan="2">
  156.                     无记录</td>
  157.                               
  158.             </tr>
  159.                     <%
  160.                 }
  161.           %>
  162.         </table>
  163.     
  164.     </div>
  165.     </form>
  166. </body>
  167. </html>