


  <div class="container-fluid">
 <div class="row">


  <div class="col-md-12">
   
		 <div class="col-md-8">
 <?php	$session_data = $this->session->userdata('logged_in');
 $data['usertype'] = $session_data['usertype'];
	 $usertype = $data['usertype'];	
	
$data['surname'] = $session_data['surname'];
$data['id'] = $session_data['id'];
 $data['companyid'] = $session_data['companyid'];
	 $companyid = $data['companyid'];
$surname=$data['surname'];
   $userid=$data['id'];
  
	  echo $this->session->flashdata('msg'); 

	 
       		$configuration = $this->usermodel->populateallarray('smsconfig','id',$companyid);
			$paybill=	$configuration [0]["address"];
   			$contact2=	$configuration [0]["contact2"];
   			$description=	$configuration [0]["description"];
   			$paymenttypes=	$configuration [0]["paymenttypes"];

			
			   $transfersms=$this->usermodel->populatuserpermissionsdataarray('sendsms','transfersms',$userid);
			
			
			
			
			
			
			
   
   ?>
 

		
		
		
		
		   <div class="panel panel-primary" data-collapsed="0">
        	<div class="panel-heading">
            	<div class="panel-title"  id="redcolor">
            		<i class="entypo-plus-circled"></i>
				Payment  Details .
            	</div>
            </div>
			<div class="panel-body">
			
			
										 <a href="<?php echo base_url(). "user/viewsms"; ?>" class="btn btn-info">Go to sms window</a>
										 
										 
										 
		
								 <?php
				 if($transfersms==true){
					 ?>
													 <a href="<?php echo base_url(). "user/transfersms"; ?>" class="btn btn-success">Transfer sms</a>

					
						<?php
						}
				  ?>




									
				<table class="tablesorter table table-bordered  table-hover" id="sortable_table">			

             <thead>
			 <tr>
    
     <th colspan="5"><CENTER>RECHARGE HISTORY</CENTER></th>
	
	

                 </tr>
         <tr>
         <th>SMS Units</th>

     <th>Amount</th>
	      <th>Rate</th>
		  	    <th>Bal Before</th>

	    <th>Bal After</th>
	 <th>Date</th>
	     <th>Code</th>
		 <th>Description</th>
	 	
	

                 </tr>
             </thead>
<?php

 if(!is_array($viewrecharging)) 

 {


   echo "<tr  style='margin-bottom:0px;margin-top:0px;' '>";
      echo "<td colspan='8'>";
    
       echo '<div class="alert alert-warning text-center">There is no recharge history found. You can only see history from 1/11/2018</div>';
    echo "</td>";
   echo "</tr>";
    }else {
?>
    
             <?php 
  
  	foreach ($viewrecharging as $c): 

		 

             ?>



             <tr>
                
            <?php 
			$id=$c->id;


?>

              
  <td><?php echo $c->units ; ?></td>

  <td><?php echo $c->amount ; ?></td>
    <td><?php echo $c->rate ; ?></td>
	    <td><?php echo $c->balancebefore ; ?></td>

    <td><?php echo $c->balance ; ?></td>
  <td><?php echo $c->dateposted ; ?></td>
     <td><?php echo $c->code ; ?></td>
  
      <td><?php echo $c->description ; ?></td>
  


             </tr>

	<?php endforeach;} ?>

          
        </table>
 <div class="row">
        <div class="col-md-12 text-center">   <?php echo $links; ?>
					   		<span style="color:red; font-size:20px"><?php  echo $total_rows. " Total  Transactions(20 Maximum per page). " ;?>    </span>

         
        </div>
    </div>
			
			

   
   </div>
		

			
		
  
</div>

</div>
	 <div class="col-md-4">
	 <div class="panel panel-primary" data-collapsed="0">
        	<div class="panel-heading">
            	<div class="panel-title"  id="redcolor">
            		<i class="entypo-plus-circled"></i>
				Payment Procedure
            	</div>
            </div>
			<div class="panel-body">

			Pay the Recharge amount through our MPESA paybill Number as explained below:<br><br>
