<section class="w3l-courses cart-page py-2">
    <div class="blog pb-5" id="courses">
        <div class="container py-lg-5 py-md-4">
            <div class="alert alert-success alert-block">
<?php $pendi = mysqli_query($conn, "SELECT * FROM aalierp_deposit WHERE user_id='".$_SESSION["user_id"]."' AND dep_status='Pending'");
      if(mysqli_num_rows($pendi) > 0){
       		while($rew=mysqli_fetch_array($pendi)){ ?>
              	<?php echo "You deposited <b>".$cur."".$rew["dep_amount"]."</b> for <b>".$rew["dep_reason"]."</b> is awaiting for approval."; ?>
      		<?php } ?>   
<?php }else{ ?>
              <b>Deposit Amount</b> to get your product..!
<?php } ?>              
            </div>
            <div class='row mb-2'>
<?php $depo = mysqli_query($conn, "SELECT * FROM aalierp_gateway"); while($dep = mysqli_fetch_array($depo)){ ?>
              	<div class="col-md-4">
    				<div class="card shadow-lg">
                  		<div class="card-body p-2">
							<h5 class="py-1"><?php echo $dep["gate_title"]; ?></h5>
                    		<p class="py-1" style="font-size: 0.7em;"><i id="myAddress"><?php echo $dep["gate_acc"]; ?></i> <button onclick="myFunction();" class="ml-2"><i class="fa fa-copy" ></i></button></p>
                    		<a href="<?php echo $dep["gate_url"]; ?>" target="_blank" class="btn btn-warning btn-sm btn-flat py-1"><?php echo $dep["gate_name"]; ?></a>
                    		<a href="<?php echo $AaliLINK; ?>/deposit" class="btn btn-success btn-sm btn-flat py-1">Add Deposit Slip</a>
						</div>
                  	</div>
                </div>
<?php } ?>
            </div>
            <div class='row mb-2'>
                <div class="col-md-3">
                    <div class="card" style="border: 2px solid #E25A00;">
                        <div class="card-body">
                            <h5 class="text-center" style='color: #E25A00;'>
                                <?php echo $_SESSION["user_name"]; ?> (<?php echo $_SESSION["user_type"]; ?>)
                            </h5>
                            <h6 class="text-center"><?php echo $_SESSION["user_mobile"]; ?></h6>
                            <h6 class="text-center "><?php echo $_SESSION["user_email"]; ?></h6>
                            <h6 class="text-center"><a href="<?php echo $AaliLINK; ?>/profile/update" class="badge badge-success">Update Profile</a></h6>
                        </div>
                    </div>
                </div>
                <div class="col-md-3">
                    <div class="card" style="border: 2px solid #E25A00;">
                        <div class="card-body">
                            <h5 class="text-center" style='color: #E25A00;'>Deposit History</h5>
                            <h2 class="text-center deposit"></h2>
                            <h6 class="text-center"><a href="<?php echo $AaliLINK; ?>/deposit" class="badge badge-success">Deposit History</a></h6>
                        </div>
                    </div>
                </div>
                <div class="col-md-3">
                    <div class="card" style="border: 2px solid #E25A00;">
                        <div class="card-body">
                            <h5 class="text-center" style='color: #E25A00;'>Orders Completed</h5>
                            <h2 class="text-center processed"></h2>
                            <h6 class="text-center">Amount Spent: <b class="deposit"></b></h6>
                        </div>
                    </div>
                </div>
                <div class="col-md-3">
                    <div class="card" style="border: 2px solid #E25A00;">
                        <div class="card-body">
                            <h5 class="text-center" style='color: #E25A00;'>Orders Processing</h5>
                            <h2 class="text-center processing"></h2>
                            <h6 class="text-center">Amount To Be Spent: <b>$0.00</b></h6>
                        </div>
                    </div>
                </div>
            </div>
            <?php 
          		$cartt = mysqli_query($conn, "SELECT COUNT(*) AS count_order FROM aalierp_cart WHERE user_id='' AND status='Processing'"); 
                $rr = mysqli_fetch_assoc($cartt);
          		if($rr["count_order"] > 0){
          	?>
            	<div class='row get_order_cart'></div>
            <?php } ?>
            <div class='row get_ordered_cart'></div>
        </div>
    </div>
</section>