<%@ page language="C#" autoeventwireup="true" inherits="Admin_DispatchRegion_Manage, GroupTGWeb_deploy" %>

<%@ Register assembly="ShopNum1.Control" namespace="ShopNum1.Control" tagprefix="ShopNum1" %>

<%@ Register src="UserControl/MessageShow.ascx" tagname="MessageShow" tagprefix="uc1" %>

<!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>Untitled Page</title>
          <link type="text/css" rel="Stylesheet" href="css/index.css" /> 
<script type="text/javascript" language="javascript" src="../js/CommonJS.js"></script>
</head>
<body style="padding:0; background-image: url(images/Bg_right.gif); background-repeat:repeat;">
  <form id="form1" runat="server">
  <div class="navigator"><asp:Label ID="LabelPageTitle" runat="server" Text="【 新增配送地区 】"></asp:Label></div>
    <div style="height: 508px" align="left">
    
<div class="vote">
        <ShopNum1:Num1GridView id="Num1GridViewShow" runat="server" 
            AutoGenerateColumns="False" Width="100%" PageSize="5" AllowPaging="True" 
                    DataSourceID="ObjectDataSourceData" AddSequenceColumn="False" 
                    AllowMultiColumnSorting="False" BorderColor="#CCDDEF" BorderStyle="Solid" 
                    BorderWidth="1px" CellPadding="4" Del="False" DeletePromptText="确实要删除指定的记录吗？" 
                    Edit="False" FixHeader="False" GridViewSortDirection="Ascending" 
                    PagingStyle="None" style="margin-left: 2px;" TableName="">
<HeaderStyle HorizontalAlign="Center" BackColor="#6699CC" Font-Bold="True" ForeColor="#FFFFFF"></HeaderStyle>

<PagerStyle HorizontalAlign="Left" BackColor="#EEEEEE" ForeColor="#6699CC"></PagerStyle>
            <Columns>
                <asp:TemplateField>
                    <HeaderTemplate>
                        <input id="checkboxAll" onclick="javascript:SelectAllCheckboxes(this);" 
                            type="checkbox" />
                    </HeaderTemplate>
                    <ItemTemplate>
                        <input id="checkboxItem" type="checkbox" value='<%# Eval("Guid") %>' />
                    </ItemTemplate>
                    <HeaderStyle HorizontalAlign="Center" />
                    <ItemStyle HorizontalAlign="Center" Width="30px" />
                </asp:TemplateField>
                <asp:BoundField DataField="Guid" HeaderText="GUID" Visible="False">
                    <ItemStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="Name" HeaderText="地区名称" SortExpression="Name" >
                    <HeaderStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="Memo" HeaderText="备注" SortExpression="Memo" >
                    <HeaderStyle HorizontalAlign="Center" />
                </asp:BoundField>
                <asp:BoundField DataField="OrderID" HeaderText="排序号" SortExpression="OrderID"  Visible="false"/>
            </Columns>
        </ShopNum1:Num1GridView>
    
            <asp:Button ID="ButtonAdd" runat="server" CausesValidation="False" Text="添加" 
                onclick="ButtonAdd_Click" CssClass="bt2"/>
            <asp:Button ID="ButtonEdit" runat="server" onclick="ButtonEdit_Click" 
                                onclientclick="return EditButton()" Text="编辑" CausesValidation="False" CssClass="bt2" />
            <asp:Button ID="ButtonDelete" runat="server" CausesValidation="False" 
                Text="删除" onclientclick="return DeleteButton()" 
                onclick="ButtonDelete_Click" CssClass="bt2"/>

        <uc1:MessageShow ID="MessageShow" runat="server" Visible="False" />
    </div>
    <asp:ObjectDataSource ID="ObjectDataSourceData" runat="server" 
        SelectMethod="Search" 
        TypeName="ShopNum1.BusinessLogic.ShopNum1_DispatchRegion_Action" 
        OldValuesParameterFormatString="original_{0}">
        <SelectParameters>
            <asp:Parameter DefaultValue="0" Name="IsDeleted" Type="Int32" />
        </SelectParameters>
    </asp:ObjectDataSource>

                <table >
                    <tr>
                        <td  colspan="2">
  
 
    <asp:HiddenField ID="CheckGuid" runat="server" Value="0" />
                        </td>
                    </tr>
                    <tr>
                        <td align="right"  width="40%">
                            <asp:Label ID="LabelRegionName" runat="server" Text="地区名称："></asp:Label>
                        </td>
                        <td align="left" width="60%">
                            <asp:TextBox ID="TextBoxRegionName" runat="server" CssClass="input2"></asp:TextBox>
                            <asp:Label ID="Label2" runat="server" Text="*" ForeColor="red"></asp:Label>
                            <asp:RequiredFieldValidator ID="RequiredFieldValidatorRegionName" 
                            runat="server" ControlToValidate="TextBoxRegionName" Display="Dynamic" 
                            ErrorMessage="该值不能为空"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidatorRegionName" 
                        runat="server" ControlToValidate="TextBoxRegionName" Display="Dynamic" 
                        ErrorMessage="地区名称最多50个字符" ValidationExpression="^[\s\S]{0,50}$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" width="40%">
                            <asp:Label ID="LabelMemo" runat="server" Text="备注："></asp:Label>
                        </td>
                        <td align="left" width="60%">
                            <asp:TextBox ID="TextBoxMemo" runat="server" Height="60px" 
                                TextMode="MultiLine" Width="440px"></asp:TextBox>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidatorMemo" 
                        runat="server" ControlToValidate="TextBoxMemo" Display="Dynamic" 
                        ErrorMessage="备注最多1000个字符" ValidationExpression="^[\s\S]{0,1000}$"></asp:RegularExpressionValidator>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" width="40%">
                            &nbsp;</td>
                        <td align="left" width="60%">
                        <asp:Button ID="ButtonConfirm" runat="server" Text="确定" 
                            onclick="ButtonConfirm_Click" ToolTip="Submit"  CssClass="bt2"/>
                            <input ID="inputReset" runat="server"  type="reset" value="重置"  class="bt2"/></td>
                    </tr>
                </table>
    </div>
    </form>
</body>
</html>
