quanwei
2 days ago 04102f7237efefa744090ed7c25f7b5d0807b679
admin/app/api/controller/order/Cart.php
@@ -70,6 +70,10 @@
        $product_num = $data['total_num'];
        $spec_sku_id = $data['spec_sku_id'];
        $model = $this->model;
        $product = ProductModel::detail($product_id);
        if ($product['is_newcomer'] == 1) {
            return $this->renderError('新人专区商品不能加入购物车');
        }
        if (!$model->add($this->user, $product_id, $product_num, $spec_sku_id)) {
            return $this->renderError($model->getError() ?: '加入购物车失败');
        }