<%@ page language="C#" masterpagefile="~/Pages/Common/MasterPages/MainMasterPage_new.master" autoeventwireup="true" inherits="Pages_Admission_AdmissionCustomSearch, App_Web_lusudvvi" 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="~/Pages/Admission/admission-plugin-custom-search.ascx" TagName="customsearch" TagPrefix="plugin" %>
<%@ Register Src="~/Pages/Admission/admission-plugin-custom-field.ascx" TagName="customfield" TagPrefix="plugin" %>
<%@ Register Src="~/Pages/Admission/admission-plugin-custom-order.ascx" TagName="customorder" TagPrefix="plugin" %>
<%@ Register Src="~/Pages/Admission/admission-plugin-custom-report.ascx" TagName="customreport" TagPrefix="plugin" %>
<%@ Register Src="~/Pages/Admission/admission-plugin-custom-alert.ascx" TagName="customalert" TagPrefix="plugin" %>
<%@ Register Src="~/UserControls/AutoComplete/AutoCompleteControl.ascx" TagName="AutoCompleteControl"
    TagPrefix="acc" %>
<%@ Register Src="~/UserControls/Common/CommonSearch/CommonSearch.ascx" TagName="CommonSearchUserControl"
    TagPrefix="uc1" %>
<%@ Register Src="~/UserControls/DatePicker/DatePickerAutoPostBackControl.ascx" TagName="DatePickerControl"
    TagPrefix="Date" %>


