<%@ Page Title="" Language="C#" MasterPageFile="~/Site1.Master" AutoEventWireup="true"
    CodeBehind="Leave.aspx.cs" Inherits="HRMS.ESS.Leave" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <asp:ScriptManager ID="scriptManager" runat="server">
    </asp:ScriptManager>
    <asp:UpdatePanel runat="server" ID="upMain" UpdateMode="Conditional" ChildrenAsTriggers="true">
        <ContentTemplate>
            <div class="main-panel">
                <div class="row">
                    <div class="col-md-12">
                        <section class="panel">
                    <header class="panel-heading">
                        Leave Request
                       <div class ="pull-right">
                            <asp:Button CssClass="btn btn-info" ID="btn_save_ltr" Text="Save for Later" 
                                runat="server" onclick="btn_save_ltr_Click" />
                            <asp:Button  CssClass="btn btn-info" ID ="btn_save" Text ="Send" runat="server" ValidationGroup="save" />
                           <asp:Button  CssClass="btn btn-info" ID ="btn_cancel" Text ="Back" runat="server" OnClick="btn_cancel_Click" />
                       </div>
                        
                    </header>
                    <div class ="panel-body">
                          <div class="span6">
                                <div id="divmessage" runat="server" visible="false" class="alert alert-info alert-dismissable">
                                    <asp:label text="" ID="lbl_msg" CssClass="msg" runat="server"></asp:label>
                                </div>
                            </div>

                            <div class="span6">
                                <div id="diverrmessage" runat="server" visible="false" class="alert alert-info alert-dismissable">
                                    <asp:label text="" id="lbl_err_msg" CssClass="msg" runat="server"></asp:label>
                                    
                                </div>
                            </div>
                        <div class ="row" style="padding-top:10px">
                                <asp:HiddenField ID="hid_Abs_id" runat ="server" />
                                <asp:HiddenField ID="hid_person_id" runat ="server" />
                             <label class="control-label col-md-2">Employee Name</label>
                            <div class ="col-md-3">
                                <asp:TextBox ID="txtempname" Enabled="false" runat ="server" CssClass ="form-control"></asp:TextBox>
                            </div>       
                           <label class ="control-label col-md-3">Employee No</label>   
                            <div class ="col-md-2">
                                <asp:TextBox ID="txtempno"   Enabled="false" runat ="server" CssClass ="form-control"></asp:TextBox>
                            </div>   
                            
                        </div>

                                  <div class ="row" style="padding-top:10px">
                             <label class="control-label col-md-2">Organization Email</label>
                                   <div class ="col-md-3">
                                <asp:TextBox ID="txtemail"  Enabled="false" runat ="server" CssClass ="form-control"></asp:TextBox>
                            </div>   
                            
                                      <label class ="control-label col-md-3">Business Group</label>
                            
                                      <div class ="col-md-3">
                                          <asp:TextBox CssClass="form-control"  Enabled="false" ID="txtbusinessgroup" runat ="server"></asp:TextBox>
                                      </div>
                            </div>
                            <hr />
                        <div class ="row" style ="padding-top:10px">
                               <%--  <label Visible="false"  class ="control-label col-md-2 col-md-offset-1">Request Status</label>--%>
                               <div class ="col-md-2">
                                   <asp:TextBox CssClass="form-control"  Visible="false" ID="txtrequest" runat="server"></asp:TextBox>
                               </div>
                                        
                        </div>
                        
                     <div class ="row" style="padding-top:10px">
                          <label class="control-label col-md-2">Absence Type</label>
                         <div class ="col-md-3" >
                                <asp:DropDownList ID ="ddl_absence_type"  runat="server"  CssClass="form-control" AutoPostBack="True" OnSelectedIndexChanged="ddl_absence_type_SelectedIndexChanged"></asp:DropDownList>
                            </div>
                         

                          <label class="control-label col-md-3">Absence Category</label>
                            <div class ="col-md-2">
                                <asp:TextBox CssClass ="form-control" Enabled="false" ID ="txtabs_catagory" runat="server"></asp:TextBox>
                            </div>
                            
                    </div>
                        
                       
                       
                        <div class ="row" style="padding-top:10px">
                            <label class ="control-label col-md-2">Start Date</label>
                            <div class ="col-md-2">
                               <asp:TextBox CssClass="form-control form_datetime" ID="txtstartdate"  runat="server" TextMode="SingleLine"></asp:TextBox> 
                                <asp:RequiredFieldValidator SetFocusOnError="true" ValidationGroup="save" runat="server" id="Req_txtstartdate" controltovalidate="txtstartdate" errormessage="Start Date is Required!" />
                            </div>

                             <label class ="control-label col-md-4">End Date</label>
                            <div class ="col-md-2">
                               <asp:TextBox CssClass="form-control form_datetime" ID="txtenddate" runat="server"></asp:TextBox>
                               <asp:RequiredFieldValidator SetFocusOnError="true" ValidationGroup="save" runat="server" id="Req_txtenddate" controltovalidate="txtenddate" errormessage="End Date is Required!" /> 
                            </div>
                        </div>
                        
                        <div class ="row" style="padding-top:10px">
                            <label class="control-label col-md-2" style="margin-left:2px">Replaced By</label>
                             <div class="col-md-3">
                                  <div class="input-group">
                                  <asp:HiddenField runat="server" ID="hid_replace" />
                                   <asp:TextBox CssClass="form-control"  ID="txtreplacedby"  runat="server"></asp:TextBox>
                                                         <span class="input-group-btn">
                                                            <button id="btn_lov_replace" type="button" runat="server" class="btn btn-white" onserverclick="btn_lov_replace_Click">
                                                            <i class="fa fa-search"></i></button>
                                                          </span>
                                                      </div>
                                                     </div>
                                                     <div class="col-md-5">
                                                     <asp:Label  CssClass="control-label" style="margin-left:278px" ID="lbl_total" Visible="false" Text="Total Days" runat="server"></asp:Label>
                                                        <asp:Label  CssClass="control-label" ID="txttotaldays" runat="server"></asp:Label>
                                                     </div>

                        </div>
                      

                        <div class ="row" style="padding-top:10px">
                            <label class="control-label col-md-2">Comment</label>
                                <div class ="col-md-8">
                               <asp:TextBox CssClass="form-control" ID="txtcommentbox" TextMode="MultiLine" runat="server" Height="100px" ></asp:TextBox> 
                               <asp:requiredfieldvalidator ID="Requiredfieldvalidator1" errormessage="Reason is Required" controltovalidate="txtcommentbox" ValidationGroup="save" runat="server"/>
                                </div> 
                        </div>
                    </div>                        
                    </section>
                    </div>
                </div>
            </div>
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="btn_save" EventName="Click" />
        </Triggers>
    </asp:UpdatePanel>
</asp:Content>
