@extends('layouts.admin') @section('title', tr('beneficiary_transaction_details')) @section('content') @section('breadcrumb') @endsection
{{-- SUMMARY --}}
{{ tr('order_id') }}
{{ $beneficiary_transaction->order_id }}
{{ tr('amount') }}
{{ formatted_amount($beneficiary_transaction->amount, $beneficiary_transaction->quote?->source?->currency) }}
{{ tr('fees') }}
{{ formatted_amount($beneficiary_transaction->commission_amount) }}
{{ tr('recipient_amount') }}
{{ formatted_amount($beneficiary_transaction->recipient_amount , $beneficiary_transaction->receiving_currency) }}
{{ tr('status') }}
{{ beneficiary_transaction_status_formatted($beneficiary_transaction->status) }}
{{ tr('sub_status') }}
{{ $beneficiary_transaction->sub_status ? beneficiary_transaction_sub_status($beneficiary_transaction->sub_status) : tr('na') }}
{{ tr('created_at') }}
{{ $beneficiary_transaction->created_at->format('d M, Y') }}
{{-- TRANSACTION DETAILS --}}
{{ tr('transaction_details') }}
@php $fields = [ ['unique_id', 'ri-hashtag', $beneficiary_transaction->unique_id], ['order_id', 'ri-hashtag', $beneficiary_transaction->order_id], ['user', 'ri-user-3-line', $beneficiary_transaction->user->name], ['amount', 'ri-bank-card-line', formatted_amount($beneficiary_transaction->amount, $beneficiary_transaction->quote?->source?->currency)], ['fees', 'ri-percent-line', formatted_amount($beneficiary_transaction->commission_amount)], ['total_amount', 'ri-calculator-line', formatted_amount($beneficiary_transaction->total_amount)], ['recipient_amount', 'ri-money-dollar-circle-line', formatted_amount($beneficiary_transaction->recipient_amount , $beneficiary_transaction->receiving_currency)], ['receiving_currency', 'ri-money-rupee-circle-line', $beneficiary_transaction->receiving_currency], ['utr_number', 'ri-barcode-line', $beneficiary_transaction->external_reference_id], ['client_reference_id', 'ri-barcode-line', $beneficiary_transaction->client_reference_id], ['txn_ref_no' , 'ri-barcode-line', $beneficiary_transaction->txn_ref_no], ['transfer_type', 'ri-exchange-funds-line', transfer_type_label($beneficiary_transaction->transfer_type)], ]; @endphp
@foreach ($fields as $f) @if($f[2] == null) @continue @endif
{{ tr($f[0]) }}
@if($f[0] === 'utr_number') {{ $f[2] }} @else
{{ $f[2] ?: tr('na') }}
@endif
@endforeach @if ($beneficiary_transaction->notes != null)
{{ tr('rejection_reason') }}
{{ $beneficiary_transaction->notes ?? tr('na') }}
@endif
{{ tr('supporting_document') }}
{!! filePreview($beneficiary_transaction->supporting_document) !!}
{{ tr('created_at') }}
{{ common_date($beneficiary_transaction->created_at, auth()->user()->timezone, 'd M Y h:i A') }}
@if(!empty($beneficiary_transaction->external_type) && $beneficiary_transaction->is_service_called)
{{ tr('processed_via') }}
{{ map_service_name($beneficiary_transaction->external_type) }}
@endif @if($beneficiary_transaction->rail)
{{ tr('type') }}
{{ $beneficiary_transaction->rail ?? tr('na') }}
@endif @if($processingTime)
{{ tr('processing_time') }}
{{ $processingTime }}
@endif
{{-- SENDER DETAILS --}} @if ($beneficiary_transaction->sender)
{{ tr('sender_details') }}
@php $sender = $beneficiary_transaction->sender; $fields = [ ['type' , 'ri-list-check', $sender->type == USER_TYPE_INDIVIDUAL ? tr('individual') : tr('business')], ['first_name', 'ri-user-line', $sender->title . " " . $sender->first_name], ['middle_name', 'ri-user-line', $sender->middle_name], ['last_name', 'ri-user-line', $sender->last_name], ['email', 'ri-mail-line', $sender->email], ['mobile_country_code', 'ri-phone-line', $sender->mobile_country_code], ['mobile', 'ri-smartphone-line', $sender->mobile], ['dob', 'ri-calendar-line', common_date($sender->dob, auth()->user()->timezone, 'd M Y')], ['country', 'ri-map-pin-line', get_country($sender->country)], ['nationality', 'ri-map-pin-line', get_country($sender->nationality)], ['address_1', 'ri-road-map-line', $sender->address_1], ['address_2', 'ri-road-map-line', $sender->address_2], ['city', 'ri-building-line', $sender->city], ['state', 'ri-building-line', $sender->state], ['postal_code', 'ri-mail-send-line', $sender->postal_code], ['id_type', 'ri-id-card-line', \App\Models\Lookup::findValuebyKey($sender->id_type, LOOKUP_TYPE_ID_TYPE) ?? ''], ['id_number', 'ri-hashtag', $sender->id_number], ['source_of_funds', 'ri-wallet-line', $sender->source_of_funds], ['status', 'ri-shield-check-line', sender_status_formatted($sender->status)], ]; $notEmpty = fn($v) => !($v === null || $v === '' || $v === []); @endphp
@foreach ($fields as $field) @if ($notEmpty($field[2]))
{{ tr($field[0]) }}
{{ $field[2] ?: tr('na') }}
@endif @endforeach
@if($beneficiary_transaction->sender) @endif @endif {{-- BENEFICIARY DETAILS --}} @php $copyText = "Account Number - " . ($beneficiary_transaction->beneficiaryAccount->account_number ?? 'NA') . "\n" . "Account Name - " . ($beneficiary_transaction->beneficiaryAccount->account_name ?? 'NA') . "\n" . "Code - " . ($beneficiary_transaction->beneficiaryAccount->swift_code ?? 'NA'); @endphp
{{ tr('beneficiary_details') }}
@php $fields = [ ['type', 'ri-list-check', $beneficiary_transaction->beneficiaryAccount->type == 1 ? tr('individual') : tr('business')], ['name', 'ri-user-3-line', $beneficiary_transaction->beneficiaryAccount->type == 1 ? ($beneficiary_transaction->beneficiaryAccount->first_name . ' ' . $beneficiary_transaction->beneficiaryAccount->last_name) : $beneficiary_transaction->beneficiaryAccount->business_name], ['bank_name', 'ri-bank-line', $beneficiary_transaction->beneficiaryAccount->bank_name], ['account_name', 'ri-bank-line', $beneficiary_transaction->beneficiaryAccount->account_name], ['account_number', 'ri-bank-card-line', $beneficiary_transaction->beneficiaryAccount->account_number], ['swift_code', 'ri-shield-keyhole-line', $beneficiary_transaction->beneficiaryAccount->swift_code], ['purpose_of_transaction', 'ri-shield-keyhole-line', $beneficiary_transaction->beneficiaryAccount->beneficiaryAdditionalDetail->purpose_of_transaction], ['intermediary_bank_swift_code', 'ri-hashtag', $beneficiary_transaction->beneficiaryAccount->intermediary_bank_swift_code], ]; $validationFields = [ ['Validated', 'ri-shield-check-line', $account_validation['is_validated'], 'bg-success', 'bg-danger'], ['Account Exists', 'ri-bank-line', $account_validation['is_account_exist'], 'bg-success', 'bg-danger'], ['NRE Account', 'ri-global-line', $account_validation['is_nre_account'], 'bg-info', 'bg-secondary'], ]; @endphp
@foreach ($fields as $f) @if(!empty($f[2]))
{{ tr($f[0]) }}
{{ $f[2] ?: tr('na') }}
@endif @endforeach
{{ tr('status') }}
{{ $beneficiary_transaction->beneficiaryAccount->status ? tr('active') : tr('inactive') }}
@foreach ($validationFields as $vf)
{{ $vf[0] }}
{{ $vf[2] ? tr('yes') : tr('no') }}
@endforeach
{{-- QUOTE DETAILS --}}
{{ tr('quote_details') }}
@php $fields = [ ['unique_id', 'ri-bank-line', $beneficiary_transaction->quote->unique_id], ['fx_rate', 'ri-line-chart-line', $beneficiary_transaction->quote->fx_rate], ['external_fx_rate', 'ri-funds-line', $beneficiary_transaction->quote->external_fx_rate], ['quote_type', 'ri-price-tag-3-line', $beneficiary_transaction->quote->quote_type], ]; @endphp
@foreach ($fields as $field) @if(!empty($field[2]))
{{ tr($field[0]) }}
{{ $field[2] ?: tr('na') }}
@endif @endforeach
{{ tr('status') }}
{{ quote_status_formatted($beneficiary_transaction->quote->status) }}
@include('components.external-calls',[$beneficiary_transaction]) @include('components.callback-logs',[$beneficiary_transaction]) @if ($beneficiary_transaction->statusHistories->count() > 0) @include('components.timeline',[$beneficiary_transaction]) @endif
@endsection