WIN-2308041133\Administrator 5 months ago
parent
commit
39dc320cd8
1 changed files with 2 additions and 1 deletions
  1. 2 1
      app/common/repositories/store/order/StoreOrderRepository.php

+ 2 - 1
app/common/repositories/store/order/StoreOrderRepository.php

@@ -12,6 +12,7 @@
 namespace app\common\repositories\store\order;
 
 use app\common\model\store\order\StoreCart;
+use app\common\model\store\product\Product;
 use app\controller\api\server\StoreProduct;
 use think\facade\Cache;
 use app\common\dao\store\order\StoreOrderDao;
@@ -1085,7 +1086,7 @@ class StoreOrderRepository extends BaseRepository
     {
         $cartIdArray = explode(',', $order['cart_id']); // 使用逗号分割字符串
         $product_id = StoreCart::where('cart_id', $cartIdArray[0])->value('product_id');
-        $storeProduct = app()->make(StoreProduct::class);
+        $storeProduct = app()->make(Product::class);
         $product_type =$storeProduct->where('product_id', $product_id)->value('type');
         // 创建用户账单仓库实例
         $make = app()->make(UserBillRepository::class);