diff --git a/app/Livewire/ComparingMethod.php b/app/Livewire/ComparingMethod.php new file mode 100644 index 00000000..a5366544 --- /dev/null +++ b/app/Livewire/ComparingMethod.php @@ -0,0 +1,45 @@ +query(Bookmaker::query()) + ->columns([ + TextColumn::make('name'), + ]) + ->filters([ + // ... + ]) + ->recordActions([ + // ... + ]) + ->toolbarActions([ + // ... + ]); + } + + public function render(): View + { + return view('livewire.comparing-method'); + } +} diff --git a/app/Livewire/Mapper/LoadEvents.php b/app/Livewire/Mapper/LoadEvents.php index c8f2d2e7..ad67abde 100644 --- a/app/Livewire/Mapper/LoadEvents.php +++ b/app/Livewire/Mapper/LoadEvents.php @@ -35,7 +35,7 @@ class LoadEvents ->with('home') ->with('away') ->where('sport_id', Auth::user()->sport_id) - ->where('starttime', '>', Carbon::now(); + ->where('starttime', '>', Carbon::now()); } switch (Auth::user()->provider_id) { diff --git a/app/Models/ComparingBookmaker.php b/app/Models/ComparingBookmaker.php new file mode 100644 index 00000000..823ec569 --- /dev/null +++ b/app/Models/ComparingBookmaker.php @@ -0,0 +1,10 @@ +id(); + $table->integer('method_id'); + $table->string('method')->nullable(); + $table->integer('sport_id')->index()->references('id')->on('sports'); + $table->integer('bookmaker_id')->index()->references('id')->on('bookmakers'); + $table->integer('provider_id')->default(0)->nullable()->index()->references('id')->on('providers'); + $table->integer('time_lastcheck'); + $table->integer('margin_threshold'); + $table->boolean('is_active')->default(false); + $table->integer('sorting')->nullable()->default(0); + $table->timestamps(); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::dropIfExists('comparing_bookmakers'); + } +}; diff --git a/resources/views/livewire/comparing-method.blade.php b/resources/views/livewire/comparing-method.blade.php new file mode 100644 index 00000000..c3fedc4a --- /dev/null +++ b/resources/views/livewire/comparing-method.blade.php @@ -0,0 +1,3 @@ +
+ {{ $this->table }} +
diff --git a/resources/views/livewire/top-menu-items.blade.php b/resources/views/livewire/top-menu-items.blade.php index 3b4e784b..20500ec4 100644 --- a/resources/views/livewire/top-menu-items.blade.php +++ b/resources/views/livewire/top-menu-items.blade.php @@ -1,4 +1,4 @@ -
+
@if ($this->current == 'filament.admin.resources.events.index') {{-- Client Swop Bookmaker --}} @@ -62,12 +62,12 @@ {{-- Event Mapper --}} - - - + + @@ -157,10 +157,10 @@ {{-- Multiline --}} - + - - + + Multiline Settings @@ -170,10 +170,10 @@ {{-- Alarm --}} - + - - + + @@ -185,19 +185,18 @@ {{-- Calculation --}} - + - - + + - Comparing + Comparing Bookmaker -
-
- + @livewire('comparing-method') +
@endif
diff --git a/resources/views/mode.md b/resources/views/mode.md deleted file mode 100644 index e69de29b..00000000