<?php include("parent/callMe.php"); ?>

<?php  include("sessioncheck.php"); 





if($_REQUEST['class_id']!=NULL){



  $m->where("classs_id", $_REQUEST['class_id']);



  // if($_REQUEST['session']!=NULL){

  // $m->where("session_id", $_REQUEST['session']);

  // }

  if($_REQUEST['year']!=NULL){

  $m->where("year", $_REQUEST['year']);

  }



  if($_REQUEST['month']!=NULL){

  $m->where("month_id", $_REQUEST['month']);

  }



	if($_REQUEST['fee']=="All"){

	} 



  else {

   $m->where("paid_status", $_REQUEST['fee']);

    }



$m->where("branch_id", $_SESSION['branch']);

$WorkAssignListings = $m->get("eduportal_monthly_challan");



} 





// getting branch details



$branch_details =getBranch($m);





?>





<!DOCTYPE html>

<html lang="en">

  <head>

    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

    <!-- Meta, title, CSS, favicons, etc. -->

    <meta charset="utf-8">

    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <meta name="viewport" content="width=device-width, initial-scale=1">

    <title> View Challan | EduPortal </title>

       

    <?php include('RootMe/css_links.php');?>



    <style type="text/css">

      

      .checkmark {border: 1px black gray;}

    </style>



  </head>



 <script>

      



function getsec(id){



    if (window.XMLHttpRequest) {



      // code for IE7+, Firefox, Chrome, Opera, Safari



      xmlhttp=new XMLHttpRequest();



    } else { // code for IE6, IE5



      xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");



    }



    xmlhttp.onreadystatechange=function() {



      if (xmlhttp.readyState==4 && xmlhttp.status==200) {



        document.getElementById("txt_section").innerHTML=xmlhttp.responseText;

        // alert(xmlhttp.responseText);



      }



    }



    xmlhttp.open("GET","get_section_all.php?class_id="+id,true);



    xmlhttp.send();









  }

                 





  </script>



  <script type="text/javascript">

  

  function checkboxes(){

 // alert("786");

var chk_arr =  document.getElementsByName("students[]");

var chklength = chk_arr.length;             

var students;

var count=0;



  for(k=0;k< chklength;k++)

  {

      

      if(chk_arr[k].checked){

         var vl=chk_arr[k].value.split(",");

         students=students+","+vl[1];

        count++;  

       // alert(students);

    }



  } 

    

if(count>0){



  window.location="messages.php?students="+students;

}else {

  

  alert("Please choose any students from checkboxes...");



}

  

}



</script>



  <body class="nav-md">

    <div class="container body">

      <div class="main_container">

        <div class="col-md-3 left_col">

     

            <?php include('RootMe/sidebar.php');?>



              <?php include('RootMe/header.php');?>

     

        <!-- page content -->

            <div class="right_col" role="main">

            <div class="row">

   



<div class="" style="margin-top:10px;">



  <a href="<?php echo $_SESSION['dashboard'];?>" style="margin-left: 33px;">Dashboard </a> &nbsp; <i style="" class="fa fa-angle-double-right"></i>  &nbsp;



  <a href="view_challan.php">View Challan </a> &nbsp; <i style="" class="fa fa-angle-double-right"></i>  &nbsp;  



  View Monthly Challan 



      <form class="" action="view_challan_details.php" enctype="multipart/form-data" method="get">

        <div class="panel panel-default">

          <div class="panel-heading " id="heading"><!-- <?php echo $total_records;?> Students Records --> <span style="float:right;margin-top: -7px;">



          <input type="hidden" value="<?php echo session_id().session_id().session_id().session_id().session_id(); ?>" name="session" />



 



<div class="pull-right" style="margin-top: 5px;">         





   <?php if($_GET['class_id']){  ?>

  <a href="<?php echo DOMAIN.AgentDirectory;?>parent/InsertMe.php?class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&session=<?php echo $_REQUEST['session'];?>&year=<?php echo $_REQUEST['year'];?>&section=<?php echo $_GET['section'];?>&action=DeleteAllMonthlyChallan" style="" onClick="return confirm('Are you sure you want to delete All Challan');"  class="btn btn-danger">Delete Challan </a> <?php } ?>



  <a href="monthly_challan.php" class="btn btn-primary" style="cursor:pointer;">Create Challan</a>



  <a href="fee_reporting.php" class="btn btn-primary" style="cursor:pointer;">Fee Reports</a>

   





