<%@ page title="" language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_Attendance_StudentAttendance, App_Web_hbbn1mxb" 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 Src="~/UserControls/Common/StudentSearch/StudentSearch.ascx" TagName="StudentSearch" TagPrefix="Std" %>

<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <asp:UpdatePanel ID="MonthlyRegisterUpdatePanel" runat="server">
        <ContentTemplate>
            <Std:StudentSearch ID="StudentSearch" Visible="false" runat="server" />
            <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">
                                <div class="himsBoxHeader card-head">
                                    <div class="leftdiv">
                                    </div>
                                    <div class="himsBoxTitle">
                                        <div class="headerText">
                                            <header>
                                                <i class="fas fa-edit"></i>
                                                <asp:Label ID="Label2" runat="server" Text="Student Attendance"></asp:Label>
                                            </header>
                                        </div>
                                    </div>
                                </div>
                                <div class="himsBoxContent card-body">
                                    <div class="contentHolder">
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="IdNoLabel" runat="server" Text="ID No"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5 display-flex">
                                                <asp:TextBox ID="IdNoTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                    SkinID="CustomWidthTextBox" Width="150px" runat="server" MaxLength="200"
                                                    AutoPostBack="true" OnTextChanged="IdNoTextBox_TextChanged">
                                                </asp:TextBox>
                                                <asp:ImageButton SkinID="FindImage" ToolTip="Student Search" ID="IdNoImageButton"
                                                    runat="server" ImageUrl="../../../../Images/icons/icon_find.gif" />
                                                <asp:HiddenField ID="AcademicIdHiddenField" runat="server" />
                                                <asp:HiddenField ID="ClassIdHiddenField" runat="server" />
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="NameLabel" runat="server" Text="Name"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5">
                                                <asp:TextBox ID="NameTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                    SkinID="CustomWidthTextBox" Width="150px" runat="server" MaxLength="200"> </asp:TextBox>
                                            </div>
                                        </div>

                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="ClassLabel" runat="server" Text="Class"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5">
                                                <asp:TextBox ID="ClassTextBox" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()"
                                                    SkinID="CustomWidthTextBox" Width="150px" runat="server" MaxLength="200"> </asp:TextBox>
                                            </div>
                                        </div>
                                        <div class="outerBox pTop5 col-md-3">
                                            <div class="controlLabelWidth">
                                                <asp:Label ID="AttendanceTypeLabel" runat="server" Text="Attendance Type"></asp:Label>
                                            </div>
                                            <div class="fLeft pRight5">
                                                <asp:DropDownList runat="server" ID="AttendanceTypeDropDownList" SkinID="CustomWidthDropDownList"
                                                    CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" AutoPostBack="true"
                                                    OnSelectedIndexChanged="AttendanceTypeDropDownList_OnSelectedIndexChanged">
                                                </asp:DropDownList>
                                            </div>
                                        </div>
                                        <div id="SubjectDiv" runat="server" visible="false">
                                            <div class="outerBox pTop5 col-md-3">
                                                <div class="controlLabelWidth">
                                                    <asp:Label ID="SubjectLabel" runat="server" Text="Subject"></asp:Label>
                                                </div>
                                                <div class="fLeft pRight5">
                                                    <asp:DropDownList runat="server" ID="SubjectDropDownList" SkinID="CustomWidthDropDownList"
                                                        CssClass="form-control" onmouseleave="showHideTooltip()" onmouseenter="showHideTooltip()" AutoPostBack="true"
                                                        OnSelectedIndexChanged="SubjectDropDownList_OnSelectedIndexChanged">
                                                    </asp:DropDownList>
                                                </div>
                                            </div>
                                        </div>

                                        <div class="outerBox pTop5 col-md-12">
                                            <div class="col-md-12 padd-0 ">
                                                <div class="col-lg-2 col-xs-6 cursor-pointer">
                                                    <div class="bg-orange width-100">
                                                        <div class="padd text-center ">
                                                            <h3><span id="PresentPercentageSpan" class="fnt">
                                                                <asp:Label ID="AttendanceTotalCount" runat="server" Text="0"></asp:Label>
                                                            </span></h3>
                                                            <p class="marg">Attendance Count</p>
                                                        </div>
                                                        <div class="icon">
                                                            <i class="ion ion-stats-bars"></i>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-lg-2 col-xs-6 cursor-pointer">
                                                    <div class="bg-green width-100">
                                                        <div class="padd">
                                                            <h3><span id="TotalInProgressSpan" class="fnt">

                                                                <asp:Label ID="PresentDayLabel" runat="server" Text="0"></asp:Label>
                                                            </span></h3>
                                                            <p class="marg">Present Days</p>
                                                        </div>
                                                        <div class="icon">
                                                            <i class="ion ion-stats-bars"></i>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="col-lg-2 col-xs-6 cursor-pointer">
                                                    <div class="bg-grey  width-100">
                                                        <div class="padd  text-center ">
                                                            <h3><span id="TotalPeriodicSpan" class="fnt">
                                                                <asp:Label ID="AbsentCountLabel" runat="server" Text="0"></asp:Label>
                                                            </span></h3>
                                                            <p class="marg">Absent Days</p>
                                                        </div>
                                                        <div class="icon">
                                                            <i class="ion ion-stats-bars"></i>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        <div id="Div2" class="himssuHeader7WireBox pTop15 col-md-12" runat="server" visible="false">
                                            <div id="Div3" runat="server" visible="True">
                                                <div class="leftdiv">
                                                </div>
                                                <div class="himsBoxTitle">
                                                </div>
                                            </div>
                                            <div class="himsBoxContent table-responsive">
                                                <asp:GridView ID="StudentRegisterGridView" runat="server" AutoGenerateColumns="False"
                                                    EmptyDataText="No Records Found !!" OnRowDataBound="StudentRegisterGridView_OnRowDataBound"
                                                    AllowPaging="false" ShowFooter="true"
                                                    ShowHeader="true"
                                                    CssClass="table table-striped table-bordered table-hover">
                                                    <Columns>
                                                        <asp:BoundField DataField="ForMonthInWord" HeaderText="For Month" ItemStyle-Width="10%" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                        <asp:BoundField DataField="ForYear" HeaderText="For Year" ItemStyle-Width="10%" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                        <asp:BoundField DataField="SubjectName" HeaderText="Subject" ItemStyle-Width="10%" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                        <asp:TemplateField HeaderText="Attendance Count" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="SubjectWorkingDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"TotalCount").ToString()=="0"? "0":Eval("TotalCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FSubjectWorkingDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="Present Count" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="SubjectPresentDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"PresentCount").ToString()=="0"? "0":Eval("PresentCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FSubjectPresentDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="Absent Count" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="SubjectAbsentDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"AbsentCount").ToString()=="0"? "0":Eval("AbsentCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FSubjectAbsentDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                            <%--Added for mantis : 31491--%>
                                                        </asp:TemplateField>
                                                        <asp:TemplateField HeaderText="Working Days" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="WorkingDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"TotalCount").ToString()=="0"? "0":Eval("TotalCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FWorkingDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="Attendance Count" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="AttendanceCountLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"AttendanceCount").ToString()=="0"? "0":Eval("AttendanceCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FAttendanceCountLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="Present Days" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="PresentDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"PresentCount").ToString()=="0"? "0":Eval("PresentCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FPresentDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="Absent Days" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="AbsentDaysLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem,"AbsentCount").ToString()=="0"? "0":Eval("AbsentCount") %>'>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                            <FooterTemplate>
                                                                <asp:Label ID="FAbsentDaysLabel" runat="server" Width="60px">
                                                                </asp:Label>
                                                            </FooterTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="Average Presence(%)" ItemStyle-Width="10%" ItemStyle-Wrap="true" HeaderStyle-HorizontalAlign="Left">
                                                            <ItemTemplate>
                                                                <asp:Label ID="AveragePresenceLabel" runat="server" Width="60px" Text='<%# DataBinder.Eval(Container.DataItem, "AveragePresence").ToString() == "0.00" ? "0.00" : Eval("AveragePresence")%> '>
                                                                </asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>
                                                        <asp:BoundField DataField="AbsentDays" HeaderText="Absent Date" ItemStyle-Width="10%" HeaderStyle-HorizontalAlign="Left"></asp:BoundField>
                                                    </Columns>
                                                    <PagerSettings Visible="False" />
                                                </asp:GridView>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                        <%--HEDP History Ends Here--%>
                    </div>
                </div>
        </ContentTemplate>
    </asp:UpdatePanel>
  <%--  <script data-main="../../JavaScript/rjs/encrypt/student-attendance-encrypt" src="../../JavaScript/rjs/require.js"></script>--%>
      <script data-main='<%=ResolveUrl("~/JavaScript/rjs/student-attendance")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
</asp:Content>
