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

<!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">
    <title>无标题页</title>
    <link href="images/StyleSheet.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <div style="text-align:center; font-size:12px">
    <table class="tableBorder" cellspacing="1" cellpadding="3" align="center" border="0">
          <tbody>
            <tr>
              <th style="font-size:14px; color:#d6dff7; font-weight:bold; text-align:left;" class="tableHeaderText" height="25">
              &nbsp;&nbsp;&nbsp;&nbsp;一级类别管理</th>
            </tr>
          </tbody>
          <tbody>
          <tr><td class="forumRow">
             <div style="text-align:right; width:98%;">
                分类名称: <asp:TextBox runat="server" ID="keywordTb"></asp:TextBox>
                <asp:Button runat="server" ID="searchBt" Text="查找" OnClick="searchBt_Click" CausesValidation="false" />
             </div>
            <asp:GridView runat="server" ID="type_1Gv" SkinID="admin_gv_skin" AllowPaging="True" AutoGenerateColumns="False" Width="98%" DataKeyNames="typeid_1" EmptyDataText="暂无相关数据" OnPageIndexChanging="type_1Gv_PageIndexChanging" OnRowDeleting="type_1Gv_RowDeleting" OnRowCancelingEdit="type_1Gv_RowCancelingEdit" OnRowEditing="type_1Gv_RowEditing" OnRowUpdating="type_1Gv_RowUpdating" OnRowDataBound="type_1Gv_RowDataBound">
                <Columns>
                    <asp:TemplateField HeaderText="商品一级分类编号">
                        <ItemTemplate>
                            <asp:Label ID="Label1" runat="server" Text='<%# Bind("TypeID_1") %>'></asp:Label>
                        </ItemTemplate>
                        <ItemStyle Width="120px" />
                    </asp:TemplateField>
                    <asp:BoundField DataField="TypeName" HeaderText="商品一级分类名称" />
                    <asp:CommandField ShowEditButton="True" HeaderText="编辑" />
                    <asp:TemplateField HeaderText="删除" ShowHeader="False">
                        <ItemTemplate>
                            <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete"
                                Text="删除" OnClientClick="return confirm('是否真的删除?')"></asp:LinkButton>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <pagersettings FirstPageText="首页" LastPageText="尾页" Mode="NextPreviousFirstLast"
                    NextPageText="下一页" PreviousPageText="上一页" />
                
            </asp:GridView>
            
            <div style="text-align:right; width:98%;">
                分类名称: <asp:TextBox runat="server" ID="addnameTb" ValidationGroup="add"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="addnameTb"
                    Display="Dynamic" ErrorMessage="请输入分类名称"  ValidationGroup="add"></asp:RequiredFieldValidator>
                <asp:Button runat="server" ID="addnameBt" Text="添加新分类" OnClick="addnameBt_Click"  ValidationGroup="add" />
             </div></td></tr>
          </tbody>
          <tbody>
            <tr>
              <th class="tableHeaderText" height="25"></th>
            </tr>
          </tbody>
          </table>
        </div>
    </form>
</body>
</html>
