
<div class="well"><!-- well start -->


        	<ul class="breadcrumb">
                  <li><a href="gateway.php?act=view_admission_reports">Allocation Report</a> <span class="divider"></span></li>

                  <li class="active"> Allocated reports  </li>

           </ul>







              <ul class="tabs">

                <li><a href="gateway.php?act=view_all_students" >All students</a></li>
                <li><a href="#view1">Allocated Students</a></li>

                <li><a href="gateway.php?act=view_not_qualified_applicants">Not Qualified</a></li>
                <li><a href="gateway.php?act=view_qualified_applicants">Qualified</a></li>



               </ul>
              <div class="tabcontents">


                <div id="view1">

						<br/>
            <!-- Nav tabs -->
<ul class="nav nav-tabs" role="tablist">
  <li class="active"><a href="#nce" role="tab" data-toggle="tab">NCE</a></li>
  <li><a href="#prence" role="tab" data-toggle="tab">PRE-NCE</a></li>

  <li><a href="#duap1" role="tab" data-toggle="tab">DUAP (ABU)</a></li>
  <li><a href="#duap2" role="tab" data-toggle="tab">DUAP (UDUS)</a></li>
  <li><a href="#summer" role="tab" data-toggle="tab">SUMMER STUDENTS</a></li>
  <li><a href="#lvsp" role="tab" data-toggle="tab">LVSP</a></li>
</ul>

<!-- Tab panes -->
<div class="tab-content">
  <div class="tab-pane active" id="nce"><br>
    <?php








    $q = "SELECT CONCAT_WS(' ', first_name, other_names) as name, phone_no,number, students_nce.id AS id,
          students_nce.gender AS gender,state.title AS state,lga.title AS lga, hostel_campuses.title AS site,
          application_number, programmes.title AS programme, students_nce.level as LEVEL,
          hostel_blocks.title AS category,hostel_rooms.title AS room FROM state,
          lga,hostel_campuses, hostel_allocation,hostel_blocks,hostel_rooms,students_nce,
          programmes  WHERE students_nce.programme_id=programmes.id  AND students_nce.state_id = state.id
          AND students_nce.lga_id = lga.id AND students_nce.id = hostel_allocation.student_id AND
          hostel_allocation.campus_id=hostel_campuses.id AND hostel_allocation.room_id=hostel_rooms.id
          AND hostel_allocation.block_id= hostel_blocks.id AND students_nce.hostel_allocation='1'
          AND hostel_allocation.status='1' AND hostel_allocation.type_id= '2'
          ORDER BY number ASC ";
    $r = mysqli_query($conn_1, $q);

    if(mysqli_num_rows($r) > 0)
    {//show table


    $output_q =
     '<table id="example" class="user display table-bordered table-hover table-striped" cellspacing="0" width="100%" style="font-size:12px;">
     <thead>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </thead>
     <tfoot>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </tfoot>

     <tbody>';

     while($row = mysqli_fetch_array($r,MYSQLI_ASSOC))
    {
      $output_q .= "<tr>";
      $output_q .="<td>&nbsp;&nbsp;&nbsp;<input type='checkbox' value='".$row['id']."' name='user[]' id='user' class='checkbox1'/></td>" ;
      $output_q .= "<td> <a href=''>".$row['name']."</a></td>"; //nam eof the user
      $output_q .= "<td>".$row['number']."</td>";
      $output_q .= "<td>".$row['phone_no']."</td>";
      $output_q .= "<td>".$row['LEVEL']."</td>";
      $output_q .= "<td>".$row['application_number']."</td>";
      $output_q .= "<td>".$row['gender']."</td>";
      $output_q .= "<td>".$row['programme']."</td>";

      $output_q .= "<td>".$row['state']."</td>";
      $output_q .= "<td>".$row['lga']."</td>";
      $output_q .= "<td>".$row['site']."</td>";
      $output_q .= "<td>".$row['category']."</td>";
      $output_q .= "<td>".$row['room']."</td>";
      $output_q .= "</tr>";



    }
    }
    else
    {//show the msg

      $output_q =
           '<div class="alert alert-danger alert-dismissable">
          <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
          <img src="images/info.png" />&nbsp;&nbsp; No record found in the system.
           </div>';


    }






     $output_q .=
     '</tbody>
       </table>';

       echo $output_q;

    ?>
  </div>
  <div class="tab-pane" id="prence"><br>
    <?php








    $q = "SELECT CONCAT_WS(' ', first_name, other_names) as name, phone_no,number, students_prence.id AS id,
          students_prence.gender AS gender,state.title AS state,lga.title AS lga, hostel_campuses.title AS site,
          application_number, programmes.title AS programme, students_prence.level as LEVEL,
          hostel_blocks.title AS category,hostel_rooms.title AS room FROM state,
          lga,hostel_campuses, hostel_allocation,hostel_blocks,hostel_rooms,students_prence,
          programmes  WHERE students_prence.programme_id=programmes.id  AND students_prence.state_id = state.id
          AND students_prence.lga_id = lga.id AND students_prence.id = hostel_allocation.student_id AND
          hostel_allocation.campus_id=hostel_campuses.id AND hostel_allocation.room_id=hostel_rooms.id
          AND hostel_allocation.block_id= hostel_blocks.id AND students_prence.hostel_allocation='1'
          AND hostel_allocation.status='1' AND hostel_allocation.type_id= '1'
          ORDER BY number ASC ";
    $r = mysqli_query($conn_1, $q);

    if(mysqli_num_rows($r) > 0)
    {//show table


    $output_q =
     '<table id="example" class="user display table-bordered table-hover table-striped" cellspacing="0" width="100%" style="font-size:12px;">
     <thead>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </thead>
     <tfoot>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </tfoot>

     <tbody>';

     while($row = mysqli_fetch_array($r,MYSQLI_ASSOC))
    {
      $output_q .= "<tr>";
      $output_q .="<td>&nbsp;&nbsp;&nbsp;<input type='checkbox' value='".$row['id']."' name='user[]' id='user' class='checkbox1'/></td>" ;
      $output_q .= "<td> <a href=''>".$row['name']."</a></td>"; //nam eof the user
      $output_q .= "<td>".$row['number']."</td>";
      $output_q .= "<td>".$row['phone_no']."</td>";
      $output_q .= "<td>".$row['LEVEL']."</td>";
      $output_q .= "<td>".$row['application_number']."</td>";
      $output_q .= "<td>".$row['gender']."</td>";
      $output_q .= "<td>".$row['programme']."</td>";

      $output_q .= "<td>".$row['state']."</td>";
      $output_q .= "<td>".$row['lga']."</td>";
      $output_q .= "<td>".$row['site']."</td>";
      $output_q .= "<td>".$row['category']."</td>";
      $output_q .= "<td>".$row['room']."</td>";
      $output_q .= "</tr>";



    }
    }
    else
    {//show the msg

      $output_q =
           '<div class="alert alert-danger alert-dismissable">
          <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
          <img src="images/info.png" />&nbsp;&nbsp; No record found in the system.
           </div>';


    }






     $output_q .=
     '</tbody>
       </table>';

       echo $output_q;

    ?>
  </div>

  <div class="tab-pane" id="duap1"><br>
    <div class="alert alert-danger alert-dismissable">
   <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
   <img src="images/info.png" />&nbsp;&nbsp; Under maintenance.
    </div>
  </div>
  <div class="tab-pane" id="duap2"><br>
    <div class="alert alert-danger alert-dismissable">
   <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
   <img src="images/info.png" />&nbsp;&nbsp; Under maintenance.
    </div>