1.Access the M-PESA menu from your phone,<br>
2.Select "Lipa Na M-PESA" option,<br>
3.Select Pay Bill option,<br>
4.Enter the Business Number:<span style="color:blue">  <?php echo  $paybill;  ?>  </span><br>
5.Enter this  account Number: <span style="color:blue"> 1171211120<?php   $userid;  ?></span> <br>
6.Foward us the the transaction code to any of these numbers: <?php echo  $contact2;  ?></span>  

<br>
<br>

	  <?PHP
	
 $myurl= base_url();



 echo $this->session->flashdata('msg'); 
                  echo form_open('https://bulksmschapchap.com/getpaymentcode' , array('class' => 'form-horizontal form-groups-bordered validate', 'target' => '_blank', 'id' => 'signup','enctype' => 'multipart/form-data'));
                 //echo form_open('https://www.bulksmschapchap.com/getpaymentcode' , array('class' => 'form-horizontal form-groups-bordered validate', 'target' => '_blank', 'id' => 'signup','enctype' => 'multipart/form-data'));

		 if(validation_errors()):?>

<?php endif;?>

				<input type="hidden" name="userid" value="<?php echo $userid; ?>"id="code" class="form-control" required placeholder="userid">

				<input type="hidden" name="companyid" value="<?php echo $companyid; ?>"id="code" class="form-control" required placeholder="userid">
  <div class="form-group">
    <label for="inputcode" class="col-sm-4 col-lg-2 col-md-2 col-xs-4 control-label"> Payment Code</label>
    <div class="col-sm-10">
				<input type="text" name="code" value="<?php if(isset($_GET['code'])) {echo $_GET['code']; }?>"id="code" class="form-control" required placeholder="Enter Mpesa Transdaction Code">
    <span class="text-danger"> Transdaction Code<?php echo form_error('code'); ?></span>
   </div>
  </div>
  
   <div class="form-group">
    <label for="inputphone" class="col-sm-4 col-lg-2 col-md-2 col-xs-4 control-label"> Phone</label>
    <div class="col-sm-10">
				<input type="text" name="phone" value="<?php if(isset($_GET['phone'])) {echo $_GET['phone']; }?>"  id="phone" class="form-control" required placeholder="Enter phone number">
    <span class="text-danger">Enter phone used to pay eg.g 2547xxxxx...<?php echo form_error('phone'); ?></span>
   </div>
  </div>
 								<input type="hidden" name="myurl" value="<?php if(isset($myurl)) {echo $myurl; }?>"id="code" class="form-control" required placeholder="userid">

	
	 <div class="form-group">

    <div class="col-sm-offset-2 col-sm-10">

	
	         <button type="submit"  value="payment" name="btn_postconfirmpayment" class="btn btn-primary"> Recharge Now   </button>

    </div>
  </div>
  					<?php echo form_close();?>
			</div>							   

									
							
								
			<div class="modal-footer">

    

				</div>

		</div>
	  			
<br>
<U style="color:blue">CORPORATE ACCOUNT PRICING</U><br>
1. Ksh.1 to Ksh.4,999=Ksh.1 per sms.<br>
2. Ksh.5,000 and above=Ksh.0.8 per sms.<br>
3.51,000-100,000 Ksh= 0.7 Ksh per SMS.<br>
4.101,000Ksh and Above.= 0.6 Ksh per SMS.<br>
<p>
</p>
<U>FREE ACCOUNT PRICING</U><br>
<?php echo  $paymenttypes;  ?>
<p>
Branding cost (Registering Business Name/ Sender ID)= KSHS. 8,000 per network.
</p>





	<P>
			
			<br><strong>The Bulk SMS  can be branded with your bussiness name e.g 'KCB, KPLC,SAFARICOM, AIRTEL, JKUAT, ROBISEARCH, REDCROSS, ORANGE, IEBC, KU, KENYA-HIGH, MASENO-SCHOOL, JUBILEE, ODM ' e.t.c.</strong>
</P>


<p class="text-center">







</strong>

<p>
Feel free to contact us: 0790962631/0716413386/0780655987<br>

</p>
 </div>	
</div>
 </div>	
</div>