mirror of
https://gitee.com/hzchunfen/erp.git
synced 2025-11-30 22:20:45 +00:00
commit
493a3c858f
@ -29,7 +29,7 @@ class GroupQueryListener
|
|||||||
{
|
{
|
||||||
$shopId = Groups::query()->where('id', $event->groupId)->value('shop_id');
|
$shopId = Groups::query()->where('id', $event->groupId)->value('shop_id');
|
||||||
$shop = Shop::query()->find($shopId);
|
$shop = Shop::query()->find($shopId);
|
||||||
$client = BusinessFactory::init()->make($shop['plat_id'])->setShopWithId($shop['id']);
|
$client = BusinessFactory::init()->make($shop['plat_id'])->setShop($shop);
|
||||||
$client->createGroup($event->groupId);
|
$client->createGroup($event->groupId);
|
||||||
sleep(1);
|
sleep(1);
|
||||||
$client->queryGroupStatus($event->groupId);
|
$client->queryGroupStatus($event->groupId);
|
||||||
|
|||||||
@ -19,7 +19,7 @@ class Groups
|
|||||||
foreach ($groupGoods as $item) {
|
foreach ($groupGoods as $item) {
|
||||||
$goodsSkus[] = [
|
$goodsSkus[] = [
|
||||||
'category_name' => $item['category_name'],
|
'category_name' => $item['category_name'],
|
||||||
'goods_desc' => $item['goods_desc'],
|
'goods_desc' => $item['goods_desc'] ?: $group['title'],
|
||||||
'goods_name' => $item['goods_name'],
|
'goods_name' => $item['goods_name'],
|
||||||
'limit_buy' => $item['limit_buy'],
|
'limit_buy' => $item['limit_buy'],
|
||||||
'market_price' => $item['market_price'],
|
'market_price' => $item['market_price'],
|
||||||
@ -33,10 +33,10 @@ class Groups
|
|||||||
];
|
];
|
||||||
}
|
}
|
||||||
$appendParams = [
|
$appendParams = [
|
||||||
'end_time' => $group['end_time'] * 1000,
|
'end_time' => (int)$group['end_time'],
|
||||||
'goods_list' => json_encode([$goodsSkus]),
|
'goods_list' => json_encode([$goodsSkus]),
|
||||||
'is_save_preview' => $group['is_save_preview'],
|
'is_save_preview' => $group['is_save_preview'],
|
||||||
'start_time' => $group['start_time'] * 1000,
|
'start_time' => (int)$group['start_time'],
|
||||||
'title' => $group['title'],
|
'title' => $group['title'],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@ -7,6 +7,7 @@ use App\Models\GoodsSku;
|
|||||||
use App\Models\GroupGoods;
|
use App\Models\GroupGoods;
|
||||||
use App\Services\Business\BusinessClient;
|
use App\Services\Business\BusinessClient;
|
||||||
use App\Models\Groups as GroupsModel;
|
use App\Models\Groups as GroupsModel;
|
||||||
|
use Illuminate\Support\Facades\Log;
|
||||||
|
|
||||||
class KuaiTuanTuan extends BusinessClient
|
class KuaiTuanTuan extends BusinessClient
|
||||||
{
|
{
|
||||||
@ -128,6 +129,7 @@ class KuaiTuanTuan extends BusinessClient
|
|||||||
} else {
|
} else {
|
||||||
// throw new \RuntimeException($res['error_response']['error_msg'] . ':' . $res['error_response']['error_msg']);
|
// throw new \RuntimeException($res['error_response']['error_msg'] . ':' . $res['error_response']['error_msg']);
|
||||||
}
|
}
|
||||||
|
Log::info(json_encode($res,256));
|
||||||
}
|
}
|
||||||
|
|
||||||
return $res;
|
return $res;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user