<%@ Page Language="C#" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<script runat="server">
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            Fm.Bussiness.public_select ps = new Fm.Bussiness.public_select();
            //公告信息
            Rep_affiche.DataSource = ps.Getps("Fm_affiche","top 6 *","aff_id<>0 order by aff_id desc");
            Rep_affiche.DataBind();
            //最新文档
            Rep_new.DataSource = ps.Getps("Fm_model_article_view","top 10 docid,title,path,html","docid<>0 and audit=1 order by docid desc");
            Rep_new.DataBind();
            //系统推荐
            Rep_commend.DataSource = ps.Getps("Fm_model_article_view", "top 10 docid,title,path,html", "commend=1 and audit=1 order by docid desc");
            Rep_commend.DataBind();
        } 
    }
</script>

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>无标题页</title>
    <LINK rel="stylesheet" type="text/css" href="../admin/skin/css.css" />
    <link href="/images/css/skin_blue.css" rel="stylesheet" type="text/css" />
    <link href="/images/css/inbox.css" rel="stylesheet" type="text/css" />
</head>
<body>
 <script language="javascript" type="text/javascript">
	window.onload=function (){
		setInterval("document.getElementById('time').innerHTML=new Date().toLocaleString()+' 星期'+'日一二三四五六'.charAt(new Date().getDay());",1000);
	}
</script>
    <form id="form1" runat="server">
    <div>
        <table style="width: 100%">
            <tr>
                <td colspan="2" class="bg">
                    基本信息</td>
            </tr>
            <tr>
                <td>
                    当前时间:<span id="time"></span>&nbsp;&nbsp;&nbsp;&nbsp;<br />当前登录IP:<%=Request.UserHostAddress %>
                   </td>
                <td>
                </td>
            </tr>
            <tr>
                <td class="bg" colspan="2">
                    最新公告:</td>
            </tr>
            <tr>
                <td colspan="2">
                    <table style="width: 100%">
                        <tr class="Ibx_gTable F2Img Ibx_gTable_TT">
                            <td class="Ibx_Th_Subject">
                                公告标题</td>
                            <td class="Ibx_Th_From">
                                发布人</td>
                            <td class="Ibx_Th_From">
                                发布时间</td>
                        </tr>
                        <asp:Repeater ID="Rep_affiche" runat="server">
                        <ItemTemplate>
                        <tr class="Ibx_gTable Ibx_gTable_Con">
                            <td>
                            <a href="/affiche.aspx?aid=<%#Eval("aff_id") %>"><%#Eval("aff_title") %></a> 
                            </td>
                            <td>
                            <%#Eval("aff_user") %>
                            </td>
                            <td>
                            <%#Eval("aff_btime") %>
                            </td>
                        </tr>
                         </ItemTemplate>
                        </asp:Repeater>
                    </table>
                </td>
            </tr>
            <tr>
                <td class="bg" colspan="2">
                    今日阅读</td>
            </tr>
            <tr>
                <td width=50%>

      <table style="width: 100%;">
                        <tr  class="Ibx_gTable F2Img Ibx_gTable_TT">
                            <td>
                                最新文档</td>
                        </tr>
                        <asp:Repeater ID="Rep_new" runat="server">
                        <ItemTemplate>
                       
                        <tr class="Ibx_gTable Ibx_gTable_Con">
                            <td>
                            <a href="<%#((bool)Eval("html"))?Eval("path"):"/article.aspx?docid="+Eval("docid") %>" target=_blank><%#Eval("title") %></a>
                            </td>
                        </tr> 
                        </ItemTemplate>
                        </asp:Repeater>
                    </table>
                </td>
                 <td width=50% valign=top>

                    <table style="width: 100%;">
                        <tr  class="Ibx_gTable F2Img Ibx_gTable_TT">
                            <td>
                                本站推荐</td>
                        </tr>
                        <asp:Repeater ID="Rep_commend" runat="server">
                        <ItemTemplate>

                        <tr class="Ibx_gTable Ibx_gTable_Con">
                            <td>
                            <a href="<%#((bool)Eval("html"))?Eval("path"):"/article.aspx?docid="+Eval("docid") %>" target=_blank><%#Eval("title") %></a>
                            </td>
                        </tr> 
                         </ItemTemplate>
                        </asp:Repeater>
                    </table>
                </td>
            </tr>
        </table>


    </div>
    </form>
                  
</body>
</html>
