!73 增量订单获取修改

Merge pull request !73 from 赵世界/develop
This commit is contained in:
赵世界 2022-08-26 06:27:44 +00:00 committed by Gitee
commit edbb1e1902
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -43,10 +43,10 @@ class Swoole extends Command
*/
public function handle()
{
Timer::tick(5000, function () {
Timer::tick(3000, function () {
$shops = Shop::query()->where('plat_id', 1)->where('status', 1)->get();
$endTime = DateTimeUtils::getMicroTime();
$beginTime = $endTime - 5000;
$beginTime = $endTime - 3000;
foreach ($shops as $shop) {
BusinessFactory::init()->make($shop->plat_id)->setShop($shop)->downloadOrdersAndSave($beginTime, $endTime, 'increment');
}