<?php
include 'header.php';
if($_SESSION['user_type']!='admin'){
	require 'permission.php';
	requireView('home');
}
?>
<div class="content-wrapper">

	<section class="content-header"><div class="container-fluid"></div></section>

	<section class="content">
		<div class="container-fluid">
			<div class="col-lg-12">
<?php
//print_r($_SESSION['permissions']['home']);
if (!empty($_SESSION['permissions']['service-followup']['view'])) {
?>
			<div class="card">
              <div class="card-header">
                <h3 class="card-title">Followup</h3>
              </div>
              <div class="card-body row">
<?php
if (!empty($_SESSION['permissions']['home']['other']['today_free_pending'])) {
				echo '<div class="col-md-6"><a href="service-followup?status=today_pending&type=free"><button type="button" class="btn btn-block btn-success btn-lg">Todays Free Pending</button></a></div>';
}
if (!empty($_SESSION['permissions']['home']['other']['today_paid_pending'])) {
				echo '<div class="col-md-6"><a href="service-followup?status=today_pending&type=paid"><button type="button" class="btn btn-block btn-primary btn-lg">Today Paid Pending</button></a></div>';
}
?>
              </div>
			  
			  <div class="card-body row">
<?php
if (!empty($_SESSION['permissions']['home']['other']['backdate_pending'])) {
				echo '<div class="col-md-6"><a href="service-followup?status=backdate_pending"><button type="button" class="btn btn-block btn-secondary btn-lg">Backdate Pending</button></a></div>';
}
if (!empty($_SESSION['permissions']['home']['other']['today_taken'])) {
				echo '<div class="col-md-6"><a href="service-followup?status=today_taken"><button type="button" class="btn btn-block btn-info btn-lg">Todays Taken</button></a></div>';
}
?>
				
			  </div>
            </div>
<?php } ?>			
          </div>
		</div>
	</section>

</div>

<?php
include 'footer.php';
?>
