PATH:
home
/
rwabteecom
/
project_11
/
storage
/
framework
/
views
/
Editing: 4e30dbb68e4e0fab9ef707fdbc37725f.php
<?php $__env->startSection("styles"); ?> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/flatpickr/4.6.13/flatpickr.min.css"/> <?php $__env->stopSection(); ?> <?php $__env->startSection("content"); ?> <?php if (isset($component)) { $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $attributes; } ?> <?php $component = App\View\Components\Card\CardContent::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-content'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardContent::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginal621b973765c726fc88d870def47fa1a6 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal621b973765c726fc88d870def47fa1a6 = $attributes; } ?> <?php $component = App\View\Components\Card\CardHeader::resolve(['title' => $user->name,'backRoute' => route('admin.users.index')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-header'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardHeader::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $attributes = $__attributesOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__attributesOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($__componentOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $component = $__componentOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__componentOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $attributes = $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> <?php if (isset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $component = $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> <div class="row my-5"> <div class="col-md-12 mb-5"> <?php if (isset($component)) { $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $attributes; } ?> <?php $component = App\View\Components\Card\CardContent::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-content'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardContent::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginal621b973765c726fc88d870def47fa1a6 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal621b973765c726fc88d870def47fa1a6 = $attributes; } ?> <?php $component = App\View\Components\Card\CardHeader::resolve(['title' => __('Basic Information')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-header'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardHeader::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $attributes = $__attributesOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__attributesOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($__componentOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $component = $__componentOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__componentOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $attributes; } ?> <?php $component = App\View\Components\Card\CardBody::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-body'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardBody::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <table class="table table-striped"> <tr> <td><?php echo e(__("User Name")); ?></td> <td><?php echo e($user->name); ?></td> </tr> <tr> <td><?php echo e(__("User Phone")); ?></td> <td><?php echo e($user->phone); ?></td> </tr> <tr> <td><?php echo e(__("User Email")); ?></td> <td><?php echo e($user->email); ?></td> </tr> </table> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $attributes = $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php if (isset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $component = $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $attributes = $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> <?php if (isset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $component = $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> </div> </div> <div class="row my-5"> <div class="col-md-12 mb-5"> <form action="<?php echo e(route('admin.users.attach-plan', $user->id)); ?>" method="post"> <?php echo csrf_field(); ?> <?php echo method_field("PUT"); ?> <?php if (isset($component)) { $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $attributes; } ?> <?php $component = App\View\Components\Card\CardContent::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-content'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardContent::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginal621b973765c726fc88d870def47fa1a6 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal621b973765c726fc88d870def47fa1a6 = $attributes; } ?> <?php $component = App\View\Components\Card\CardHeader::resolve(['title' => __('Attach Plan')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-header'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardHeader::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <span class="fw-bolder p-3 px-5 fs-3"> <?php echo e(__("Current Plan")); ?> </span> <?php if($user->is_subscribed_to_free_plan && $user->plans()->count() == 0): ?> <span class="badge badge-info p-3 px-5 fs-3"><?php echo e(__("Free Plan")); ?></span> <?php else: ?> <?php if($user->currentPlan): ?> <span class="badge badge-info p-3 px-5 fs-3"><?php echo e($user->currentPlan->title); ?></span> <?php else: ?> <span class="badge badge-danger p-3 px-5 fs-3"><?php echo e(__("No Plan Selected Yet, or plan is not paid")); ?></span> <?php endif; ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $attributes = $__attributesOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__attributesOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($__componentOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $component = $__componentOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__componentOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $attributes; } ?> <?php $component = App\View\Components\Card\CardBody::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-body'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardBody::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <div class="col-md-4"> <label for="plan_id" class="required form-label"><?php echo e(__('Plan')); ?></label> <select id="plan_id" name="plan_id" class="form-select form-select-solid" data-control="select2" required data-placeholder="<?php echo e(__('Select an option')); ?>" data-allow-clear="true"> <option></option> <?php $__currentLoopData = $plans; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $plan): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <option <?php echo e(old("plan_id") == $plan->id ? "selected" : ""); ?>value="<?php echo e($plan->id); ?>" data-date="<?php echo e(\Carbon\Carbon::now()->addDays($plan->duration_in_days)->format("Y-m-d")); ?>"> <?php echo e($plan->title); ?> <?php if(!$plan->is_free_plan): ?> - (<?php echo e(number_format($plan->price, 2)); ?>) <?php endif; ?> - (<?php echo e($plan->duration_in_days); ?> <?php echo e(__("Day")); ?>) </option> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </select> </div> <?php if (isset($component)) { $__componentOriginal797c51186a43d87e83e25a1a9a6b4418 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal797c51186a43d87e83e25a1a9a6b4418 = $attributes; } ?> <?php $component = App\View\Components\Fields\Input::resolve(['col' => '4','name' => 'plan_expired_at','required' => true,'title' => __('Plan Expired At'),'type' => 'date'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('input-field'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Fields\Input::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal797c51186a43d87e83e25a1a9a6b4418)): ?> <?php $attributes = $__attributesOriginal797c51186a43d87e83e25a1a9a6b4418; ?> <?php unset($__attributesOriginal797c51186a43d87e83e25a1a9a6b4418); ?> <?php endif; ?> <?php if (isset($__componentOriginal797c51186a43d87e83e25a1a9a6b4418)): ?> <?php $component = $__componentOriginal797c51186a43d87e83e25a1a9a6b4418; ?> <?php unset($__componentOriginal797c51186a43d87e83e25a1a9a6b4418); ?> <?php endif; ?> <div class="col-md-4"> <label for="payment_status" class="required form-label"><?php echo e(__('Payment Status')); ?></label> <select id="payment_status" name="payment_status" class="form-select form-select-solid" data-control="select2" required data-placeholder="<?php echo e(__('Select an option')); ?>" data-allow-clear="true"> <option></option> <option <?php echo e(old("payment_status") == 1 ? "selected" : ""); ?> value="1"><?php echo e(__("Paid")); ?></option> <option <?php echo e(old("payment_status") == 0 ? "selected" : ""); ?> value="0"><?php echo e(__("Not Paid")); ?></option> </select> </div> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $attributes = $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php if (isset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $component = $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginal8ccf90a59e764e7f6297ac27b693eda1 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal8ccf90a59e764e7f6297ac27b693eda1 = $attributes; } ?> <?php $component = App\View\Components\Card\CardFooter::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-footer'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardFooter::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginalc4c99ca5d114e5c407aea939feb70a52 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginalc4c99ca5d114e5c407aea939feb70a52 = $attributes; } ?> <?php $component = App\View\Components\Button\LoadingBtn::resolve(['title' => __('Attach Plan')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('loading-btn'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Button\LoadingBtn::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginalc4c99ca5d114e5c407aea939feb70a52)): ?> <?php $attributes = $__attributesOriginalc4c99ca5d114e5c407aea939feb70a52; ?> <?php unset($__attributesOriginalc4c99ca5d114e5c407aea939feb70a52); ?> <?php endif; ?> <?php if (isset($__componentOriginalc4c99ca5d114e5c407aea939feb70a52)): ?> <?php $component = $__componentOriginalc4c99ca5d114e5c407aea939feb70a52; ?> <?php unset($__componentOriginalc4c99ca5d114e5c407aea939feb70a52); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal8ccf90a59e764e7f6297ac27b693eda1)): ?> <?php $attributes = $__attributesOriginal8ccf90a59e764e7f6297ac27b693eda1; ?> <?php unset($__attributesOriginal8ccf90a59e764e7f6297ac27b693eda1); ?> <?php endif; ?> <?php if (isset($__componentOriginal8ccf90a59e764e7f6297ac27b693eda1)): ?> <?php $component = $__componentOriginal8ccf90a59e764e7f6297ac27b693eda1; ?> <?php unset($__componentOriginal8ccf90a59e764e7f6297ac27b693eda1); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $attributes = $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> <?php if (isset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $component = $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> </form> </div> </div> <div class="row my-5"> <div class="col-md-12 mb-5"> <?php if (isset($component)) { $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3 = $attributes; } ?> <?php $component = App\View\Components\Card\CardContent::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-content'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardContent::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginal621b973765c726fc88d870def47fa1a6 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal621b973765c726fc88d870def47fa1a6 = $attributes; } ?> <?php $component = App\View\Components\Card\CardHeader::resolve(['title' => __('Plans and invoices')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-header'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardHeader::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $attributes = $__attributesOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__attributesOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($__componentOriginal621b973765c726fc88d870def47fa1a6)): ?> <?php $component = $__componentOriginal621b973765c726fc88d870def47fa1a6; ?> <?php unset($__componentOriginal621b973765c726fc88d870def47fa1a6); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $component; } ?> <?php if (isset($attributes)) { $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08 = $attributes; } ?> <?php $component = App\View\Components\Card\CardBody::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('card-body'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Card\CardBody::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <table class="table text-center table-striped table-bordered"> <thead> <tr> <th>#</th> <th><?php echo e(__("Plan Name")); ?></th> <th><?php echo e(__("Plan Price")); ?></th> <th><?php echo e(__("Plan Start Date")); ?></th> <th><?php echo e(__("Plan Expiration Date")); ?></th> <th><?php echo e(__("Invoice Number")); ?></th> <th><?php echo e(__("Payment Status")); ?></th> </tr> </thead> <tbody> <?php $__currentLoopData = $user->plans()->latest("user_plans.created_at")->get(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $plan): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <tr> <td><?php echo e($loop->iteration); ?></td> <td><?php echo e($plan->title); ?></td> <td><?php echo e(number_format($plan->price,2)); ?></td> <td><?php echo e($plan->created_at->format("Y-m-d")); ?></td> <td><?php echo e($plan->plan_end_at); ?></td> <td><?php echo e($plan->invoice?->invoice_number); ?></td> <td> <?php if(!$loop->first): ?> <?php if($plan->invoice?->is_paid): ?> <div class="badge badge-success"><?php echo e(__("Paid")); ?></div> <?php endif; ?> <?php if(! $plan->invoice?->is_paid): ?> <div class="badge badge-danger"><?php echo e(__("Not Paid")); ?></div> <?php endif; ?> <?php else: ?> <?php if($plan->invoice?->is_paid): ?> <div class="badge badge-success"><?php echo e(__("Paid")); ?></div> <?php else: ?> <form action="<?php echo e(route('admin.invoices.mark-invoice-as-paid', $plan->invoice?->id)); ?>" method="post" id="mark_invoice_as_paid_<?php echo e($plan->invoice?->id); ?>"> <?php echo csrf_field(); ?> <?php echo method_field('PUT'); ?> <button class="btn btn-info btn-sm" type="button" onclick="if(confirm('<?php echo e(__('Are you sure ?')); ?>')) { document.getElementById('mark_invoice_as_paid_<?php echo e($plan->invoice->id); ?>').submit(); }"> <?php echo e(__("Mark as paid")); ?> </button> </form> <?php endif; ?> <?php endif; ?> </td> </tr> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </tbody> </table> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $attributes = $__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__attributesOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php if (isset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08)): ?> <?php $component = $__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08; ?> <?php unset($__componentOriginal0100f33f60b5f0d770c8394fa0ea5c08); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $attributes = $__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__attributesOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> <?php if (isset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3)): ?> <?php $component = $__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3; ?> <?php unset($__componentOriginalc0effd62b083bf085c8b6c73c5a6cce3); ?> <?php endif; ?> </div> </div> <?php $__env->stopSection(); ?> <?php $__env->startSection('scripts'); ?> <script src="https://cdnjs.cloudflare.com/ajax/libs/flatpickr/4.6.13/flatpickr.min.js"></script> <?php if(LaravelLocalization::getCurrentLocale() == "ar"): ?> <script src="https://cdnjs.cloudflare.com/ajax/libs/flatpickr/4.6.13/l10n/ar.min.js"></script> <?php endif; ?> <script> $(function () { let planExpiredAtFlatpickr = $("#plan_expired_at").flatpickr({ enableTime: false, dateFormat: "Y-m-d", <?php if(LaravelLocalization::getCurrentLocale() == "ar"): ?> locale: "ar" <?php endif; ?> }); function setPlanExpirationDate() { if ($('#plan_id').val()) { let plan = $('#plan_id').find('option:selected'); let date = plan.data('date'); planExpiredAtFlatpickr.setDate(date) } } setPlanExpirationDate(); $('#plan_id').on('change', function () { setPlanExpirationDate(); }) }) </script> <?php $__env->stopSection(); ?> <?php echo $__env->make("admin.layouts.app", \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/rwabtee/project/resources/views/admin/pages/users/show.blade.php ENDPATH**/ ?>
SAVE
CANCEL