This commit is contained in:
salam committed 2026-01-04 09:51:35 +01:00
1 parent 612a5444d3
commit 7dce81013b
3 files changed
+21 -5

No files matched your search

@@ -12,6 +12,8 @@ class Column3way extends Column
protected ?array $min;
protected ?array $act;
protected ?array $bookmakers;
protected ?bool $has_data;
@@ -32,19 +34,30 @@ class Column3way extends Column
{
$this->max['h3w'] = $record->odds_3way->max('h3w');
$this->min['h3w'] = $record->odds_3way->min('h3w');
$this->act['h3w'] = $record->odds_3way->where('bookmaker_id', auth()->user()->bookmaker_id);
$this->max['d3w'] = $record->odds_3way->max('d3w');
$this->min['d3w'] = $record->odds_3way->min('d3w');
$this->act['d3w'] = $record->odds_3way->where('bookmaker_id', auth()->user()->bookmaker_id)->get('d3w');
$this->max['a3w'] = $record->odds_3way->max('a3w');
$this->min['a3w'] = $record->odds_3way->min('a3w');
$this->act['a3w'] = $record->odds_3way->where('bookmaker_id', auth()->user()->bookmaker_id)->get('a3w');
$this->max['margin'] = $record->odds_3way->max('margin');
$this->min['margin'] = $record->odds_3way->min('margin');
$this->act['margin'] = $record->odds_3way->where('bookmaker_id', auth()->user()->bookmaker_id)->get('margin');
dd($this->act);
$this->has_data = count($record->odds_3way) ? true : false;
}
public function getAct()
{
return $this->act;
}
public function getMax()
{
return $this->max;
@@ -22,7 +22,6 @@
'decimal' => 2,
'max' => false,
'min' => false,
'main' => true,
])
@include('filament.tables.columns.multiline.odds', [
@@ -30,7 +29,6 @@
'decimal' => 2,
'max' => false,
'min' => false,
'main' => true,
])
@include('filament.tables.columns.multiline.odds', [
@@ -38,7 +36,6 @@
'decimal' => 2,
'max' => false,
'min' => false,
'main' => true,
])
@include('filament.tables.columns.multiline.odds', [
@@ -46,11 +43,16 @@
'decimal' => 1,
'max' => false,
'min' => false,
'main' => true,
])
@endif
@endforeach
<div class="col-span-5 h-2"></div>
@php
$act = $getAct();
@endphp
@foreach ($getBookmaker() as $bookmaker_id)
@foreach ($record->odds_3way as $item)
@if ($item->bookmaker_id == $bookmaker_id)
@@ -64,6 +66,7 @@
'decimal' => 2,
'max' => false,
'min' => false,
'over' => $item->d3w < $act['h3w'] ? 1 : 0,
])
@include('filament.tables.columns.multiline.odds', [
@@ -1,7 +1,7 @@
<div class="mb-0.5 ml-0.5
@if (isset($max) && $max == true) bg-green-600/25 rounded
@elseif (isset($min) && $min == true) bg-blue-600/25 rounded @endif
@if (isset($main) && $main == true) border border-gray-300 bg-gray-100 @endif"
@if (isset($over) && $over == true) border border-gray-300 bg-gray-100 @endif"
style="font-size: 10.5px; text-align:center;">
&nbsp;
@if (isset($odd))