@extends('layouts.app') @section('title','Buy Points') @push('styles') @endpush @section('content') {{-- Current Balance --}}
💰
Current Balance
{{ number_format($user->points) }} pts
≈ GH₵{{ number_format(round($user->points * (float)\App\Models\Setting::get('points_to_cedis_rate',0.001), 2), 2) }}
Rate
GH₵{{ $ratePerK }}
per 1,000 pts
{{-- Steps --}}
1
Choose Package
2
Payment Method
3
Confirm
@csrf {{-- STEP 1: Choose Package ────────────────────────────────────────────── --}}
Select a Package
@foreach($packages as $pkg) @endforeach
{{-- Custom Amount --}}
— or enter custom amount —
GH₵0.00
{{-- STEP 2: Payment Method ─────────────────────────────────────────────── --}} {{-- STEP 3: Confirm ───────────────────────────────────────────────────── --}}
{{-- Purchase History --}} @if($purchases->isNotEmpty())
Purchase History
@foreach($purchases as $p)
{{ $p->method_icon }}
{{ number_format($p->total_points) }} points
{{ $p->method_label }} • {{ $p->created_at->format('d M Y') }}
GH₵{{ number_format($p->amount_ghs,2) }}
{{ ucfirst($p->status) }}
@endforeach
@endif @endsection @push('scripts') @endpush