@extends('corporate.layout.base') @section('title', 'Recharge ') @section('content') @if(empty($default_card) && (count($cards) !=0))
Please active any one card.!
@elseif(count($cards) ==0)
Please Add card.!
@endif
Card Details
@if(Setting::get('CARD') == 1) @lang('user.card.add_card')     @endif @if(Auth::user()->recharge_option == 'PREPAID' && $default_card) @lang('user.card.Recharge') @else @if(Auth::user()->recharge_option == 'PREPAID') @endif @endif


@foreach($cards as $index => $card) @endforeach
@lang('admin.id') Last Four Digit Brand Status @lang('admin.action')
{{ $index + 1 }} ****{{$card->last_four}} {{ $card->brand }} is_default==0) style="background-color: greenyellow;" @else style="background-color: #c4e88b;" @endif>{{ ($card->is_default==0) ? 'NoDefault' : 'Default' }}
{{csrf_field()}} @if($card->is_default ==0 ) Active @else Deactive @endif
@lang('admin.id') Last Four Digit Brand Status @lang('admin.action')
@if(Setting::get('demo_mode') == 1)
** Demo Mode : No Permission to Edit and Delete.
@endif
Payment Transaction @if(Setting::get('demo_mode', 0) == 1) (*personal information hidden in demo) @endif
@php $user_ids = \App\User::wherecorporate_id($corporate->id)->pluck('id'); @endphp
@lang('admin.corporate.Ride_count') @lang('admin.recharge_option') @lang('admin.total_riding_amount') @lang('admin.action')
{{ count(\App\UserRequests::whereIn('user_id',$user_ids)->wherepostpaid_payment_status('NOTPAID')->wherestatus('COMPLETED')->pluck('id')) }} {{ $corporate->recharge_option }} {{ currency(\App\UserRequestPayment::whereIn('request_id',$user_request_ids)->sum('total')) }} @if(\App\UserRequestPayment::whereIn('request_id',$user_request_ids)->sum('total') != 0) @if($default_card && (Auth::user()->recharge_option == 'POSTPAID')) @else @if(Auth::user()->recharge_option == 'POSTPAID') @else PAID @endif @endif @else Paid @endif
@lang('admin.corporate.Ride_count') @lang('admin.recharge_option') @lang('admin.total_riding_amount') @lang('admin.action')
@if(Setting::get('demo_mode') == 1)
** Demo Mode : No Permission to Edit and Delete.
@endif
Transaction History @if(Setting::get('demo_mode', 0) == 1) (*personal information hidden in demo) @endif
@foreach($tranasction_history as $index => $history) @endforeach
@lang('admin.id') Recharge Option Amount Payment Status Paid Date
{{ $index + 1 + $page_plus }} {{ $history->recharge_option }} {{ $history->amount }} {{ $history->payment_status }} {{ date('d M Y', strtotime($history->created_at) )}}
@lang('admin.id') Recharge Option Amount Payment Status Paid Date
{{--$recharges->appends(['search' => @Request::get('search')])->links()--}}
@if(Setting::get('CARD') == 1) @endif @endsection