<%@ page language="C#" autoeventwireup="true" inherits="Pages_MaterialManagement_Procurement_StockInwardNew, App_Web_juwaiqy3" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" uiculture="auto" meta:resourcekey="PageResource1" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="~/UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager"
    TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteControl.ascx" TagName="AutoCompleteControl"
    TagPrefix="acc" %>
<%@ Register Src="~/UserControls/DatePicker/DatePickerControl.ascx" TagName="DataPickerControl"
    TagPrefix="HIMS" %>
<%@ Register Src="~/UserControls/MaterialManagement/Procurement/BatchUpdation.ascx"
    TagPrefix="BUC" TagName="BatchUserControl" %>
<%@ Register Src="~/UserControls/Common/CommonSearch/CommonSearch.ascx" TagName="CommonSearchUserControl"
    TagPrefix="Common" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl"
    TagPrefix="ScreenGroup" %>
<%@ Register Src="~/UserControls/Common/CommonSearch/AlphabetSearchCommonControl.ascx" TagName="AlphabetSearchCommonControl"
    TagPrefix="ACS" %>
<%@ Register Src="~/UserControls/Common/Stock/StockDetailBoxControl.ascx" TagName="StockControl" TagPrefix="Stock" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <%--<link href="../../../App_Themes/responsiv-popup.css" rel="stylesheet" />
    <div id="dvTestLoadingmsg" class="hls-wrap">
        <div class="hls-container">
            <div class="hls-content">
                <div class="dsh-syndicate white-popup" style="display: inline-block; width: 119%; height: 150px">
                    <div class="shippingcard" style="text-align: center; vertical-align: middle; width: 100%;">
                        <span id="spn1msg">Loading Details</span><br>
                        <span style="line-height: 2;" id="spn2msg"><b>Please Wait ...</b></span><br>
                        <span id="spnloadingimgOPD">
                            <img src="../../../Images/Loading1.gif" /></span>
                    </div>
                </div>
            </div>
        </div>
    </div>--%>
    <asp:UpdatePanel ID="StockInwardUpdatePanel" runat="server">
        <ContentTemplate>
            <Common:CommonSearchUserControl ID="CommonSearchControl" runat="server" Visible="false" />
            <ACS:AlphabetSearchCommonControl ID="AlphabetCommonSearch" runat="server" Visible="false" />
            <div id="divContentPage" class="divcontentpagemargin">
                <!-- ContentPlaceHolder Box Starts -->

                <div class="dashBoardLeftCont" valign="top">
                    <div class="himssuHeader3WireBox">
                        <%--  <div class="himsBoxHeader">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle">
                                            <div class="headerText">
                                            <asp:Label runat="server" ID="ScreenGroupNameLabel"></asp:Label>    
                                            </div>
                                        </div>
                                    </div>--%>
                        <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">
                    <Stock:StockControl ID="StockUserControl" runat="server" Visible="true" />
                    <!-- Sub Container Box Start -->
                    <div class="card card-box">
                        <asp:Panel ID="Panel1" runat="server" meta:resourcekey="Panel1Resource1" Visible="true">
                            <div class="himsBoxHeader card-head">
                                <div class="leftdiv">
                                </div>
                                <div class="himsBoxTitle">
                                    <div class="headerText" id="codeHeader">
                                        <header>
                                            <i class="fas fa-search"></i>
                                            Stock Inward Search
                                        </header>
                                    </div>
                                    <div class="pull-right mt-27">
                                        <asp:Button ID="SearchButton" runat="server" SkinID="0" CssClass="btn btn-search fas" Text="&#xf002; Search" OnClick="SearchButton_Click" />
                                    </div>
                                </div>
                            </div>
                            <div class="himsBoxContent card-body">
                                <div class="contentHolder">
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="InwardNoLabel" runat="server" Text="Inward No"
                                                meta:resourcekey="InwardNoLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft display-flex">
                                            <acc:AutoCompleteControl ID="InwardNoTextBox" runat="server" MinimumPrefixLength="2"
                                                Width="150px" ContextKey="Procurement.StockInwardNumber"
                                                AutoPostBack="true" DisplayLoadingStatus="true"
                                                FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="false" />
                                            <asp:ImageButton ID="InwardNoSearchImageButton" ToolTip="Inward No. Search" SkinID="FindImage"
                                                OnClick="InwardNoSearchImageButton_Click" runat="server"
                                                meta:resourcekey="InwardNoSearchImageButtonResource1" />
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="InwardDateLabel" runat="server" Text="Inward Date"
                                                meta:resourcekey="InwardDateLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox SkinID="DisabledTextbox" ReadOnly="True" ID="InwarddDateLabel"
                                                runat="server" meta:resourcekey="InwarddDateLabelResource1"></asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="InwarddByLabel" runat="server" Text="Inward By"
                                                meta:resourcekey="InwarddByLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox ID="InwarddByTextBox" SkinID="CustomWidthTextBox" runat="server"
                                                MaxLength="100" onmouseleave="showHideTooltip()"
                                                onmouseenter="showHideTooltip()" meta:resourcekey="InwarddByTextBoxResource1"></asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="cBoth">
                                    </div>
                                    <div class="outerBox pTop5 col-md-3" runat="server">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="RequestNoLabel" runat="server" Text="Req. No"
                                                meta:resourcekey="RequestNoLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft display-flex">
                                            <acc:AutoCompleteControl ID="RequestNoTextBox" runat="server" MinimumPrefixLength="2"
                                                Width="150px" ContextKey="Procurement.StockInwardRequestNumber" AutoPostBack="true"
                                                DisplayLoadingStatus="true" FirstRowSelected="false" MaxLength="20"
                                                ValidateOnTextChanged="false" />
                                            <asp:ImageButton ID="RequestNoSearchImageButton" ToolTip="Request No. Search" SkinID="FindImage"
                                                OnClick="RequestNoSearchImageButton_Click" runat="server"
                                                meta:resourcekey="RequestNoSearchImageButtonResource1" />
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3" runat="server">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="RequestDateLabel" runat="server" Text="Req. Date"
                                                meta:resourcekey="RequestDateLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox SkinID="DisabledTextbox" ReadOnly="True" ID="RequestedDateDisplayLabel"
                                                runat="server" meta:resourcekey="RequestedDateDisplayLabelResource1"></asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="cBoth">
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="VendorLabel" runat="server" Text="Vendor Code" meta:resourcekey="InwardNoLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft display-flex">
                                            <acc:AutoCompleteControl ID="VendorCodeAutoCompleteControl" runat="server" MinimumPrefixLength="2"
                                                Width="150px" ContextKey="Procurement.Code" AutoPostBack="true"
                                                DisplayLoadingStatus="true" FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="false" />
                                            <asp:ImageButton ID="Ven_ImageButton" ToolTip="Vendor Code" SkinID="FindImage"
                                                OnClick="Ven_ImageButton_Click" runat="server" meta:resourcekey="InwardNoSearchImageButtonResource1" />
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="VendorNameLabel" runat="server" Text="Vendor Name" meta:resourcekey="InwardNoLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft">
                                            <asp:TextBox ID="VendorTextBox" runat="server" Enabled="false"></asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3" runat="server" visible="false">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="FromLocationLabel" SkinID="mandatoryLabel" runat="server"
                                                Text="To SubLocation" meta:resourcekey="FromLocationLabelResource1"></asp:Label>
                                        </div>
                                        <div class="fLeft">
                                            <asp:DropDownList ID="ToStoreLocationDropDownList" runat="server" CssClass="form-control" AutoPostBack="True"
                                                SkinID="CustomWidthDropDownList"
                                                onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                meta:resourcekey="ToStoreLocationDropDownListResource1">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="cBoth">
                                    </div>

                                </div>
                            </div>
                            <!-- Sub Container Box Ends -->
                            <div class="spacer">
                                <asp:Image ID="Image2" runat="server" ImageUrl="~/Images/spacer.gif"
                                    meta:resourcekey="Image2Resource1" />
                            </div>
                            <!-- Sub Container Box Start -->
                            <div class="himssuHeader1WireBox">
                                <div class="himsBoxHeader divcontentpagemargin card-head inner">
                                    <div class="leftdiv">
                                    </div>
                                    <div class="himsBoxTitle">
                                        <div class="headerText">
                                            <header>
                                                Stock Inward Details Add
                                            </header>
                                        </div>
                                    </div>
                                </div>
                                <div class="himsBoxContent card-body">
                                    <div class="contentHolder">
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="ItemCodeLabel" SkinID="mandatoryLabel" runat="server"
                                                    Text="Item Code" meta:resourcekey="ItemCodeLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft display-flex">
                                                <acc:AutoCompleteControl ID="StockItemCodeTextBox" runat="server" MinimumPrefixLength="2"
                                                    IsCacheEnabled="false" Width="100px" ContextKey="Common.ItemTitleAll"
                                                    AutoPostBack="true" DisplayLoadingStatus="true"
                                                    FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="false" />
                                                <asp:ImageButton ID="ItemCodeSearchButton" ToolTip="Item Code Search" SkinID="FindImage"
                                                    OnClick="ItemCodeSearchButton_Click" runat="server"
                                                    meta:resourcekey="ItemCodeSearchButtonResource1" />
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="NameLabel" runat="server" Text="Item Name"
                                                    meta:resourcekey="NameLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5 display-flex">
                                                <acc:AutoCompleteControl ID="StockItemNameTextBox" runat="server" MinimumPrefixLength="2"
                                                    IsCacheEnabled="false" Width="150px"
                                                    ContextKey="InventoryPlanning.ItemTitleAll" AutoPostBack="true"
                                                    DisplayLoadingStatus="true" FirstRowSelected="false" MaxLength="300"
                                                    ValidateOnTextChanged="false" />
                                                <asp:ImageButton ID="ItemNameSearchButton" ToolTip="Item Name Search" SkinID="FindImage"
                                                    OnClick="ItemNameSearchButton_Click" runat="server"
                                                    meta:resourcekey="ItemNameSearchButtonResource1" />
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="RequestedQtyLabel" runat="server" Text="Requested Qty" Visible="false"
                                                    meta:resourcekey="RequestedQtyLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5">
                                                <asp:TextBox ID="RequestedQtyTextBox" runat="server" MaxLength="13" onblur="javascript:return fnValidateDecimal(this,10,2)"
                                                    onKeypress="javascript:return MaskDecimal(event,10,2)" onmouseleave="showHideTooltip()"
                                                    onmouseenter="showHideTooltip()" Style="text-align: right;" Visible="false"
                                                    meta:resourcekey="RequestedQtyTextBoxResource1"></asp:TextBox>
                                            </div>
                                        </div>
                                        <div class="cBoth">
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="InwardQtyLabel" SkinID="mandatoryLabel" runat="server"
                                                    Text="Inward Qty" meta:resourcekey="InwardQtyLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft">
                                                <asp:TextBox ID="InwardQtyTextBox" runat="server" MaxLength="13" onblur="javascript:return fnValidateDecimal(this,10,2)"
                                                    onKeypress="javascript:return MaskDecimal(event,10,2)" onmouseleave="showHideTooltip()"
                                                    onmouseenter="showHideTooltip()" Style="text-align: right;"
                                                    meta:resourcekey="InwardQtyTextBoxResource1"></asp:TextBox>
                                                <asp:ImageButton ID="InwardQtyAddImageButton" ToolTip="Add Batch" ImageUrl="~/Images/icons/icon_visit.png"
                                                    OnClick="InwardQtyAddImageButton_Click" runat="server" Visible="false"
                                                    CssClass="CursorHand" meta:resourcekey="InwardQtyAddImageButtonResource1" />
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="Label1" SkinID="mandatoryLabel" runat="server"
                                                    Text="Inward Value" meta:resourcekey="InwardQtyLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft">
                                                <asp:TextBox ID="InwardValueTextBox" runat="server" MaxLength="23" onblur="javascript:return fnValidateDecimal(this,16,6)"
                                                    onKeypress="javascript:return MaskDecimal(event,16,6)" onmouseleave="showHideTooltip()"
                                                    onmouseenter="showHideTooltip()" Style="text-align: right;"></asp:TextBox>
                                            </div>
                                        </div>
                                        <div class="cBoth">
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="BatchLabel" SkinID="mandatoryLabel" runat="server" Text="Batch" Visible="false"
                                                    meta:resourcekey="InwardQtyLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft">
                                                <asp:TextBox ID="BatchTextBox" runat="server" MaxLength="23" Visible="false"></asp:TextBox>
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="ExpiryLabel" SkinID="mandatoryLabel" runat="server" Text="Expiry date" Visible="false"
                                                    meta:resourcekey="InwardQtyLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft">
                                                <HIMS:DataPickerControl ID="ExpiryDateDatePickerControl" runat="server" DisplayDatePicker="true" Visible="false"
                                                    class="datepick" style="display: initial !important; width: 80% !important;" />
                                            </div>
                                        </div>
                                        <div class="cBoth">
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="RemarksLabel" runat="server" Text="Remarks" Visible="false"
                                                    meta:resourcekey="RemarksLabelResource1"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5">
                                                <asp:TextBox ID="RemarksTextBox" runat="server" Style="border-color: #7F9DB9; border-width: 1px; border-style: Solid; font-size: 11px; height: 40px; width: 390px"
                                                    TextMode="MultiLine"
                                                    MaxLength="300" onKeypress="javascript:return fnMaxLength(this, 300)" onblur="javascript:return CheckLength(this, 300)"
                                                    onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" Visible="false"
                                                    meta:resourcekey="RemarksTextBoxResource1"></asp:TextBox>
                                            </div>
                                        </div>
                                        <div class="cBoth">
                                        </div>

                                        <div class="controlLabelWidth pTop5" style="padding-left: 10px">
                                            <a href="javascript:;" onclick="OpenFileUpload();">
                                                <img src='<%= ResolveUrl("~/Images/browse.png") %>' /></a>

                                            <asp:FileUpload ID="flUpload" runat="server" onChange="readURL(this);" ClientIDMode="Static" Style="display: none;" />
                                            <asp:Label ID="Label2" runat="server" Text="" Style="padding-left: 10px; font-size: medium;"></asp:Label>
                                        </div>
                                        <br />
                                        <div style="padding-left: 10px">
                                            <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/ContentTemplates/Import/Stock_Inward.xls" Text="&#xf101; Stock Inward Template" CssClass="pointer fas"></asp:HyperLink>
                                        </div>
                                        <div class=" alignCenter pTop5">
                                            <asp:Button ID="AddToListButton" class="btn btn-add fas" Text="&#xf067; Add" runat="server" SkinID="0"
                                                OnClick="AddToListButton_Click"
                                                meta:resourcekey="AddToListButtonResource1" />
                                            <asp:Button ID="ClearDetailButton" runat="server" Text="&#xf12d; Clear" CssClass="btn btn-clear fas" SkinID="0"
                                                OnClick="ClearDetail_Click" meta:resourcekey="ClearButtonResource1" />
                                            <asp:Button ID="ImportButton" runat="server" SkinID="0" Text="&#xf019; Import Detail" CssClass="btn btn-examcommon fas"
                                                OnClick="ImportButton_Click" meta:resourcekey="AddToListButtonResource1" />
                                        </div>

                                        <div class="cBoth">
                                        </div>

                                        <div id="StockInwardDetailDiv" class="himssuHeader6WireBox col-md-12" runat="server">

                                            <div class="himsBoxHeader" id="PatientRelationDiv" runat="server">
                                                <div class="leftdiv">
                                                </div>
                                                <div class="himsBoxTitle" style="width: 99%">
                                                    <div class="headerText">
                                                        <div class="fLeft">
                                                            <asp:Label ID="GridViewLabel" Text="" runat="server" Font-Bold="True"
                                                                meta:resourcekey="GridViewLabelResource1" />
                                                        </div>
                                                    </div>
                                                    <div align="right" class="fRight" style="margin-top: 0px;" runat="server" visible="false">
                                                        <uc1:GridViewPager ID="StockInwardDetailGridView_GridViewPager" runat="server" OnFirstRecordClick="StockInwardDetailGridView_GridViewPager_FirstRecordClick"
                                                            OnLastRecordClick="StockInwardDetailGridView_GridViewPager_LastRecordClick" OnNextRecordClick="StockInwardDetailGridView_GridViewPager_NextRecordClick"
                                                            OnPrevRecordClick="StockInwardDetailGridView_GridViewPager_PrevRecordClick" OnTextBoxValueChange="StockInwardDetailGridView_GridViewPager_TextBoxValueChange"
                                                            ParentGridView="StockInwardDetailGridView" />
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="himsBoxContent">
                                                <%--<div id="DivHeader" style="vertical-align: top; width: 100%;">
                                <asp:Table ID="InwardGridViewTable" runat="server" CellPadding="0" CellSpacing="0"
                                    BackColor="#E8E8E8" ForeColor="Black" Width="100%" GridLines="Both" CssClass="GridViewTableRow"
                                    meta:resourcekey="InwardGridViewTableResource1">
                                </asp:Table>
                            </div>--%>
                                                <div class="himsBoxContentMsg" id="GridMessageDiv" runat="server"
                                                    visible="False">
                                                </div>
                                                <%--<div id="DivData" class="Container" style="vertical-align: top; height: 100px; width: 99.6%;">--%>
                                                <div id="Div3" runat="server" class="table-responsive">
                                                    <asp:GridView ID="StockInwardDetailGridView" runat="server" Width="100%" AutoGenerateColumns="False"
                                                        OnRowDataBound="StockInwardDetailGridView_RowDataBound" OnPageIndexChanging="StockInwardDetailGridView_PageIndexChanging"
                                                        OnDataBinding="StockInwardDetailGridView_DataBinding"
                                                        ShowHeader="True" DataKeyNames="StockItemId,IsBatchWiseTracking,InwardQuantity,Id"
                                                        EmptyDataText="No Records Found"
                                                        meta:resourcekey="StockInwardDetailGridViewResource1"
                                                        CssClass="table table-striped table-bordered table-hover">
                                                        <Columns>
                                                            <asp:TemplateField HeaderText="Item Code" meta:resourcekey="TemplateFieldResource1" HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:Label ID="StockItemCodeLinkButton" runat="server" Text='<%# Bind("StockItemCode") %>'></asp:Label>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Left" Width="15%" />
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Item Name" HeaderStyle-HorizontalAlign="Left"
                                                                meta:resourcekey="TemplateFieldResource2">
                                                                <ItemTemplate>
                                                                    <asp:Label CssClass="boxEllips" ToolTip='<%# Bind("StockItemName") %>' ID="NameLabel"
                                                                        runat="server" Text='<%# Bind("StockItemName") %>' Width="200px"></asp:Label>
                                                                </ItemTemplate>
                                                                <ItemStyle Width="20%" />
                                                            </asp:TemplateField>
                                                            <asp:BoundField DataField="UOM" HeaderText="UOM" HeaderStyle-HorizontalAlign="Left"
                                                                meta:resourcekey="BoundFieldResource1">
                                                                <ItemStyle Width="10%" />
                                                            </asp:BoundField>
                                                            <asp:TemplateField HeaderText="Batch">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="BatchGridTextbox"
                                                                        runat="server" Text='<%#Eval("Number")%>' Width="100px"></asp:TextBox>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Right" Width="8%" />
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Expiry Date">
                                                                <ItemTemplate>
                                                                    <%--   <DPC:DatePickerControl ID="ExpiryDateGridTextbox" runat="server" DisplayDatePicker="true"
                                                            class="datepick"  style="display: initial !important; width: 80% !important;" Text='<%#Eval("ExpiryDate","{0:dd/MM/yyyy}")%>' />--%>
                                                                    <asp:TextBox ID="ExpiryDateGridTextbox"
                                                                        runat="server" Text='<%#Eval("ExpiryDate","{0:dd/MM/yyyy}")%>' Width="100px" OnTextChanged="ExpiryDateGridTextbox_TextChanged"></asp:TextBox>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Right" Width="14%" />
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Requested Qty">
                                                                <ItemTemplate>
                                                                    <asp:Label ID="RequestedLabel" runat="server" Text='<%#Eval("RequestedQuantity") %>'></asp:Label>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Right" Width="8%" />
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Inward Qty" HeaderStyle-HorizontalAlign="Right"
                                                                meta:resourcekey="TemplateFieldResource3">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="InwardQuantityTextBoxGrid"
                                                                        runat="server"
                                                                        Text='<%# String.Format("{0:F}", Eval("InwardQuantity")) %>' Width="100px"
                                                                        MaxLength="13" onblur="javascript:return fnValidateDecimal(this,10,2)" onKeypress="javascript:return MaskDecimal(event,10,2)"
                                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" Style="text-align: right;"></asp:TextBox>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Right" Width="15%" />
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Inward Value" HeaderStyle-HorizontalAlign="Right"
                                                                meta:resourcekey="TemplateFieldResource3">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="InwardUnitPriceTextBoxGrid"
                                                                        runat="server"
                                                                        Text='<%# String.Format("{0:F}", Eval("InwardValue")) %>' Width="100px"
                                                                        MaxLength="13" onblur="javascript:return fnValidateDecimal(this,10,2)" onKeypress="javascript:return MaskDecimal(event,10,2)"
                                                                        onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" Style="text-align: right;"></asp:TextBox>
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Right" Width="15%" />
                                                            </asp:TemplateField>

                                                            <asp:TemplateField HeaderText="Delete"
                                                                meta:resourcekey="TemplateFieldResource4">
                                                                <ItemTemplate>
                                                                    <asp:ImageButton ID="DeleteImageButton" runat="server" CommandName="Delete" CommandArgument='<%# Eval("StockItemId") %>'
                                                                        OnClick="DeleteImageButton_Click" SkinID="DeleteImage" ToolTip="Delete"
                                                                        Enabled='<%# GetDeleteImageGridBehavior(Eval("Id")) %>'
                                                                        meta:resourcekey="DeleteImageButtonResource1" />
                                                                </ItemTemplate>
                                                                <HeaderStyle HorizontalAlign="Center" />
                                                                <ItemStyle HorizontalAlign="Center" Width="5%" />
                                                            </asp:TemplateField>
                                                        </Columns>
                                                        <PagerSettings Visible="False" />
                                                    </asp:GridView>
                                                </div>
                                            </div>
                                        </div>

                                    </div>
                                </div>
                                <!--Grid starts-->

                                <!--Grid Ends-->
                                <BUC:BatchUserControl ID="BatchUpdationCtrl" runat="server" />
                            </div>
                        </asp:Panel>

                        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                            <ContentTemplate>
                                <asp:Panel ID="Panel2" runat="server" meta:resourcekey="Panel1Resource1" Visible="false">
                                    <div class="himssuHeader1WireBox">
                                        <div class="himsBoxHeader card-head">
                                            <div class="leftdiv">
                                            </div>
                                            <div class="himsBoxTitle">
                                                <div class="headerText">
                                                    <header>
                                                        <i class="fal fa-search"></i>
                                                        Search
                                                    </header>
                                                </div>
                                                <div class="pull-right mt-27">
                                                    <asp:Button ID="Button" runat="server" SkinID="0" CssClass="btn btn-back fas" Text="&#xf30a; Back" OnClick="BacButton_Click" />
                                                </div>
                                            </div>
                                        </div>
                                        <div class="himsBoxContent card-body">
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="Label24" runat="server" Text="Inward No" meta:resourcekey="InwarddByLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:TextBox ID="ReqNoCompleteControl" runat="server" Text="*"></asp:TextBox>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <asp:Label ID="FromDateLable" runat="server" Text="From Date"></asp:Label>
                                                <HIMS:DataPickerControl DisplayDatePicker="true" Width="100px" ID="FromDatePickerControl"
                                                    Visible="True" runat="Server"></HIMS:DataPickerControl>
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="ToDateLabel" runat="server" Text="To Date"></asp:Label>
                                                </div>
                                                <HIMS:DataPickerControl DisplayDatePicker="true" Width="100px" ID="ToDateDatePickerControl"
                                                    Visible="True" runat="Server"></HIMS:DataPickerControl>
                                            </div>
                                            <div class="cBoth">
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="VendorCodeLabel" runat="server" Text="Vendor Code" meta:resourcekey="InwardNoLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft display-flex">
                                                    <acc:AutoCompleteControl ID="VendorAutoCompleteControl" runat="server" MinimumPrefixLength="2"
                                                        Width="150px" ContextKey="Procurement.Code" AutoPostBack="true"
                                                        DisplayLoadingStatus="true" FirstRowSelected="false" MaxLength="20" ValidateOnTextChanged="false" />
                                                    <asp:ImageButton ID="VendorImageButton" ToolTip="Vendor Code" SkinID="FindImage"
                                                        OnClick="VendorImageButton_Click" runat="server" meta:resourcekey="InwardNoSearchImageButtonResource1" />
                                                </div>
                                            </div>

                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="VendorsearchLabel" runat="server" Text="Vendor Name" meta:resourcekey="InwardNoLabelResource1"></asp:Label>
                                                </div>
                                                <div class="fLeft">
                                                    <asp:TextBox ID="VendorsearchTextBox" runat="server" Enabled="false"></asp:TextBox>
                                                </div>
                                            </div>
                                            <div class="spacer">
                                                <img src="../../../Images/spacer.gif" />
                                            </div>

                                            <div class="spacer">
                                                <img src="../../../Images/spacer.gif" />
                                            </div>
                                            <div class="alignCenter pTop5 col-md-12">
                                                <asp:Button ID="Search_Button" Text="&#xf002; Search" runat="Server" OnClick="Search_Button_Click" SkinID="0" CssClass="fas btn btn-search" />
                                                <asp:Button ID="ResetButton" runat="server" Text="&#xf12d; Clear" CssClass="btn btn-clear fas" SkinID="0" OnClick="ResetButton_Click" />


                                            </div>
                                            <div class="spacer">
                                                <img src="../../../Images/spacer.gif" />
                                            </div>



                                            <div class="himsBoxContent col-md-12">

                                                <div class="himsBoxHeader card-head inner">
                                                    <div class="headerText">
                                                        <header>
                                                            <asp:Label ID="ListLabel" runat="server" Text="List" CssClass="fLeft"></asp:Label>
                                                        </header>
                                                    </div>
                                                </div>

                                                <div align="right" class="fRight" style="margin-top: 0px;" runat="server" visible="false">
                                                    <uc1:GridViewPager ID="StockIssueGridView_GridViewPager" runat="server" OnFirstRecordClick="StockIssueGridView_GridViewPager_FirstRecordClick"
                                                        OnLastRecordClick="StockIssueGridView_GridViewPager_LastRecordClick" OnNextRecordClick="StockIssueGridView_GridViewPager_NextRecordClick"
                                                        OnPrevRecordClick="StockIssueGridView_GridViewPager_PrevRecordClick"
                                                        ParentGridView="StockIssueGridView" Visible="false" />
                                                </div>
                                                <div class="himsBoxContent">
                                                    <div id="Div1" runat="server" class="table-responsive">
                                                        <asp:GridView ID="StockIssueGridView" runat="server" CssClass="table table-striped table-bordered table-hover"
                                                            AutoGenerateColumns="False" ShowHeader="true" DataKeyNames="Id,Number,InwardByName,InwardDate,RequestNumber,RequestedDate"
                                                            OnRowDataBound="StockIssueGridView_RowDataBound" EmptyDataText="No Records Found">
                                                            <Columns>
                                                                <asp:TemplateField>
                                                                    <ItemStyle Width="1%" />
                                                                    <ItemTemplate>
                                                                        <asp:LinkButton ID="EditLinkButton" runat="server" Enabled="true" OnClick="LinkButton_Click"
                                                                            Text="Select"></asp:LinkButton>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Inward Number" meta:resourcekey="TemplateFieldResource1">
                                                                    <ItemTemplate>
                                                                        <asp:Label Text='<%#Eval("Number") %>' ID="ItemCodeLabel"
                                                                            runat="server" meta:resourcekey="ItemCodeLabelResource2"></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle Width="15%" />
                                                                    <ItemStyle Width="15%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Inward Date" meta:resourcekey="TemplateFieldResource1">
                                                                    <ItemTemplate>
                                                                        <asp:Label Text='<%#Eval("InwardDate","{0:dd-MM-yyyy}") %>' ID="InwardDateLabel"
                                                                            runat="server" meta:resourcekey="ItemCodeLabelResource2"></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle Width="15%" />
                                                                    <ItemStyle Width="15%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Request Number" meta:resourcekey="TemplateFieldResource1">
                                                                    <ItemTemplate>
                                                                        <asp:Label Text='<%#Eval("RequestNumber") %>' ID="ReqNumberLabel"
                                                                            runat="server" meta:resourcekey="ItemCodeLabelResource2"></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle Width="15%" />
                                                                    <ItemStyle Width="15%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Requested Date" meta:resourcekey="TemplateFieldResource2" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:Label Text='<%#Eval("RequestedDate","{0:dd-MM-yyyy}") %>' ID="RequestedDateLabel"
                                                                            runat="server" meta:resourcekey="ItemNameLabelResource2"></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle Width="15%" />
                                                                    <ItemStyle Width="15%" />
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Inward By" meta:resourcekey="TemplateFieldResource2" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:Label Text='<%#Eval("InwardByName") %>' ID="ToStoreLocationCodeLabel"
                                                                            runat="server" meta:resourcekey="ItemNameLabelResource2"></asp:Label>
                                                                    </ItemTemplate>
                                                                    <HeaderStyle Width="15%" />
                                                                    <ItemStyle Width="15%" />
                                                                </asp:TemplateField>

                                                            </Columns>
                                                            <PagerSettings Visible="False" />
                                                        </asp:GridView>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                </asp:Panel>
                                <Common:CommonSearchUserControl ID="CommonSearchUserControl1" runat="server" Visible="false" />
                                <ACS:AlphabetSearchCommonControl ID="AlphabetSearchCommonControl1" runat="server" Visible="false" />
                            </ContentTemplate>
                        </asp:UpdatePanel>
                    </div>
                </div>

            </div>
            <div class="spacer">
                <img src="../../../Images/spacer.gif" />
            </div>

        </ContentTemplate>
    </asp:UpdatePanel>
    <%--<script data-main="../../../JavaScript/rjs/stock-inward" src="../../../JavaScript/rjs/require.js"></script>--%>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/stock-inward")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>    
</asp:Content>
