Explorar o código

修改基础配置接口返回的微信支付错误问题
处理购物车手动修改数量的错误提示问题
处理无法正常进行拼团下单的问题
处理发票后台统计错误的问题
处理删除了砍价商品,砍价列表还显示的问题
处理支付金额为0积分抵扣也为0的时候的报错

evoxwht %!s(int64=2) %!d(string=hai) anos
pai
achega
cbeda6f33f

+ 1 - 1
crmeb/app/api/controller/v1/PublicController.php

@@ -681,7 +681,7 @@ class PublicController
         $data['member_card_status'] = sys_config('member_card_status');//是否开启付费会员
         $data['member_price_status'] = sys_config('member_price_status');//商品会员折扣价展示启用
         $data['ali_pay_status'] = sys_config('ali_pay_status') != '0';//支付宝是否启用
-        $data['wechat_pay_status'] = sys_config('pay_weixin_open') != '0';//微信是否启用
+        $data['pay_weixin_open'] = sys_config('pay_weixin_open') != '0';//微信是否启用
         $data['yue_pay_status'] = sys_config('yue_pay_status') == 1 && sys_config('balance_func_status') != 0;//余额是否启用
         $data['offline_pay_status'] = sys_config('offline_pay_status') == 1;//线下是否启用
         $data['friend_pay_status'] = sys_config('friend_pay_status') == 1;//好友是否启用

+ 2 - 1
crmeb/app/api/controller/v1/store/StoreCartController.php

@@ -124,7 +124,8 @@ class StoreCartController
             ['id', 0],//购物车编号
             ['number', 0],//购物车编号
         ]);
-        if (!$where['id'] || !$where['number'] || !is_numeric($where['id']) || !is_numeric($where['number'])) return app('json')->fail(100100);
+        if (!$where['id'] || !is_numeric($where['id'])) return app('json')->fail(100100);
+        if (!$where['number'] || !is_numeric($where['number'])) return app('json')->fail(100007);
         $res = $this->services->changeUserCartNum($where['id'], $where['number'], $request->uid());
         if ($res) return app('json')->success(100001);
         else return app('json')->fail(100007);

+ 2 - 0
crmeb/app/dao/activity/combination/StoreCombinationDao.php

@@ -59,6 +59,8 @@ class StoreCombinationDao extends BaseDao
                     $query->name('store_category')->where('pid', $where['cid'])->field('id')->select();
                 })->field('product_id')->select();
             });
+        })->when(isset($where['id']) && $where['id'], function ($query) use ($where) {
+            $query->where('id', $where['id']);
         });
     }
 

+ 1 - 1
crmeb/app/dao/order/StoreOrderInvoiceDao.php

@@ -53,7 +53,7 @@ class StoreOrderInvoiceDao extends BaseDao
         return parent::search($where, $search)->when($type, function ($query) use ($type) {
             switch ($type) {
                 case 1://待开
-                    $query->where('is_invoice', 0)->where('invoice_time', 0)->where('is_refund', 0);
+                    $query->where('is_invoice', 0)->where('is_refund', 0);
                     break;
                 case 2://已开
                     $query->where('is_invoice', 1);

+ 1 - 1
crmeb/app/services/activity/bargain/StoreBargainUserServices.php

@@ -220,7 +220,7 @@ class StoreBargainUserServices extends BaseServices
     public function userBargainStatusFail($bargain_id, $is_true)
     {
         if ($is_true) {
-            $this->dao->delete(['bargain_id' => $bargain_id, 'status' => 1]);
+            $this->dao->delete(['bargain_id' => $bargain_id]);
             /** @var StoreBargainUserHelpServices $service */
             $service = app()->make(StoreBargainUserHelpServices::class);
             $service->delete(['bargain_id' => $bargain_id]);

+ 2 - 2
crmeb/app/services/order/StoreOrderComputedServices.php

@@ -226,8 +226,8 @@ class StoreOrderComputedServices extends BaseServices
         // 可用积分
         $usable = bcsub((string)$userInfo['integral'], (string)$userBillServices->getBillSum(['uid' => $userInfo['uid'], 'is_frozen' => 1]), 0);
 
-        $SurplusIntegral = 0;
-        if ($useIntegral && $userInfo['integral'] > 0) {
+        $SurplusIntegral = $usable;
+        if ($useIntegral && $userInfo['integral'] > 0 && $other['integralRatio'] > 0) {
             //积分抵扣上限
             $integralMaxNum = sys_config('integral_max_num', 200);
             if ($integralMaxNum > 0 && $usable > $integralMaxNum) {