<?php  if($_REQUEST['class_id']!=NULL){ ?>





      <a target="_blank" class="btn btn-success fa fa-print" style="height: 34px;padding: 9px;" title="Print Fee Report" href="print_students_feelist.php?<?php echo session_id().session_id().session_id(); ?>&class_id=<?php echo $_GET['class_id'];?>&session=<?php echo $_GET['session'];?>&year=<?php echo $_REQUEST['year'];?>&month=<?php echo $_GET['month'];?>&from=<?php echo $_GET['from'];?>&to=<?php echo $_GET['to'];?>&fee=<?php echo $_GET['fee'];?>&section=<?php echo $_GET['section'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1ocllgnioo156a61oe8lqc1&others=<?php echo $_GET['others'];?>">

        Print Fee List

      </a>



<?php } ?>







            <div class="btn-group" >



              

                <button style="padding:6%;margin-top: -5px;" data-toggle="dropdown" class="btn btn-primary dropdown-toggle btn-sm" type="button" aria-expanded="true"><i class="fa fa-print m-right-xs"></i>&nbsp;Print Vouchers <span class="caret"></span>

                </button>









                <ul role="menu" class="dropdown-menu">

               

                           <?php 



    $pageSingleVoucher;



    if($brid[0]['single_all_voucher']!=NULL){

      $pageSingleVoucher=$brid[0]['single_all_voucher'];

    }else{

      $pageSingleVoucher="print_all_vouchers_single.php";  

    }



    ?>  

                 

                  <li><a href="<?php echo $pageSingleVoucher;?>?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&year=<?php echo $_REQUEST['year'];?>&session=<?php echo $_REQUEST['session'];?>&section=<?php echo $_GET['section'];?>&fee=<?php echo $_GET['fee'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1" target="_blank" >Single Vouchers</a> </li>



                  <li><a href="print_all_vouchers_DB_onePage.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&year=<?php echo $_REQUEST['year'];?>&session=<?php echo $_REQUEST['session'];?>&section=<?php echo $_GET['section'];?>&fee=<?php echo $_GET['fee'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1" target="_blank" >OnePaege DB Vouchers </a> </li>



                  <li><a href="print_all_vouchers_single_two_std_per_pg.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&year=<?php echo $_REQUEST['year'];?>&session=<?php echo $_REQUEST['session'];?>&section=<?php echo $_GET['section'];?>&fee=<?php echo $_GET['fee'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1" target="_blank" >One Page Double Students </a> </li>



           

                  <li><a href="print_all_vouchers_db.php?a61oea61oe8lqc1oclfi4llgnioo156&amp;class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&year=<?php echo $_REQUEST['year'];?>&session=<?php echo $_REQUEST['session'];?>&section=<?php echo $_GET['section'];?>&fee=<?php echo $_GET['fee'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1" target="_blank" 

                 >Double Vouchers</a> </li>



           		   <?php 



		$page;



		if($brid[0]['triple_all_voucher']!=NULL){

			$page=$brid[0]['triple_all_voucher'];

		}else{

			$page="print_all_voucheres.php";	

		}



		?>

                  <li><a href="<?php echo $page;?>?a61oe8i4llgnioo156a61oa61oe8lqc1oclfi4llgnioo156&amp;class_id=<?php echo $_REQUEST['class_id'];?>&month=<?php echo $_REQUEST['month'];?>&year=<?php echo $_REQUEST['year'];?>&session=<?php echo $_REQUEST['session'];?>&section=<?php echo $_GET['section'];?>&fee=<?php echo $_GET['fee'];?>&8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1"  target="_blank">Triple Vouchers</a> </li>



                    </ul>

              </div>



      &nbsp;&nbsp;&nbsp;&nbsp;



 





