<?php $__env->startSection('title'); ?>
    <?php echo app('translator')->getFromJson('User Wallet History'); ?> - <?php echo e(config('app.name')); ?>

<?php $__env->stopSection(); ?>

<?php $__env->startSection('meta-tags'); ?>
    <meta name="description" content="<?php echo app('translator')->getFromJson('User Wallet History'); ?>">
<?php $__env->stopSection(); ?>

<?php $__env->startSection('meta-tags-og'); ?>
    <meta property="og:url" content="<?php echo e(url()->current()); ?>" />
    <meta property="og:type" content="website" />
    <meta property="og:title" content="<?php echo app('translator')->getFromJson('User Wallet History'); ?> - <?php echo e(config('app.name')); ?>" />
    <meta property="og:description" content="<?php echo app('translator')->getFromJson('User Wallet History'); ?>" />
    <meta property="og:image" content="<?php echo e(url('/img/'.config('settings.site_logo'))); ?>" />
<?php $__env->stopSection(); ?>

<?php $__env->startSection('styles'); ?>
    <?php echo $__env->make('includes.order_tracker_style', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
    <style>
        .orders-details-inner > h3 {
            padding: 6px !important;
            margin: 0px !important;
            font-size: 18px;
            border-bottom: 1px solid #eee;
        }

        .orders-details-inner > ul > li {
            float: left;
            list-style: none;
            margin-bottom: 20px;
            padding: 10px !important;
            border-right: 1px solid #eee;
        }

        .orders-details-inner ul li a {
            color: #333;
            font-size: 16px;
        }

        .orders-details {
            background-color: #f9f9f9;
            padding: 15px;
            margin-top: 15px;
        }

        .bar1, .bar2, .bar3 {
            width: 22px;
            height: 3px;
            background-color: #333;
            margin: 4px 0;
            transition: 0.4s;
        }

        .change .bar1 {
            -webkit-transform: rotate(-45deg) translate(-7px, 3px);
            transform: rotate(-45deg) translate(-7px, 3px);
        }

        .change .bar2 {
            opacity: 0;
        }

        .change .bar3 {
            -webkit-transform: rotate(45deg) translate(-7px, -3px);
            transform: rotate(45deg) translate(-7px, -3px);
        }

        .btn-toggle-close a {
            margin-top: 20px !important;
            display: block;
        }

        .orders-details-inner-sub-2 {
            margin-top: 15px;
        }

        .orders-details-inner-sub-2 img {
            width: 60px;
            float: left;
            margin-right: 15px;
        }

        .orders-details-inner-sub-2 h4 a {
            color: #888;
        }

        .orders-details-inner-sub-2 p {
            padding-top: 0px;
            font-size: 14px;
            color: #333;
        }

        @media (max-width: 767px) {
            .orders-details-inner-sub-2 {
                height: 100%;
                display: block;
                margin: 40px auto;
            }
        }

        .panel-body-row {
            text-align: left;
        }

        .img-box {
            text-align: center;
        }

        .img-box .product-img {
            height: 80px;
            width: auto !important;
        }

        .product-img {
            width: 100% !important;
        }

        .grand-total p {
            text-align: left;
            padding: 0px;
        }

        .panel-heading, .panel-body {
            border: 1px solid #e5e5e5;
        }

        .panel-heading {
            border-bottom: none;
        }

        .orders-details {
            border: 1px solid #158cba;
            border-radius: 5px;
        }

        .media-body {
            text-align: center;
        }

        .order_detail_item_name {
            color: #444;
        }
    </style>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('sidebar'); ?>
    <?php echo $__env->make('includes.user-account-sidebar', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('above_content'); ?>
    <div class="breadcrumb">
        <div class="container">
            <div class="breadcrumb-inner">
                <ul class="list-inline list-unstyled">
                    <li><a href="<?php echo e(url('/')); ?>"><?php echo app('translator')->getFromJson('Home'); ?></a></li>
                    <li class="active"><?php echo app('translator')->getFromJson('Wallet History'); ?></li>
                </ul>
            </div>
            <!-- /.breadcrumb-inner -->
        </div>
        <!-- /.container -->
    </div>
    <!-- /.breadcrumb -->
<?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>
    <div class="col-md-9 user_account">
        <div class="shopping-cart">
            <div class="page-title">
                <h2><?php echo app('translator')->getFromJson('Wallet History'); ?>
                    <button type="button" class="btn btn-primary pull-right device-none mt-minus-3">
                        Current Balance : <?php echo e(currency_format($user_wallet_bal->wallet_balance, config('currency.default') )); ?>

                    </button></h2>

            </div>
            <div class="content-panel">
                <div class="col-md-12 panel-heading">
                    <div class="col-md-1 device-none">
                        <h4></h4>
                    </div>
                    <div class="col-md-2 col-xs-4">
                        <h4> <?php echo app('translator')->getFromJson('Txn Id'); ?> </h4>
                    </div>
                    <div class="col-md-2 col-xs-6">
                        <h4> <?php echo app('translator')->getFromJson('Txn Amount'); ?> </h4>
                    </div>
                    <div class="col-md-4 col-xs-6 device-none">
                        <h4> <?php echo app('translator')->getFromJson('Description'); ?> </h4>
                    </div>
                    <div class="col-md-2 device-none">
                        <h4><?php echo app('translator')->getFromJson('Txn Date'); ?> </h4>
                    </div>
                    <div class="col-md-1 col-xs-2 ">
                    </div>
                </div>
                <?php if(count($user_wallet_history) > 0): ?>
                    <?php $__currentLoopData = $user_wallet_history; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $wallet): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                    <div class="col-md-12 panel-body">
                        <div class="panel-body-row">
                            <div class="col-md-1 device-none">
                                <h4> <?php echo e($key+1); ?> </h4>
                            </div>
                            <div class="col-md-2 col-xs-4">
                                <h4>
                                    <a class="" onclick="myFunction(this)" class="btn-toggle-close"
                                       data-toggle="collapse" href="#multiCollapseExample<?php echo e($key+1); ?>"
                                       aria-expanded="false" aria-controls="multiCollapseExample<?php echo e($key+1); ?>">
                                        #TXN-<?php echo e(StringHelper::preZero($wallet->wallet_id)); ?>

                                    </a>
                                </h4>
                            </div>
                            <div class="col-md-2 col-xs-6 device-none text-center">
                                <h4>
                                    <?php if(!empty($wallet->credit_amt) && $wallet->debit_amt == 0): ?>
                                        <span class="text-success"><?php echo e(currency_format($wallet->transaction_amt,$wallet->transaction_currency)); ?></span>
                                    <?php else: ?>
                                        <span class="text-danger"><?php echo e(currency_format($wallet->transaction_amt,$wallet->transaction_currency)); ?></span>
                                    <?php endif; ?>
                                </h4>
                            </div>
                            <div class="col-md-4 col-xs-6">
                                <strong><?php echo e($wallet->transaction_description); ?></strong>
                            </div>


                            <div class="col-md-2 device-none">
                                <h4> <?php echo e($wallet->created_at->toFormattedDateString()); ?> </h4>
                            </div>

                            <div class="col-md-1 col-xs-2 btn-toggle-close">
                                <a class="" onclick="myFunction(this)" class="btn-toggle-close" data-toggle="collapse"
                                   href="#multiCollapseExample<?php echo e($key+1); ?>" aria-expanded="false"
                                   aria-controls="multiCollapseExample<?php echo e($key+1); ?>">
                                    <div class="bar1"></div>
                                    <div class="bar2"></div>
                                    <div class="bar3"></div>
                                </a>
                            </div>
                        </div>

                        <div class="clearfix"></div>

                        <div class="col-md-12 multi-collapse collapse" id="multiCollapseExample<?php echo e($key+1); ?>"
                             aria-expanded="false" style="height: 0px;">
                            <div class="orders-details">
                                <div class="orders-details-inner">
                                    <h3><strong> <?php echo app('translator')->getFromJson('Txn Id'); ?> : #TXN-<?php echo e(StringHelper::preZero($wallet->wallet_id)); ?> </strong></h3>
                                </div>
                                <div class="clearfix"></div>

                                <div class="col-md-6 grand-total">
                                    <p><strong><?php echo app('translator')->getFromJson('Transaction Action:'); ?></strong>
                                        <?php if(!empty($wallet->credit_amt) && $wallet->debit_amt == 0): ?>
                                            <strong class="text-success"><?php echo app('translator')->getFromJson('Credit'); ?></strong>
                                        <?php else: ?>
                                            <strong class="text-danger"><?php echo app('translator')->getFromJson('Debit'); ?></strong>
                                        <?php endif; ?>
                                    </p>
                                    <hr>
                                    <p><strong><?php echo app('translator')->getFromJson('Currency :'); ?></strong> <?php echo e($wallet->transaction_currency); ?> </p>
                                    <hr>
                                    <p><strong><?php echo app('translator')->getFromJson('Transaction Date :'); ?></strong> <?php echo e($wallet->created_at); ?> </p>
                                    <hr>
                                </div>
                                <div class="col-md-4 grand-total">
                                    <div class="pull-right">
                                        <p><strong><?php echo app('translator')->getFromJson('Transaction Amount :'); ?></strong> <?php echo e(currency_format($wallet->transaction_amt, $wallet->transaction_currency)); ?>

                                        </p>
                                        <p><strong><?php echo app('translator')->getFromJson('Transaction Description :'); ?></strong> <?php echo e($wallet->transaction_description); ?> </p>
                                        <p><strong><?php echo app('translator')->getFromJson('Wallet Balance :'); ?></strong> <?php echo e(currency_format($wallet->wallet_balance, $wallet->transaction_currency)); ?> </p>
                                        <hr>
                                    </div>
                                </div>
                                <div class="clearfix"></div>
                            </div>
                        </div>

                    </div>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                 <?php else: ?>
                    <div class="row text-center">
                        <div class="empty-bag">
                            <div class="empty-bag-icon">
                                <img src="<?php echo e(asset('/img/icons/wallet-512.png')); ?>" class="img-responsive m-a" alt="<?php echo app('translator')->getFromJson('No Wallet History'); ?>" width="100">
                            </div>
                            <h3 class="text-center text-muted"><?php echo app('translator')->getFromJson('NO WALLET HISTORY FOUND'); ?></h3>
                        </div>
                    </div>
                <?php endif; ?>
                    <?php if(count($user_wallet_history)): ?>
                    <div class="text-right">
                        <?php echo e($user_wallet_history->links()); ?>

                    </div>
                    <?php endif; ?>

            </div>
        </div>
    </div>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('scripts'); ?>
    <script>
        function myFunction(x) {
            x.classList.toggle("change");
        }
    </script>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.front', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>