<?php
if (Auth('admin')->User()->dashboard_style == 'light') {
    $text = 'dark';
    $bg = 'light';
} else {
    $text = 'light';
    $bg = 'dark';
}
?>

<?php $__env->startSection('content'); ?>
    <?php echo $__env->make('admin.topmenu', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
    <?php echo $__env->make('admin.sidebar', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
    <div class="main-panel">
        <div class="content ">
            <div class="page-inner">
                <?php if (isset($component)) { $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4 = $component; } ?>
<?php $component = $__env->getContainer()->make(Illuminate\View\AnonymousComponent::class, ['view' => 'components.danger-alert','data' => []]); ?>
<?php $component->withName('danger-alert'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php $component->withAttributes([]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4)): ?>
<?php $component = $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4; ?>
<?php unset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4); ?>
<?php endif; ?>
                <?php if (isset($component)) { $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4 = $component; } ?>
<?php $component = $__env->getContainer()->make(Illuminate\View\AnonymousComponent::class, ['view' => 'components.success-alert','data' => []]); ?>
<?php $component->withName('success-alert'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php $component->withAttributes([]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4)): ?>
<?php $component = $__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4; ?>
<?php unset($__componentOriginalc254754b9d5db91d5165876f9d051922ca0066f4); ?>
<?php endif; ?>
                <!-- Beginning of  Dashboard Stats  -->
                <div class="row">
                    <div class="col-md-12">
                        <div class="p-3 card ">
                            <div class="card-body">
                                <div class="row">
                                    <div class="col-md-12 ">
                                        <h1 class="d-inline text-primary"><?php echo e($user->name); ?></h1><span></span>
                                        <div class="d-inline">
                                            <div class="float-right btn-group">
                                                <a class="btn btn-primary btn-sm" href="<?php echo e(route('manageusers')); ?>"> <i
                                                        class="fa fa-arrow-left"></i> back</a> &nbsp;
                                                <button type="button" class="btn btn-secondary dropdown-toggle btn-sm"
                                                    data-toggle="dropdown" data-display="static" aria-haspopup="true"
                                                    aria-expanded="false">
                                                    Actions
                                                </button>
                                                <div class="dropdown-menu dropdown-menu-lg-right">
                                                    <a class="dropdown-item"
                                                        href="<?php echo e(route('loginactivity', $user->id)); ?>">Login Activity</a>
                                                    <?php if($user->status == null || $user->status == 'blocked' || $user->status == 'banned' || $user->status == 'disabled'): ?>
                                                        <a class="dropdown-item text-success"
                                                            href="<?php echo e(url('admin/dashboard/uunblock')); ?>/<?php echo e($user->id); ?>">
                                                            <i class="fas fa-unlock mr-2"></i>Unban / Enable Account
                                                        </a>
                                                    <?php else: ?>
                                                        <a class="dropdown-item text-warning"
                                                            href="<?php echo e(url('admin/dashboard/uublock')); ?>/<?php echo e($user->id); ?>">
                                                            <i class="fas fa-ban mr-2"></i>Ban / Disable Account
                                                        </a>
                                                    <?php endif; ?>
                                                    <!--<?php if($user->tradetype == 'Profit'): ?>-->
                                                    <!--    <a class="dropdown-item"-->
                                                    <!--        href="<?php echo e(url('admin/dashboard/usertrademode')); ?>/<?php echo e($user->id); ?>/off">Turn-->
                                                    <!--        trade mode to Loss</a>-->
                                                    <!--<?php else: ?>-->
                                                    <!--    <a class="dropdown-item"-->
                                                    <!--        href="<?php echo e(url('admin/dashboard/usertrademode')); ?>/<?php echo e($user->id); ?>/on">Turn trade mode to Profit</a>-->
                                                    <!--<?php endif; ?>-->
                                                    <?php if($user->email_verified_at): ?>
                                                    <?php else: ?>
                                                        <a href="<?php echo e(url('admin/dashboard/email-verify')); ?>/<?php echo e($user->id); ?>"
                                                            class="dropdown-item">Verify Email</a>
                                                    <?php endif; ?>
                                                    <a href="#" data-toggle="modal" data-target="#topupModal"
                                                        class="dropdown-item">Credit/Debit</a>


                                                        <?php if($user->signal_status == 'on'): ?>
                                                        <a href="#" data-toggle="modal" data-target="#ugpradeSignalStatus"
                                                        class="dropdown-item">Turn off Upgrade Signal status</a>
                                                        <?php else: ?>
                                                        <a href="#" data-toggle="modal" data-target="#ugpradeSignalStatus"
                                                        class="dropdown-item">Turn on Upgrade Signal status</a>
                                                        <?php endif; ?>


                                                        <?php if($user->plan_status=='on'): ?>
                                                        <a href="#" data-toggle="modal" data-target="#ugpradePlanStatus"
                                                        class="dropdown-item">Turn off Upgrade Plan status</a>
                                                        <?php else: ?>
                                                        <a href="#" data-toggle="modal" data-target="#ugpradePlanStatus"
                                                        class="dropdown-item">Turn on Upgrade Plan status</a>
                                                        <?php endif; ?>

                                                         
                                                        <a href="#" data-toggle="modal" data-target="#TradingModal"
                                                        class="dropdown-item">Trade for this client</a>
                                                        <?php if($user->signals !=Null): ?>
                                                        <a href="#" data-toggle="modal" data-target="#Signal"
                                                        class="dropdown-item"> Create Signal for this Client </a>
                                            <?php endif; ?>

                                                        <a href="#" data-toggle="modal" data-target="#Nostrades"
                                                        class="dropdown-item">Set Number of trade for Withdrawal </a>

                                                        <a href="#" data-toggle="modal" data-target="#Planhistory"
                                                        class="dropdown-item">Add Plan History</a>
                                                        <a href="#" data-toggle="modal" data-target="#tradingProgressModal"  class="dropdown-item">Signal Strength</a>
                                               <a href="#" data-toggle="modal" data-target="#withdrawalcode"
                                                        class="dropdown-item">Set Withdrawal Code for client </a>
                                                    <a href="#" data-toggle="modal" data-target="#resetpswdModal"
                                                        class="dropdown-item">Reset Password</a>
                                                    <a href="#" data-toggle="modal" data-target="#clearacctModal"
                                                        class="dropdown-item">Clear Account</a>

                                                    <a href="#" data-toggle="modal" data-target="#edituser"
                                                        class="dropdown-item">Edit</a>
                                                    <a href="<?php echo e(route('showusers', $user->id)); ?>" class="dropdown-item">Add
                                                        Referral</a>
                                                        <a href="#" data-toggle="modal"
                                                        data-target="#notifyuser" class="dropdown-item">Notify User dashboard</a>
                                                    <a href="#" data-toggle="modal"
                                                        data-target="#sendmailtooneuserModal" class="dropdown-item">Send
                                                        Email</a>
                                                    <a href="#" data-toggle="modal" data-target="#switchuserModal"
                                                        class="dropdown-item text-success">Login as <?php echo e($user->name); ?></a>
                                                    <a href="#" data-toggle="modal" data-target="#deleteModal"
                                                        class="dropdown-item text-danger">Delete <?php echo e($user->name); ?></a>

                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <div class="p-3 mt-4 border rounded row ">
                                    <div class="col-md-3">
                                        <h5 class="text-bold">Account Balance</h5>
                                        <p><?php echo e($user->currency); ?><?php echo e(number_format($user->account_bal, 2, '.', ',')); ?>

                                        </p>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Profit</h5>
                                        <p><?php echo e($user->currency); ?><?php echo e(number_format($user->roi, 2, '.', ',')); ?> </p>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Current Signal </h5>
                                          <p>  <?php if($user->signals==Null): ?>
                                            <span >No Signal Yet </span>
                                            <?php else: ?>
                                            <span class='badge badge-success'><?php echo e($user->signals); ?> </span>
                                            <?php endif; ?>
                                          </p>

                                        <p><?php echo e($user->currency); ?><?php echo e(number_format($user->ref_bonus, 2, '.', ',')); ?></p>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Bonus</h5>
                                        <p><?php echo e($user->currency); ?><?php echo e(number_format($user->bonus, 2, '.', ',')); ?></p>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Client Plans</h5>
                                        <?php if($user->plan != null): ?>
                                            <a class="btn btn-sm btn-primary d-inline"
                                                href="<?php echo e(route('user.investments', $user->id)); ?>">View Plans</a>
                                        <?php else: ?>
                                            <p>No Trades</p>
                                        <?php endif; ?>
                                        
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Client Trades</h5>
                                        
                                        <?php if($user->trade != null): ?>
                                            <a class="btn btn-sm btn-primary d-inline"
                                                href="<?php echo e(route('user.plans', $user->id)); ?>">View Trades</a>
                                        <?php else: ?>
                                            <p>No Trades</p>
                                        <?php endif; ?>

                                    </div>
                                    <div class="col-md-3">
                                        <h5>KYC</h5>
                                        <?php if($user->account_verify == 'Verified'): ?>
                                            <span class="badge badge-success">Verified</span>
                                        <?php else: ?>
                                            <span class="badge badge-danger">Not Verified</span>
                                        <?php endif; ?>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Trade Mode</h5>
                                        <?php if($user->tradetype == 'Loss' || $user->trade_mode == null): ?>
                                            <span class="badge badge-danger">Loss</span>
                                        <?php else: ?>
                                            <span class="badge badge-success">Profit</span>
                                        <?php endif; ?>
                                    </div>
                                    <div class="col-md-3">
                                        <h5>Account Status</h5>
                                        <?php if(in_array($user->status, ['blocked', 'banned', 'disabled'])): ?>
                                            <span class="badge badge-danger">
                                                <i class="fas fa-ban mr-1"></i>
                                                <?php echo e(ucfirst($user->status)); ?>

                                            </span>
                                        <?php elseif($user->status == 'active'): ?>
                                            <span class="badge badge-success">
                                                <i class="fas fa-check-circle mr-1"></i>
                                                Active
                                            </span>
                                        <?php else: ?>
                                            <span class="badge badge-warning">
                                                <i class="fas fa-clock mr-1"></i>
                                                Pending
                                            </span>
                                        <?php endif; ?>
                                    </div>
                                </div>
                                <div class="mt-3 row ">
                                    <div class="col-md-12">
                                        <h5>USER INFORMATION</h5>
                                    </div>
                                </div>
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Fullname</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e($user->name); ?></h5>
                                    </div>
                                </div>
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Email Address</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e($user->email); ?></h5>
                                    </div>
                                </div>
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Mobile Number</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e($user->phone); ?></h5>
                                    </div>
                                </div>
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Date of birth</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e($user->dob); ?></h5>
                                    </div>
                                </div>
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Nationality</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e($user->country); ?></h5>
                                    </div>
                                </div>
                                
                                <div class="p-3 border row ">
                                    <div class="col-md-4 border-right">
                                        <h5>Registered</h5>
                                    </div>
                                    <div class="col-md-8">
                                        <h5><?php echo e(\Carbon\Carbon::parse($user->created_at)->toDayDateTimeString()); ?></h5>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <?php echo $__env->make('admin.Users.users_actions', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>


        <script>



function changecurr() {
       var e = document.getElementById("select_c");
       var selected = e.options[e.selectedIndex].id;
       document.getElementById("s_c").value = selected;
       console.log(selected);
   }

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

<?php echo $__env->make('layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/elitemaxpro/check.elitemaxpro.click/resources/views/admin/Users/userdetails.blade.php ENDPATH**/ ?>