<%@ Page Language="C#" MasterPageFile="~/AdminMaster.master" AutoEventWireup="true" CodeFile="AssetCategory.aspx.cs" Inherits="AssetCategory" Title="Untitled Page" %>

<%@ Register src="US_MainAdminChecker.ascx" tagname="US_MainAdminChecker" tagprefix="uc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

<table style="width:100%;">
        <tr>
            <td style="text-align: left" colspan="3">
                <asp:Label ID="Lbl_Title" runat="server" CssClass="LabelHeaader" 
                    Text="درج طبقه بندی کالا"></asp:Label>
            </td>
        </tr>
        <tr>
            <td style="text-align: left">
                &nbsp;</td>
            <td style="text-align: right">
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td style="text-align: left">
                <asp:Label ID="Lbl_AsseCategory" runat="server" CssClass="Label1" 
                    Text="عنوان طبقه بندی کالا:"></asp:Label>
            </td>
            <td style="text-align: right">
                <asp:TextBox ID="Txt_AsseCategory" runat="server" 
                    CssClass="TextNormalAlignLeftDLeft" ValidationGroup="11"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                    ControlToValidate="Txt_AsseCategory" 
                    ErrorMessage="ورود عنوان طبقه بندی کالا الزامی می باشد" 
                    ValidationGroup="11">*</asp:RequiredFieldValidator>
            </td>
            <td>
                &nbsp;</td>
        </tr>
        <tr>
            <td style="text-align: left">
                &nbsp;</td>
            <td>
                <asp:Button ID="Btn_Insert" runat="server" CssClass="ButtonAdd" 
                    onclick="Btn_Insert_Click" Text="درج طبقه" ValidationGroup="11" />
            </td>
            <td>
                <asp:Label ID="Lbl_Error" runat="server" CssClass="LabelError"></asp:Label>
            </td>
        </tr>
        <tr>
            <td style="text-align: right" colspan="3">
                <uc1:US_MainAdminChecker ID="US_MainAdminChecker1" runat="server" />
                <asp:ValidationSummary ID="ValidationSummary1" runat="server" Width="700px" 
                    ValidationGroup="11" />
            </td>
        </tr>
        <tr>
            <td style="text-align: center" colspan="3">
                <asp:GridView ID="Grd_AssetCategory" runat="server" CssClass="mGrid" 
                    AllowPaging="True" AllowSorting="True" AutoGenerateColumns="False" 
                    DataKeyNames="AssetCategoryID" DataSourceID="LinqDt_AssetCategory" 
                    PageSize="20">
                    <Columns>
                        <asp:CommandField ShowEditButton="True">
                            <ItemStyle Width="50px" />
                        </asp:CommandField>
                        <asp:BoundField DataField="AssetCategoryID" HeaderText="کد" 
                            InsertVisible="False" ReadOnly="True" SortExpression="AssetCategoryID">
                            <ItemStyle Width="50px" />
                        </asp:BoundField>
                        <asp:BoundField DataField="AssetCategoryDescription" HeaderText="عنوان طبقه بندی" 
                            SortExpression="AssetCategoryDescription" />
                        <asp:CommandField ShowDeleteButton="True">
                            <ItemStyle Width="50px" />
                        </asp:CommandField>
                    </Columns>
                    <HeaderStyle ForeColor="#E4E4E4" />
                </asp:GridView>
                <asp:LinqDataSource ID="LinqDt_AssetCategory" runat="server" 
                    ContextTypeName="LSC_WareHouseDataContext" EnableDelete="True" 
                    EnableUpdate="True" OrderBy="AssetCategoryID desc" 
                    TableName="tblAssetCategories">
                </asp:LinqDataSource>
            </td>
        </tr>
        <tr>
            <td style="text-align: left">
                &nbsp;</td>
            <td>
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
    </table>

</asp:Content>

