<%@ page language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_Hostel_HostelStudentGatePass, App_Web_bid2cnfm" title="Student Gate Pass" enableEventValidation="false" viewStateEncryptionMode="Never" %>

<%@ Register Src="~/UserControls/DatePicker/DatePickerControl.ascx" TagName="DatePickerControl" TagPrefix="Date" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager" TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl" TagPrefix="ScreenGroup" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteControl.ascx" TagName="AutoCompleteControl" TagPrefix="acc" %>
<%@ Register Src="~/UserControls/Common/EmployeeSearch/EmployeeSearch.ascx" TagName="EmployeeSearchControl" TagPrefix="hims" %>
<%@ Register Src="~/UserControls/Common/StudentSearch/StudentSearch.ascx" TagName="StudentSearch" TagPrefix="Std" %>
<%@ Register Assembly="TimePicker" Namespace="MKB.TimePicker" TagPrefix="timePicker" %>
<%@ Register Src="~/UserControls/Common/Hostel/HostelDetailBoxControl.ascx" TagName="HostelControl" TagPrefix="Hostel" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="ResonMasterUpdatePanel" runat="server" UpdateMode="Always">
        <ContentTemplate>
            <Std:StudentSearch ID="StudentSearch" Visible="false" runat="server" />
            <div id="divContentPage">
                <div style="width: 100%; padding: 2px; margin: 2px">
                    <table width="100%" border="0" style="vertical-align: top; margin-top: -1px; border-collapse: collapse" cellspacing="0">
                        <tr>
                            <td 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="175"
                                                            Visible="true" runat="server" />
                                                    </div>
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                </div>
                            </td>
                            <td style="vertical-align: top" width="100%" class="whiteboxpaddingleft">
                                <Hostel:HostelControl ID="HostelUserControl" runat="server" Visible="true" />
                                <div class="himssuHeader5WireBox whitebox" id="SearchDiv" runat="server" visible="true">
                                    <div class="himsBoxHeader note note1 box box-danger">
                                        <asp:Panel ID="Panel1" runat="server">
                                            <div class="leftdiv">
                                            </div>
                                            <div class="himsBoxTitle">
                                                <div class="headerText">
                                                    <asp:Label ID="Label3" runat="server" Text="Search"></asp:Label>
                                                </div>
                                                <div class="fRight" style="margin-top: -20px">
                                                    <asp:Button ID="AddNewButtonID" runat="server" OnClick="AddNewButton_Click" SkinID="0"
                                                        CssClass="AddButton" Text="Add" />
                                                </div>
                                            </div>
                                        </asp:Panel>
                                    </div>
                                    <div class="himsBoxContent">
                                        <asp:Panel ID="DetailPanel" runat="Server">
                                            <div class="contentHolder">
                                                <asp:Panel ID="SearchCriteriaPanel" runat="Server">
                                                    <div class="outerBox pTop5">
                                                        <div class="controlLabelWidth">
                                                            <asp:Label ID="StudentIdLabel" runat="server" Text="Student Id No"></asp:Label>
                                                        </div>
                                                        <div class="fLeft pRight5">
                                                            <asp:TextBox ID="StudentIdtextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                SkinID="CustomWidthTextBox" Width="150px" runat="server" MaxLength="150"> </asp:TextBox>
                                                        </div>
                                                    </div>
                                                    <div class="outerBox pTop5">
                                                        <div class="controlLabelWidth">
                                                            <asp:Label ID="SearchOutDateId" runat="server" Text="From Date"></asp:Label>
                                                        </div>
                                                        <div class="fLeft pRight5">
                                                            <Date:DatePickerControl DisplayDatePicker="true" ID="SearchOutDateDatePickerControl"
                                                                Visible="True" runat="server" />
                                                        </div>
                                                    </div>
                                                    <div class="outerBox pTop5">
                                                        <div class="controlLabelWidth">
                                                            <asp:Label ID="SearchInDateLabel" runat="server" Text="To Date"></asp:Label>
                                                        </div>
                                                        <div class="fLeft pRight5">
                                                            <Date:DatePickerControl DisplayDatePicker="true" ID="SearchInDatePickerControl" Visible="True"
                                                                runat="server" />
                                                        </div>
                                                    </div>
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="OutLabel" runat="server" Text="Out Time" Visible="False"></asp:Label>
                                                    </div>
                                                    <br />
                                                    <div>
                                                        <timePicker:TimeSelector ID="TimeSelector2" runat="server" DisplaySeconds="False"
                                                            SelectedTimeFormat="Twelve" AmPm="AM" Date="" Hour="0" Minute="0"
                                                            Second="0" meta:resourcekey="ActivityStartTimeSelectorResource1" ReadOnly="true" />
                                                    </div>
                                                    <div class="cBoth">
                                                    </div>
                                                    <div class="alignCenter pTop5">
                                                        <asp:Button ID="SearchButton" runat="Server" CssClass="btn-primary-search" OnClick="SearchButton_Click"
                                                            SkinID="0" Text="Search" />
                                                        <asp:Button ID="ResetButton" runat="server" OnClick="ResetButton_Click" Text="Reset" />
                                                        <asp:HiddenField ID="studentHiddenField" runat="server" />
                                                    </div>
                                                    <div class="cBoth">
                                                    </div>
                                                </asp:Panel>
                                                <div id="Div1" class="himssuHeader7WireBox box-body box-solid gridviewfont" runat="server">
                                                    <div id="ReasonMasterDetailDiv" visible="false" runat="server">
                                                        <div class="spacer">
                                                            <asp:Image ID="Image3" runat="server" ImageUrl="~/Images/spacer.gif" />
                                                        </div>
                                                        <div class="himsBoxHeader">
                                                            <div class="leftdiv">
                                                            </div>
                                                            <div class="himsBoxTitle">
                                                                <div class="headerText">
                                                                    <asp:Label ID="Label1" runat="server" Text=""></asp:Label>
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div class="himsBoxContent">
                                                            <asp:UpdatePanel ID="MenuPlanDetailUpdatePanel" runat="server" UpdateMode="Always">
                                                                <ContentTemplate>
                                                                    <div id="Div5" runat="server" visible="false">
                                                                        <asp:GridView ID="HostelStudentGatePassGridView" runat="server" Width="100%" AutoGenerateColumns="False"
                                                                            OnRowDataBound="HostelStudentGatePassGridView_RowDataBound" OnPageIndexChanging="HostelStudentGatePassGridView_PageIndexChanging"
                                                                            AllowPaging="false" SkinID="" ShowHeader="True" PagerSettings-Visible="false"
                                                                            EmptyDataText="No records Found !!!" DataKeyNames="Id,StudentId"
                                                                            CssClass="table table-striped table-bordered">
                                                                            <Columns>
                                                                                <asp:TemplateField ItemStyle-Width="5%" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true">
                                                                                    <ItemTemplate>
                                                                                        <asp:LinkButton ID="EditLinkButton" runat="server" CommandName="Select" OnClick="EditLinkButton_Click"
                                                                                            Text="Select" CausesValidation="false"></asp:LinkButton>
                                                                                    </ItemTemplate>
                                                                                </asp:TemplateField>
                                                                                <asp:TemplateField HeaderText="Student Name" ItemStyle-Width="10%" SortExpression="Title"
                                                                                    HeaderStyle-HorizontalAlign="Left" ItemStyle-Wrap="true">
                                                                                    <ItemTemplate>
                                                                                        <asp:Label ID="StudentLabel" runat="server" Text='<%# Bind("StudentName") %>'></asp:Label>
                                                                                    </ItemTemplate>
                                                                                </asp:TemplateField>
                                                                                <asp:TemplateField HeaderText="Hostel Name" ItemStyle-Width="10%" SortExpression="Title"
                                                                                    HeaderStyle-HorizontalAlign="Left" ItemStyle-Wrap="true">
                                                                                    <ItemTemplate>
                                                                                        <asp:Label ID="HosteltLabel" runat="server" Text='<%# Bind("HostelName") %>'></asp:Label>
                                                                                    </ItemTemplate>
                                                                                </asp:TemplateField>
                                                                                <asp:TemplateField HeaderText="From Date" ItemStyle-Width="10%" SortExpression="Title"
                                                                                    HeaderStyle-HorizontalAlign="Left" ItemStyle-Wrap="true">
                                                                                    <ItemTemplate>
                                                                                        <asp:Label ID="OutTimeLabel" runat="server" Text='<%# Bind("OutDate","{0:dd/MM/yyyy}") %>'></asp:Label>
                                                                                    </ItemTemplate>
                                                                                </asp:TemplateField>
                                                                                <asp:TemplateField HeaderText="To Date" ItemStyle-Width="10%" SortExpression="Title"
                                                                                    HeaderStyle-HorizontalAlign="Left" ItemStyle-Wrap="true">
                                                                                    <ItemTemplate>
                                                                                        <asp:Label ID="InTimeLabel" runat="server" Text='<%#  Bind("InDate","{0:dd/MM/yyyy}") %>'></asp:Label>
                                                                                    </ItemTemplate>
                                                                                </asp:TemplateField>
                                                                            </Columns>
                                                                        </asp:GridView>
                                                                    </div>
                                                                </ContentTemplate>
                                                            </asp:UpdatePanel>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </asp:Panel>
                                    </div>
                                </div>
                                <div class="himssuHeader1WireBox whitebox" id="DetailDiv" runat="server" visible="false">
                                    <div class="himsBoxHeader">
                                        <div class="leftdiv">
                                        </div>
                                        <div class="himsBoxTitle note note1 box box-danger">
                                            <div class="headerText">
                                                <asp:Label ID="VisitorLogDetailLabel" runat="server" Text="Hostel Gate Pass"></asp:Label>
                                            </div>
                                            <div class="fRight" style="margin-top: -20px">
                                                <table>
                                                    <tr>
                                                        <td class="formLabel">
                                                            <div id="NumberOfRecordDiv" class="display-flex" runat="server" visible="true">
                                                                <asp:ImageButton AlternateText="First page" ToolTip="First page" ID="FirstRecordImageButton"
                                                                    runat="server" ImageUrl="~/Images/arrowLlast.gif" CommandName="Page" CommandArgument="First"
                                                                    OnClick="FirstRecordImageButton_Click" />
                                                                <asp:ImageButton AlternateText="Previous page" ToolTip="Previous page" ID="PreviousImageButton"
                                                                    runat="server" ImageUrl="~/Images/arrowLeft.gif" CommandName="Page" CommandArgument="Prev"
                                                                    OnClick="PreviousImageButton_Click" />
                                                                <asp:Label ID="LabelPage" runat="server" Text="Record " AssociatedControlID="ReCordNumber" />
                                                                <asp:Label ID="ReCordNumber" Font-Bold="true" SkinID="Dummy" runat="server"></asp:Label>
                                                                <asp:Label ID="ofLabel" Text="of" runat="server" />
                                                                <asp:Label ID="TotalRecord" runat="server" />
                                                                <asp:ImageButton AlternateText="Next page" ToolTip="Next page" ID="NextImageButtom"
                                                                    runat="server" ImageUrl="~/Images/arrowRight.gif" CommandName="Page" CommandArgument="Next"
                                                                    OnClick="NextImageButton_Click" />
                                                                <asp:ImageButton AlternateText="Last page" ToolTip="Last page" ID="LastRecordImageButton"
                                                                    runat="server" ImageUrl="~/Images/arrowRLast.gif" CommandName="Page" CommandArgument="Last"
                                                                    OnClick="LastRecordImageButton_Click" />
                                                            </div>
                                                        </td>
                                                        <td>
                                                            <asp:Button ID="BackButton" runat="Server" OnClick="BackButton_Click" SkinID="0"
                                                                CssClass="BackButton" Text="Back" />
                                                        </td>
                                                    </tr>
                                                </table>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="himsBoxContent">
                                        <div class="contentHolder">
                                            <table>
                                                <tr>
                                                    <td align="left">
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5" id="SUIDDiv" runat="server" visible="false">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="SuidLabel" Text="SU ID" runat="server"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <asp:TextBox ID="SuidTextBox" AutoPostBack="true" runat="server" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" Width="150px" SkinID="CustomWidthTextBox" OnTextChanged="SUIdTextBox_TextChanged"></asp:TextBox>
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="StudentSearchIdNoLabel" runat="server" Text="Student Id No" SkinID="MandatoryLabel"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <asp:TextBox ID="StudentSearchIdNoTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                    SkinID="CustomWidthTextBox" Width="150px" runat="server" MaxLength="150"
                                                                    AutoPostBack="true" OnTextChanged="StudentSearchIdNoTextBox_TextChanged">
                                                                </asp:TextBox>
                                                                <asp:ImageButton SkinID="FindImage" ToolTip="Student Search" ID="StudentIdNoImageButton"
                                                                    runat="server" OnClick="StudentIdNoImageButton_Click" />
                                                                <asp:HiddenField ID="StudentSearchIdHiddenField" runat="server" />
                                                                <br />
                                                                <asp:HiddenField ID="TempHiddenField" runat="server" />
                                                                <asp:HiddenField ID="MaxRowHiddenField" runat="server" />
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="fLeft pRight5">
                                                                <div class="controlLabelWidth">
                                                                    <asp:Label ID="StudentSearchNameLable" runat="server" Text="Name"></asp:Label>
                                                                </div>
                                                                <div class="fLeft pRight5">
                                                                    <asp:TextBox ID="StudentSearchNameTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                        SkinID="CustomWidthTextBox" Width="250px" runat="server" MaxLength="150"> </asp:TextBox>
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="SourceNameLabel" runat="server" Text="Whom to Meet" SkinID="MandatoryLabel"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <asp:TextBox ID="WhithWhomTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                    Width="150px" runat="server" MaxLength="100" AutoPostBack="false" SkinID="CustomWidthTextbox"></asp:TextBox>
                                                                <asp:HiddenField ID="SourceIdHiddenField" runat="server" />
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="ApproveLabel" runat="server" Text="Approve By" SkinID="MandatoryLabel"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <asp:TextBox ID="ApproveTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                    Width="150px" runat="server" MaxLength="100" AutoPostBack="false" SkinID="CustomWidthTextbox"></asp:TextBox>
                                                                <asp:HiddenField ID="IdHiddenField" runat="server" />
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="ReasonLabel" runat="server" Text="Reason" SkinID="MandatoryLabel"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <asp:TextBox ID="ReasonTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                                    SkinID="MultiLineTextBox" Width="300px" TextMode="MultiLine" Height="40px" runat="server"
                                                                    MaxLength="200" AutoPostBack="false"></asp:TextBox>
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="OutDateLabel" runat="server" Text="From Date" Visible="true" SkinID="MandatoryLabel"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <Date:DatePickerControl DisplayDatePicker="true" ID="OutDatePickerControl" Visible="true"
                                                                    runat="server" />
                                                            </div>
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="OutTimeLabel" runat="server" Text="From Time"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <timePicker:TimeSelector ID="OutTimeSelector" runat="server" DisplaySeconds="False"
                                                                    SelectedTimeFormat="Twelve" AmPm="AM" Date="" Hour="0" Minute="0" Visible="true"
                                                                    Second="0" meta:resourcekey="ActivityStartTimeSelectorResource1" />
                                                            </div>
                                                        </div>
                                                        <div class="cBoth">
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="InDateLabel" runat="server" Text="To Date" Visible="true"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <Date:DatePickerControl DisplayDatePicker="true" ID="InDatePickerControl" Visible="true"
                                                                    runat="server" />
                                                            </div>
                                                        </div>
                                                        <div class="outerBox pTop5">
                                                            <div class="controlLabelWidth">
                                                                <asp:Label ID="InTimeLabel" runat="server" Text="To Time"></asp:Label>
                                                            </div>
                                                            <div class="fLeft pRight5">
                                                                <timePicker:TimeSelector ID="InTimeSelector" runat="server" DisplaySeconds="False"
                                                                    SelectedTimeFormat="Twelve" AmPm="AM" Date="" Hour="0" Minute="0" Visible="true"
                                                                    Second="0" meta:resourcekey="ActivityStartTimeSelectorResource1" />
                                                            </div>
                                                        </div>
                                                    </td>
                                                </tr>
                                        </div>
                                    </div>
                                </div>
                            </td>
                        </tr>
                    </table>
                    <div class="cBoth">
                    </div>
                </div>
            </div>
            </td> </tr> </table> </div> </div>
        </ContentTemplate>
    </asp:UpdatePanel>
    <script data-main="../../JavaScript/rjs/encrypt/hostelstudent-gatepass-encrypt" src="../../JavaScript/rjs/require.js"></script>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/hostelstudent-gatepass")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>