</div>







          </span><div class="clearfix"></div> </div>

          <div class="panel-body">

          

            <div class="col-md-12" id="advanceSearch" style="">

             <div class="col-md-3 col-xs-12" style="padding: 8px;">

                <div class="form-group ">

                  <label class="required">Class</label>

 

                  <select name="class_id" class="form-control" onChange="getsec(this.value)" required >

                    <option value="">Select Class</option>



                    <?php

                    $m->where("branch_id", $_SESSION['branch']);

                    $WorkAssignList = $m->get("edu_class_config");

                    foreach($WorkAssignList as $WorkAssignListVal)

                    { ?>



                       <option <?php if($_REQUEST['class_id']==$WorkAssignListVal['class_id']){echo 'selected';}?> value="<?php echo $WorkAssignListVal['class_id']; ?>"><?php echo $WorkAssignListVal['Class_Name']; ?></option>





                            <?php

                    } ?>



                </select> 

                </div>

              </div>

              

              

            

              <div class="col-md-2 col-xs-12" style="padding: 8px;">

                <div class="form-group ">

                  <label class="required">Section</label>

                    <select name="section" id="txt_section" class="form-control"   >

                      <option value="All">All</option>

                   <?php

                              if(isset($_REQUEST['section']))

                              { 



                              $m->where("class_id", $_REQUEST['class_id']);    



                              $secondLevel = $m->get("edu_adm_section_detail");

                              

                              foreach($secondLevel as $secondLevel_val)

                              {

                              

                               ?>

                                <option <?php if($_REQUEST['section']==$secondLevel_val['section_id']){echo "selected";} ?> value="<?php echo $secondLevel_val['section_id']; ?>"><?php echo trim(utf8_encode_all($secondLevel_val['section_name'])); ?></option>



                              <?php }   ?>

                                

                          <?php } ?>



                    </select>



                  

                </div>

              </div>         

              

              <div class="col-md-2 col-xs-12" style="padding: 8px;">

                <div class="form-group ">

                  <label class="required">Year</label>

                  <select name="year" class="form-control">

                    <option value="All">All</option>

                    <?php

                    $match;

                    if(!isset($_REQUEST['year'])){

                      $match=date("Y");

                    }else { $match=$_REQUEST['year']; }

                    for($i=2018;$i<2031;$i++){ ?> 

                      <option <?php if($match==$i){echo 'selected';}?> value="<?php echo $i; ?>"><?php echo $i; ?></option>

                    <?php } ?>  

                  </select>

                </div>

              </div>





                 <div class="col-md-2 col-xs-12" style="padding: 8px;">



             <div class="form-group ">



                <label class="required">Challan Month</label>

                    <select name="month" id="month" class="form-control"  required>



                              <option value="">Select Month</option>

                        



                        <?php

                        $WorkAssignList = $m->get("eduportal_month_config");

                        foreach($WorkAssignList as $WorkAssignListVal)

                        { ?>



                           <option <?php if($_REQUEST['month']==$WorkAssignListVal['Month_Id']){echo 'selected';}?> value="<?php echo $WorkAssignListVal['Month_Id']; ?>"><?php echo $WorkAssignListVal['Month_Name']; ?></option>





                                <?php

                        } ?>



                    </select>

                </div>





        </div> 





        <div class="col-md-2 col-xs-12" style="padding: 8px;">



                       <div class="form-group ">



                          <label class="required">Fee Status</label>

                              <select name="fee" onChange="HideDate(this.value);" class="form-control"  >



                                <option value="All">All</option>

                          

                                <option <?php if($_GET['fee']=="1"){echo 'selected';}?> value='1'>PAID</option>

                                <option <?php if($_GET['fee']=="0"){echo 'selected';}?> value='0'>UNPAID</option>

                          



                                  

                              </select>

                            </div>





                    </div>

        

        

    

              <div class="col-md-1 pull-right" style="padding:2px;">

                <div class="form-group ">

                   <input type="hidden" name="addaccountAdmin" value="1">

                <button type="submit" class="btn btn-primary" style="margin-top: 28px;float: right;">Search</button>

                </div>

              </div>



             

            </div>

            <div class="clearfix"></div>

          </div>

        </div>

      </form>

      <div class="clearfix"></div>

    </div>





 <?php  if(!isset($_REQUEST['class_id'])){?>



        <div class="col-md-12">



          

           <div id="check_std_msg" style="color:white;font-size:18px;" class="alert alert-danger alert-dismissible">

                    <a href="#" class="close" data-dismiss="alert" aria-label="close">×</a>

                     <strong>Warning!</strong> Please select class & session from advance search to view challan !!!

            </div>

    



        </div>



  <?php   }?>





   <?php  if(isset($_SESSION['upsuccess'])){?>





            <div class="alert alert-success" id="msg">

             <a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a>

              <strong>Success!</strong> Fee challan is paid successfully...

            </div>





          <?php  unset($_SESSION['upsuccess']); }?>  