<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
    <link href="../../App_Themes/jquery-ui.css" rel="stylesheet" />
    <div id="divContentPage" class="divcontentpagemargin">
        <div class="hls-bg"></div>
        <div id="dvLoadingmsg" class="hls-wrap1">
            <div class="hls-container">
                <div class="hls-content">
                    <div class="dsh-syndicate">
                        <div class="shippingcard">
                            <span id="spnloadingimg">
                                <img src="../../../Images/loading-2.gif" /></span>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="dashBoardLeftCont">
            <div class="himssuHeader3WireBox">
                <table>
                    <tr>
                        <td>
                            <div class="leftUlMenu">
                                <ScreenGroup:ScreenGroupControl EnableViewState="true" ID="ScreenGroupControl" ScreenGroupId="112"
                                    Visible="true" runat="server" />
                            </div>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div class="whiteboxpaddingleft row">
            <div class="himssuHeader1WireBox card card-box">
                <div class="himsBoxHeader card-head">
                    <div class="himsBoxTitle">
                        <div class="headerText fLeft">
                            <header>
                                <i class="fas fa-cog"></i>&nbsp;  Admission Custom Search
                            </header>
                        </div>
                    </div>
                </div>
                <div class="himsBoxContent card-body padd-0">
                    <div class="contentHolder">
                        <div class="tableContainer tabs-style-iconbox">
                            <div class="addproducttab tabs-style-iconboxinner">
                                <a id="CustomSearch" href="javascript:;" group="ProductTab" onclick="OpenProductTab(this,'CustomSearch');" class="active fancyTab"><i class="fas fa-search"></i>&nbsp;Admission Custom Search</a>
                                <a id="CustomField" href="javascript:;" group="ProductTab" onclick="OpenProductTab(this,'CustomField');" class="fancyTab"><i class="fas fa-pencil-alt"></i>&nbsp;Custom Field</a>
                                <a id="OrderBy" href="javascript:;" group="ProductTab" onclick="OpenProductTab(this,'OrderBy');" class="fancyTab"><i class="fas fa-sort-alpha-up"></i>&nbsp;Order By</a>
                                <a id="ReportList" href="javascript:;" group="ProductTab" onclick="OpenProductTab(this,'ReportList');" class="fancyTab"><i class="fas fa-file-alt"></i>&nbsp;Report List</a>
                                <a id="Alert" href="javascript:;" group="ProductTab" onclick="OpenProductTab(this,'Alert');" class="fancyTab"><i class="fas fa-exclamation-triangle"></i>&nbsp;Alert</a>
                            </div>
                            <plugin:customsearch ID="customsearch1" runat="server" />
                            <plugin:customfield ID="customfield1" runat="server" />
                            <plugin:customorder ID="customorder1" runat="server" />
                            <plugin:customreport ID="customreport1" runat="server" />
                            <plugin:customalert ID="customalert1" runat="server" />
                        </div>
                        <div class="alignCenter pTop5 col-md-12">
                            <input type="button" id="btnSearch" value="&#xf002; Search" class="fas btn btn-search" onclick="SearchStudents();" />
                            <input type="button" id="btnClear" value="&#xf0e2; Reset" class="fas btn btn-reset" OnClick="ResetControls();"/>
                            <input type="button" id="btnGenerateReport" value="&#xf15b; Generate Report" onclick="GenerateReport();" class="fas btn btn-report" />
                            <%-- <input type="button" id="btnGetStudentData" value="&#xf15b; Get Student Data" class="fas btn btn-search" onclick="btnGetStudentData_Click" />--%>
                            <%--<asp:Button ID="btnGetStudentData" runat="server" Text="Show Popup" OnClientClick="ShowPopup(a,b)" class="fas btn btn-search" />--%>
                            <%--<input type="button" id="btnGetStudentData" value="Get Data" onclick="ShowPopup();" class="fas btn btn-search" />--%>
                            <%--<button type="button" id="btnStudentDataGet" data-dismiss="modal" class="btn btn-primary" data-toggle="modal" data-target="#exampleModal">
                                Get Student Details
                            </button>--%>

                            <asp:Button ID="btnGenerate" runat="server" Text="Generate" ClientIDMode="Static" class=" btn btn-generate" OnClick="btnGenerate_Click" Style="display: none;" />
                            <asp:Button ID="btnView" runat="server" Text="Generate" ClientIDMode="Static" class=" btn btn-generate" OnClick="btnView_Click" Style="display: none;" />
                            <asp:Button ID="btnSaveReport" runat="server" Text="Save Report" ClientIDMode="Static" class=" btn btn-generate" OnClick="btnSaveReport_Click" Style="display: none;" />
                        </div>
                        <div>
                            <div class="himssuHeader6WireBox col-md-12 pTop15 gridviewfont">
                                <div class="himsBoxHeader card-head inner">

                                    <div class="himsBoxTitle">
                                        <%-- <div class="gridHeaderText">
                                                <header>
                                                    <label>List</label>
                                                </header>
                                            </div>--%>
                                        <div class="pull-right mt12 display-flex">
                                            <input type="hidden" id="hdnPageIndex" value="1" />
                                            <ul id="pagging" class="pagination pagination-sm" style="float: right;">
                                            </ul>
                                            &nbsp;<label id="lblTotalRecords" style="margin-top: 12px;"></label>&nbsp;                                                                      
                                        </div>
                                    </div>
                                </div>
                                <div class="himsBt table-responsive" id="TableDiv" style="display:block">
                                    <table class="table table-striped table-hover table-bordered ">
                                        <thead>
                                            <tr>
                                                <th scope="col"></th>
                                                <th scope="col">Organization</th>
                                                <th scope="col">Batch</th>
                                                <th scope="col">FormNo</th>
                                                <th scope="col">Name</th>
                                                <th scope="col">Class</th>
                                                <th scope="col">Status</th>
                                            </tr>
                                        </thead>
                                        <tbody id="tbladmissionlist">
                                                <tr>
                                                  <td colspan="7">
                                                    No Records Available</td></tr>                                     
                                        </tbody>
                                    </table>
                            </div>
                                <div class="himsBt table-responsive" id="TableDiv1" style="display:none">
                                    <table class="table table-striped table-hover table-bordered ">
                                        <thead>
                                            <tr>
                                                <th scope="col"></th>
                                                <th scope="col">Organization</th>
                                                <th scope="col">Batch</th>
                                                <th scope="col">FormNo</th>
                                                <th scope="col">Name</th>
                                                <th scope="col">Class</th>
                                                <th scope="col">Status</th>
                                            </tr>
                                        </thead>
                                        <tbody id="tbladmissionlist1">
                                                <tr>
                                                  <td colspan="7">
                                                    No Records Available</td></tr>                                     
                                        </tbody>
                                    </table>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="modal fade popup-data" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
        <div class="modal-dialog modal-dialog modal-xl" role="document">
            <div class="modal-content">
                <div class="modal-header">
                    <h5 class="modal-title" id="exampleModalLabel">Admission Details
                              <button type="button" class="btn btn-primary clsSave" style="margin-left: 502px">
                                  Save
                              </button>
                        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                            <span aria-hidden="true">&times;</span>
                        </button>

                    </h5>

                </div>
                <div class="modal-body">
                    <a href="#" class="previous">&laquo; Previous</a>
                    <a href="#" class="next">Next &raquo;</a>

                    <div class="table-responsive">
                        <div style="overflow-y: auto;" class="clsValidation"></div>
                        <div id="divStudentLoading" style="display: none; text-align: center; font-size: 16px; color: #000; font-weight: bold;"></div>

                        <table id="tlbStudentData" class="table table-striped table-bordered table-hover">
                        </table>

                    </div>
                </div>
                <%-- <div class="modal-footer">
                        <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
                        <button type="button" class="btn btn-primary">Save changes</button>
                    </div>--%>
            </div>
        </div>
    </div>
    </div>

    <style type="text/css">
        @media (min-width: 1200px) {
            .modal-xl {
                max-width: 1140px;
            }
        }

        @media (min-width: 992px) {
            .modal-lg, .modal-xl {
                max-width: 1348px;
            }
        }

        .clsVal {
            height: auto;
            padding: 0px 10px;
            overflow-y: auto;
            width: 100%;
            min-height: auto;
            max-height: 100px;
            font-size: 13px;
            color: #000;
            border: 1px solid #e83c06;
            border-radius: 4px;
        }

        #Prev {
            text-decoration: none;
            display: inline-block;
            padding: 8px 16px;
        }

            #Prev:hover {
                background-color: #ddd;
                color: black;
            }

        .previous {
            background-color: #f1f1f1;
            color: black;
        }

        .next {
            background-color: #4CAF50;
            color: white;
        }

        .round {
            border-radius: 50%;
        }

        .DropdownValue {
            width: 100px;
        }
    </style>
    <script data-main='<%=ResolveUrl("~/JavaScript/rjs/admission-custom-search")%>' src='<%=ResolveUrl("~/JavaScript/rjs/require.js")%>'></script>
    <script>
        $(document).ready(function () {          

            if(<%=this.IsSMSAlert%> == 1)
            {
                $("#rdoSMS").attr('disabled', false);
                $("#rdoSMS").attr('checked', true);
            }
            else{
                $("#rdoSMS").attr('disabled', true);
                $("#rdoSMS").attr('checked', false);
            }

            if(<%=this.IsEmailAlert%> == 1)            
                $("#rdoMail").attr('disabled', false);
            else
                $("#rdoMail").attr('disabled', true);

            if(<%=this.IsNotificationAlert%> == 1)            
                $("#rdoMobile").attr('disabled', false);
            else
                $("#rdoMobile").attr('disabled', true);          
        });
    </script>

</asp:Content>
