wip
This commit is contained in:
1 parent
a26c555b05
commit
cec5a5e2f7
20 files changed
+211
-120
No files matched your search
@@ -1,43 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Actions;
|
||||
|
||||
use App\Models\Event;
|
||||
|
||||
class MapperEvents
|
||||
{
|
||||
public static function load()
|
||||
{
|
||||
switch (auth()->user()->provider_id) {
|
||||
case 2:
|
||||
// BETSAPI
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('betsapi_id', 0);
|
||||
break;
|
||||
|
||||
case 20:
|
||||
// Magloo Kenia
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('magnig_id', 0);
|
||||
break;
|
||||
|
||||
case 24:
|
||||
// Magloo Nigeria
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('magken_id', 0);
|
||||
break;
|
||||
|
||||
case 26:
|
||||
// Logifuture Nigeria
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('lognig_id', 0);
|
||||
break;
|
||||
|
||||
case 27:
|
||||
// Magloo Colombia
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('logcol_id', 0);
|
||||
break;
|
||||
|
||||
default:
|
||||
return Event::query()->where('sport_id', auth()->user()->sport_id)->where('betradar_id', 0);
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Actions;
|
||||
|
||||
use App\Models\Mapper;
|
||||
|
||||
class MapperProvider
|
||||
{
|
||||
public static function load()
|
||||
{
|
||||
|
||||
return Mapper::query()->where('sport_id', auth()->user()->sport_id)->where('provider_id', auth()->user()->provider_id);
|
||||
}
|
||||
}
|
||||
@@ -4,8 +4,7 @@ namespace App\Console\Commands\Grapper\Betsapi;
|
||||
|
||||
use App\Console\Commands\Curl;
|
||||
use App\Console\Commands\Nuh;
|
||||
use App\Models\Event;
|
||||
use App\Models\Mapper;
|
||||
use App\Mapper\FindEvent;
|
||||
use App\Models\Sport;
|
||||
use App\Utilities\Notice;
|
||||
use Illuminate\Support\Carbon;
|
||||
@@ -59,6 +58,7 @@ class Fixtures
|
||||
if (isset($row['home']['id']) && isset($row['away']['id']) && strpos($row['league']['name'], 'Esoccer') === false) {
|
||||
|
||||
$event = [
|
||||
'event_id' => (int) $row['id'],
|
||||
'sport_id' => (int) $sport_id,
|
||||
'provider_id' => (int) Nuh::$options['provider_id'],
|
||||
'starttime' => Carbon::createFromTimestamp((string) $row['time'])->toDateTimeString(),
|
||||
@@ -72,13 +72,8 @@ class Fixtures
|
||||
'group_id' => (int) $row['league']['id'] ?? 0,
|
||||
'group_cc' => strtoupper($row['league']['cc']) ?? '',
|
||||
];
|
||||
$event_id = (int) $row['id'];
|
||||
$match_id = Event::where('betsapi_id', $event_id)->value('id');
|
||||
if ($match_id) {
|
||||
Mapper::where('event_id', $event_id)->delete();
|
||||
} else {
|
||||
Mapper::updateOrCreate(['event_id' => $event_id], $event);
|
||||
}
|
||||
|
||||
FindEvent::search($event);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
{"success":1,"pager":{"page":1,"per_page":50,"total":103},"results":[{"id":"11196131","sport_id":"1","time":"1767265200","time_status":"0","league":{"id":"2369","name":"Syria Division 1","cc":"sy"},"home":{"id":"1232083","name":"Omaya SC","image_id":"1311226","cc":"sy"},"away":{"id":"184357","name":"Hutteen","image_id":"189388","cc":"sy"},"ss":null,"round":"3"},{"id":"11196132","sport_id":"1","time":"1767265200","time_status":"0","league":{"id":"2369","name":"Syria Division 1","cc":"sy"},"home":{"id":"177711","name":"Tishreen","image_id":"157792","cc":"sy"},"away":{"id":"1231539","name":"Khan Shaykhun SC","image_id":"1311228","cc":"sy"},"ss":null,"round":"3"},{"id":"11198690","sport_id":"1","time":"1767265200","time_status":"0","league":{"id":"42027","name":"Algeria U20 League","cc":"dz"},"home":{"id":"1194258","name":"ES Ben Aknoun U20","image_id":"1292973","cc":"dz"},"away":{"id":"1206680","name":"Paradou AC U20","image_id":"1300782","cc":"dz"},"ss":null,"bet365_id":"187231851"},{"id":"10173612","sport_id":"1","time":"1767270600","time_status":"0","league":{"id":"880","name":"England Championship","cc":"gb"},"home":{"id":"17201","name":"Blackburn","image_id":"46","cc":"gb"},"away":{"id":"1875","name":"Wrexham","image_id":"64","cc":"gb"},"ss":null,"round":"25","bet365_id":"186496893"},{"id":"10270360","sport_id":"1","time":"1767270600","time_status":"0","league":{"id":"156","name":"Wales Premier League","cc":"gb"},"home":{"id":"60899","name":"Colwyn Bay","image_id":"597088","cc":"gb"},"away":{"id":"8512","name":"Flint Town Utd","image_id":"37090","cc":"gb"},"ss":null,"round":"21","bet365_id":"185889723"},{"id":"10476839","sport_id":"1","time":"1767270900","time_status":"0","league":{"id":"809","name":"Saudi Arabia Division 1","cc":"sa"},"home":{"id":"56220","name":"Al Orubah","image_id":"114259","cc":"sa"},"away":{"id":"682282","name":"Al Jandal","image_id":"522144","cc":"sa"},"ss":null,"round":"14","bet365_id":"185936511"},{"id":"10476859","sport_id":"1","time":"1767270900","time_status":"0","league":{"id":"809","name":"Saudi Arabia Division 1","cc":"sa"},"home":{"id":"56221","name":"Al Taee","image_id":"168072","cc":"sa"},"away":{"id":"583338","name":"Al Zulfi","image_id":"757980","cc":"sa"},"ss":null,"round":"14","bet365_id":"185936514"},{"id":"11133547","sport_id":"1","time":"1767271800","time_status":"0","league":{"id":"1945","name":"Saudi Arabia Division 2","cc":"sa"},"home":{"id":"244281","name":"Weg Taif SC","image_id":"276755","cc":"sa"},"away":{"id":"622080","name":"Al Rayyan Ar Rawdah","image_id":"857289","cc":"sa"},"ss":null,"round":"13"},{"id":"10321213","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"319","name":"England Northern Premier League","cc":"gb"},"home":{"id":"46501","name":"Morpeth Town","image_id":"47120","cc":"gb"},"away":{"id":"193388","name":"Stockton Town","image_id":"630010","cc":"gb"},"ss":null,"round":"25","bet365_id":"186823577"},{"id":"10874159","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"854","name":"Iran Pro League","cc":"ir"},"home":{"id":"15854","name":"Sepahan","image_id":"8018","cc":"ir"},"away":{"id":"43979","name":"Esteghlal","image_id":"34316","cc":"ir"},"ss":"3-0","round":"10"},{"id":"11173754","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"39521","name":"Iraq Stars League","cc":"iq"},"home":{"id":"284537","name":"Al Minaa","image_id":"405353","cc":"iq"},"away":{"id":"594899","name":"Newroz SC","image_id":"845058","cc":"iq"},"ss":null,"round":"9","bet365_id":"187165073"},{"id":"11173872","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"39521","name":"Iraq Stars League","cc":"iq"},"home":{"id":"284412","name":"Al Najaf","image_id":"508998","cc":"iq"},"away":{"id":"239046","name":"Al Naft SC","image_id":"508988","cc":"iq"},"ss":null,"round":"9","bet365_id":"187149701"},{"id":"11202124","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"1212","name":"England Northern League Division One","cc":"gb"},"home":{"id":"172842","name":"Grimsby Borough","image_id":"58005","cc":"gb"},"away":{"id":"507428","name":"North Ferriby","image_id":"170","cc":"gb"},"ss":null,"bet365_id":"187149512"},{"id":"11202354","sport_id":"1","time":"1767272400","time_status":"0","league":{"id":"1212","name":"England Northern League Division One","cc":"gb"},"home":{"id":"64562","name":"Bedworth Utd","image_id":"188","cc":"gb"},"away":{"id":"296243","name":"Coventry Sphinx","image_id":"37994","cc":"gb"},"ss":null,"bet365_id":"187149503"},{"id":"11205156","sport_id":"1","time":"1767273600","time_status":"0","league":{"id":"12352","name":"Oman U21 Championship","cc":"om"},"home":{"id":"241665","name":"Dhofar U21","image_id":null,"cc":null},"away":{"id":"1231918","name":"Al Shabab Seeb U21","image_id":null,"cc":null},"ss":null,"bet365_id":"187161283"},{"id":"10205757","sport_id":"1","time":"1767276000","time_status":"0","league":{"id":"18163","name":"Wales Championship North","cc":"gb"},"home":{Line truncated
|
||||
@@ -13,7 +13,7 @@ use App\Models\BettypeUser;
|
||||
use App\Models\Country;
|
||||
use App\Models\Event;
|
||||
use App\Models\MultilineClient;
|
||||
use Carbon\Carbon;
|
||||
use CodeWithKyrian\FilamentDateRange\Forms\Components\DateRangePicker;
|
||||
use Filament\Actions\Action;
|
||||
use Filament\Actions\ActionGroup;
|
||||
use Filament\Actions\DeleteAction;
|
||||
@@ -28,6 +28,7 @@ use Filament\Tables\Enums\FiltersLayout;
|
||||
use Filament\Tables\Filters\Filter;
|
||||
use Filament\Tables\Table;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use Illuminate\Support\Carbon;
|
||||
|
||||
class EventsTable
|
||||
{
|
||||
@@ -235,13 +236,30 @@ class EventsTable
|
||||
}
|
||||
$arr = [];
|
||||
foreach ($res as $val) {
|
||||
$arr[$val->competition_group_id] = $val->country?->name.' - '.$val->competition_group->name;
|
||||
$arr[$val->competition_group_id] = $val->country?->name.' '.$val->competition_group->name;
|
||||
}
|
||||
asort($arr);
|
||||
|
||||
return $arr;
|
||||
})
|
||||
->live(),
|
||||
DateRangePicker::make('starttime_period')
|
||||
->columnSpan(2)
|
||||
->startPrefix('From')
|
||||
->displayFormat('d M Y')
|
||||
->minDate(now())
|
||||
->hiddenLabel()
|
||||
->label('')
|
||||
->live(),
|
||||
Action::make('reset')
|
||||
->hiddenLabel()
|
||||
->color('gray')
|
||||
->icon('heroicon-o-arrow-path')
|
||||
->action(function ($livewire) {
|
||||
$livewire->resetTableFiltersForm(); // Clears all filters
|
||||
$livewire->tableSearch = ''; // Clears the main search bar
|
||||
}),
|
||||
|
||||
])
|
||||
->query(function (Builder $query, array $data): Builder {
|
||||
return $query
|
||||
@@ -251,6 +269,28 @@ class EventsTable
|
||||
)->when(
|
||||
$data['competition_group_id'],
|
||||
fn (Builder $query, $competition_group_id) => $query->whereIn('competition_group_id', $competition_group_id)
|
||||
)->when(
|
||||
$data['starttime_period'],
|
||||
function (Builder $query, $starttime_period) {
|
||||
if (isset($starttime_period['start']) && isset($starttime_period['end'])) {
|
||||
$from = Carbon::createFromDate($starttime_period['start']);
|
||||
$end = Carbon::createFromDate($starttime_period['end']);
|
||||
|
||||
return $query
|
||||
->where('starttime', '>=', $from->format('Y-m-d 00:00:00'))
|
||||
->where('starttime', '<=', $end->format('Y-m-d 00:00:00'));
|
||||
} elseif (isset($starttime_period['start'])) {
|
||||
$from = Carbon::createFromDate($starttime_period['start']);
|
||||
|
||||
return $query
|
||||
->where('starttime', '>=', $from->format('Y-m-d 00:00:00'));
|
||||
} elseif (isset($starttime_period['end'])) {
|
||||
$end = Carbon::createFromDate($starttime_period['end']);
|
||||
|
||||
return $query
|
||||
->where('starttime', '<=', $end->format('Y-m-d 00:00:00'));
|
||||
}
|
||||
}
|
||||
);
|
||||
})
|
||||
->columns(6)->columnSpan(6),
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
namespace App\Livewire;
|
||||
|
||||
use App\Actions\MapperEvents;
|
||||
use App\Filament\Tables\Columns\MapperLeftColumn;
|
||||
use App\Mapper\LoadEvents;
|
||||
use App\Models\CompetitionGroup;
|
||||
use App\Models\Country;
|
||||
use App\Models\Event;
|
||||
@@ -38,7 +38,7 @@ class MapperLeft extends Component implements HasActions, HasSchemas, HasTable
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $table
|
||||
->query(MapperEvents::load())
|
||||
->query(LoadEvents::load())
|
||||
->columns([
|
||||
MapperLeftColumn::make('left')->label(''),
|
||||
])
|
||||
@@ -108,6 +108,7 @@ class MapperLeft extends Component implements HasActions, HasSchemas, HasTable
|
||||
->columns(4)->columnSpan(4),
|
||||
], layout: FiltersLayout::AboveContent)
|
||||
->filtersFormColumns(3)
|
||||
->persistFiltersInSession()
|
||||
->deferFilters(false)
|
||||
->toolbarActions([
|
||||
Action::make('reload_data_left')
|
||||
@@ -117,8 +118,7 @@ class MapperLeft extends Component implements HasActions, HasSchemas, HasTable
|
||||
// ->icon('phosphor-x')
|
||||
->action(function (Component $livewire) {
|
||||
$livewire->resetTableFiltersForm(); // Clears all filters
|
||||
$livewire->tableSearch = ''; // Clears the main search bar
|
||||
$this->dispatch('reload_data');
|
||||
$this->tableSearch = ''; // Clears the main search bar
|
||||
}),
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
namespace App\Livewire;
|
||||
|
||||
use App\Actions\MapperProvider;
|
||||
use App\Filament\Tables\Columns\MapperRightColumn;
|
||||
use App\Mapper\LoadProvider;
|
||||
use App\Models\Event;
|
||||
use App\Models\Mapper;
|
||||
use Filament\Actions\Action;
|
||||
@@ -34,7 +34,7 @@ class MapperRight extends Component implements HasActions, HasSchemas, HasTable
|
||||
public function table(Table $table): Table
|
||||
{
|
||||
return $table
|
||||
->query(MapperProvider::load())
|
||||
->query(LoadProvider::load())
|
||||
->columns([
|
||||
MapperRightColumn::make('right')->label(''),
|
||||
])->searchable(['home', 'away'])
|
||||
@@ -81,6 +81,7 @@ class MapperRight extends Component implements HasActions, HasSchemas, HasTable
|
||||
->columns(4)->columnSpan(4),
|
||||
], layout: FiltersLayout::AboveContent)
|
||||
// ->hiddenFilterIndicators()
|
||||
->persistFiltersInSession()
|
||||
->filtersFormColumns(3)
|
||||
->deferFilters(false)
|
||||
->toolbarActions([
|
||||
@@ -91,8 +92,7 @@ class MapperRight extends Component implements HasActions, HasSchemas, HasTable
|
||||
// ->icon('phosphor-x')
|
||||
->action(function (Component $livewire) {
|
||||
$livewire->resetTableFiltersForm(); // Clears all filters
|
||||
$livewire->tableSearch = ''; // Clears the main search bar
|
||||
$this->dispatch('reload_data');
|
||||
$this->tableSearch = ''; // Clears the main search bar
|
||||
}),
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -62,7 +62,7 @@ class TopMenuItems extends Component
|
||||
|
||||
$bookmaker_id = array_shift($bookmakers);
|
||||
|
||||
User::where('id', auth()->user()->id)->update(['provider_id' => $provider_id, 'bookmaker_id' => $bookmaker_id, 'client_id' => $client_id]);
|
||||
User::where('id', auth()->user()->id)->update(['sport_id' => 1, 'provider_id' => $provider_id, 'bookmaker_id' => $bookmaker_id, 'client_id' => $client_id]);
|
||||
|
||||
$this->js('window.location.reload()');
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mapper;
|
||||
|
||||
use App\Models\Event;
|
||||
use App\Models\Mapper;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
class FindEvent
|
||||
{
|
||||
public static function search($event)
|
||||
{
|
||||
dd($event);
|
||||
|
||||
$event_id = $event['event_id'];
|
||||
|
||||
$match_id = Event::where('betsapi_id', $event_id)->value('id');
|
||||
|
||||
if ($match_id) {
|
||||
Mapper::where('event_id', $event_id)->delete();
|
||||
} else {
|
||||
|
||||
Mapper::updateOrCreate(['event_id' => $event_id], $event);
|
||||
}
|
||||
|
||||
return Mapper::query()->where('sport_id', Auth::user()->sport_id)->where('provider_id', Auth::user()->provider_id);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mapper;
|
||||
|
||||
use App\Models\Event;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
class LoadEvents
|
||||
{
|
||||
public static function load()
|
||||
{
|
||||
switch (Auth::user()->provider_id) {
|
||||
case 2:
|
||||
// BETSAPI
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('betsapi_id', 0);
|
||||
break;
|
||||
|
||||
case 20:
|
||||
// Magloo Kenia
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('magnig_id', 0);
|
||||
break;
|
||||
|
||||
case 24:
|
||||
// Magloo Nigeria
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('magken_id', 0);
|
||||
break;
|
||||
|
||||
case 26:
|
||||
// Logifuture Nigeria
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('lognig_id', 0);
|
||||
break;
|
||||
|
||||
case 27:
|
||||
// Magloo Colombia
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('logcol_id', 0);
|
||||
break;
|
||||
|
||||
default:
|
||||
return Event::query()->where('sport_id', Auth::user()->sport_id)->where('betradar_id', 0);
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mapper;
|
||||
|
||||
use App\Models\Mapper;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
|
||||
class LoadProvider
|
||||
{
|
||||
public static function load()
|
||||
{
|
||||
return Mapper::query()->where('sport_id', Auth::user()->sport_id)->where('provider_id', Auth::user()->provider_id);
|
||||
}
|
||||
}
|
||||
@@ -15,6 +15,7 @@
|
||||
"bezhansalleh/filament-shield": "^4.0",
|
||||
"codeat3/blade-phosphor-icons": "^2.0",
|
||||
"codewithdennis/filament-lucide-icons": "*",
|
||||
"codewithkyrian/filament-date-range": "^2.0",
|
||||
"filament/filament": "^4.0",
|
||||
"joaopaulolndev/filament-edit-profile": "^2.0",
|
||||
"laravel/framework": "^12.0",
|
||||
|
||||
Generated
+50
-1
@@ -4,7 +4,7 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "f7c5bb72f0348ddbd51bf015f82c3feb",
|
||||
"content-hash": "79916f11ba10822650ae1a1dc62bbfe3",
|
||||
"packages": [
|
||||
{
|
||||
"name": "agencetwogether/hookshelper",
|
||||
@@ -969,6 +969,55 @@
|
||||
],
|
||||
"time": "2025-07-10T12:30:10+00:00"
|
||||
},
|
||||
{
|
||||
"name": "codewithkyrian/filament-date-range",
|
||||
"version": "2.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/CodeWithKyrian/filament-date-range.git",
|
||||
"reference": "f68e79d57cf2ee7bede0d8cfe0cd3addf802e28c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/CodeWithKyrian/filament-date-range/zipball/f68e79d57cf2ee7bede0d8cfe0cd3addf802e28c",
|
||||
"reference": "f68e79d57cf2ee7bede0d8cfe0cd3addf802e28c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"filament/forms": "^4.0",
|
||||
"filament/tables": "^4.0",
|
||||
"php": "^8.2"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"laravel": {
|
||||
"providers": [
|
||||
"CodeWithKyrian\\FilamentDateRange\\DateRangeServiceProvider"
|
||||
]
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"CodeWithKyrian\\FilamentDateRange\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Kyrian Obikwelu",
|
||||
"email": "kyrianobikwelu@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "A date range field and filter for Filament v3.",
|
||||
"support": {
|
||||
"issues": "https://github.com/CodeWithKyrian/filament-date-range/issues",
|
||||
"source": "https://github.com/CodeWithKyrian/filament-date-range/tree/2.0.0"
|
||||
},
|
||||
"time": "2025-12-02T22:48:37+00:00"
|
||||
},
|
||||
{
|
||||
"name": "danharrin/date-format-converter",
|
||||
"version": "v0.3.1",
|
||||
|
||||
+1
-1
@@ -65,7 +65,7 @@ return [
|
||||
|
|
||||
*/
|
||||
|
||||
'timezone' => 'UTC',
|
||||
'timezone' => 'CET',
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
||||
+6
-4
@@ -11,11 +11,13 @@ return new class extends Migration
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('element_filters', function (Blueprint $table) {
|
||||
Schema::create('element_providers', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->integer('sport_id')->index();
|
||||
$table->integer('country_id')->default(0)->nullable()->index();
|
||||
$table->integer('element_id')->index();
|
||||
$table->integer('bkm_element_id')->index();
|
||||
$table->integer('bookmaker_id')->index();
|
||||
$table->integer('provider_id')->default(0)->nullable()->index();
|
||||
$table->integer('provider_element_id')->index();
|
||||
$table->string('name');
|
||||
$table->timestamps();
|
||||
});
|
||||
@@ -26,6 +28,6 @@ return new class extends Migration
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('element_filters');
|
||||
Schema::dropIfExists('element_providers');
|
||||
}
|
||||
};
|
||||
@@ -1,31 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('group_filters', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->integer('group_id')->index();
|
||||
$table->integer('bkm_group_id')->index();
|
||||
$table->integer('bookmaker_id')->index();
|
||||
$table->string('name')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('group_filters');
|
||||
}
|
||||
};
|
||||
+6
-4
@@ -11,11 +11,13 @@ return new class extends Migration
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('competition_group_filters', function (Blueprint $table) {
|
||||
Schema::create('competition_group_providers', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->integer('sport_id')->index();
|
||||
$table->integer('country_id')->default(0)->nullable()->index();
|
||||
$table->integer('competition_group_id')->default(0)->nullable()->index();
|
||||
$table->integer('bkm_competition_group_id')->default(0)->nullable()->index();
|
||||
$table->integer('bookmaker_id')->default(0)->nullable()->index();
|
||||
$table->integer('provider_id')->default(0)->nullable()->index();
|
||||
$table->integer('provider_group_id')->default(0)->nullable()->index();
|
||||
$table->string('name')->nullable();
|
||||
$table->timestamps();
|
||||
});
|
||||
@@ -26,6 +28,6 @@ return new class extends Migration
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('competition_group_filters');
|
||||
Schema::dropIfExists('competition_group_providers');
|
||||
}
|
||||
};
|
||||
@@ -28,7 +28,7 @@ class RolesAndPermissionsSeeder extends Seeder
|
||||
'client_id' => 1,
|
||||
'sport_id' => 1,
|
||||
'bookmaker_id' => 20,
|
||||
'provider_id' => 20,
|
||||
'provider_id' => 4,
|
||||
]);
|
||||
$user->assignRole('super_admin');
|
||||
$user->assignRole('konto_switch');
|
||||
@@ -43,7 +43,7 @@ class RolesAndPermissionsSeeder extends Seeder
|
||||
'client_id' => 1,
|
||||
'sport_id' => 1,
|
||||
'bookmaker_id' => 20,
|
||||
'provider_id' => 20,
|
||||
'provider_id' => 4,
|
||||
]);
|
||||
$user->assignRole('super_admin');
|
||||
$user->assignRole('konto_switch');
|
||||
|
||||
@@ -0,0 +1,2 @@
|
||||
/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */
|
||||
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-space-x-reverse:0;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-duration:initial}}}:root,:host{--color-blue-100:oklch(93.2% .032 255.585);--color-blue-200:oklch(88.2% .059 254.128);--color-blue-800:oklch(42.4% .199 265.638);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-200:oklch(92.8% .006 264.531);--color-gray-300:oklch(87.2% .01 258.338);--color-gray-400:oklch(70.7% .022 261.325);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-600:oklch(44.6% .03 256.802);--color-gray-700:oklch(37.3% .034 259.733);--color-gray-800:oklch(27.8% .033 256.848);--color-gray-900:oklch(21% .034 264.665);--color-gray-950:oklch(13% .028 261.692);--color-black:#000;--color-white:#fff;--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--font-weight-normal:400;--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--radius-md:.375rem;--radius-lg:.5rem}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.start-0{inset-inline-start:calc(var(--spacing)*0)}.end-0{inset-inline-end:calc(var(--spacing)*0)}.end-2\.5{inset-inline-end:calc(var(--spacing)*2.5)}.top-0{top:calc(var(--spacing)*0)}.top-1\/2{top:50%}.z-10{z-index:10}.container{width:100%}.-m-2{margin:calc(var(--spacing)*-2)}.-mx-1{margin-inline:calc(var(--spacing)*-1)}.mx-auto{margin-inline:auto}.my-1{margin-block:calc(var(--spacing)*1)}.ms-auto{margin-inline-start:auto}.me-auto{margin-inline-end:auto}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-3{margin-top:calc(var(--spacing)*3)}.mb-1{margin-bottom:calc(var(--spacing)*1)}.mb-2{margin-bottom:calc(var(--spacing)*2)}.mb-3{margin-bottom:calc(var(--spacing)*3)}.ml-1{margin-left:calc(var(--spacing)*1)}.block{display:block}.flex{display:flex}.grid{display:grid}.inline{display:inline}.inline-block{display:inline-block}.inline-flex{display:inline-flex}.table{display:table}.h-5{height:calc(var(--spacing)*5)}.h-6{height:calc(var(--spacing)*6)}.h-full{height:100%}.h-screen{height:100vh}.w-1\/2{width:50%}.w-5{width:calc(var(--spacing)*5)}.w-6{width:calc(var(--spacing)*6)}.w-40{width:calc(var(--spacing)*40)}.w-full{width:100%}.w-screen{width:100vw}.min-w-0{min-width:calc(var(--spacing)*0)}.min-w-56{min-width:calc(var(--spacing)*56)}.min-w-96{min-width:calc(var(--spacing)*96)}.flex-1{flex:1}.shrink-0{flex-shrink:0}.flex-grow,.grow{flex-grow:1}.-translate-y-1\/2{--tw-translate-y:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}.cursor-pointer{cursor:pointer}.appearance-none{appearance:none}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.justify-around{justify-content:space-around}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-1{gap:calc(var(--spacing)*1)}.gap-1\.5{gap:calc(var(--spacing)*1.5)}.gap-2{gap:calc(var(--spacing)*2)}.gap-3{gap:calc(var(--spacing)*3)}:where(.space-x-1>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*1)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-x-reverse)))}:where(.space-x-2>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*2)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-x-reverse)))}:where(.space-x-4>:not(:last-child)){--tw-space-x-reverse:0;margin-inline-start:calc(calc(var(--spacing)*4)*var(--tw-space-x-reverse));margin-inline-end:calc(calc(var(--spacing)*4)*calc(1 - var(--tw-space-x-reverse)))}.gap-y-0\.5{row-gap:calc(var(--spacing)*.5)Line truncated
|
||||
@@ -0,0 +1 @@
|
||||
var Oi=Object.create;var yn=Object.defineProperty;var Ai=Object.getOwnPropertyDescriptor;var Ei=Object.getOwnPropertyNames;var zi=Object.getPrototypeOf,Ii=Object.prototype.hasOwnProperty;var k=(n,t)=>()=>(t||n((t={exports:{}}).exports,t),t.exports);var qi=(n,t,a,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let e of Ei(t))!Ii.call(n,e)&&e!==a&&yn(n,e,{get:()=>t[e],enumerable:!(i=Ai(t,e))||i.enumerable});return n};var se=(n,t,a)=>(a=n!=null?Oi(zi(n)):{},qi(t||!n||!n.__esModule?yn(a,"default",{value:n,enumerable:!0}):a,n));var $n=k((je,He)=>{(function(n,t){typeof je=="object"&&typeof He<"u"?He.exports=t():typeof define=="function"&&define.amd?define(t):(n=typeof globalThis<"u"?globalThis:n||self).dayjs_plugin_advancedFormat=t()})(je,function(){"use strict";return function(n,t){var a=t.prototype,i=a.format;a.format=function(e){var r=this,o=this.$locale();if(!this.isValid())return i.bind(this)(e);var _=this.$utils(),m=(e||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(u){switch(u){case"Q":return Math.ceil((r.$M+1)/3);case"Do":return o.ordinal(r.$D);case"gggg":return r.weekYear();case"GGGG":return r.isoWeekYear();case"wo":return o.ordinal(r.week(),"W");case"w":case"ww":return _.s(r.week(),u==="w"?1:2,"0");case"W":case"WW":return _.s(r.isoWeek(),u==="W"?1:2,"0");case"k":case"kk":return _.s(String(r.$H===0?24:r.$H),u==="k"?1:2,"0");case"X":return Math.floor(r.$d.getTime()/1e3);case"x":return r.$d.getTime();case"z":return"["+r.offsetName()+"]";case"zzz":return"["+r.offsetName("long")+"]";default:return u}});return i.bind(this)(m)}}})});var Cn=k((we,Te)=>{(function(n,t){typeof we=="object"&&typeof Te<"u"?Te.exports=t():typeof define=="function"&&define.amd?define(t):(n=typeof globalThis<"u"?globalThis:n||self).dayjs_plugin_customParseFormat=t()})(we,function(){"use strict";var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,a=/\d/,i=/\d\d/,e=/\d\d?/,r=/\d*[^-_:/,()\s\d]+/,o={},_=function(f){return(f=+f)+(f>68?1900:2e3)},m=function(f){return function(h){this[f]=+h}},u=[/[+-]\d\d:?(\d\d)?|Z/,function(f){(this.zone||(this.zone={})).offset=function(h){if(!h||h==="Z")return 0;var y=h.match(/([+-]|\d\d)/g),Y=60*y[1]+(+y[2]||0);return Y===0?0:y[0]==="+"?-Y:Y}(f)}],l=function(f){var h=o[f];return h&&(h.indexOf?h:h.s.concat(h.f))},M=function(f,h){var y,Y=o.meridiem;if(Y){for(var v=1;v<=24;v+=1)if(f.indexOf(Y(v,0,h))>-1){y=v>12;break}}else y=f===(h?"pm":"PM");return y},s={A:[r,function(f){this.afternoon=M(f,!1)}],a:[r,function(f){this.afternoon=M(f,!0)}],Q:[a,function(f){this.month=3*(f-1)+1}],S:[a,function(f){this.milliseconds=100*+f}],SS:[i,function(f){this.milliseconds=10*+f}],SSS:[/\d{3}/,function(f){this.milliseconds=+f}],s:[e,m("seconds")],ss:[e,m("seconds")],m:[e,m("minutes")],mm:[e,m("minutes")],H:[e,m("hours")],h:[e,m("hours")],HH:[e,m("hours")],hh:[e,m("hours")],D:[e,m("day")],DD:[i,m("day")],Do:[r,function(f){var h=o.ordinal,y=f.match(/\d+/);if(this.day=y[0],h)for(var Y=1;Y<=31;Y+=1)h(Y).replace(/\[|\]/g,"")===f&&(this.day=Y)}],w:[e,m("week")],ww:[i,m("week")],M:[e,m("month")],MM:[i,m("month")],MMM:[r,function(f){var h=l("months"),y=(l("monthsShort")||h.map(function(Y){return Y.slice(0,3)})).indexOf(f)+1;if(y<1)throw new Error;this.month=y%12||y}],MMMM:[r,function(f){var h=l("months").indexOf(f)+1;if(h<1)throw new Error;this.month=h%12||h}],Y:[/[+-]?\d+/,m("year")],YY:[i,function(f){this.year=_(f)}],YYYY:[/\d{4}/,m("year")],Z:u,ZZ:u};function d(f){var h,y;h=f,y=o&&o.formats;for(var Y=(f=h.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function($,H,N){var F=N&&N.toUpperCase();return H||y[N]||n[N]||y[F].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(S,p,c){return p||c.slice(1)})})).match(t),v=Y.length,g=0;g<v;g+=1){var C=Y[g],A=s[C],I=A&&A[0],q=A&&A[1];Y[g]=q?{regex:I,parser:q}:C.replace(/^\[|\]$/g,"")}return function($){for(var H={},N=0,F=0;N<v;N+=1){var S=Y[N];if(typeof S=="string")F+=S.length;else{var p=S.regex,c=S.parser,L=$.slice(F),D=p.exec(L)[0];c.call(H,D),$=$.replace(D,"")}}return function(b){var j=b.afternoon;if(j!==void 0){var T=b.hours;j?T<12&&(b.hours+=12):T===12&&(b.hours=0),delete b.afternoon}}(H),H}}return function(f,h,y){y.p.customParseFormat=!0,f&&f.parseTwoDigitYear&&(_=f.parseTwoDigitYear);var Y=h.prototype,v=Y.parse;Y.parse=function(g){var C=g.date,A=g.utc,I=g.args;this.$u=A;var q=I[1];if(typeof q=="string"){var $=I[2]===!0,H=I[3]===!0,N=$||H,F=I[2];H&&(F=I[2]),o=this.$locale(),!$&&F&&(o=y.Ls[F]),this.$d=function(L,D,b,j){try{if(["x","X"].indexOf(D)>-1)return new Date((D==="X"?1e3:1)*L);var T=d(D)(L),z=T.year,x=T.month,W=T.day,P=T.hours,X=T.minutes,K=T.seconds,re=T.milliseconds,V=T.zone,U=T.week,Z=new Date,Q=W||(z||x?1:Z.getDate()),ee=z||Z.getFullYear(),fe=0;z&&!x||(fe=x>0?x-1:Z.getMonth());var me,pe=P||0,De=X||0,Le=K||0,ve=re||0;return V?new Date(Date.UTC(ee,Line truncated
|
||||
Reference in new issue
Block a user