diff --git a/app/Console/Commands/Grapper/TxOdds/Fixtures.php b/app/Console/Commands/Grapper/TxOdds/Fixtures.php index fc61fb3a..cbd3c658 100644 --- a/app/Console/Commands/Grapper/TxOdds/Fixtures.php +++ b/app/Console/Commands/Grapper/TxOdds/Fixtures.php @@ -29,8 +29,6 @@ class Fixtures $total_soccer = 0; $total_others = 0; - $now = Carbon::now(); - /** * Delete */ @@ -53,7 +51,11 @@ class Fixtures if ($today) { Nuh::$options['days_from'] = 0; - Nuh::$options['days_to'] = 1; + if (now()->between(today(), today()->addHour())) { + Nuh::$options['days_to'] = 2; + } else { + Nuh::$options['days_to'] = 2; + } } elseif ($week) { Nuh::$options['days_from'] = 0; Nuh::$options['days_to'] = 6; @@ -134,7 +136,7 @@ class Fixtures } if ($debug) { - Notice::note($now->toDateString()." - $count events processed", 'g'); + Notice::note(now()->toDateString()." - $count events processed", 'g'); } } if ($debug) { diff --git a/app/Filament/Resources/Events/EventResource.php b/app/Filament/Resources/Events/EventResource.php index dd061cbf..1d245b52 100644 --- a/app/Filament/Resources/Events/EventResource.php +++ b/app/Filament/Resources/Events/EventResource.php @@ -53,12 +53,12 @@ class EventResource extends Resource public static function getEloquentQuery(): Builder { $query = parent::getEloquentQuery() - ->where('starttime', '>', Carbon::now()) ->with('competition_group') ->with('country') ->with('home') ->with('away') - ->with('event_user_star'); + ->with('event_user_star') + ->where('starttime', '>=', now()); if (auth()->user()->stars) { $query->whereHas('event_user_star'); diff --git a/app/Livewire/ComparingBookmakerMenu.php b/app/Livewire/ComparingBookmakerMenu.php index 774b062f..555c6736 100644 --- a/app/Livewire/ComparingBookmakerMenu.php +++ b/app/Livewire/ComparingBookmakerMenu.php @@ -64,15 +64,13 @@ class ComparingBookmakerMenu extends Component implements HasActions, HasSchemas TextColumn::make('bookmaker_id')->label('Id'), BookmakerIcon::make('bookmaker.icon')->label('Icon')->size('lg'), TextInputColumn::make('time_lastcheck') - ->tooltip('If lastcheck is older bookmaker will be ignored') ->label('Time Passed') ->prefix('Seconds:') - ->rules(['required', 'max:200', 'min:100']), + ->rules(['required', 'integer', 'between:60,1200']), TextInputColumn::make('margin_threshold') - ->tooltip('If margin is higher bookmaker will be ignored') ->label('Maximum Margin') ->prefix('Threshold:') - ->rules(['required', 'max:200', 'min:100']), + ->rules(['required', 'integer', 'between:100,200']), // ToggleColumn::make('is_active'), ]) ->searchable(['bookmaker.name']) @@ -96,7 +94,7 @@ class ComparingBookmakerMenu extends Component implements HasActions, HasSchemas ); } }) - ->form([ + ->schema([ TextInput::make('time_lastcheck') ->numeric() @@ -114,11 +112,12 @@ class ComparingBookmakerMenu extends Component implements HasActions, HasSchemas ); } }) - ->form([ + ->schema([ TextInput::make('margin_threshold') ->hiddenLabel() ->numeric() - ->rules(['required', 'max:200', 'min:100']) + ->minValue(100) + ->maxValue(250) ->prefix('Threshold'), ]), BulkAction::make('Switch On') diff --git a/composer.lock b/composer.lock index 9b09d119..0d0dcf1a 100644 --- a/composer.lock +++ b/composer.lock @@ -10924,16 +10924,16 @@ }, { "name": "phpstan/phpdoc-parser", - "version": "2.3.1", + "version": "2.3.2", "source": { "type": "git", "url": "https://github.com/phpstan/phpdoc-parser.git", - "reference": "16dbf9937da8d4528ceb2145c9c7c0bd29e26374" + "reference": "a004701b11273a26cd7955a61d67a7f1e525a45a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/16dbf9937da8d4528ceb2145c9c7c0bd29e26374", - "reference": "16dbf9937da8d4528ceb2145c9c7c0bd29e26374", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/a004701b11273a26cd7955a61d67a7f1e525a45a", + "reference": "a004701b11273a26cd7955a61d67a7f1e525a45a", "shasum": "" }, "require": { @@ -10965,9 +10965,9 @@ "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", - "source": "https://github.com/phpstan/phpdoc-parser/tree/2.3.1" + "source": "https://github.com/phpstan/phpdoc-parser/tree/2.3.2" }, - "time": "2026-01-12T11:33:04+00:00" + "time": "2026-01-25T14:56:51+00:00" }, { "name": "phpstan/phpstan", @@ -12814,12 +12814,12 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": {}, "prefer-stable": true, "prefer-lowest": false, "platform": { "php": "^8.3" }, - "platform-dev": [], - "plugin-api-version": "2.6.0" + "platform-dev": {}, + "plugin-api-version": "2.9.0" } diff --git a/database/migrations/2023_05_25_112701_create_event_bookmakers_table.php b/database/migrations/2023_05_25_112701_create_event_bookmakers_table.php index be05653d..c357f0f2 100644 --- a/database/migrations/2023_05_25_112701_create_event_bookmakers_table.php +++ b/database/migrations/2023_05_25_112701_create_event_bookmakers_table.php @@ -20,20 +20,26 @@ return new class extends Migration $table->boolean('in_feed')->default(0); $table->boolean('send_status')->default(0); $table->boolean('has_to_qualify')->index()->default(0); - $table->integer('bkm_2w')->nullable()->default(0); - $table->integer('bkm_2ws1')->nullable()->default(0); - $table->integer('bkm_3w')->nullable()->default(0); - $table->integer('bkm_3wht')->nullable()->default(0); - $table->integer('bkm_dc')->nullable()->default(0); - $table->integer('bkm_dbn')->nullable()->default(0); - $table->integer('bkm_ggng')->nullable()->default(0); - $table->integer('bkm_po')->nullable()->default(0); - $table->integer('bkm_poht')->nullable()->default(0); - $table->integer('bkm_poq1')->nullable()->default(0); - $table->integer('bkm_to')->nullable()->default(0); - $table->integer('bkm_toht')->nullable()->default(0); - $table->integer('bkm_toq1')->nullable()->default(0); - $table->integer('bkm_tq')->nullable()->default(0); + /** + * favorit client is lower then favorit from method + * 0.01 + * 0.3 + * 0.5 + */ + $table->integer('alarm_2w')->nullable()->default(0); + $table->integer('alarm_2ws1')->nullable()->default(0); + $table->integer('alarm_3w')->nullable()->default(0); + $table->integer('alarm_3wht')->nullable()->default(0); + $table->integer('alarm_dc')->nullable()->default(0); + $table->integer('alarm_dbn')->nullable()->default(0); + $table->integer('alarm_ggng')->nullable()->default(0); + $table->integer('alarm_po')->nullable()->default(0); + $table->integer('alarm_poht')->nullable()->default(0); + $table->integer('alarm_poq1')->nullable()->default(0); + $table->integer('alarm_to')->nullable()->default(0); + $table->integer('alarm_toht')->nullable()->default(0); + $table->integer('alarm_toq1')->nullable()->default(0); + $table->integer('alarm_tq')->nullable()->default(0); $table->timestamps(); }); diff --git a/resources/views/components/alarm-gray.blade.php b/resources/views/components/alarm-gray.blade.php new file mode 100644 index 00000000..3c6d95d0 --- /dev/null +++ b/resources/views/components/alarm-gray.blade.php @@ -0,0 +1,4 @@ +