<div class="col-sm-10">
    <div class="row ">
        <div class="col-sm-12 padding-zero " style="margin-top:5px ">
            <div class="col-sm-12 ">
                <div class="col-sm-4 form-group">
                    <div class="input-group">
                        <input type="text" class="form-control"  
                               value="<?php echo $this->session->sess_search_input; ?>" 
                               id="searchCourseRegisterText"
                               placeholder="Search here..." aria-describedby="basic-addon1">
                        <span class="input-group-addon" id="basic-addon1"><i class="fa fa-search"></i></span>
                    </div>
                    <input type="hidden" id="baseUrl" value="<?php echo base_url(); ?>">
                </div>

                <div class="col-sm-3 col-sm-offset-1 form-group">
                    <div class="form-group col-sm-12">
                        <div class="input-group date" id="datetimepicker13">
                            <input type="text" 
                                   class="form-control" 
                                   aria-describedby="basic-addon1"
                                   value="<?php echo $this->session->sess_selected_date; ?>"
                                   onblur="getCourseRegisterStudentDate(this.value)"
                                   id="learnerCourseDate"
                                   placeholder="YYYY-MM" >
                            <span class="input-group-addon">
                                <span class="glyphicon glyphicon-calendar"></span>
                            </span>
                        </div>
                    </div>
                    <script type="text/javascript">
                        //for Date   #datetimepicker1 is ID for Date Input Field     
                        $(function () {
                            $('#datetimepicker13').datetimepicker({
                                viewMode: 'years',
                                format: 'YYYY-MM'
                            });
                        });
                    </script>
                </div>

                <div class="col-sm-3 col-sm-offset-1 form-group">
                    <select class="form-control"
                            id="paymentStatus">
                        <option value=''>All</option>
                        <option value='1' <?php echo ($this->session->sess_payment_status == 1) ? 'selected=""' : ''; ?> >Paid</option>
                        <option value='2' <?php echo ($this->session->sess_payment_status == 2) ? 'selected=""' : ''; ?>>Partial Paid</option>
                        <option value='3' <?php echo ($this->session->sess_payment_status == 3) ? 'selected=""' : ''; ?>>Unpaid</option>
                        <option value='4' <?php echo ($this->session->sess_payment_status == 4) ? 'selected=""' : ''; ?>>Drop</option>
                        <option value='5' <?php echo ($this->session->sess_payment_status == 5) ? 'selected=""' : ''; ?>>Cancel</option>
                        <option value='6' <?php echo ($this->session->sess_payment_status == 6) ? 'selected=""' : ''; ?>>Pending</option>
                        <option value='7' <?php echo ($this->session->sess_payment_status == 7) ? 'selected=""' : ''; ?>>Refund Request</option>
                        <option value='8' <?php echo ($this->session->sess_payment_status == 8) ? 'selected=""' : ''; ?>>Refund</option>
                    </select>
                </div>
            </div>
        </div>




        <div class="col-sm-12 ">
            <div class="col-sm-12" ><br>  <hr></div>
            <div class="col-sm-12" >
                <div class="col-sm-12 gray_ttc" style="border-bottom: 2px solid #8CC73F;padding-top: 10px;padding-bottom: 10px;font-weight: bold">
                    <div class="col-sm-2">Roll Number</div>
                    <div class="col-sm-3 padding-zero">Name</div>
                    <div class="col-sm-3 padding-zero">Register Date</div>
                    <div class="col-sm-3 padding-zero">Payment Status</div>
                    <div class="col-sm-1 padding-zero">Action</div>
                </div>
                <div class="col-sm-12"><br></div>
                <div id="view_learner_course" class="padding-zero">
                    <?php
                    if (!empty($student_info)) {
                        foreach ($student_info as $value) {
                            if(empty($person_info[$value->student_id])){
                                continue;
                            }
                            ?>
                            <div class="col-sm-12 gray_ttc " style="padding-top: 10px;padding-bottom: 10px;">
                                <div class="col-sm-2">
                                    <?php echo "<strong>$value->student_roll_number</strong>" ?>
                                </div>

                                <div class="col-sm-3 padding-zero">
                                    <a href="<?php echo base_url() . $person_info[$value->student_id]->url ?>" target="_blank">
                                        <?php echo $person_info[$value->student_id]->person_first_name . ' ' . $person_info[$value->student_id]->person_last_name; ?>
                                    </a>
                                </div>

                                <div class="col-sm-3 padding-zero">
                                    <?php
                                    echo date("F j, Y, g:i a", strtotime($value->register_date_time));
                                    ?>
                                </div>

                                <div class="col-sm-3 padding-zero"><strong id="paymentStatusMessage<?php echo $value->student_roll_number; ?>">
                                        <?php
                                        if (!empty($payment_info[$value->student_id])) {
                                            echo $this->tt_message->set_payment_status($payment_info[$value->student_id]->payment_status)
                                                    ->get_payment_status_message();
                                        } else {
                                            echo 'FREE';
                                        }
                                        ?></strong>
                                </div>

                                <div class="col-sm-1 padding-zero" >
                                    <?php
                                    if (!empty($payment_info[$value->student_id])) {
                                        ?>
                                        <input type="hidden" id="paymentID<?php echo $value->student_roll_number; ?>" value="<?php echo $encrypt_payment_id[$value->student_id]; ?>">
                                        <input type="hidden" id="status<?php echo $value->student_roll_number; ?>" value="">
                                        <a href="javascript:void(0)" id="viewAllInvoices<?php echo $value->student_roll_number; ?>"><i class="fa fa-money" title="All Payment"></i></a>
                                        <span>&nbsp;</span>
                                        <?php
                                    }
                                    ?>
                                    <a href="<?php echo base_url("admin/assign-course/" . $person_info[$value->student_id]->url); ?>"><i class="glyphicon glyphicon-paste" title="Assign Course"></i></a>
                                    <span>&nbsp;</span>
                                    <a href="<?php echo base_url('admin/student-accounts-details/' . $person_info[$value->student_id]->url) ?>"><i class="fa  fa-th" title="View Details"></i></a>
                                    <span>&nbsp;</span>
                                </div>
                                <div class="col-sm-12 col-sm-offset-4" style="margin-top: 20px; display: none;" id="loadingImage<?php echo $value->student_roll_number; ?>">
                                    <img src="<?php echo base_url('image\loading.gif'); ?>">
                                </div>
                                <div class="col-sm-12" style="margin-top: 20px; display: none;" id="displayAllInvoice<?php echo $value->student_roll_number; ?>">
                                </div>
                            </div>
                        <?php } ?>

                        <?php
                        echo $paginzation_link;
                    } else {
                        echo 'There is no available student';
                    }
                    ?>

                </div>
            </div>
        </div>
    </div>
</div>
<script type="text/javascript" src="<?php echo base_url() ?>back_end_resource/accounts/course_register_student.js">
</script>