Your IP : 52.14.234.146


Current Path : /home/lentoinv/blossomfoodint.com/account/
Upload File :
Current File : //home/lentoinv/blossomfoodint.com/account/dashboard.php

<?php
session_start(); ob_start();
?>
<!doctype html>
	<html lang="en">
 
	<head>
		<!-- Required meta tags -->
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<!--favicon-->
		<link rel="icon" href="assets/images/favicon-32x32.png" type="image/png" />
		<!--plugins-->
		<link href="assets/plugins/simplebar/css/simplebar.css" rel="stylesheet" />
		<link href="assets/plugins/perfect-scrollbar/css/perfect-scrollbar.css" rel="stylesheet" />
		<link href="assets/plugins/highcharts/css/highcharts.css" rel="stylesheet" />
		<link href="assets/plugins/vectormap/jquery-jvectormap-2.0.2.css" rel="stylesheet" />
		<link href="assets/plugins/metismenu/css/metisMenu.min.css" rel="stylesheet" />
		<link href="assets/plugins/datatable/css/dataTables.bootstrap5.min.css" rel="stylesheet" />
		<!-- loader-->
		<link href="treestyle.css" rel="stylesheet">
		<link href="assets/css/pace.min.css" rel="stylesheet" />
		<script src="assets/js/pace.min.js"></script>
		<!-- Bootstrap CSS -->
		<link href="assets/css/bootstrap.min.css" rel="stylesheet">
		<link href="assets/css/bootstrap-extended.css" rel="stylesheet">
		<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;500&display=swap" rel="stylesheet">
		<link href="assets/css/app.css" rel="stylesheet">
		<!-- <link rel="stylesheet" href="assets/css/style3.css"> -->
		<link href="assets/css/icons.css" rel="stylesheet">
		
		<!-- Theme Style CSS -->
		<link rel="stylesheet" href="assets/css/dark-theme.css" />
<!-- 		<link rel="stylesheet" href="assets/css/semi-dark.css" />
		<link rel="stylesheet" href="assets/css/header-colors.css" /> -->
		<title>Overview</title>
		<style type="text/css">
			.col .card{border: solid 3px green; }
		</style>
	</head>

	<body>
		<!--wrapper-->
		<div class="wrapper">
			
			<?php include('nav.php');

			if($uidx!=1){header('location: ./'); } ?>
			<!--start page wrapper -->
			<div class="page-wrapper">
				<div class="page-content">
					
					<div class="row row-cols-1 row-cols-lg-2 row-cols-xl-4">
						<div class="col">
							<div class="card bg-light">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0">Total Users</p>
											<h4 class="my-1"><?= number_format(sqL('user')) ?></h4><br>
										</div>
										<!-- <div class="ms-auto font-35"><i class='bx bx-user-pin'></i>
										</div> -->
									</div>
								</div>
							</div>
						</div>
						<div class="col">
							<div class="card bg-light">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0">Total Revenue</p>
											<h4 class="my-1">₦<?php $r = sqL('user')*63000; echo number_format($r) ?> <br><small class="text-success">100%</small></h4>
										</div>
										<!-- <div class="ms-auto font-35"><i class='bx bx-dollar'></i>
										</div> -->
									</div>
								</div>
							</div>
						</div>
						<?php $i=11; $v=0; while($i<=14){$e=$i++;  ?>
						<div class="col">
							<div class="card bg-light">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0"><?= $pro->walletRemark($e) ?></p>
											<h4 class="my-1">₦<?php $a = $pro->walletadmin($e); $v += $a; echo number_format($a) ?> <br><small class="text-success"><?php echo number_format(100*$a/$r,2) ?>%</small></h4>
										</div>
										<!-- <div class="ms-auto font-35"><i class='bx bx-dollar'></i>
										</div> -->
									</div>
								</div>
							</div>
						</div>
						<?php } ?>
					<div class="col">
							<div class="card bg-light ">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0">Total Payout</p>
											<h4 class="my-1">₦<?php
											echo number_format($v) ?>  <br><small class="text-success"><?php echo number_format(100*$v/$r,2) ?>%</small></h4>
										</div>
										<!-- <div class="ms-auto font-35"><i class='bx bx-dollar'></i>
										</div> -->
									</div>
								</div>
							</div>
						</div>

						<div class="col">
							<div class="card bg-light table-primary">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0">Balance</p>
											<h4 class="my-1">₦<?php $d = $r-$v; echo number_format($d) ?>  <br><small class="text-success"><?php echo number_format(100*$d/$r,2) ?>%</small></h4>
										</div>
										<!-- <div class="ms-auto font-35"><i class='bx bx-dollar'></i>
										</div> -->
									</div>
								</div>
							</div>
						</div>

						

					<!-- 	<div class="col">
							<div class="card bg-danger">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0 text-light">Pending Withdrawals</p>
											<h4 class="text-light my-1">₦<?php echo number_format(abs($pro->pendingWithd()),2) ?> | <?= $pro->pendingWithd(1) ?> </h4>
										</div>
										<div class="text-white ms-auto font-35"><i class='bx bx-dollar'></i>
										</div>
									</div>
								</div>
							</div>
						</div>
						<div class="col">
							<div class="card bg-danger">
								<div class="card-body">
									<div class="d-flex align-items-center">
										<div>
											<p class="mb-0 text-light">Withdrawal Charges</p>
											<h4 class="text-light my-1">₦<?php echo number_format(sqL1('wallet','type',4)*2.5,2) ?>  
										</h4>
									</div>
									<div class="text-white ms-auto font-35"><i class='bx bx-dollar'></i>
									</div>
								</div>
							</div>
						</div>
					</div> -->

				
			</div>



					<div class="card">
						<div class="card-body">
							<div class="card-title">
								<h5 class="mb-0">Recent Transactions</h5>
