<%@ page language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_MaterialManagement_Procurement_StockItemDataUpdate, App_Web_tvvzwpls" title="Stock Item Parameter Update" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="~/UserControls/DatePicker/DatePickerControl.ascx" TagName="DatePickerControl" TagPrefix="DPC" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl" TagPrefix="ScreenGroup" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteTextBoxForGridView.ascx" TagName="AutoCompleteControl" TagPrefix="acc" %>
<%@ Register Src="~/UserControls/Common/Stock/StockDetailBoxControl.ascx" TagName="StockControl" TagPrefix="Stock" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">

    <asp:UpdatePanel ID="HREmployeeMasterSearchUpdatePanel" runat="server">
        <ContentTemplate>
            <input type="hidden" id="hdnSessionid" runat="server" />
            <div id="divContentPage">

                <div class="dashBoardLeftCont" valign="top">
                    <div class="himssuHeader3WireBox">
                        <table width="0px" cellpadding="0" cellspacing="0">
                            <tr>
                                <td>
                                    <div class="himsBoxContent">
                                        <div class="leftUlMenu">
                                            <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="160"
                                                Visible="true" runat="server" />
                                        </div>
                                    </div>
                                </td>
                            </tr>
                        </table>
                    </div>
                </div>
                <div class="whiteboxpaddingleft row">
                    <div class="himssuHeader5WireBox">
                        <Stock:StockControl ID="StockUserControl" runat="server" Visible="true" />
                        <div class="contentHolder" style="padding-top: 0px; padding-left: 0px; padding-right: 0px">
                            <div class="himssuHeader1WireBox card card-box">
                                <div class="himsBoxHeader card-head">
                                    <div class="leftdiv">
                                    </div>
                                    <div class="himsBoxTitle">
                                        <div class="headerText">
                                            <header>
                                                <i class="fas fa-list-ul"></i>
                                                <asp:Label ID="Label1" runat="server" Text="Stock Item Parameter Update"></asp:Label>
                                            </header>
                                        </div>
                                    </div>
                                </div>
                                <div class="himsBoxContent card-body">
                                    <asp:Panel ID="DetailPanel" runat="Server">
                                        <div class="contentHolder">
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SearchCategoryLabel" Text="Category" SkinID="MandatoryLabel" runat="server"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="SearchCategoryDropDownList" runat="server"
                                                        SkinID="CustomWidthDropDownList" CssClass="form-control" AutoPostBack="true" OnSelectedIndexChanged="SearchCategoryDropDownList_SelectedIndexChanged">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SearchSubCategoryLabel" Text="Parameters" SkinID="MandatoryLabel"
                                                        runat="server"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="SearchSubCategoryDropDownList" runat="server"
                                                        SkinID="CustomWidthDropDownList" CssClass="form-control">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>

                                            <div class="outerBox pTop5 col-md-3" runat="server" visible="false">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="Label4" runat="server" Text="Location" SkinID="MandatoryLabel"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="ddlLocation" runat="server" SkinID="CustomWidthDropDownList" CssClass="form-control">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>


                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SearchMainGroupLabel" runat="server" Text="Main Group" meta:resourcekey="Label11Resource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="SearchMainGroupDropDownList" runat="server"
                                                        OnSelectedIndexChanged="Fill_SearchSubmain_Group" AutoPostBack="true" SkinID="CustomWidthDropDownList" CssClass="form-control"
                                                        meta:resourcekey="MainGroupDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>

                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SearchSubGroupLabel" runat="server" Text="Sub Group" meta:resourcekey="Label11Resource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="SearchSubGroupDropDownList" runat="server"
                                                        AutoPostBack="false" SkinID="CustomWidthDropDownList" CssClass="form-control"
                                                        meta:resourcekey="MainGroupDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="cBoth">
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="Label2" runat="server" Text="Category" meta:resourcekey="Label11Resource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList ID="ddlcategory" runat="server"
                                                        AutoPostBack="false" SkinID="CustomWidthDropDownList" CssClass="form-control"
                                                        meta:resourcekey="SearchCategoryDropDownListResource1">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop15 col-md-3">

                                                <div class="controlLabelWidth">
                                                    <asp:CheckBox ID="chkblank" Text="Blank Entry" runat="server" />

                                                </div>
                                            </div>
                                            <div class="cBoth">
                                            </div>
                                            <div class="alignCenter pTop5">
                                                <asp:Button ID="SearchButton" CssClass="btn btn-search fas" Text="&#xf002; Search" runat="Server" OnClick="SearchButton_Click"
                                                    SkinID="0" />
                                                <asp:Button ID="ResetButton" Text="&#xf12d; Clear" CssClass="btn btn-clear fas" SkinID="0" runat="Server" OnClick="ResetButton_Click" />
                                            </div>

                                            <br />
                                            <div id="Div1" class="himssuHeader6WireBox col-md-12" runat="server">
                                                <div id="GridViewPagerDiv" runat="server">
                                                    <div class="leftdiv">
                                                    </div>
                                                    <div class="himsBoxTitle">
                                                        <div class="headerText fLeft">
                                                            <asp:Label ID="GridViewLabel" Text="" runat="server" />
                                                        </div>
                                                    </div>
                                                    <div class="pull-right mt-27 display-flex">
                                                        <asp:TextBox ID="ApplyAllTextBox" runat="server" ClientIDMode="Static" MaxLength="100" style="margin-top:10px"
                                                            SkinID="CustomWidthTextBox"></asp:TextBox>
                                                        &nbsp;&nbsp;&nbsp;
                                                        <asp:Button ID="ApplyAllButton" runat="server" CssClass="btn btn-apply fas" OnClick="ApplyAllButton_Click"
                                                            Text="Apply All" SkinID="0" />
                                                    </div>
                                                </div>
                                                <div class="himsBoxContent pTop15">
                                                    <div id="Div2" runat="server" class="table-responsive">
                                                        <asp:GridView runat="server" ID="stockDataUpdateGridview" Width="100%" AutoGenerateColumns="False"
                                                            EmptyDataText="No records Found!!!" DataKeyNames="Id,code,Title,SubCategory" AllowPaging="False"
                                                            ShowHeader="True" OnRowDataBound="stockDataUpdateGridview_RowDataBound"
                                                            CssClass="table table-striped table-bordered table-hover">
                                                            <PagerSettings Visible="False" />
                                                            <Columns>
                                                                <asp:TemplateField HeaderText="Code" meta:resourcekey="TemplateFieldResource1">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="CodeLabel" runat="server" Text='<%# Eval("Code") %>' CssClass="boxEllips"
                                                                            ToolTip='<%# Bind("Code") %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle HorizontalAlign="Left" />
                                                                    <ItemStyle HorizontalAlign="Left" Width="15%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Name" meta:resourcekey="TemplateFieldResource2">
                                                                    <ItemTemplate>
                                                                        <asp:Label ID="NameLabel" runat="server" Text='<%# Eval("Title") %> ' CssClass="boxEllips"
                                                                            ToolTip='<%# Bind("Title") %>'></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle HorizontalAlign="Left" />
                                                                    <ItemStyle HorizontalAlign="Left" Width="30%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Stock Item Data" ItemStyle-Width="45%" ItemStyle-HorizontalAlign="Left"
                                                                    ItemStyle-Wrap="true">
                                                                    <ItemTemplate>
                                                                        <div class="display-flex">
                                                                            <asp:DropDownList ID="SubCategoryDropDownList" CssClass="form-control top-0" runat="server"
                                                                                Visible="false" SkinID="CustomWidthDropDownList">
                                                                            </asp:DropDownList>&nbsp;&nbsp;
                                                                            <asp:TextBox ID="SubCategoryTextBox" runat="server" SkinID="CustomWidthTextBox" Visible="false">
                                                                            </asp:TextBox>&nbsp;&nbsp;
                                                                           <%--<asp:Label class="rt-chkbox rt-chkbox-outline" runat="server" ID="Labelsub" Visible="false">
                                                                               <asp:CheckBox ID="SubCategoryCheckBox" style="opacity:initial" runat="server" Visible="false"></asp:CheckBox>
                                                                               <span></span>
                                                                           </asp:Label>--%>
                                                                            <label class="rt-chkbox rt-chkbox-outline" runat="server" ID="Labelsub" Visible="false">
                                                                                <asp:CheckBox ID="SubCategoryCheckBox" runat="server" Visible="false" />
                                                                                <span></span>
                                                                            </label>
                                                                        </div>
                                                                        <DPC:DatePickerControl ID="SubCategoryDatePicker" runat="server" DisplayDatePicker="true"
                                                                            Visible="false" />
                                                                        <acc:AutoCompleteControl ID="SubCategoryAutoCompleteControl" runat="server" MinimumPrefixLength="2"
                                                                            MaxLength="200" AutoPostBack="true" DisplayLoadingStatus="true" SkinID="CustomWidthTextBox"
                                                                            ValidateOnTextChanged="false" Visible="false" />
                                                                    </ItemTemplate>
                                                                    <HeaderStyle HorizontalAlign="Left" />
                                                                    <ItemStyle HorizontalAlign="Left" Width="40%" />
                                                                </asp:TemplateField>
                                                            </Columns>
                                                            <PagerSettings Visible="False" />
                                                        </asp:GridView>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                            </div>
                        </div>
                    </div>

                </div>

            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
    <%--<script data-main='<%=ResolveUrl("~/JavaScript/rjs/stock-inwardrequest")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>--%>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/Stock-Item-Data-Update")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>
