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

<%@ 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/Common/EmployeeSearch/EmployeeSearch.ascx" TagName="EmployeeSearchControl"
    TagPrefix="hims" %>
<%@ Register Assembly="TimePicker" Namespace="MKB.TimePicker" TagPrefix="timePicker" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="ResonMasterUpdatePanel" runat="server" UpdateMode="Always">
        <ContentTemplate>
            <hims:EmployeeSearchControl ID="EmployeeSearch" Visible="false" runat="server" />
            <div id="divContentPage" class="divcontentpagemargin">
                
                            <div class="dashBoardLeftCont">
                                <div class="himssuHeader3WireBox">
                                    <table>
                                        <tr>
                                            <td>
                                                <div class="himsBoxContent">
                                                    <div class="leftUlMenu">
                                                        <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="166"
                                                            Visible="true" runat="server" />
                                                    </div>
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                                </div>
                            </div>
                            <div style="vertical-align: top" class="whiteboxpaddingleft row">
                                <div class="himssuHeader5WireBox card card-box" id="SearchDiv" runat="server">
                                    <div class="himsBoxHeader card-head">
                                        <asp:Panel ID="TopPanel" runat="server">
                                            
                                            <div class="himsBoxTitle">
                                                <div class="headerText">
                                                     <header>
                                                    <i class="fas fa-list-ul"></i>
                                                    <asp:Label ID="HeaderTextLabel" runat="server" Text="Employee Leave Verify"></asp:Label>
                                                         <//header>
                                                </div>
                                            </div>
                                        </asp:Panel>

                                      
                                    </div>
                                    <div class="himsBoxContent card-body">
                                        <div class="contentHolder">
                                            <asp:Panel ID="PanelSearch" runat="server">
                                              
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="SearchEmployeeCodeLabel" runat="server" Text="Employee Code"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5 display-flex">
                                                        <asp:TextBox ID="SearchEmployeeCodeTextBox" SkinID="CustomWidthTextBox"
                                                            runat="server" MaxLength="100" AutoPostBack="true" OnTextChanged="SearchEmployeeCodeTextBox_TextChanged"> </asp:TextBox>
                                                        <asp:ImageButton SkinID="FindImage" ToolTip="Search" ID="SearchEmployeeCodeImageButton"
                                                            runat="server" OnClick="SearchEmployeeCodeImageButton_Click" ImageUrl="../../../../Images/icons/icon_find.gif" />
                                                    </div>
                                                </div>
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="SearchEmployeeNameLabel" runat="server" Text="Employee Name"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:TextBox ID="SearchEmployeeNameTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                            SkinID="CustomWidthTextBox" runat="server" MaxLength="100"> </asp:TextBox>
                                                    </div>
                                                </div>
                                               
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="DepartmentLabel" Text="Department" runat="server"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList ID="DepartmentDropDownList" runat="server" onmouseleave="showHideTooltip()"
                                                            onmouseenter="showHideTooltip()" AutoPostBack="false" SkinID="CustomWidthDropDownList"
                                                            CssClass="form-control">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="EmployeeGroupLabel" runat="server" Text="Employee Group"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList runat="server" ID="EmployeeGroupDropDownList" SkinID="CustomWidthDropDownList"
                                                            onmouseleave="showHideTooltip()" CssClass="form-control" onmouseenter="showHideTooltip()">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                               
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="SearchForYearLabel" runat="server" Text="For Year" SkinID="MandatoryLabel"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList runat="server" ID="SearchForYearDropDownList" SkinID="CustomWidthDropDownList"
                                                            CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" AutoPostBack="true"
                                                            OnSelectedIndexChanged="SearchForYearDropDownList_OnSelectedIndexChanged">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                                <div class="outerBox pTop5 col-md-3">
                                                    <div class="controlLabelWidth">
                                                        <asp:Label ID="SearchForMonthLabel" runat="server" Text="For Month" SkinID="MandatoryLabel"></asp:Label>
                                                    </div>
                                                    <div class="fLeft pRight5">
                                                        <asp:DropDownList runat="server" ID="SearchForMonthDropDownList" SkinID="CustomWidthDropDownList"
                                                            CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" AutoPostBack="false">
                                                        </asp:DropDownList>
                                                    </div>
                                                </div>
                                                <br />
                                                <div class="alignCenter col-md-12 center pTop5">
                                                    <asp:Button ID="SearchButton" Text="&#xf002; Search" runat="Server" SkinID="0" class="btn-search btn fas" OnClick="SearchButton_Click" />
                                                    <asp:Button ID="ResetButton" runat="server" Text="&#xf0e2; Reset" SkinID="0" class="btn-reset btn fas" OnClick="ResetButton_Click" />
                                                </div>
                                                <br />
                                                <div id="EmployeeLeaveVerifyDiv" runat="server" visible="false">

                                                      <div class="pull-right pTop15 col-md-6 display-flex">
                                                        <asp:DropDownList ID="ApplyDropDownList" runat="server" SkinID="CustomWidthDropDownList" CssClass="form-control mt-10">
                                                            <asp:ListItem Text="- Select -" Value="-1" Selected="True"></asp:ListItem>
                                                            <asp:ListItem Text="Leave Type" Value="1"></asp:ListItem>
                                                            <asp:ListItem Text="Absent Reason" Value="2"></asp:ListItem>
                                                        </asp:DropDownList>
                                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                                        <asp:TextBox ID="ApplyAllTextBox" runat="server" ClientIDMode="Static" MaxLength="15"
                                                            SkinID="CustomWidthTextBox" CssClass="pTop5"></asp:TextBox>&nbsp;&nbsp;&nbsp;&nbsp;
                                                        <asp:Button ID="ApplyAllButton" runat="server" OnClick="ApplyAllButton_Click"
                                                            Text="Apply All" SkinID="0" CssClass="btn btn-apply mt-10" />
                                                      </div>

                                                    <div class="himssuHeader7WireBox pTop10 col-md-12" id="PatientRelationDiv"
                                                        runat="server">
                                                        <asp:GridView ID="EmployeeLeaveVerifyGridView" runat="server" class="himssuHeader7WireBox col-md-12 table-responsive" AutoGenerateColumns="False"
                                                            EmptyDataText="No Records Found !!" AllowPaging="false" OnRowDataBound="EmployeeLeaveVerifyGridView_OnRowDataBound"
                                                            ShowHeader="true" DataKeyNames="EmployeeId,EmployeeOnLeave" CssClass="table table-striped table-bordered">
                                                            <Columns>
                                                                <asp:TemplateField HeaderStyle-HorizontalAlign="Center">
                                                                    <HeaderTemplate>
                                                                        <label class="rt-chkbox rt-chkbox-outline">
                                                                        <asp:CheckBox ID="HeaderSelectCheckBox" runat="server" AutoPostBack="true" OnCheckedChanged="HeaderSelectCheckBox_OnCheckedChanged" />
                                                                            <span></span>
                                                                        </label>
                                                                    </HeaderTemplate>
                                                                    <ItemStyle HorizontalAlign="Center" />
                                                                    <ItemTemplate>
                                                                        <label class="rt-chkbox rt-chkbox-outline">
                                                                        <asp:CheckBox ID="SelectCheckBox" runat="server" />
                                                                            <span></span>
                                                                        </label>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>

                                                                <asp:BoundField DataField="Code" HeaderText="Code" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                                <asp:BoundField DataField="EmployeeName" HeaderText="Name" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                                <asp:BoundField DataField="AttndanceDate" HeaderText="Attndance Date" DataFormatString="{0:dd/MM/yyyy}" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                                <asp:BoundField DataField="PresentStatus" HeaderText="Leave Status" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                                <asp:TemplateField HeaderText="Leave Type" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:DropDownList runat="server" ID="LeaveTypeDropDownList" SkinID="CustomWidthDropDownList"
                                                                            Width="154px" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()">
                                                                        </asp:DropDownList>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                                <asp:TemplateField HeaderText="Absent Reason" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                                    <ItemTemplate>
                                                                        <asp:DropDownList runat="server" ID="AbsentReasonDropDownList" SkinID="CustomWidthDropDownList"
                                                                            CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()">
                                                                        </asp:DropDownList>
                                                                    </ItemTemplate>
                                                                </asp:TemplateField>
                                                            </Columns>
                                                            <PagerSettings Visible="False" />
                                                        </asp:GridView>
                                                    </div>
                                                </div>
                                            </asp:Panel>
                                        </div>
                                    </div>
                                </div>
                            </div>                      
                </div>
            </div>
        </ContentTemplate>
    </asp:UpdatePanel>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/assign-organization")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>    
</asp:Content>
