<?php
require_once("../app/config.php");
$id=$_GET['id'];
$transx= mysqli_fetch_array(mysqli_query($dbc, "SELECT * FROM deposits WHERE trx='$id'"));
$gate=mysqli_fetch_array(mysqli_query($dbc,"SELECT * FROM gateways WHERE id='".$transx['gateway_id']."'"));
$title='Deposit Preview';
$pay=$transx['charge']+$transx['amount'];
require_once('include/user_header.php');
require_once('include/user_navbar.php');
require_once('include/user_sidebar.php');
?>
<div class="content-wrapper">

      <!-- Page header -->
      <div class="page-header page-header-light">
        <div class="page-header-content header-elements-md-inline">
        </div>
      </div>
<div class="content">
  <div class="row">
    <div class="col-lg-12">
      <div class="card bg-<?php echo $set['dashboard_color'];?>">
        <div class="card-body">
          <div class="d-sm-flex align-item-sm-center flex-sm-nowrap">
            <div>
              <h6 class="font-weight-semibold"><?php echo $gate['main_name'];?></h6>
              <ul class="list list-unstyled mb-0">
                <li>Amount: <span class="font-weight-semibold"><?php echo $scan2['currency'].$transx['amount'];?></span></li>
                <li>Charge: <span class="font-weight-semibold"><?php echo $scan2['currency'].$transx['charge'];?></span></li>
                <li>Payable: <span class="font-weight-semibold"><?php echo $scan2['currency'].$pay;?></span></li>
                <li>In <?php echo $scan2['currency'];?>: <span class="font-weight-semibold"><?php echo $scan2['currency'].$transx['usd'];?></span></li>
              </ul>
            </div>

            <div class="text-sm-right mb-0 mt-3 mt-sm-0 ml-auto">
              <ul class="list list-unstyled mb-0">
                <li>Status: <span class="badge bg-danger-400 font-weight-semibold">UNPAID</span></li>
              </ul>
            </div>
          </div>
        </div>

        <div class="card-footer d-sm-flex justify-content-sm-between align-items-sm-center">
          <span>
            <span class="badge badge-mark border-white mr-2"></span>
            transxaction ID:
            <span class="font-weight-semibold">#<?php echo $id;?></span>
          </span>
            <ul class="list-inline list-inline-condensed mb-0 mt-2 mt-sm-0">
                <li class="list-inline-item">
                <form action="../app/payment?id=depositconfirm" method="post">
                  <input type="hidden" name="trx" value="<?php echo $id;?>">
                  <button type="submit" class="btn bg-white">Pay now</button>
                </form>
              </div>
              </li>
            </ul>
        </div>
      </div>
    </div>
  </div>
<?php require_once("include/user_footer.php"); ?>