@extends('dashboard.layouts.main') @section('title', 'Core Mining ⛏️- AI Gold Mining ⛏️') @push('styles') @endpush @section('content')

Mining Transaction History

Track all your mining activities and transactions in one place

Total Earning
${{ number_format($totalEarning ?? 0, 2) }}
Referral Earning
${{ number_format($referralEarning ?? 0, 2) }}
Total Deposit
${{ number_format($totalDeposits ?? 0, 2) }}
Total Withdrawn
${{ number_format($totalWithdrawals ?? 0, 2) }}

All Transactions

View and filter your complete transaction history

@forelse(($transactionsData['data'] ?? []) as $transaction) @php $type = $transaction['type']; $amount = $transaction['amount']; $description = $transaction['description'] ?? ''; $status = $transaction['status'] ?? 'completed'; $createdAt = $transaction['created_at']; // Determine icon and styling based on transaction type $isCredit = in_array($type, ['deposit', 'referral_earning', 'mining_earning']); $iconClass = 'transactions-type-icon-success-new'; $icon = 'fa-arrow-down'; $amountClass = 'transactions-amount-success-new'; $amountPrefix = '+'; if ($type === 'withdrawal') { $iconClass = 'transactions-type-icon-danger-new'; $icon = 'fa-arrow-up'; $amountClass = 'transactions-amount-danger-new'; $amountPrefix = '-'; } elseif ($type === 'referral_earning') { $icon = 'fa-trophy'; } elseif ($type === 'mining_earning') { $icon = 'fa-coins'; } elseif ($type === 'deposit') { $icon = 'fa-plus-circle'; } // Format date $date = $createdAt instanceof \Carbon\Carbon ? $createdAt : \Carbon\Carbon::parse($createdAt); $dateFormatted = $date->format('M d, Y'); $timeFormatted = $date->format('h:i A'); $dateTimeFormatted = $dateFormatted . ', ' . $timeFormatted; // Status badge class $statusBadgeClass = 'transactions-status-' . $status; $statusBadgeClassNew = 'transactions-status-' . $status . '-new'; @endphp @empty @endforelse
Transaction Amount Status
{{ $description ?: ucfirst(str_replace('_', ' ', $type)) }}
{{ $dateTimeFormatted }}
{{ $amountPrefix }}${{ number_format($amount, 2) }}
@if($type === 'deposit') Fund Wallet: ${{ number_format($balances['fund_wallet'] ?? 0, 2) }} @elseif($type === 'withdrawal') Net Balance: ${{ number_format($balances['net_balance'] ?? 0, 2) }} @elseif($type === 'referral_earning') Referral Earning: ${{ number_format($balances['referral_earning'] ?? 0, 2) }} @elseif($type === 'mining_earning') Mining Earning: ${{ number_format($balances['mining_earning'] ?? 0, 2) }} @else Net Balance: ${{ number_format($balances['net_balance'] ?? 0, 2) }} @endif
{{ ucfirst($status) }}
{{ ucfirst($status) }}
{{ $date->diffForHumans() }}

No transactions found

@php $lastPage = (int) ($transactionsData['last_page'] ?? 1); @endphp @if($lastPage > 1)
@php $currentPage = (int) ($transactionsData['current_page'] ?? 1); $prevUrl = $currentPage > 1 ? request()->fullUrlWithQuery(['page' => $currentPage - 1]) : null; $nextUrl = $currentPage < $lastPage ? request()->fullUrlWithQuery(['page' => $currentPage + 1]) : null; $startPage = max(1, $currentPage - 2); $endPage = min($lastPage, $currentPage + 2); if ($startPage > 1) { $endPage = min($lastPage, $startPage + 4); } if ($endPage < $lastPage) { $startPage = max(1, $endPage - 4); } @endphp @if($prevUrl) @else @endif
@if($startPage > 1) 1 @if($startPage > 2) ... @endif @endif @for($page = $startPage; $page <= $endPage; $page++) @if($page === $currentPage) {{ $page }} @else {{ $page }} @endif @endfor @if($endPage < $lastPage) @if($endPage < $lastPage - 1) ... @endif {{ $lastPage }} @endif
@if($nextUrl) @else @endif
@endif
@push('scripts') @endpush @endsection