Files
nuhodds_fi4/app/Console/Commands/Services/Tasks/Alarm/AlarmSettings.php
T
2026-01-26 18:26:02 +01:00

26 lines
660 B
PHP

<?php
namespace App\Console\Commands\Services\Tasks\Alarm;
use App\Console\Commands\Nuh;
use App\Models\AlarmSetting;
class AlarmSettings
{
public static function get($client_bookmaker_id)
{
$res = AlarmSetting::where('sport_id', Nuh::$options['sport_id'])
->where('client_bookmaker_id', $client_bookmaker_id)
->where('disabled', 0)
->select('multiline_setting_id', 'level_id', 'alarm_threshold')
->get();
$arr = [];
foreach ($res as $value) {
$arr[$value->multiline_setting_id][$value->level_id] = $value->alarm_threshold;
}
return $arr;
}
}