50 lines
1.1 KiB
PHP
50 lines
1.1 KiB
PHP
<?php
|
|
|
|
namespace App\Console\Commands\Grapper;
|
|
|
|
use App\Console\Commands\Grapper\Logifuture\Auth;
|
|
use App\Console\Commands\Grapper\Logifuture\BaseUrl;
|
|
use App\Console\Commands\Nuh;
|
|
use App\Models\Sport;
|
|
use App\Utilities\Notice;
|
|
|
|
class Logifuture
|
|
{
|
|
public static function switch()
|
|
{
|
|
$debug = Nuh::$options['d'] ?? 0;
|
|
$proxy = Nuh::$options['p'] ?? 0;
|
|
|
|
$sportmap = Sport::map('logi', 1, [1, 2, 3, 5]);
|
|
|
|
dd($sportmap);
|
|
|
|
if ($debug) {
|
|
Notice::note(Nuh::$options['provider']['name'].' '.Nuh::$options['sport']['name'], 'g');
|
|
}
|
|
|
|
switch (Nuh::$options['provider_id']) {
|
|
case 5:
|
|
Nuh::$options['bookmaker_id'] = 35;
|
|
break;
|
|
case 6:
|
|
Nuh::$options['bookmaker_id'] = 36;
|
|
break;
|
|
}
|
|
|
|
$base_url = BaseUrl::get();
|
|
|
|
$header = Auth::exe();
|
|
|
|
foreach ($sportmap as $client_sportid => $sportid) {
|
|
|
|
$url = $base_url.'/v1/matches?sportId='.$client_sportid;
|
|
|
|
$data = Loader::curlLoader($url, ['curl_options' => $header]);
|
|
|
|
dd($data);
|
|
}
|
|
|
|
}
|
|
}
|