Log::
This commit is contained in:
parent
b5c1013ac8
commit
07660724d4
@ -87,12 +87,8 @@ class OrderService extends Service
|
||||
throw new NotAllowedException("当前请求数据量过大,请筛选过滤后查询");
|
||||
}
|
||||
|
||||
Log::info('1', [microtime(true)]);
|
||||
|
||||
$cards = $this->orderCardPartitionRepository->withVirtual($conditions)->currentModel()->get()->toArray();
|
||||
|
||||
Log::info('2', [microtime(true)]);
|
||||
|
||||
$tmpCards = array_groupBy($cards, 'virtual_order_id');
|
||||
|
||||
$orderIds = array_unique(array_keys($tmpCards));
|
||||
@ -103,16 +99,12 @@ class OrderService extends Service
|
||||
unset($orderIds[$key]);
|
||||
}
|
||||
|
||||
Log::info('3', [microtime(true)]);
|
||||
|
||||
$virtualOrders = [];
|
||||
// 有订单的从订单中读取公司和套餐
|
||||
if (!empty($orderIds)) {
|
||||
$virtualOrders = app(VirtualOrderRepository::class)->withConditions(['id' => $orderIds])->get()->keyBy('id')->toArray();
|
||||
}
|
||||
|
||||
Log::info('4', [microtime(true)]);
|
||||
|
||||
$companyService = app(CompanyService::class);
|
||||
$packageService = app(PackageService::class);
|
||||
|
||||
@ -131,8 +123,6 @@ class OrderService extends Service
|
||||
$item['package_name'] = !$item['package_id'] ? '' : $packageService->load($item['package_id'])['name'] ?? '';
|
||||
}
|
||||
|
||||
Log::info('5', [microtime(true)]);
|
||||
|
||||
return array_values(array_sort($cards, function ($value) {
|
||||
return $value['order_id'] . '-' . $value['sim'];
|
||||
}));
|
||||
|
Loading…
x
Reference in New Issue
Block a user