@php use \App\Enums\TransactionType as dTType; use \App\Enums\TransactionStatus as dTStatus; use \App\Enums\TransactionCalcType as dTCType; $base_currency = base_currency(); $amount = $tnx->amount; $total = $tnx->total; $currency = $tnx->currency; $tnx_currency = $tnx->tnx_currency; $tnx_amount = $tnx->tnx_amount; $tnx_total = $tnx->tnx_amount; $exchange = $tnx->exchange; $completed_by = data_get($tnx, 'completed_by'); $confirmed_by = data_get($tnx, 'confirmed_by'); $pay_to_acc_name = ''; if ($tnx->tnx_method == 'bank-transfer') { $pay_to_acc_name = data_get($tnx, 'meta.pay_meta.account_name'); } if ($tnx->tnx_method == 'crypto-wallet') { $pay_to_acc_name = get_currency(data_get($tnx, 'meta.currency'), 'name'); } if ($tnx->tnx_method == 'wd-bank-transfer') { $pay_to_acc_name = data_get($tnx, 'meta.pay_meta.payment.acc_name'); } if ($tnx->tnx_method == 'wd-paypal') { $pay_to_acc_name = data_get($tnx, 'meta.pay_meta.label'); } @endphp

{{ __('Transaction') }} #{{ the_tnx(data_get($tnx, 'tnx')) }}

{!! tnx_type_icon($transaction, 'tnx-type-icon') !!}
{{ money($tnx_amount, $tnx_currency) }}
{{ show_date(data_get($tnx, 'created_at'), true) }}
{{ __('In Account') }}
{{ __('Amount') }} {{ money($amount, $base_currency) }}
{{ __('Total :Type', ['type' => data_get($tnx, 'type')]) }} {{ money($total, $base_currency) }}
{{ __('Fees') }} {{ money(data_get($tnx, 'fees', '-'), $base_currency) }}
{{ __('In Transaction') }}
{{ __('Amount') }} {{ money($tnx_amount, $tnx_currency) }}
{{ ($tnx->type == dTType::WITHDRAW) ? __('Total Withdraw') : (($tnx->type == dTType::DEPOSIT) ? __('Total Payment') : __('Total Amount') ) }} {{ money(data_get($tnx, 'tnx_total', '-'), $tnx_currency) }}
{{ __('Exchage Rate') }} {{ __('1 :from = :rate', ['rate' => money($exchange, $tnx_currency), 'from' => $base_currency]) }}
{{ __('User Account') }} {{ the_uid($tnx->customer->id) }}
{{ __('User Email') }} {{ str_protect($tnx->customer->email) }}
@if($base_currency!=$currency)

{{ __("Attention: Current base currency (:system) does not match with this transaction currency (:tnx).", ['system' => $base_currency, 'tnx' => $currency]) }}

{{ __('Note: System base currency was changed after transaction made. ') }}

@endif
{{ __('Order Details') }}
{{ __('Order Date') }} {{ show_date(data_get($tnx, 'created_at')) }}
{{ __('Placed By') }} {{ the_uid($tnx->transaction_by->id) }}
@if(data_get($tnx, 'confirmed_at'))
{{ __('Confirmed At') }} {{ show_date(data_get($tnx, 'confirmed_at'), true) }}
{{ __('Confirmed By') }} {!! (isset($confirmed_by['name']) ? $confirmed_by['name'] : ''. __('Unknown') .'') !!}
@endif @if(data_get($tnx, 'completed_at'))
{{ __('Completed At') }} {{ show_date(data_get($tnx, 'completed_at'), true) }}
{{ __('Completed By') }} {!! (isset($completed_by['name']) ? $completed_by['name'] : ''. __('Unknown') .'') !!}
@endif
{{ __('Additional Details') }}
{{ __('Transaction Type') }} {{ ucfirst(data_get($tnx, 'type')) }}
{{ __('Payment Gateway') }} {{ data_get($tnx, 'method_name') }} @if(data_get($tnx, 'is_online') == 1) {{ __('Online Gateway') }} @endif
@if(data_get($tnx, 'pay_from'))
{{ __('Payment From') }} {{ from_to_case(data_get($tnx, 'pay_from', '~')) }}
@endif @if(data_get($tnx, 'reference'))
{{ __('Reference / Hash') }} {{ data_get($tnx, 'reference', '~') }}
@endif @if(data_get($tnx, 'pay_to'))
{{ __('Payment To') }} @if($pay_to_acc_name) ({{ $pay_to_acc_name }}) @endif {{ data_get($tnx, 'pay_to', '~') }}
@endif @if(data_get($tnx->ledger,'balance'))
{{ __('Updated Balance') }} {{ money(data_get($tnx->ledger, 'balance'),base_currency()) }}
@endif @if(data_get($tnx, 'description'))
{{ __('Transaction Details') }} {{ data_get($tnx, 'description') }}
@endif @if(data_get($tnx, 'remarks'))
{{ __('Note by Admin') }} {{ data_get($tnx, 'remarks') }}
@endif