diff --git a/app/api/controller/LocalStoreGoods.php b/app/api/controller/LocalStoreGoods.php index 03db80e6..a9274236 100755 --- a/app/api/controller/LocalStoreGoods.php +++ b/app/api/controller/LocalStoreGoods.php @@ -119,7 +119,7 @@ class LocalStoreGoods extends Api public function getCartGoods() { $form = $this->request->post(); - LocalStoreGoodsCartLogic::getCartGoods($form, $this->user_id); + return JsonServer::success('', LocalStoreGoodsCartLogic::getCartGoods($form, $this->user_id)); } // 获取购物车数量 diff --git a/app/api/logic/LocalStoreGoodsCartLogic.php b/app/api/logic/LocalStoreGoodsCartLogic.php index 2d1db554..3efb71d0 100644 --- a/app/api/logic/LocalStoreGoodsCartLogic.php +++ b/app/api/logic/LocalStoreGoodsCartLogic.php @@ -69,6 +69,7 @@ class LocalStoreGoodsCartLogic extends Logic ->field('c.id, c.item_id, c.goods_num, g.id as lsg_id, g.title, g.price') ->append(['pic', 'item']) ->select(); + return $cart; } public static function cartNum($post, $user_id)