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

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="row">
        <div class="col-lg-12">
            <!--breadcrumbs start -->
            <ul class="breadcrumb">
                <li><a href="#"><i class="fa fa-home"></i>Home</a></li>
                <li><a href="#">Identity Management</a></li>
                <li class="active">User Group(s)</li>
            </ul>
            <!--breadcrumbs end -->
        </div>
    </div>
    <div class="row">
        <div class="col-lg-12">
            <section class="panel">
                <header class="panel-heading" style="padding-bottom:30px">
                           <span class="label label-primary">User Group</span>


                </header>
                    <div class="panel-body">
                             <div class="span6">
                                <div id="divMessage" runat="server" visible="false" class="alert alert-info alert-dismissable">

                                    <i class="icon-check-sign"></i>
                                    <asp:Label ID="lblMessage" class="msg" runat="server" Text="" ></asp:Label>
                                </div>
                                <div id="diverrorMessage" runat="server" visible="false" class="alert alert-danger alert-dismissable">

                                    <i class="icon-check-sign"></i>
                                    <asp:Label ID="lblerrorMessage" class="msg" runat="server" Text="" ></asp:Label>
                                </div>
                            </div>
                                  <div class="form-group">
                                        <div class="col-lg-1"></div>
                                        <asp:HiddenField runat="server" ID="hdnUgrpId"/>
                                      <label for="inputEmail1" class="col-lg-2 col-sm-2 control-label"> User Group</label>
                                      <div class="col-lg-4">
                                      
                                      <asp:TextBox ID="txtUGrpName" runat="server" placeholder="User Group" MaxLength="50" CssClass="form-control"></asp:TextBox>
                                      </div>
                                     </div>
                                    <div class="form-group">
                                       <div class="col-lg-1"></div>
                                          <label for="inputPassword1" class="col-lg-2 col-sm-2 control-label">User Status</label>
                                          <div class="col-lg-4">
                                           <asp:DropDownList ID="ddlStatus" runat="server" CssClass="form-control" >
                                              <asp:ListItem>-- Select --</asp:ListItem>
                                              <asp:ListItem Text="Active" Value="A"></asp:ListItem>
                                              <asp:ListItem Text="De-active" Value="D"></asp:ListItem>
                                              </asp:DropDownList>
                                       
                                          </div>
                                    </div>
                                  <div class="form-group">
                                   <div class="col-lg-1"></div>
                                      <label for="inputPassword1" class="col-lg-2 col-sm-2 control-label">User Type </label>
                                      <div class="col-lg-4">
                                        <asp:RadioButton ID="rdAdmin" CssClass="checkbox-inline" GroupName="UType" Text="Administrator" runat="server" />
                                        <asp:RadioButton ID="rdSup" CssClass="checkbox-inline" GroupName="UType" Text=" Supervisor" runat="server" />
                                      </div>
                              </div>
                                   
                                   
                                   
                                  <div class="form-group">
                                  <div class="col-lg-1"></div>
                                      <div class="col-lg-offset-2 col-lg-8">
                                      <asp:Button ID="btnSave" class="btn btn-info" runat="server" Text="Save" OnClick="btnSave_Click"></asp:Button>
                                      <a href="#" id="aCancel" runat="server" class="btn btn-info">Cancel</a>
                                          
                                      </div>
                                  </div>
                                  
                                  <div class="row">
                                    <div class="col-lg-12">
                                        <div class="panel">
                                            <div class="panel-heading">Add User(s) to User Group</div>
                                            <div class="panel-body">
                                                <asp:GridView ID="grdUGrp" runat="server" AutoGenerateColumns="false" cellpadding="0" cellspacing="0" border="0" class="display" OnRowDataBound="grdUGrp_OnRowDataBound" OnRowCommand="grdUGrp_OnRowCommand" >
                                                    <Columns>
                                                        <asp:TemplateField ItemStyle-Width="40%" HeaderText ="User Name">
                                                            <ItemTemplate >
                                                                <div class="form-group">
                                                                    <div class="col-lg-10">
                                                                        <asp:DropDownList ID="ddlUser" CssClass="form-control" runat="server" Width="100%" ></asp:DropDownList>
                                                                        <asp:Label ID="lblUser" runat="server" Text='<%# Eval("UserId") %>' Visible = "false" />
                                                                    </div>
                                                                </div>
                                                                
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField ItemStyle-Width="20%" HeaderText ="From Date">
                                                            <ItemTemplate>
                                                            <div class="form-group">
                                                                <div class="col-lg-10">
                                                                
                                                                    <asp:TextBox ID="txtFromDate" CssClass="form_datetime form-control" runat="server" Width="100%" placeholder="From Date" MaxLength="11" Text='<%# Bind("FromDate") %>'></asp:TextBox>
                                                                    
                                                                </div>
                                                            </div>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField ItemStyle-Width="20%" HeaderText ="To Date">
                                                            <ItemTemplate>
                                                                <div class="form-group">
                                                                    <div class="col-lg-10">
                                                                        <asp:TextBox ID="txtToDate" CssClass="form_datetime form-control" runat="server" Width="100%" placeholder="To Date" Text='<%# Bind("ToDate") %>'></asp:TextBox>
                                                                    </div>
                                                                </div>
                                                                
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField ItemStyle-Width="10%" HeaderText="Action">
                                                            <ItemTemplate>
                                                                <%--   <%#Container.DataItemIndex+1 %>
                                                                <asp:CheckBox ID="chk" runat="server" />--%>
                                                                <asp:LinkButton ID="lnkAdd" runat="server" CommandName="gAdd"><i class="fa fa-plus" style="font-size:20px !important"></i></asp:LinkButton>
                                                                &nbsp
                                                                <%--<a href="Menu.aspx?uid=<%# Eval("MenuCode") %>"><i class="fa fa-pencil" style="font-size:20px !important"></i></a>--%>
                                                                &nbsp<asp:LinkButton ID="lnkDelete" runat="server" CommandName="gDelete" OnClientClick="return confirm('Are you sure to delete?')"><i class="fa fa-trash" style="font-size:20px !important"></i></asp:LinkButton>
                        
                        
                            
                                                             </ItemTemplate>
                                                        </asp:TemplateField>
                                                    </Columns>
                                                    <%-- Mandatory--%>
                                                    <RowStyle CssClass="rowStyle"/>
                                                   <%-- Mandatory--%>
                                                    <HeaderStyle CssClass="headerStyle" />
                                                   <%-- optional--%>
                                                   <FooterStyle  CssClass="footerStyle"  />
                                                </asp:GridView>
                                                    <script src="../../../ThemeScrips/Datatables/media/js/jquery.js" type="text/javascript"></script>
                                                    <script src="../../../ThemeScrips/Datatables/media/js/jquery.dataTables.min.js" type="text/javascript"></script>
                                                    <script src="../../../ThemeScrips/Datatables/media/js/jquery.dataTables.js" type="text/javascript"></script>
                                                    <script src="../../../ThemeScrips/Datatables/media/js/GridviewFix.js" type="text/javascript"></script>
                                                    <script type="text/javascript">
                                                        //without passing class names.
                                                        $("#ContentPlaceHolder1_grdUGrp").GridviewFix().dataTable({ bFilter: false, bInfo: false });
                                                        //Passing class names

                                                        
                                                    </script>
                                                        <br />
                                            </div>
                                        </div>
                                    </div>
                                  </div>
                          </div>
             </section>
        </div>
    </div>
</asp:Content>
