<%@ Page Language="C#" AutoEventWireup="true" CodeFile="PhotoList.aspx.cs" Inherits="Admin_PhotoList" %>

<%@ Import Namespace ="Spaces" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%=Globals.Text["PostList_Title"]%></title>

<link href="Admin.css" rel="stylesheet" type="text/css">


</head>
<body>
<form id="Form1" runat="server" >
<table width="640" border="0" align="center" cellpadding="0" cellspacing="0" class="black333333_red_noline">
  <tr>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>
      <table width="100%"  border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="3" height="3"><img src="img/O_angle_up_left.gif" width="3" height="3"></td>
          <td bgcolor="#ACD373" width="100%"></td>
          <td width="3"><img src="img/O_angle_up_right.gif" width="3" height="3"></td>
        </tr>
    </table></td>
  </tr>
  <tr>
    <td bgcolor="#ACD373"><img src="img/article_txt.gif" width="130" height="25"></td>
  </tr>
  <tr>
    <td class="form_border">
      <table width="100%"  border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="20">&nbsp;</td>
          <td>&nbsp;</td>
          <td width="20">&nbsp;</td>
        </tr>
        <tr>
          <td style="height: 117px">&nbsp;</td>
          <td style="height: 117px"><table width="100%"  border="0" cellspacing="0" cellpadding="0" class="black333333_red_noline">
              <tr> 
                <td align="right" > <font color="#FF6600"><a href="editPost.aspx"><%=Globals.Text["EditHtmlList_PublishArtical"]%></a></font> 
                </td>
              </tr>
              <tr> 
                <td> <fieldset>
                  <legend>&nbsp;<%=Globals.Text["PostList_BlogManage"]%>&nbsp;</legend>
                  <div align="right"><%=Globals.Text["PostList_BlogInterface"]%><br>
                    　　<%=Globals.Text["PostList_BlogEdit"]%><br>
                    <br>
                  </div>
                  </fieldset></td>
              </tr>
            </table></td>
          <td style="height: 117px">&nbsp;</td>
        </tr>
        <tr>
          <td>&nbsp;</td>
          <td><table width="100%" border="0" cellpadding="0" cellspacing="0"  >
              <tr>
                <td width="11%"></td>
                <td width="89%">
                    </td>
              </tr>
            </table>
              <asp:Repeater ID="rprPhotoList" runat="server">
                  <HeaderTemplate>
                      <table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#FFFFFF"  >
              <tr bgcolor="#669900"> 
              <td width="25%" bgcolor="#669900"><font color="#FFFFFF">图片</font></td>
                <td width="20%" bgcolor="#669900"><font color="#FFFFFF">图片名称</font></td>
                <td width="10%" align="center" bgcolor="#669900"><font color="#FFFFFF">标签</font></td>
                <td width="10%" align="center" bgcolor="#669900"><font color="#FFFFFF">大小</font></td>
                <td width="18%" align="center" bgcolor="#669900"><font color="#FFFFFF">封面</font></td>
                <td width="10%" align="center" bgcolor="#669900"><font color="#FFFFFF">编辑</font></td>
                <td width="7%" align="center" bgcolor="#669900"><font color="#FFFFFF">删除</font></td>
              </tr>
                  </HeaderTemplate>
                  <ItemTemplate>
                     <tr bgcolor="#EEF5E2">
                      <td> 
                        <a href="" Target="_blank">
                        <img src='<%#string.Format("{0}/{1}/{2}/small/{3}",Config.GetConfig().PhotosUrl,User.Identity.Name,Eval("CategoryID"),Eval(  "SmallPic")) %>' alt='<%# Eval(  "Title")%>' width="64" height="64"/>
                                             
                        </a>
                        
                        </td> 
                <td> 
                        <a href="" Target="_blank">
                        <%# Utils.FormatLength(Eval( "Title"),18) %>
                        </a>
                        
                        </td>
                <td align="center">
                
                <%#Utils.TagsToString((System.Collections.Generic.List<string>)Eval("Tags"))%> 
                </td>
                <td><%# Utils.FormatSpaceSize(Convert.ToInt32(Eval(  "Size"))) %> </td>
                <td align="center">                 <asp:LinkButton ID="SetMainPic" CausesValidation="False" CommandName="setmain" CommandArgument='<%# Eval(  "PhotoID") %>'
                        OnClientClick="return confirm('您要将该图片设为封面吗？')"      runat="server"  >设置</asp:LinkButton> </td>
                <td align="center"><a href='UploadPhoto.aspx?photoID=<%# Eval(  "PhotoID") %>'><img src="./img/edit.gif" width="20" height="18" /></a></td>
                <td align="center">
                 <asp:LinkButton ID="lnkDelete" CausesValidation="False" CommandName="Delete" CommandArgument='<%# Eval(  "PhotoID") %>'
                        OnClientClick="return confirm('是否真的删除该图片？')"      runat="server"  ><img src="./img/icon_del.gif" width="14" height="14" /></asp:LinkButton>
                </td>
              </tr>
                  </ItemTemplate>
                
                  <FooterTemplate>
                      </table>
                  </FooterTemplate>
              </asp:Repeater>
            
            <br>
              &nbsp;</td>
          <td>&nbsp;</td>
        </tr>
    </table></td>
    <tr>
    <td height="30" bgcolor="#E3F0D0"  align=center >&nbsp; 
    
 </td>
  </tr>
 
</table>
</form>
</body>
</html>