<?php  if(isset($_SESSION['msg_not_sent'])){?>



<div class="alert alert-danger" id="msg">

 <a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a>

  <strong>Warning!</strong> You can't send this SMS because your SMS Limit has been Exceed. Remaining SMS: <?php echo $sms_credit-$total_sms_monthly_used;?>

</div>





<?php  unset($_SESSION['msg_not_sent']);

}?>   

  

  <form class="form-style-7" action="<?php echo DOMAIN.AgentDirectory;?>parent/InsertMe.php" method="post" enctype="multipart/form-data">



  

      <input type="hidden" name="action_call" value="SendFeeNotifications"  />

      <input type="hidden" name="session"  value="<?php echo $_REQUEST['session']; ?>" >

      <input type="hidden" name="class" value="<?php echo $_REQUEST['class_id']; ?>" >

      <input type="hidden" name="section" value="<?php echo $_REQUEST['section']; ?>" >

      <input type="hidden" name="month_name" value="<?php echo getMonthName($m,$_REQUEST['month']); ?>" >

      <input type="hidden" name="month" value="<?php echo $_REQUEST['month']; ?>" >

      <input type="hidden" name="sms_left" value="<?php echo $sms_credit-$total_sms_monthly_used;?>">

      

    <?php if(count($WorkAssignListings)>0 && $_GET['section']){  ?>



        

            <div class="col-md-6 pull-right " style="margin-bottom:1%;">



             <input type="submit" name="submit" 

             class="btn btn-primary pull-right"  value="Send Fee SMS to Selected"  />

                         

             <input type="submit" name="defaulter" 

             class="btn btn-primary pull-right"  value="Send Fee Defaulter SMS to Selected"  />            

        

           <!-- <a href="#" class="btn btn-primary pull-right" onClick="checkboxes();"> Send Custom SMS To Selected </a> -->



              </div>

      <?php  } ?>    

             



       



    <table id="listofstudents" data-page-length='100' class="table table-striped table-bordered" style="width:100%;background-color:#FFFFFF;">

          

          <thead>

            <tr>

                

                <th width="5%">S.No</th>

                <th width="15%">Student / Father Name</th>

                <th width="8%">Roll / Adm#</th>

                <th width="8%" style="text-align:center;"> Monthly Fee </th>

                <th width="8%"> Arrears </th>

               <!--  <th width="8%" style="text-align:center;"> Transport </th>

                <th width="5%" style="text-align:center;"> <?php if ($brid[0]['misc_title']!=NULL){echo $brid[0]['misc_title'];}else {echo 'Misc.';} ?> </th>

                

                <th width="8%"> Arrears </th>

                <th width="8%"> Other Fee </th>

                <th width="8%"> Disc. </th> -->

                <th width="10%">Total </th>

                <th width="10%">Print </th>

                <th width="8%"> Status </th>

                <th width="5%">



              <label class="container1"><input  type="checkbox" id="checkAll"/><span class="checkmark" style="margin-top: -17px;"></span></label>

              

               </th>





            </tr>

        </thead>

        <tbody>

   

     

     <?php 



      $sr=1;

      foreach($WorkAssignListings as $WorkAssignListVal)

      { 



   		 // getting students details 



         

          $m->where("student_id", $WorkAssignListVal['student_id']);

          $m->where("status", 0);

          $student=$m->get("edu_student_details");

          

           

      if($student[0]['section_id']!=$_GET['section'] && $_GET['section']!='' && $_GET['section']!='All' ){

		      continue;

		   }



        if(count($student)==0){

          continue;

        }



      $totalTutionFee+=$WorkAssignListVal['tutionfee'];

      $totalBalance+=$WorkAssignListVal['balance'];



      ?>



      <tr>

       

        <td style="text-align: center;"><?php echo $sr; $sr++;?></td>



        <td>  

  

         <a target="_blank" href="pay_fee.php?ss=l97tl259rv1us7o8eu9bsen3t3l97tl259rv1us7o8eu9bsen3t3l97tl259rv1us7o8eu9bsen3t3l97tl259rv1us7o8eu9bsen3t3l97tl259rv1us7o8eu9bsen3t3&student=<?php echo $WorkAssignListVal['student_id'];?>&session=<?php echo $_SESSION['current_session'];?>"><?php echo $student[0]['first_name']." / ".$student[0]['last_name'];?>  </a>



         </td>



          <td> <?php echo $student[0]['candidate_roll_no']. " / ".$student[0]['ref_no'] ;?> </td>

      

          <td> <?php echo $WorkAssignListVal['tutionfee'];?> </td>



          <td style="text-align:center;"> 



          <a href="pay_fee.php?<?php echo session_id().session_id().session_id().session_id(); ?>&student=<?php echo $WorkAssignListVal['student_id']; ?>" target="_blank" style="padding: 0px 4px; font-size:14px;"  class="btn btn-warning">



                  <?php echo $WorkAssignListVal['balance'];





                  ?>  



                </a> 





           </td>



          <!-- <td> <?php echo $WorkAssignListVal['transportfee'];?> </td> 

          <td> <?php echo $WorkAssignListVal['misc_fee'];?> </td> 



          -->



     

      <!--  <td style="text-align:center;"> 





        <a data-toggle="modal" data-target="#otherFee<?php echo $WorkAssignListVal['student_id'];?>" style="padding: 0px 4px; font-size:14px;"  class="btn btn-warning">



        <?php echo 0+getFeeAllOtherFee($student[0]['student_id'],$WorkAssignListVal['challan_id'],$m);?>  



      </a> 





      

      <div id="otherFee<?php echo $WorkAssignListVal['student_id'];?>" class="modal fade" role="dialog">

        <div class="modal-dialog">



          

          <div class="modal-content" style="width: 900px;margin-left: -25%;">

            <div class="modal-header">

              <button type="button" class="close" data-dismiss="modal">&times;</button>

              <h4 class="modal-title"> Other Fee Parameters  </h4>

            </div>





            <div class="modal-body">







              <p> <?php echo $student[0]['first_name'];?>  <?php echo $student[0]['last_name'];?>  </b>

                (<?php echo getClassName($m,$_GET['class_id']);?>)



              </p>





            </div>





          <br>

          <div class="col-md-12" >

            



            <table border="1" width="100%">  





              <tr>  



                <th class="thStyle" style="text-align: center;padding:1%;"> Fee Type  </th>

                <th class="thStyle" style="text-align: center;padding:1%;"> Amount  </th>

              

              </tr>

<?php 



 $fee_types = $m->get("eduportal_fee_types"); 



if(count($fee_types)<=0){

  echo "<tr> <td colspan='10' style='color:red;text-align:center;'> No record found ! </td> </tr> ";



}



 foreach ($fee_types as $type) {



  $fee=getFeeOfOtherParameter($student[0]['student_id'],$details['challan_id'],$type['feetype_id'],$m);

  if($fee==NULL){

    continue;

  }



?>            

              <tr>  



                <td> <?php echo $type['feetype_name'];?> </td> 

                <td> <?php echo $fee;?> </td> 

                

              </tr>



<?php   } ?>



          

 

             </table>



          </div>



          <br><br>





            <div class="modal-footer">



             <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>





            </div>







          </div>



        </div>

      </div>



     







               </td> -->



                <!-- <td style="text-align:center;"> 

                <?php  echo $WorkAssignListVal['disc_amount']; ?>  

                 </td> -->





              <td style="text-align:center;"> <?php $totalAmount= $WorkAssignListVal['tutionfee']+$WorkAssignListVal['transportfee']+$WorkAssignListVal['balance']+$WorkAssignListVal['misc_fee']+getFeeAllOtherFee($student[0]['student_id'],$WorkAssignListVal['challan_id'],$m); 



               echo $totalAmount-$WorkAssignListVal['disc_amount']; 



               $allTotalAmount+=$totalAmount-$WorkAssignListVal['disc_amount'];



     if($totalAmount!=0){

 

              ?> 





                <input type="hidden" name="std_name<?php echo $WorkAssignListVal['student_id'];?>" value="<?php echo $student[0]['first_name']; ?>" />

                <input type="hidden" name="balance<?php echo $WorkAssignListVal['student_id'];?>" value="<?php echo $WorkAssignListVal['balance']; ?>" />

                <input type="hidden" name="total_fee<?php echo $WorkAssignListVal['student_id'];?>" value="<?php echo $totalAmount-$WorkAssignListVal['disc_amount']; ?>" />

                <input type="hidden" name="duedate<?php echo $WorkAssignListVal['student_id'];?>" value="<?php echo date("d-M",strtotime($WorkAssignListVal['challan_duedate'])); ?>" />

                <input type="hidden" name="numbers<?php echo $WorkAssignListVal['student_id'];?>" value="<?php echo $student[0]['cell_no']; ?>" />



    <?php } ?>



                  </td>



                  <td>



  <div class="btn-group">

    <button data-toggle="dropdown" class="btn btn-warning dropdown-toggle btn-sm" type="button" aria-expanded="true">Print <span class="caret"></span>

    </button>

    <ul role="menu" class="dropdown-menu">

       <?php



    $page;



    if($brid[0]['triple_single_voucher']!=NULL){

      $page=$brid[0]['triple_single_voucher'];

    }else{

      $page="print_voucher.php";

    }



    ?>





            <li><a href="print_single_voucher.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;student_id=<?php echo $WorkAssignListVal['student_id'];?>&year=<?php echo $_REQUEST['year']; ?>&month_id=<?php echo $_REQUEST['month'];?>" target="_blank">Single Voucher</a></li>



            <li><a href="print_double_voucher.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;student_id=<?php echo $WorkAssignListVal['student_id'];?>&year=<?php echo $_REQUEST['year']; ?>&month_id=<?php echo $_REQUEST['month'];?>" target="_blank">Double Voucher</a></li>



            <li><a href="<?php echo $page;?>?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;student_id=<?php echo $WorkAssignListVal['student_id'];?>&year=<?php echo $_REQUEST['year'];?>&month=<?php echo $month[0]['Month_Name'];?>&month_id=<?php echo $_REQUEST['month'];?>" target="_blank">Triple Voucher</a></li>



            <!-- <li><a href="print_single_family_profile_voucher.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;student_id=<?php echo $WorkAssignListVal[0]['student_id'];?>&month=<?php echo $month[0]['Month_Name'];?>&month_id=<?php echo $month[0]['Month_Id'];?>&year=<?php echo $_REQUEST['year']; ?>&familyCode=<?php echo $WorkAssignListVal[0]['cell_no'];?>&familyName=<?php echo $WorkAssignListVal[0]['last_name'];?>" target="_blank">Single Family Voucher</a></li> -->



            <!-- <li><a href="print_family_profile_voucher_db.php?a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156a61oe8lqc1oclfi4llgnioo156&amp;student_id=<?php echo $WorkAssignListVal['student_id'];?>&month=<?php echo $month[0]['Month_Name'];?>&month_id=<?php echo $_REQUEST['month'];?>&session=<?php echo $_REQUEST['session']; ?>&familyCode=<?php echo $WorkAssignListVal['cell_no'];?>&familyName=<?php echo $WorkAssignListVal['last_name'];?>" target="_blank">Double Family Voucher</a></li> -->





                      </ul>

                </div>



                  </td>





                  

          <td> 



   <!-- <?php echo $totalAmount; ?> -->  



      <?php if($WorkAssignListVal['paid_status']==0 || $WorkAssignListVal['paid_status']=="0"){ ?>    





          <a data-toggle="modal" data-target="#payChallan2222<?php echo $WorkAssignListVal['student_id'];?>" style="padding: 0px 5px; font-size:14px;" href="#" class="btn btn-danger">



                  Unpaid

                  

            </a> 



         <?php } elseif($totalAmount<"0" || $totalAmount<0) 



           {



            ?>    





          <a data-toggle="modal" style="padding: 0px 5px; font-size:14px;"  class="btn btn-success">



                  Paid <i class="fa fa-check" aria-hidden="true"></i>



                  </a> 





         <?php } elseif($WorkAssignListVal['paid_status']==1 || $WorkAssignListVal['paid_status']=="1") { ?>



          <a data-toggle="modal" style="padding: 0px 5px; font-size:14px;"  class="btn btn-success">



                  Paid <i class="fa fa-check" aria-hidden="true"></i>



                  </a>



        <?php } ?>   



                  </td>





            <td style="padding: 2px;">

              <label class="container1">

                <input type="checkbox" name="students[]" value="<?php echo $WorkAssignListVal['student_id'];?>"><span class="checkmark"></span>

              </label>



            </td>



              </tr>



              <?php

      } ?>



        <tr style="background-color: lightgray;color: black;">

          <td colspan="3" style="text-align: center;">Total</td>

          <td><?php echo $totalTutionFee;?></td>

          <td style="text-align: center;"><?php echo $totalBalance;?></td>

          <td style="text-align: center;"><?php echo $allTotalAmount;?></td>

          <td colspan="3"></td>

        </tr>



        </tbody>

        

    </table>





 </form>











        </div> 

        </div>





            </div>

          </div>

        </div>

        <!-- /page content -->



    <?php include('RootMe/js_linksscript.php');?>



  <script src="https://cdn.datatables.net/1.10.13/js/jquery.dataTables.min.js"></script>

    <script>

        $(document).ready(function() {

        $('#listofstudents').DataTable();

        $("th").removeClass("sorting");

        } 

        );



      $("#checkAll").change(function () {



      $("input:checkbox").prop('checked', $(this).prop("checked"));

      });

    </script>

  </body>

</html>

