40 lines
741 B
PHP
40 lines
741 B
PHP
<?php
|
||
|
||
|
||
|
||
|
||
declare (strict_types=1);
|
||
|
||
namespace app\command;
|
||
|
||
use crmeb\jobs\SyncProductTopJob;
|
||
use think\console\Command;
|
||
use think\console\Input;
|
||
use think\console\Output;
|
||
use think\facade\Queue;
|
||
|
||
class changeHotTop extends Command
|
||
{
|
||
protected function configure()
|
||
{
|
||
// 指令配置
|
||
$this->setName('change:hotTop')
|
||
->setDescription('清楚缓存:php think change:hotTop');
|
||
}
|
||
|
||
/**
|
||
* TODO
|
||
* @param Input $input
|
||
* @param Output $output
|
||
* @return int|void|null
|
||
* @author Qinii
|
||
* @day 4/24/22
|
||
*/
|
||
protected function execute(Input $input, Output $output)
|
||
{
|
||
Queue::push(SyncProductTopJob::class,[]);
|
||
$output->writeln('执行成功');
|
||
}
|
||
|
||
}
|