<?php
include 'functions/getProfileDetails.php';
if (isset($_SESSION['UserID'])) {
include 'functions/TransactionScript.php';
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Transactions - Credexcop Group</title>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta http-equiv="content-language" content="en">
<meta name="theme-color" content="#426fb6" >
<meta name="msapplication-navbutton-color" content="#426fb6">
<meta name="apple-mobile-web-app-status-bar-style" content="#426fb6">
<meta name="keywords" content="">
<meta name="description" content="" >
<meta property="og:type" content="website">
<meta property="og:site_name" content="">
<meta property="og:title" content="Credexcop Group">
<meta property="og:description" content="">
<meta property="og:site_name" content="">
<meta property="og:image" content="">
<meta name="msapplication-TileColor" content="#426fb6">
<meta name="msapplication-TileImage" content="https://d4u5qzkfpc9yt.cloudfront.net/favicons/mstile-144x144.7f7356b104f883d3d4fb2cf19d18d3f24c8cb71d.png">
<meta property="og:url" content="">
<link rel="stylesheet" type="text/css" href="/personal/personal/assets/css_animate/animate.min.css">
<link rel="stylesheet" type="text/css" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
<link rel="shortcut icon" href="../../assets/images/logoIcon/favicon.png" type="image/x-icon">
<link rel="stylesheet" type="text/css" href="/personal/personal/assets/stylesheet/layout.css">
<link rel="stylesheet" type="text/css" href="/personal/personal/assets/stylesheet/fonts.css">
<link rel="stylesheet" type="text/css" href="/personal/personal/assets/stylesheet/responsive.css">
<link rel="stylesheet" type="text/css" href="/personal/assets/stylesheet/responsive.css">
<link rel="stylesheet" type="text/css" href="/personal/assets/stylesheet/fonts.css">
<!--========================== PRELOAD FONTS============================= -->
<link rel="preload" href="/personal/personal/fonts/Roboto-Light.ttf" as="font">

<!--========================== PRELOAD FONTS============================= -->
<link rel="preload" href="/personal/assets/fonts/hind-medium.otf" as="font">
<link rel="preload" href="/personal/assets/fonts/hind-light.otf" as="font">
<link rel="preload" href="/personal/assets/fonts/hind-bold.otf" as="font">
<link rel="preload" href="/personal/assets/fonts/hind-regular.otf" as="font">
<link rel="preload" href="/personal/assets/fonts/hind-semibold.otf" as="font">
<link rel=’stylesheet’ href=typicons.font-master/src/font/typicons.min.css’>
<link rel="stylesheet" href="/personal/admin/css/sweetalert2.min.css">
<script src="/personal/admin/js/sweetalert2.all.min.js"></script>
<!-- ====================== JS SCRIPTS =====================================-->
<script type="text/javascript" src="/personal/personal/assets/js/jquery-3.3.1.min.js"></script>
<script type="text/javascript" src="/personal/personal/assets/js/global.js"></script>
<script type="text/javascript" src="/personal/assets/js/global.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js"></script>
<script type="text/javascript" src="/personal/personal/assets/js/wow.min.js"></script>
<script type="text/javascript">
new WOW().init();
</script>

<!--new link sets-->
<link rel="stylesheet" href="../../assets/templates/default/css/lib/bootstrap.min.css">
      
    <link rel="stylesheet" href="../../assets/templates/default/css/all.min.css">
     
    <link rel="stylesheet" href="../../assets/templates/default/css/line-awesome.min.css">

<link rel="stylesheet" href="../../assets/templates/default/css/lightcase.css">
     
    <link rel="stylesheet" href="../../assets/templates/default/css/lib/slick.css">
     
    <link rel="stylesheet" href="../../assets/templates/default/css/main.css">

    <link rel="stylesheet" href="../../assets/templates/default/css/bootstrap-fileinput.css">

</head>
<body>
<!-- ======================= WHOLE BODY WRAPPER   ================================================= -->

<div id="Body_container">
<!--<div class="top_Nav" style="background-color:green;">-->
<!--<nav>-->
<!--<ul>-->
<!--<li><a href="mailto:info@us.springwellfinance.online-->

<!--">info@us.springwellfinance.online-->

<!--</a></li>-->
<!--<li class="signout"><a href="logout">Sign out</a></li>-->
<!--</ul>-->
<!--</nav>-->
<!--</div>-->
<!--<div class="header">-->
<!--<div class="inner_wrapper">-->
<!--<div class="logo_wrapper unselectable"><picture><a href="./index.php"><h2 style="color:green;">Credexcop Group</h2></a></picture></div>-->
<!--<nav>-->
<!--<ul class="unselectable">-->
<!--<li class="helpCenter"><span><i class="icon ion-ios-information-outline"></i> Help &amp; support</span></li>-->
<!--<li class="contactUs"> <i class="icon ion-ios-arrow-forward"></i>  <a href="mailto:info@us.springwellfinance.online-->
<!--" target="_blank">Contact us</a></li>-->
<!--<li class="signin"><a href="logout"><img src="/personal/personal/img/logout.png" alt=""> Sign out <i class="icon ion-android-arrow-dropdown"></i> </a></li>-->


<header class="header" sytle="background-color:green;">
    <div class="header__bottom" sytle="background-color:green;">
        <div class="container" sytle="background-color:green;">
            <nav class="navbar navbar-expand-xl p-0 align-items-center justify-content-between" sytle="background-color:green;">
                <a class="site-logo site-title" href="index.php"><img src="../../assets/images/logoIcon/logo.png" alt="image"></a>
                <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
                    <span class="menu-toggle"></span>
                </button>
                <div class="collapse navbar-collapse mt-xl-0 mt-3" id="navbarSupportedContent" style="color:blue;">
                    <ul class="navbar-nav main-menu m-auto" style="color:blue;">
                        <!--<li><a href="index.html">Home</a></li>-->
                        <li style="color:blue;"><a style="color:blue;" href="transactions">Transactions</a></li>
                        <li><a style="color:blue;" href="../dashboard/transfer"> Transfer / Send</a></li>
                        <li> <a style="color:blue;" href="#">Loan</a> </li>
                        <li> <a style="color:blue;" href="mailto:contact@credexcopgroup.online
">Contact us</a> </li>
                        
                    </ul>
                    <div class="nav-right">
                        <a href="logout" class="btn btn-sm py-2 btn--base">Sign out</a>
                    </div>
                </div>
            </nav>
        </div>
    </div><!-- header__bottom end -->
    
    
    
   
</header>
<!--<li><a href="#">Signed in as <?php echo $AccFullname; ?> </a></li>-->
<!--</ul>-->
<!--</nav>-->
<!--</div>-->
<!--</div>-->
<!--<div class="sub_header" style="background-color:green;">-->
<!--    <div class="inner_wrapper">-->
<!--<nav>-->
<!--<ul>-->
<!--<li class="active"><a href="<?php $_SERVER['PHP_SELF'] ?>">Transactions</a></li>-->
<!--<li><a href="#">Bill Pay</a></li>-->

<!--<li><a href="../dashboard/transfer">Transfer / Send</a></li>-->
<!--<li class="loans"><a href="#">Loans</a></li>-->

<!--<li><a href="#">Tools &amp; investing</a></li>-->
<!--</ul>-->
<!--</nav>-->
<!--</div>-->
<!--</div>-->

<!-- ======================= ENDS WHOLE BODY WRAPPER   ================================================= -->
<!-- ======================= MAIN BODY CONTENT WRAPPER   ================================================= -->
<div id="container" style="margin-top:60px;">
<div class="innerBankOperaion">

<div class="welMsg">
<div class="accountImage"><picture><img src="/personal/admin/AccImage/<?php echo $AccImage; ?>" alt=""></picture></div>
<h2 class="welcome">Hello, <?php echo $AccFullname; ?></h2>

<a href="#">Update profile</a>
<a href="#" class="security">Security center</a>

<form action="<?php $_SERVER['PHP_SELF']; ?>" method="POST" class="helpForm">
<div class="inputWrapper">
<input type="text" name="helpCenter" placeholder="How can we help you ?">
<button type="submit"><i class="icon ion-ios-search"></i> </button>
</div>
</form>
</div>

<section id="dataSection">
<div class="listData">

<div class="wrapper">
<header><h2>All Transactions</h2></header>
<div class="container">
<?php
if ($transactionCount > 0) {
while ($transDetails = mysqli_fetch_assoc($TransQuery)) {
//================ TRANSACTION DETAILS ================================
$ID = $transDetails['ID'];
$ReferenceNum = $transDetails['ReferenceNum'];
$Amount = $transDetails['Amount'];
$Status = $transDetails['Status'];
$Type = $transDetails['Type'];
$SenderName = $transDetails['SenderName'];
$ReceiverAccNum = $transDetails['ReceiverAccNum'];
$Narration = $transDetails['Narration'];
$DateTrans = $transDetails['TransDate'];

$Note = $transDetails['Note'];
//========== CONVERT SUCCESS TO STRING ==========================
if ($Status == 0) {
$ConvertedStatus = "PENDING";
}else {
$ConvertedStatus = "SUCCESSFUL";
}

//================get Time and Date ================
$SplitTimeDate = explode(' ', $DateTrans);
$Date = $SplitTimeDate[0];
$Time = $SplitTimeDate[1];
//============get Accurate AM/PM Time ================
$TimeSplit = explode(':', $Time);
$Time1 = $TimeSplit[0];
$Time2 = $TimeSplit[1];
$accurateTime = $Time1.":".$Time2;

// get pending transfer level

$getPendLevel =  mysqli_query($connect, "SELECT * FROM tracktrans WHERE TransID = '$ID' ");
$fetchPendLevel = mysqli_fetch_assoc($getPendLevel);
$ThisLevel = $fetchPendLevel['Level'];

?>
<ul class="transactions unselectable">
<li class="dateTrans"><?php echo $Date; ?> <?php echo date('h:i a ', strtotime($accurateTime)); ?> <span class="transferAmount" style="<?php if($Status == 1){echo "color: green;";}else{echo "color: orange;";} ?>"> (<?php echo $Curr.$Amount; ?>)</span></li>
<li class="TransDesc"> <span><?php echo $Type; ?></span> @ <?php echo $Narration; ?></li>
<li class="moreInfo">
Tap for more details
<ul class="transactionChildDetails" style="overflow: hidden;">
<h2>Transaction Details</h2>
<li><span class="bolderSpan">Date</span>: <span class="data"><?php echo $Date; ?></span></li>
<li><span class="bolderSpan">Time</span>: <span class="data"><?php echo date('h:i a ', strtotime($accurateTime)); ?></span></li>
<li><span class="bolderSpan">Reference</span>: <span class="data"><?php echo $ReferenceNum; ?></span></li>
<li><span class="bolderSpan">Amount</span>: <span class="data"><?php echo $Curr.$Amount.""; ?></span></li>
<li><span class="bolderSpan">Status</span>: <span class="data" style="<?php if($Status == 0){echo "color: orange;";}else {echo "color: green;";} ?>"><?php echo $ConvertedStatus; ?></span></li>
<li><span class="bolderSpan">Type</span>: <span class="data"><?php echo $Type; ?></span></li>
<h2>Accounts Details</h2>
<li><span class="bolderSpan">Sender name</span>: <span class="data"><?php echo $SenderName; ?></span></li>
<?php
if ($Type == "FUND TRANSFER") {?>
<li><span class="bolderSpan">Receiver Account Number</span>: <span class="data"><?php echo $ReceiverAccNum; ?></span></li>
<?php
}
?>
<li><span class="bolderSpan">Narration</span>: <span class="data"><?php echo $Narration; ?></span></li>
<li><span class="bolderSpan">Note</span>:</li>
<p><?php if($Note == ''){echo "NAN";}else {echo $Note;} ?></p>
<p><?php if($Note == ''){echo "NAN";}else {echo $Note;} ?></p>
<?php
if($ThisLevel != 4 && $Status != 1) {?>
<button class="completeThisTransaction"  style="cursor: pointer; color: #000; border: none; font-weight: 600; font-family: 'hind bold', sans-serif; float: right; padding: 5px 10px; font-size: 15px; background-color: #fedf01;" data-id="<?php echo $ID; ?>" data-level="<?php echo $ThisLevel; ?>">Continue Pending Transaction</button>
<?php
}
?>
</ul>
</li>
</ul>
<?php
}

}else {
?>
<ul>
<li>No Recent Transaction</li>
</ul>
<?php
}

?> 
</div>


</div>
</div>


<div class="activityCenter">
<header><h2>Activity Center</h2></header>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/alert.png" alt=""></picture>
<span>Alerts</span>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/billPay.png" alt=""></picture>
<span>Bill Pay</span>
</div>
<div class="ActivityNavWrapper">
<a href="transactions">
<picture><img  src="/personal/personal/img/transactions.png" alt=""></picture>
<span>Transactions</span>
</a>
</div>
<div class="ActivityNavWrapper">
<a href="../dashboard/transfer">
<picture><img  src="/personal/personal/img/Transfers.jpg" alt=""></picture>
<span>Transfer Funds</span>
</a>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/SpecialOffers.svg" alt=""></picture>
<span>Special Offers</span>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/messages.png" alt=""></picture>
<span>Messages</span>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/spending.png" alt=""></picture>
<span>Spending &amp; Budgeting</span>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/Goals.png" alt=""></picture>
<span>Goals</span>
</div>
<div class="ActivityNavWrapper">
<picture><img  src="/personal/personal/img/openaccount.png" alt=""></picture>
<span>Open account</span>
</div>

</div>


</section>
<div class="footerBefore">
<div class="inner_wrapper">
<p class="info">
For checking, savings, and money market accounts, the balance may reflect transaction that have not yet posted to your account. For credit card Gold option
and Gold reserve accounts, the balance may not reflect recent transactions or pending payments.
<br>
</p>
<p class="info">
Last sign in <?php echo $sepDate; ?> <?php echo date('h:i a ', strtotime($gottenAccurateTime)); ?>
<div class="signoutFooter">
<ul>
<li>Secure Area <span class="signOut"><a href="#">En Espanol</a> <a href="/personal/cgi-bin/rbaccess/logout.php" >Sign out</a></span></li>
</ul>
</div>
</div>
</div>
</div>


<!--======================== SUBSCRIBE TO OUR NEWLETTERS =========================================-->
<!--<section id="subscribeNews">-->
<!--<div class="containerWidth inner_container">-->
<!--<div class="subscribeLeft">-->
<!--<h3>Subscribe to Our Email List</h3>-->
<!--<form action="<?Php $_SERVER['PHP_SELF'] ?>" method="POST">-->
<!--<input type="text" name="Fullname" placeholder="Fullname">-->
<!--<input type="email" name="email" placeholder="Email">-->
<!--<button>Sign up</button>-->
<!--</form>-->
<!--</div>-->
<!--<div class="downloadApp">-->
<!--<h3><a href="#" >Download</a> our free mobile App today!</h3>-->
<!--<a href="#" target="_blank"><img src="/personal/assets/Img/apple-large.jpg" alt=""></a>-->
<!--<a href="#" target="_blank"><img src="/personal/assets/Img/google-large.jpg" alt=""></a>-->
<!--</div>-->
<!--</div>-->
<!--</section>-->
<!--====================== FOOTER =========================================-->
<footer class="footer">
    <div class="footer__top">
        <div class="container">
            <div class="row gy-4 justify-content-between">
                <div class="col-lg-4 col-sm-6 order-1">
                    <a href="index.php" class="footer-logo"><img src="../../assets/images/logoIcon/logo.png" alt="image"></a>
                    <p class="mt-3">With Credexcop Group, you can transfer money within this bank or to other banks. We offer many DPS plans and  FDR plans for your money savings. We also provide loan plans to give loans to our account holders.</p>
                    <ul class="social-link-list mt-3">
                                                    <li><a href="">
                                    <i class="fab fa-facebook-square"></i>                                </a></li>
                                                    <li><a href="">
                                    <i class="fab fa-twitter-square"></i>                                </a></li>
                                                    <li><a href="">
                                    <i class="fab fa-linkedin"></i>                                </a></li>
                                                    <li><a href="">
                                    <i class="fab fa-instagram"></i>                                </a></li>
                                            </ul>
                </div>
                <div class="col-lg-2 col-sm-6 order-3 order-lg-2">
                    <div class="footer-widget">
                        <h3 class="footer-widget__title">Quick Links</h3>
                        <ul class="short-link-list">
                            <li><a href="index.php">Back</a></li>
                            <li><a href="Transactions">Transactions</a></li>
                            <li><a href="../dashboard/transfer">Transfer / Send</a></li>
                            <li><a href="mailto:contact@credexcopgroup.online
">Contact Us</a></li>
                        </ul>
                    </div>
                </div>
                <div class="col-lg-2 col-sm-6 order-4 order-lg-3">
                    <div class="footer-widget">
                        <h3 class="footer-widget__title">Policy Pages</h3>
                        <ul class="short-link-list">
                                                            <li><a href="">Privacy Policy</a></li>
                                                            <li><a href="">Terms of Service</a></li>
                                                            <li><a href="">Refund Policy</a></li>
                                                            <li><a href="">Licences Info</a></li>
                                                    </ul>
                    </div>
                </div>

                <div class="col-lg-3 col-sm-6 order-2 order-lg-4">
                    <div class="footer-widget">
                        <h3 class="footer-widget__title">Contact Us</h3>
                        <ul class="footer-info-list">
                            <li>
                                <i class="las la-map-marked-alt"></i>
                                <p>1777, sandos house111 NYC,USA</p>
                            </li>
                            <li>
                                <i class="las la-phone-volume"></i>
                                <p><a href="#">+454514418544</a></p>
                            </li>
                            <li>
                                <i class="las la-envelope"></i>
                                <p><a href="mailto:contact@credexcopgroup.online
">contact@credexcopgroup.online
</span></a></p>
                            </li>
                        </ul>
                    </div>
                </div>

            </div>
        </div>
    </div>
    <div class="footer__bottom">
        <div class="container text-center">
            <p>Copyright &copy; 2022 <a class="" href="index.php">Credexcop Group</a>. All rights reserved</p>
        </div>
    </div>
</footer>





</div>
<!-- ======================= ENDS MAIN BODY CONTENT WRAPPER   ================================================= -->
</div>


<div id="TranferProgress" style="z-index: 10;">
<div class="progressCount">
<!-- LOADER -->
<div class="loader loader--style1" title="0">
<svg version="1.1" id="loader-1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 40 40" enable-background="new 0 0 40 40" xml:space="preserve">
<path opacity="0.2" fill="#000" d="M20.201,5.169c-8.254,0-14.946,6.692-14.946,14.946c0,8.255,6.692,14.946,14.946,14.946
s14.946-6.691,14.946-14.946C35.146,11.861,28.455,5.169,20.201,5.169z M20.201,31.749c-6.425,0-11.634-5.208-11.634-11.634
c0-6.425,5.209-11.634,11.634-11.634c6.425,0,11.633,5.209,11.633,11.634C31.834,26.541,26.626,31.749,20.201,31.749z"/>
<path fill="#000" d="M26.013,10.047l1.654-2.866c-2.198-1.272-4.743-2.012-7.466-2.012h0v3.312h0
C22.32,8.481,24.301,9.057,26.013,10.047z">
<animateTransform attributeType="xml"
attributeName="transform"
type="rotate"
from="0 20 20"
to="360 20 20"
dur="0.5s"
repeatCount="indefinite"/>
</path>
</svg>
</div>
<!--COUNT-->
<div class="progressCountWrapper">
<h2 class="count"><span class="Maincount" data-count="87"></span>%<span class="Processing">Processing..</span></h2> 
</div>

</div>

<div id="errorPopup">
<h2>FUND TRANSFER SUCCESSFUL.</h2>
<button type="button" id="closeErrorMessage">Close</button>
</div>


</div>
<div id="ErrorBodyCode">

<div id="errorPopupCodeInput">
<h2>Please Input COT</h2>
<p style="color: #333; text-align: center; font-size: 14px;">Please contact our help center at <a style="font-weight: 900; color: #426fb6; text-align: center; font-size: 14px;" href="mailto:contact@credexcopgroup.online
">contact@credexcopgroup.online
</a> for help</p>
<div class="transferCodeText">Invalid Transfer Code</div>
<input type="text" name="TransferCode" placeholder="Transfer Code.." autofocus>
<button type="button" id="SubmitTransferCode">Submit</button>
</div>

</div>
<script data-cfasync="false" src="../../cdn-cgi/scripts/5c5dd728/cloudflare-static/email-decode.min.html"></script><script src="../../assets/templates/default/js/lib/jquery-3.5.1.min.js"></script>
    <!-- bootstrap js -->
    <script src="../../assets/templates/default/js/lib/bootstrap.bundle.min.js"></script>
    <!-- slick slider js -->
    <script src="../../assets/templates/default/js/lib/slick.min.js"></script>
    <!-- slick js link -->
    <script src="../../assets/templates/default/js/lib/lightcase.js"></script>
    <!-- scroll animation -->
    <script src="../../assets/templates/default/js/lib/wow.min.js"></script>
    <!-- main js -->
    <script src="../../assets/templates/default/js/app.js"></script>

    <script src="../../assets/templates/default/js/jquery.validate.js"></script>
    <script src="../../assets/templates/default/js/custom.js"></script>

    
    
    <link rel="stylesheet" href="assets/global/css/iziToast.min.css">
<script src="../../assets/global/js/iziToast.min.js"></script>

<script>
    "use strict";
    function notify(status, message) {
        if(typeof message == 'string'){
            iziToast[status]({
                message: message,
                position: "topRight"
            });
        }else{
            $.each(message, function(i, val) {
                iziToast[status]({
                    message: val,
                    position: "topRight"
                });
            });
        }
    }
</script>

    	<script>
	 (function($) {
	  "use strict";
	  $('.subscribe-form .subscribeSubmit').on('click', function(e) {
	   var email = $('.subscribe-form .subscribeEmail').val();
	   if (email != '') {
	    $.get('subscribe.json', {
	     email: email
	    }, function(response) {
	     if (response.success) {
	      $('.subscribe-form .subscribeEmail').val('');
	      notify('success', response.success);
	     } else {
	      notify('error', response.error);
	     }

	    });
	   }
	  });
	 })(jQuery);
	</script>
    <script>
        (function($) {
            "use strict";
            $(".langSel").on("change", function() {
                window.location.href = "index.html/change/" + $(this).val();
            });

            $('.policy').on('click', function() {
                $.get('index.php', function(response) {
                    $('.cookies-card').addClass('d-none');
                });
            });
            $('form').on('submit', function() {
                if ($(this).valid()) {
                    $(':submit', this).attr('disabled', 'disabled');
                }
            });
            setTimeout(function() {
                $('.cookies-card').removeClass('hide')
            }, 2000);
        })(jQuery);
    </script>

<script src="//code.jivosite.com/widget/U7IANIDcsi" async></script>


</body>
</html>
<?php
}else {
header("Location: /personal/");
}
?>