This commit is contained in:
salam committed 2026-01-26 01:52:47 +01:00
1 parent 45cd621cf7
commit d317c733b9
13 files changed
+142 -58

No files matched your search

@@ -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) {
@@ -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');
+6 -7
View File
@@ -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')