更新
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace app\command;
|
||||
|
||||
use app\common\service\qywx\QywxPromotionRangeSyncService;
|
||||
use think\console\Command;
|
||||
use think\console\Input;
|
||||
use think\console\Output;
|
||||
|
||||
/** 重试回调调度后尚未同步到企业微信的获客链接成员范围。 */
|
||||
class QywxSyncPromotionRanges extends Command
|
||||
{
|
||||
protected function configure()
|
||||
{
|
||||
$this->setName('qywx:sync-promotion-ranges')
|
||||
->setDescription('同步企业微信官方获客链接的下一名承接成员');
|
||||
}
|
||||
|
||||
protected function execute(Input $input, Output $output): int
|
||||
{
|
||||
$result = (new QywxPromotionRangeSyncService())->syncPending(100);
|
||||
$output->writeln(sprintf(
|
||||
'QYWX_PROMOTION_RANGE_SYNC selected=%d synced=%d failed=%d',
|
||||
$result['selected'],
|
||||
$result['synced'],
|
||||
$result['failed']
|
||||
));
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user