</div>
  <div class="tab-pane" id="summer"><br>
    <?php








    $q = "SELECT CONCAT_WS(' ', first_name, other_names) as name, phone_no,number, summer_students.id AS id,
          summer_students.gender AS gender,state.title AS state,lga.title AS lga, hostel_campuses.title AS site,
          application_number, programmes.title AS programme, summer_students.level as LEVEL,
          hostel_blocks.title AS category,hostel_rooms.title AS room FROM state,
          lga,hostel_campuses, hostel_allocation,hostel_blocks,hostel_rooms,summer_students,
          programmes  WHERE summer_students.programme_id=programmes.id  AND summer_students.state_id = state.id
          AND summer_students.lga_id = lga.id AND summer_students.id = hostel_allocation.student_id AND
          hostel_allocation.campus_id=hostel_campuses.id AND hostel_allocation.room_id=hostel_rooms.id
          AND hostel_allocation.block_id= hostel_blocks.id AND summer_students.hostel_allocation='1'
          AND hostel_allocation.status='1' AND hostel_allocation.type_id= '5'
          ORDER BY number ASC ";
    $r = mysqli_query($conn_1, $q);

    if(mysqli_num_rows($r) > 0)
    {//show table


    $output_q =
     '<table id="example" class="user display table-bordered table-hover table-striped" cellspacing="0" width="100%" style="font-size:12px;">
     <thead>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </thead>
     <tfoot>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </tfoot>

     <tbody>';

     while($row = mysqli_fetch_array($r,MYSQLI_ASSOC))
    {
      $output_q .= "<tr>";
      $output_q .="<td>&nbsp;&nbsp;&nbsp;<input type='checkbox' value='".$row['id']."' name='user[]' id='user' class='checkbox1'/></td>" ;
      $output_q .= "<td> <a href=''>".$row['name']."</a></td>"; //nam eof the user
      $output_q .= "<td>".$row['number']."</td>";
      $output_q .= "<td>".$row['phone_no']."</td>";
      $output_q .= "<td>".$row['LEVEL']."</td>";
      $output_q .= "<td>".$row['application_number']."</td>";
      $output_q .= "<td>".$row['gender']."</td>";
      $output_q .= "<td>".$row['programme']."</td>";

      $output_q .= "<td>".$row['state']."</td>";
      $output_q .= "<td>".$row['lga']."</td>";
      $output_q .= "<td>".$row['site']."</td>";
      $output_q .= "<td>".$row['category']."</td>";
      $output_q .= "<td>".$row['room']."</td>";
      $output_q .= "</tr>";



    }
    }
    else
    {//show the msg

      $output_q =
           '<div class="alert alert-danger alert-dismissable">
          <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
          <img src="images/info.png" />&nbsp;&nbsp; No record found in the system.
           </div>';


    }






     $output_q .=
     '</tbody>
       </table>';

       echo $output_q;

    ?>
  </div>
  <div class="tab-pane" id="lvsp">
    <?php








    $q = "SELECT CONCAT_WS(' ', first_name, other_names) as name, phone_no,number, students_lvsp.id AS id,
          students_lvsp.gender AS gender,state.title AS state,lga.title AS lga, hostel_campuses.title AS site,
          application_number, programmes.title AS programme, students_lvsp.level as LEVEL,
          hostel_blocks.title AS category,hostel_rooms.title AS room FROM state,
          lga,hostel_campuses, hostel_allocation,hostel_blocks,hostel_rooms,students_lvsp,
          programmes  WHERE students_lvsp.programme_id=programmes.id  AND students_lvsp.state_id = state.id
          AND students_lvsp.lga_id = lga.id AND students_lvsp.id = hostel_allocation.student_id AND
          hostel_allocation.campus_id=hostel_campuses.id AND hostel_allocation.room_id=hostel_rooms.id
          AND hostel_allocation.block_id= hostel_blocks.id AND students_lvsp.hostel_allocation='1'
          AND hostel_allocation.status='1' AND hostel_allocation.type_id= '6'
          ORDER BY number ASC ";
    $r = mysqli_query($conn_1, $q);

    if(mysqli_num_rows($r) > 0)
    {//show table


    $output_q =
     '<table id="example" class="user display table-bordered table-hover table-striped" cellspacing="0" width="100%" style="font-size:12px;">
     <thead>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </thead>
     <tfoot>
       <th>S/No</th>
       <th>Name</th>
       <th>Matric Number</th>
       <th>Phone Number</th>
       <th>Level</th>
       <th>Application Number</th>
       <th>Gender</th>
       <th>Programme</th>
       <th>State</th>
       <th>LGA</th>
       <th>Campus</th>
       <th>Block</th>
       <th>Room</th>


     </tfoot>

     <tbody>';

     while($row = mysqli_fetch_array($r,MYSQLI_ASSOC))
    {
      $output_q .= "<tr>";
      $output_q .="<td>&nbsp;&nbsp;&nbsp;<input type='checkbox' value='".$row['id']."' name='user[]' id='user' class='checkbox1'/></td>" ;
      $output_q .= "<td> <a href=''>".$row['name']."</a></td>"; //nam eof the user
      $output_q .= "<td>".$row['number']."</td>";
      $output_q .= "<td>".$row['phone_no']."</td>";
      $output_q .= "<td>".$row['LEVEL']."</td>";
      $output_q .= "<td>".$row['application_number']."</td>";
      $output_q .= "<td>".$row['gender']."</td>";
      $output_q .= "<td>".$row['programme']."</td>";

      $output_q .= "<td>".$row['state']."</td>";
      $output_q .= "<td>".$row['lga']."</td>";
      $output_q .= "<td>".$row['site']."</td>";
      $output_q .= "<td>".$row['category']."</td>";
      $output_q .= "<td>".$row['room']."</td>";
      $output_q .= "</tr>";



    }
    }
    else
    {//show the msg

      $output_q =
           '<div class="alert alert-danger alert-dismissable">
          <button class="close" aria-hidden="true" data-dismiss="alert" type="button">x</button>
          <img src="images/info.png" />&nbsp;&nbsp; No record found in the system.
           </div>';


    }






     $output_q .=
     '</tbody>
       </table>';

       echo $output_q;

    ?>
  </div>
</div>







</form>
                </div>





              </div>





</form>

</div>
