Commit 8f9ce3ee by 杨树贤

优化兼容

parent 920d82b0
Showing with 3 additions and 0 deletions
......@@ -87,6 +87,9 @@ class SkuService
if (!empty($sku['ladder_price'])) {
$priceService = new PriceService();
$moqPrice = $priceService->getMoqPrice($sku['ladder_price']);
if (!is_array($sku['ladder_price'])) {
$sku['ladder_price'] = json_decode($sku['ladder_price'], true);
}
foreach ($sku['ladder_price'] as &$ladder) {
$ladder['purchases'] = $ladder['purchases'] == 0 ? $sku['moq'] : $ladder['purchases'];
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment