update
This commit is contained in:
@ -22,11 +22,10 @@ class AutoPush extends BaseSpider
|
||||
*/
|
||||
protected string $baseUrl = 'http://data.zz.baidu.com/urls?site=https://hegsfc.com&token=5CtAd8vD3QQazJjh';
|
||||
|
||||
protected const PLATFORM = 'elle-street';
|
||||
|
||||
public function __construct(protected ContainerInterface $container, LoggerFactory $loggerFactory)
|
||||
{
|
||||
parent::__construct('baidu:auto-push');
|
||||
$this->commandLogger = $loggerFactory->get('log', 'command-baidu-auto-push');
|
||||
}
|
||||
|
||||
public function configure()
|
||||
@ -46,7 +45,6 @@ class AutoPush extends BaseSpider
|
||||
$query = AppWebsiteConfig::query()
|
||||
->select(['app_domain', 'id'])
|
||||
->where('is_delete', 0)
|
||||
->where('is_record', 0)
|
||||
->orderBy('id', 'DESC')
|
||||
->limit(10);
|
||||
if ($id = $input->getOption('platform')) {
|
||||
@ -66,7 +64,7 @@ class AutoPush extends BaseSpider
|
||||
curl_setopt_array($ch, $options);
|
||||
$result = curl_exec($ch);
|
||||
$pushArray = [];
|
||||
var_dump($result);
|
||||
$this->commandLogger->info($result);
|
||||
};
|
||||
foreach ($query as $item) {
|
||||
$article = AppNews::query()->where('platform', $item['id'])->select(['id'])->get()->toArray();
|
||||
@ -78,12 +76,6 @@ class AutoPush extends BaseSpider
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// echo $result;
|
||||
// var_dump($result);
|
||||
|
||||
var_dump($pushArray);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user