<?php
$sitename = $this->settings_model->get('sitename');
$sitename = !empty($sitename) ? $sitename : "Company";
$amount = isset($transaction->aclbdtamount) ? $transaction->aclbdtamount : 0;
$amount += isset($transaction->aclgatewayfee) ? $transaction->aclgatewayfee : 0;
$amount = number_format($amount, 2, '.', '');
$referrer = getReferrerHome($transaction->redirecturl, $transaction->usertype);
?>
<!DOCTYPE HTML>
<html>
   <head>
        <title><?php echo $gateway->name . ' | ' . $sitename ?></title>
        <meta charset="utf-8" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
       <link rel="stylesheet" type="text/css" href="<?php echo base_url('assets/css/bootstrap.min.css') ?>" />
    </head>
    <body>
    <style type="text/css">
        .m-t-40 {
            margin-top: 40px;
        }
        .m-t-20 {
            margin-top: 20px;
        }
        .bg-custom {
            background: #ddd;
        }
        .m-b-0 {
            margin-bottom: 0!important;
        }
    </style>
    <div class="container">
        <div class="row m-t-40">
            <div class="col-sm-12">
                <div class="jumbotron text-center">
                    <h1>Pending Approval</h1>
                    <p class="m-t-40">This transaction is awaiting approval. The authorities have been informed about the payment through email. Be patient until the process is complete. The process can take up to 24 hours to complete</p>
                   <div class="table-responsive bg-custom text-left">
                        <table class="table table-bordered table-striped m-b-0">
                            <thead>
                            <tr>
                                <th>Reference</th>
                                <th>Total Amount</th>
                                <th>Gateway Fee</th>
                                <th>Customer</th>
                                <th>Pay Using</th>
                                <th>Status</th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr>
                                <td><?php echo $transaction->aclreference ?></td>
                                <td><?php echo $amount . ' BDT' ?></td>
                                <td><?php echo number_format(( isset($transaction->aclgatewayfee) ? $transaction->aclgatewayfee : 0 ), 2, '.', '') . ' BDT' ?></td>
                                <td><?php echo $transaction->name ?></td>
                                <td><?php echo $gateway->name ?></td>
                                <td>Pending</td>
                            </tr>
                            </tbody>
                        </table>
                    </div>
                    <?php if(!empty($referrer)) : ?>
                        <a href="<?php echo xss_clean($referrer) ?>" class="btn btn-inverse btn-block m-t-20">Get Back to Home</a>
                    <?php endif; ?>
                </div>
            </div>
        </div>
    </div>
    <script src="<?php echo base_url('assets/js/jquery-3.3.1.min.js') ?>"></script>
    <script src="<?php echo base_url('assets/js/bootstrap.min.js') ?>"></script>
    </body>
<html>