@extends('layouts.header') @section('content')
@csrf
@if (isset($bets) && $bets->count() > 0) @php $i = 0; @endphp @foreach ($bets as $group_key => $bet_group) @php $i++; @endphp @endforeach @else @endif
S.No Date Type Number Points Total Status
{{ $i }} {{ \Carbon\Carbon::parse($bet_group['bets'][0]['created_at'])->format('d/m/y') }} {{ $bet_group['bets'][0]['bet_type'] }} @php $numbers = collect($bet_group['bets'])->pluck('number')->toArray(); @endphp {!! implode( ',', array_map( function ($num, $index) { return ($index + 1) % 5 == 0 ? $num . '
' : $num; }, $numbers, array_keys($numbers), ), ) !!}
{{ $bet_group['bets'][0]['amount'] ?? 'N/A' }} {{ $bet_group['total_amount'] }} @if ($bet_group['bets'][0]['status'] == 'win') {{ $bet_group['bets'][0]['status'] }} @elseif($bet_group['bets'][0]['status'] == 'loose') {{ $bet_group['bets'][0]['status'] }} @else {{ $bet_group['bets'][0]['status'] }} @endif
No Data Found
@endsection