<?php //	$pro->processWallet('h2242f32',5000,5,6,'Cash'); ?>
							</div>
							<hr/>

							<div class="table-responsive mt-3">
								<table id="example" class="table table-bordered table-striped">
									<thead>
										<tr>
											<th>S/N</th>

											<th>Date</th>
											<th>Amount</th>

											<th>Type</th>

											<th>Remark</th>
											<th>Status</th>
											<th>User</th> 
										</tr>
									</thead>
									<tbody>
										<?php
										$i=1;
										$sql = $db->query("SELECT * FROM wallet ORDER BY sn DESC LIMIT 200 "); 
										while($row = $sql->fetch_assoc()) { $e = $i++;
											$type = $row['cos']>0 ? 'Credit' : 'Debit';
											?>
											<tr>
												<td><?php echo $e; ?></td>


												<td><?php echo date('d/m/y', $row['ctime']); ?></td>
												<td>₦<?php echo number_format(abs($row['cos']),2) ?></td>

												<td><?php echo $type; ?></td>
												<td><?php echo $row['remark']; ?> </td>
												<td><?php echo $pro->walletStatus($row['status']); ?> </td>

												<td><?php  echo userName($row['id']) ?> (<?php  echo userName($row['id'],'user') ?>)</td></tr>
											<?php } ?>
										</tbody>
									</table>
								</div>
							</div><!--end row-->

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

	
             </div>
         </div>
         <!--end page wrapper -->
         <?php include('foot.php') ?>

     </div>
     <!--end wrapper-->
     
     <!-- Bootstrap JS -->
     <script src="assets/js/bootstrap.bundle.min.js"></script>
     <!--plugins-->
     <script src="assets/js/jquery.min.js"></script>
     <script src="assets/plugins/simplebar/js/simplebar.min.js"></script>
     <script src="assets/plugins/metismenu/js/metisMenu.min.js"></script>
     <script src="assets/plugins/perfect-scrollbar/js/perfect-scrollbar.js"></script>
     <script src="assets/plugins/vectormap/jquery-jvectormap-2.0.2.min.js"></script>
     <script src="assets/plugins/vectormap/jquery-jvectormap-world-mill-en.js"></script>
     <script src="assets/plugins/highcharts/js/highcharts.js"></script>
     <script src="assets/plugins/highcharts/js/exporting.js"></script>
     <script src="assets/plugins/highcharts/js/variable-pie.js"></script>
     <script src="assets/plugins/highcharts/js/export-data.js"></script>
     <script src="assets/plugins/highcharts/js/accessibility.js"></script>
     <script src="assets/plugins/apexcharts-bundle/js/apexcharts.min.js"></script>
     <script src="assets/plugins/datatable/js/jquery.dataTables.min.js"></script>
     <script src="assets/plugins/datatable/js/dataTables.bootstrap5.min.js"></script>
     <script>
     	$(document).ready(function() {
     		$('#example').DataTable();
     	} );
     </script>
     <script src="assets/js/index2.js"></script>
     <!--app JS-->
     <script src="assets/js/app.js"></script>
     <script>
     	new PerfectScrollbar('.customers-list');
     	new PerfectScrollbar('.store-metrics');
     	new PerfectScrollbar('.product-list');
     </script>
 </body>

 </html>

?>