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

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %>
<%@ Register Src="~/UserControls/GridViewPager/GridViewPager.ascx" TagName="GridViewPager" TagPrefix="uc1" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>
<%@ Register Src="~/UserControls/Common/ScreenGroup/ScreenGroup.ascx" TagName="ScreenGroupControl" TagPrefix="ScreenGroup" %>
<%@ Register Assembly="Sapphire.Ohu.Web.ControlToolKit.Controls" Namespace="Sapphire.Ohu.Web.ControlToolKit.Controls" TagPrefix="cc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="OTQueueListingUpdatePanel" runat="server">
        <ContentTemplate>
            <div id="divContentPage" class="divcontentpagemargin">
                <div class="dashBoardLeftCont">
                    <div class="himssuHeader3WireBox">
                        <div class="himssuHeader3WireBox">
                            <table>
                                <tr>
                                    <td>
                                        <div class="himsBoxContent">
                                            <div class="leftUlMenu">
                                                <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="110"
                                                    Visible="true" runat="server" />
                                            </div>
                                        </div>
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <div class="row whiteboxpaddingleft">
                            <div class="himssuHeader5WireBox card card-box" id="SearchDiv" runat="server">
                                <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 mt-27">
                                                <asp:Button ID="AddNewButtonID" runat="server" OnClick="AddNewButton_Click" SkinID="0" CssClass="btn btn-add fas" Text="&#xf067; Add" />
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                                <div class="himsBoxContent card-body" style="padding-bottom: 5px">
                                    <asp:Panel ID="SearchPanel" runat="Server">
                                        <div class="contentHolder">
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SearchTitleLabel" runat="server" Text="Name"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:TextBox ID="SearchTitleTextBox" runat="server" onmouseleave="showHideTooltip()"
                                                        SkinID="CustomWidthTextBox" onmouseenter="showHideTooltip()" MaxLength="100"></asp:TextBox>
                                                </div>
                                            </div>
                                            <div class="alignCenter pTop5 col-md-12">
                                                <asp:Button ID="SearchButton" runat="server" Text="&#xf002; Search" OnClick="SearchButton_Click"
                                                    SkinID="0" CssClass="btn-search btn fas" />
                                                <asp:Button ID="ResetButton" runat="server" Text="&#xf0e2; Reset" OnClick="ResetButton_Click"
                                                    SkinID="0" CssClass="btn-reset btn fas" />
                                            </div>
                                            <div id="Div2" class="himssuHeader1WireBox col-md-12" runat="server">
                                                <div id="GradeSetMasterListDetailDiv" runat="server" visible="false">
                                                    <div id="GradeSetMasterListDiv" visible="false" runat="server">
                                                        <div class="leftdiv">
                                                        </div>
                                                        <div class="himsBoxTitle">
                                                            <div class="headerText">
                                                                <asp:Label ID="Label2" runat="server" Text=""></asp:Label>
                                                            </div>
                                                        </div>
                                                    </div>
                                                    <div class="himsBoxContent card-body" style="padding-bottom: 5px; padding-top: 10px">
                                                        <asp:UpdatePanel ID="MenuPlanDetailUpdatePanel" runat="server" UpdateMode="Always">
                                                            <ContentTemplate>
                                                                <div class="himsBoxContentMsg" id="GridMessageDiv" runat="server" visible="false">
                                                                </div>
                                                                <div id="Div5" runat="server" visible="false" class="table table-responsive">
                                                                    <asp:GridView ID="FilterGridview" runat="server" AutoGenerateColumns="False"
                                                                        SkinID="" EmptyDataText="No Records Found !!"
                                                                        DataKeyNames="FilterCriteriaId" OnRowDataBound="FilterGridview_RowDataBound" OnPageIndexChanging="FilterGridview_PageIndexChanging" CssClass="table table-striped table-bordered table-hover">
                                                                        <Columns>
                                                                            <asp:TemplateField ItemStyle-Width="10%" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true"
                                                                                HeaderText="">
                                                                                <ItemTemplate>
                                                                                    <asp:LinkButton ID="SelectLinkButton" runat="server" CommandName="Select" Text="Select"
                                                                                        CausesValidation="false" OnClick="SelectLinkButton_Click"></asp:LinkButton>
                                                                                </ItemTemplate>
                                                                            </asp:TemplateField>
                                                                            <asp:BoundField DataField="FilterCriteriaId" HeaderText="Id" ItemStyle-Width="7%" Visible="false" />
                                                                            <asp:BoundField DataField="Code" HeaderText="Code" ItemStyle-Width="40%" HeaderStyle-HorizontalAlign="Left" />
                                                                            <asp:BoundField DataField="Title" HeaderText="Name" ItemStyle-Width="50%" HeaderStyle-HorizontalAlign="Left" />
                                                                            <asp:TemplateField HeaderText="InActive" ItemStyle-Width="10%" SortExpression="IsObsolete"
                                                                                HeaderStyle-HorizontalAlign="Center" ItemStyle-HorizontalAlign="Center" ItemStyle-Wrap="true">
                                                                                <ItemTemplate>
                                                                                    <asp:Label ID="ObsoleteLabel" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"IsObsolete").ToString().ToUpper()=="TRUE"?"Y":"N" %>'></asp:Label>
                                                                                </ItemTemplate>
                                                                            </asp:TemplateField>
                                                                        </Columns>
                                                                    </asp:GridView>
                                                                </div>
                                                            </ContentTemplate>
                                                        </asp:UpdatePanel>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                            </div>
                            <!-- Sub Container2 Box Ends -->

                            <!-- Sub Container1 Box Start -->
                            <div class="himssuHeader1WireBox card card-box" id="DetailDiv" runat="server" visible="false">
                                <div class="himsBoxHeader card-head">
                                    <div class="leftdiv">
                                    </div>
                                    <div class="himsBoxTitle">
                                        <div class="headerText">
                                            <header>
                                                <i class="fas fa-filter"></i>
                                                <asp:Label ID="Label1" runat="server" Text="Filter Criteria Detail "></asp:Label>
                                            </header>
                                        </div>
                                    </div>
                                    <div class="fRight mt-27 pagination display-flex ">

                                        <div id="NumberOfRecordDiv" class="display-flex" runat="server" visible="true">
                                            <asp:LinkButton AlternateText="First page" ToolTip="First page" ID="FirstRecordImageButton"
                                                runat="server" CommandName="Page" CommandArgument="First"
                                                OnClick="FirstRecordImageButton_Click" CssClass="btn btn-default gridviewpagerbuttonpadding">
                                                    <i class="fa fa-fast-backward"></i>
                                            </asp:LinkButton>
                                            <asp:LinkButton AlternateText="Previous page" ToolTip="Previous page" ID="PreviousImageButton"
                                                runat="server" CommandName="Page" CommandArgument="Prev"
                                                OnClick="PreviousImageButton_Click" CssClass="btn btn-default gridviewpagerbuttonpadding">
                                                    <i class="fa fa-play fa-rotate-180"></i>
                                            </asp:LinkButton>

                                            <asp:Label ID="LabelPage" runat="server" Text="Record " AssociatedControlID="ReCordNumber" />
                                            &nbsp; 
                                            <asp:Label ID="ReCordNumber" Font-Bold="true" SkinID="Dummy" runat="server"></asp:Label>
                                            &nbsp;
                                            <asp:Label ID="ofLabel" Text="of" runat="server" />
                                            &nbsp;  
                                            <asp:Label ID="TotalRecord" runat="server" />
                                            &nbsp;
                                                <asp:LinkButton AlternateText="Next page" ToolTip="Next page" ID="NextImageButtom"
                                                    runat="server" CssClass="btn btn-default gridviewpagerbuttonpadding" CommandName="Page" CommandArgument="Next"
                                                    OnClick="NextImageButton_Click">
                                                     <i class="fa fa-play"></i>
                                                </asp:LinkButton>
                                            <asp:LinkButton AlternateText="Last page" ToolTip="Last page" ID="LastRecordImageButton"
                                                runat="server" CssClass="btn btn-default gridviewpagerbuttonpadding" CommandName="Page" CommandArgument="Last"
                                                OnClick="LastRecordImageButton_Click">
                                                      <i class="fa fa-fast-forward"></i>
                                            </asp:LinkButton>
                                            &nbsp;  &nbsp; &nbsp;
                                        </div>

                                        <asp:Button ID="BackButton" runat="Server" OnClick="BackButton_Click" SkinID="0" CssClass="btn btn-back fas" Text="&#xf30a;  back" />

                                    </div>
                                </div>
                                <div class="himsBoxContent card-body">
                                    <asp:Panel ID="DetailPanel" runat="Server">
                                        <div class="contentHolder" runat="server" visible="true">
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="GradeCodeLabel" Text="Code" runat="server" SkinID="MandatoryLabel"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:TextBox ID="GradeCodeTextBox" runat="server" onmouseleave="showHideTooltip()"
                                                        SkinID="CustomWidthTextBox" onmouseenter="showHideTooltip()" MaxLength="20"></asp:TextBox>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="GradeTitleLabel" Text="Name" runat="server" SkinID="MandatoryLabel"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:TextBox ID="GradeTitleTextBox" runat="server" onmouseleave="showHideTooltip()"
                                                        SkinID="CustomWidthTextBox" onmouseenter="showHideTooltip()" MaxLength="100"></asp:TextBox>
                                                </div>
                                            </div>
                                            <div class="outerBox pTop15 col-md-3">
                                                <%--  <div class="controlLabelWidth">
                                                    <asp:CheckBox ID="ObsoleteCheckBox" runat="server" />
                                                    <asp:Label ID="ObsoleteLabel" runat="server" Text="InActive" class="pLeft5"></asp:Label>
                                                </div>--%>
                                                <asp:Label CssClass="rt-chkbox rt-chkbox-outline" runat="server" AssociatedControlID="ObsoleteCheckBox" ID="ObsoleteLabel">
                                                    <asp:CheckBox ID="ObsoleteCheckBox" runat="server" />
                                                    <span></span>
                                                    InActive
                                                </asp:Label>
                                            </div>
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="fLeft pRight5">
                                                    <asp:HiddenField ID="DetailHiddenField" runat="server" />
                                                </div>
                                            </div>
                                            <div class="himssuHeader6WireBox col-md-12" id="Div1" runat="server">
                                                <div class="himsBoxHeader  card-head inner" id="GridViewPagerDiv" runat="server" visible="True">
                                                    <div class="leftdiv">
                                                    </div>
                                                    <div class="himsBoxTitle">
                                                        <div class="outerBox fRight pTop5 col-md-3 himsBoxContent">
                                                            <div class="" style="float: right">
                                                                <asp:Button ID="AddButton" runat="server" class="btn btn-add fas" OnClick="AddButton_Click" SkinID="0"
                                                                    Text="&#xf067; Add" />
                                                            </div>
                                                            <div class="" style="float: right">
                                                                <asp:DropDownList ID="AddGridDropDownList" Width="80px" runat="server" AutoPostBack="false" CssClass="form-control">
                                                                    <asp:ListItem Text="1" Value="0" Selected="True"></asp:ListItem>
                                                                    <asp:ListItem Text="5" Value="5"></asp:ListItem>
                                                                    <asp:ListItem Text="10" Value="10"></asp:ListItem>
                                                                    <asp:ListItem Text="15" Value="15"></asp:ListItem>
                                                                </asp:DropDownList>
                                                            </div>

                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="himsBoxContent table-responsive pTop5 pb-">
                                                    <div id="GridViewMessageDiv" class="himsBoxContentMsg" runat="server" visible="False">
                                                    </div>
                                                    <asp:GridView ID="GradeGridView" runat="server" AutoGenerateColumns="False"
                                                        EmptyDataText="No Records Found !!" AllowPaging="false" ShowHeader="True" DataKeyNames="Id,Index" CssClass="table table-striped table-bordered table-hover">
                                                        <Columns>
                                                            <asp:BoundField DataField="Id" HeaderText="Id" Visible="false"></asp:BoundField>
                                                            <asp:BoundField DataField="Index" HeaderText="Index" Visible="false"></asp:BoundField>
                                                            <asp:TemplateField HeaderText="Average Attendance" ItemStyle-Width="17%" ItemStyle-Wrap="true"
                                                                HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="MinimumScoreTextBox" runat="server" Width="90px" MaxLength="13"
                                                                        onblur="javascript:return fnValidateDecimal(this,10,2)" onKeypress="javascript:return MaskDecimal(event,10,2)"
                                                                        Text='<%# DataBinder.Eval(Container.DataItem,"MinimumScore").ToString()=="0"? "":Eval("MinimumScore") %>'></asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Grade" ItemStyle-Width="17%" ItemStyle-Wrap="true"
                                                                HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="GradeCodeTextBox" runat="server" Width="90px" MaxLength="20" Text='<%# Bind("GradeCode") %>'></asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Indicator" ItemStyle-Width="17%" ItemStyle-Wrap="true"
                                                                HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="GradeTitleTextBox" runat="server" Width="90px" MaxLength="100" Text='<%# Bind("GradeTitle") %>'></asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Point" ItemStyle-Width="17%" ItemStyle-Wrap="true"
                                                                HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="GradePointTextBox" runat="server" Width="90px" MaxLength="13" onblur="javascript:return fnValidateDecimal(this,10,2)"
                                                                        onKeypress="javascript:return MaskDecimal(event,10,2)" Text='<%# DataBinder.Eval(Container.DataItem,"GradePoint").ToString()=="0"? "":Eval("GradePoint") %>'></asp:TextBox>
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField HeaderText="Color" ItemStyle-Width="17%" ItemStyle-Wrap="true"
                                                                HeaderStyle-HorizontalAlign="Left">
                                                                <ItemTemplate>
                                                                    <asp:TextBox ID="ColorTextBox" runat="server" Width="90px" MaxLength="100" Text='<%# Bind("HighlightColor") %>'>
                                                                    </asp:TextBox>
                                                                    <cc1:ColorPickerExtender ID="ColorPicker1" runat="server"
                                                                        TargetControlID="ColorTextBox"
                                                                        PopupButtonID="Button1"
                                                                        PopupPosition="Right"
                                                                        OnClientColorSelectionChanged="Color_Changed" />
                                                                </ItemTemplate>
                                                            </asp:TemplateField>
                                                            <asp:TemplateField ShowHeader="true" HeaderText="Delete">
                                                                <ItemTemplate>
                                                                    <asp:ImageButton SkinID="DeleteImage" ID="DeleteImageButton" runat="server" OnClick="DeleteImageButton_Click"
                                                                        ToolTip="Delete" ImageUrl="../../../Images/icons/icon_delete.gif" />
                                                                </ItemTemplate>
                                                                <ItemStyle HorizontalAlign="Center" Width="7%" />
                                                            </asp:TemplateField>
                                                        </Columns>
                                                        <PagerSettings Visible="False" />
                                                    </asp:GridView>
                                                </div>
                                            </div>
                                        </div>
                                    </asp:Panel>
                                </div>
                            </div>
                            <%--HEDP History Ends Here--%>
                        </div>
        </ContentTemplate>
    </asp:UpdatePanel>
    <%--  <script data-main="../../JavaScript/rjs/encrypt/filter-details-encrypt" src="../../JavaScript/rjs/require.js"></script>--%>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/filter-details")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>

