<%@ page language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_Hostel_DepositAddBulk, App_Web_kux14qts" enableEventValidation="false" viewStateEncryptionMode="Never" %>


<%@ Register Src="~/UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager"
    TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl"
    TagPrefix="ScreenGroup" %>
<%@ Register Src="~/UserControls/DatePicker/DatePickerControl.ascx" TagName="DatePickerControl"
    TagPrefix="Date" %>
<%@ Register Src="~/UserControls/Common/Hostel/HostelDetailBoxControl.ascx" TagName="HostelControl"
    TagPrefix="Hostel" %>
<%@ Register Src="~/UserControls/Common/CommonSearch/CommonSearch.ascx" TagName="CommonSearchUserControl"
    TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteControl.ascx" TagName="AutoCompleteControl"
    TagPrefix="acc" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="FeeHeadMasterUpdatePanel" runat="server" UpdateMode="Always">
        <ContentTemplate>
            <uc1:CommonSearchUserControl ID="CommonSearchControl" Visible="false" runat="server" />
            <div id="divContentPage" class="divcontentpagemargin">
                <!-- ContentPlaceHolder Box Starts -->

                <div class="dashBoardLeftCont">
                    <div class="himssuHeader3WireBox">
                        <table>
                            <tr>
                                <td>
                                    <div class="himsBoxContent">
                                        <div class="leftUlMenu">
                                            <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="175"
                                                Visible="true" runat="server" />
                                        </div>
                                    </div>
                                </td>
                            </tr>
                        </table>
                    </div>
                </div>
                <div class="whiteboxpaddingleft row">
                    <Hostel:HostelControl ID="HostelUserControl" runat="server" Visible="true" />
                    <div class="himssuHeader5WireBox card card-box">
                        <div class="himsBoxHeader card-head">
                            <asp:Panel ID="Panel1" runat="server">
                                <div class="leftdiv">
                                </div>
                                <div class="himsBoxTitle">
                                    <div class="headerText">
                                        <header>
                                            <i class="fas fa-search"></i>
                                            <asp:Label ID="Label3" runat="server" Text="Search"></asp:Label>
                                        </header>
                                    </div>
                                    <div class="fRight">
                                    </div>
                                </div>
                            </asp:Panel>
                        </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="SearchOrganizationLabel" Text="Organization" runat="server"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList ID="SearchOrganizationDropDownList" runat="server" onmouseleave="showHideTooltip()"
                                                onmouseenter="showHideTooltip()" SkinID="CustomWidthDropDownList"
                                                CssClass="form-control">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="RoomCategoryLabel" Text="Room Category" runat="server"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList ID="RoomCategoryDropDownList" runat="server" onmouseleave="showHideTooltip()"
                                                onmouseenter="showHideTooltip()"
                                                SkinID="CustomWidthDropDownList" CssClass="form-control">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="BuildingLabel" runat="server" Text="Building"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList runat="server" ID="BuildingDropDownList" SkinID="CustomWidthDropDownList"
                                                CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()">
                                            </asp:DropDownList>
                                        </div>
                                    </div>

                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="RoomLabe" runat="server" Text="Room"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList runat="server" ID="RoomDropDownList" SkinID="CustomWidthDropDownList"
                                                CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="SearchIdNoLabel" runat="server"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox ID="SearchIdNoTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                SkinID="CustomWidthTextBox" runat="server"> </asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="SuidLabel" runat="server" Text="SUID"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox ID="SuidTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                SkinID="CustomWidthTextBox" runat="server">
                                            </asp:TextBox>
                                        </div>
                                    </div>

                                    <div class="alignCenter pTop5 col-md-12">
                                        <asp:Button ID="SearchButton" Text="&#xf002; Search" runat="Server" OnClick="SearchButton_Click"
                                            SkinID="0" class="btn-search btn fas" />
                                        <asp:Button ID="ResetButton" runat="server" Text="&#xf0e2; Reset" OnClick="ResetButton_Click"
                                            SkinID="0" class="btn-reset btn fas" />
                                    </div>

                                    <div class="outerBox pTop10 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="SearchDepositHeadLabel" Text="Deposit Head" runat="server" CssClass="mandatory"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList ID="SearchDepositHeadIdDropDownList" runat="server" onmouseleave="showHideTooltip()"
                                                onmouseenter="showHideTooltip()" SkinID="CustomWidthDropDownList"
                                                CssClass="form-control">
                                            </asp:DropDownList>
                                        </div>
                                    </div>

                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="PayTypeLabel" runat="server" Text="Pay Type" SkinID="MandatoryLabel"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:DropDownList runat="server" ID="PayTypeDropDownList" SkinID="CustomWidthDropDownList"
                                                CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                AutoPostBack="true" OnSelectedIndexChanged="PayTypeDropDownList_SelectedIndexChanged">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="ChequeNoLabel" runat="server" Text="Cheque No"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <asp:TextBox ID="ChequeNoTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                SkinID="CustomWidthTextBox" runat="server" MaxLength="20"> </asp:TextBox>
                                        </div>
                                    </div>
                                    <div class="outerBox pTop5 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="BankLabel" runat="server" Text="Bank Name"></asp:Label>
                                        </div>
                                        <div class="fLeft pRight5 display-flex">
                                            <acc:AutoCompleteControl ID="BankTextBox" runat="server" MinimumPrefixLength="2"
                                                TabIndex="1" Width="150px" ValidateOnTextChanged="false" ContextKey="sFinanceCommon.Bank"
                                                DisplayLoadingStatus="true" FirstRowSelected="false" MaxLength="200" AutoPostBack="true" />
                                            <asp:ImageButton ID="BankSearchButton" runat="server" SkinID="FindImage" ToolTip="Bank Name Search"
                                                TabIndex="2" OnClick="BankSearchButton_OnClick" meta:resourcekey="BankSearchButtonResource1"
                                                ImageUrl="../../Images/icons/icon_find.gif" />
                                        </div>
                                    </div>

                                    <div class="outerBox pTop10 col-md-3">
                                        <div class="controlLabelWidth">
                                            <asp:Label ID="Label1" Text="Deposit Date" runat="server" CssClass="mandatory">  </asp:Label>
                                        </div>
                                        <div class="fLeft pRight5">
                                            <Date:DatePickerControl ID="AddDatePickerControl" runat="server" DisplayDatePicker="true"></Date:DatePickerControl>
                                        </div>
                                    </div>

                                    <div id="Div1" class="himssuHeader7WireBox" runat="server" visible="false">
                                        <div id="DepositAddListDetailDiv" runat="server">
                                            <div class="himsBoxHeader card-head inner">
                                                <div class="leftdiv">
                                                </div>
                                                <div class="himsBoxTitle">
                                                    <div class="pull-right col-md-5 display-flex">

                                                        <asp:DropDownList ID="ApplyDropDownList" runat="server" SkinID="CustomWidthDropDownList" CssClass="form-control">
                                                            <asp:ListItem Text="- Select -" Value="-1" Selected="True"></asp:ListItem>
                                                            <asp:ListItem Text="Amount" Value="1"></asp:ListItem>
                                                            <asp:ListItem Text="Remark" Value="2"></asp:ListItem>
                                                        </asp:DropDownList>
                                                       &nbsp;&nbsp;
                                                                <%--<asp:Label ID="LabelAm" runat="server" HeaderStyle-HorizontalAlign="right" Text="Amount"></asp:Label>--%>
                                                        <asp:TextBox ID="ApplyAmountTextBox" runat="server" HeaderStyle-HorizontalAlign="right" Width="80px"> </asp:TextBox>
                                                       &nbsp;&nbsp;  <asp:Button ID="ApplyButton" runat="server" SkinID="0" Text="Apply All" CssClass="btn btn-apply" OnClick="ApplyButton_Click" />

                                                    </div>
                                                </div>
                                            </div>
                                            <div class="himsBoxContent pTop10 col-md-12">
                                                <div id="Div5" runat="server" class="table-responsive">
                                                    <asp:GridView ID="HostelDepositAddBulkGridView" runat="server" AutoGenerateColumns="False"
                                                        AllowPaging="false" PageSize="5" SkinID="" PagerSettings-Visible="false" EmptyDataText="No Records Found !!"
                                                        DataKeyNames="StudentId,AcademicId" OnRowDataBound="DepositAddGridView_RowDataBound"
                                                        OnPageIndexChanging="DepositAddGridView_PageIndexChanging" CssClass="table table-striped table-bordered table-hover">
                                                        <Columns>
                                                            <asp:TemplateField ItemStyle-Width="3%" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true"
                                                                HeaderText="">
                                                                <HeaderTemplate>
                                                                    <label class="rt-chkbox rt-chkbox-outline">
                                                                        <asp:CheckBox ID="HeaderSelectCheckBox" runat="server" onclick="checkAllRows(this);" OnCheckedChanged="HeaderSelectCheckBox_CheckedChanged" AutoPostBack="true"></asp:CheckBox>
                                                                        <span></span>
                                                                    </label>
                                                                </HeaderTemplate>
                                                                <ItemTemplate>
                                                                    <label class="rt-chkbox rt-chkbox-outline">
                                                                        <asp:CheckBox ID="SelectCheckBox" runat="server" onClick="checkUncheckHeaderCheckBox(this);" OnCheckedChanged="SelectCheckBox_CheckedChanged" AutoPostBack="true"></asp:CheckBox>
                                                                        <span></span>
                                                                    </label>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:BoundField DataField="SUID" HeaderText="SUID" ItemStyle-Width="5%"
                                                                HeaderStyle-HorizontalAlign="Left" />
                                                            <asp:BoundField DataField="Code" HeaderText="Admission No" ItemStyle-Width="5%"
                                                                HeaderStyle-HorizontalAlign="Left" />
                                                            <asp:BoundField DataField="StudentName" HeaderText="StudentName" ItemStyle-Width="12%"
                                                                HeaderStyle-HorizontalAlign="Left" />

                                                            <asp:BoundField DataField="ClassDivisionName" HeaderText="Class" ItemStyle-Width="5%"
                                                                HeaderStyle-HorizontalAlign="Left" />
                                                            <asp:TemplateField ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true"
                                                                HeaderText="Amount">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="AmountTextBox" runat="server" HeaderStyle-HorizontalAlign="Left" onkeypress="javascript:return MaskDecimal(event,10,2)"
                                                                        onblur="javascript:return fnValidateDecimal(this,10,2)" Enabled="false" TextMode="Number"> </asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField ItemStyle-Width="10%" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true"
                                                                HeaderText="Remark">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="RemarkTextBox" runat="server" HeaderStyle-HorizontalAlign="Left" MaxLength="200" Enabled="false"></asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                        </Columns>
                                                    </asp:GridView>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </asp:Panel>
                        </div>
                    </div>

                </div>

                <%--HEDP History Ends Here--%>
            </div>
            </div>
           
        </ContentTemplate>
    </asp:UpdatePanel>
    <%--<script data-main="../../JavaScript/rjs/encrypt/room-list-encrypt" src="../../JavaScript/rjs/require.js"></script>--%>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/room-list")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
    <script type="text/javascript">
        function fnValidateDepositAdd() {
            //debugger;
            var himsValidator = [
                                new hims_ctl_val('ctl00_CP_SearchDepositHeadIdDropDownList', "Deposit Head", "T", "", "", "", 20),
                                new hims_ctl_val('<%= AddDatePickerControl.ClientID %>' + '_DateTextbox', "Add Date", "T", "", "", "", 10),
                                new hims_ctl_val("<%= PayTypeDropDownList.ClientID %>", "Pay Type", "T", "", "", "", 20)
            ];
            if (fnDoValidate(himsValidator))
                return true;
            else
                return false;
        }

        function uppercase() {
            key = window.event.keyCode;
            if ((key > 0x60) && (key < 0x7B))
                window.event.keyCode = key - 0x20;
        }
        function isNumberKey(evt) {
            var charCode = (evt.which) ? evt.which : event.keyCode
            if (charCode > 31
            && (charCode < 48 || charCode > 57))
                return false;

            return true;
        }
    </script>
</asp:Content>
