<%@ page language="C#" masterpagefile="AdminIndexMaster.master" autoeventwireup="true" inherits="Admin_Admin_Skin, mallz" title="风格管理" enableeventvalidation="false" validaterequest="false" viewstateencryptionmode="Never" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

<script type="text/javascript">
    function RequestQuerry(val)
    {
       var uri = window.location.search;
       var re = new RegExp("" +val+ "\=([^\&\?]*)", "ig");
       return ((uri.match(re))?(uri.match(re)[0].substr(val.length+1)):null);
    }
    function PageReload()
    {
      window.location.reload();
    }

</script>
<script type="text/javascript" src="../JS/mouse.js" ></script> 
 
  <table class="adminheading">
         <tr>
            <th>风格管理</th>                  
            <td align="right"><div style="width:630px">
            导航：
                <a href="Admin_Skin.aspx?SkinType=Index">首页风格</a>&nbsp;|   
                <a href="Admin_Skin.aspx?SkinType=Shop">店铺风格</a>&nbsp;|  
                <a href="Admin_Skin.aspx?SkinType=Special">专题风格</a>&nbsp;|  
                <a href="Admin_Skin.aspx?SkinType=Product">商品风格</a>&nbsp;|  
                <a href="Admin_Skin.aspx?SkinType=Class">分类风格</a>&nbsp;|  
                <a href="Admin_Skin.aspx?SkinType=Basic">基本风格</a>&nbsp;|  
                <a href="Admin_Skin.aspx?SkinType=Member">会员中心风格</a>&nbsp;|
                <a href="Admin_Skin.aspx?SkinType=Customer">自定义风格</a>&nbsp;|  
                <a href="javascript:void(0)" onclick="AddSkin('','Add')">新增风格</a>
             </div>               
             </td>
             <td class="rtdw"></td>  
         </tr>
  </table> 
    
         <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataKeyNames="SkinID" EnableViewState="false"
            OnRowDataBound="GridView1_RowDataBound" CssClass="adminlist" AllowPaging="True" PageSize="20" OnDataBound="GridView1_DataBound">
            <Columns>               
                <asp:BoundField DataField="Skinid" HeaderText="编号" >
                    <HeaderStyle Width="5%" />
                </asp:BoundField>
                <asp:BoundField DataField="SkinType" HeaderText="类型">
                    <HeaderStyle Width="10%" />
                </asp:BoundField>
                <asp:BoundField DataField="ProjectName" HeaderText="所属方案">
                    <HeaderStyle Width="20%" />
                </asp:BoundField>
                <asp:TemplateField HeaderText="风格名称">
                   <ItemTemplate>
                     <asp:HyperLink ID="SkinName" Text='<%# Eval("SkinName") %>' ToolTip='<%#Eval("SkinPreviewImg")%>' NavigateUrl="#" runat="server" />                   
                   </ItemTemplate>
                   <HeaderStyle Width="20%" />
                </asp:TemplateField>   
              
                 <asp:BoundField DataField="IsDefault" HeaderText="默认">
                    <HeaderStyle Width="5%" />
                </asp:BoundField>
               
                <asp:TemplateField HeaderText="操作选项">
                   <ItemTemplate>
                      <asp:LinkButton ID="SetIsDefault" runat="server" CommandArgument='<%# Eval("SkinID")+","+Eval("SkinType") %>' CommandName="SetIsDefault" Text="设为默认" OnCommand="Command_OnClick" /> |                         
                      <a id="btnUpdateSkin" href='<%#"Admin_AddSkin.aspx?Action=Modify&SkinID="+Eval("Skinid")%>'>修改</a> | 
                      <a id="btnAddSkin" href='<%#"Admin_AddSkin.aspx?Action=Add&SkinType="+Eval("SkinType")%>'>添加</a> | 
                      <asp:LinkButton id="btnDelete" runat="server" OnClientClick ="return confirm('确定要彻底删除此风格吗?')" CommandName="DelSkin" CommandArgument='<%# Eval("SkinID")+","+Eval("SkinType") %>' Text="删除" OnCommand="Command_OnClick"/> 
                   </ItemTemplate>                 
                    <HeaderStyle Width="30%" />
                </asp:TemplateField>             
            </Columns>
            <EmptyDataTemplate>
               <tr><td colspan="6">暂无风格！</td></tr>
            </EmptyDataTemplate>
         </asp:GridView>
   
</asp:Content>

