WIN-2308041133\Administrator 1 year ago
parent
commit
61503d5c8a
1 changed files with 2 additions and 1 deletions
  1. 2 1
      application/api/controller/Lave.php

+ 2 - 1
application/api/controller/Lave.php

@@ -209,6 +209,7 @@ class Lave extends Api
 //                'category_id'=>$where1['category_id'],
                 'order_name'=>$where1['order_name'],
             ];
+            $count=WechatPlanRecord::where('uid', $where1['user_id'])->where('plan_id',$plan_id)->count();
             $record=WechatPlanRecord::create($plan_record);
             $plan_record['spbill_create_ip']=User::where('id', $where1['user_id'])->value('loginip');
             $plan_record['contract_notify_url']=Request::instance()->domain() . "/api/wechat/notify/" . $where['cid'];
@@ -225,7 +226,7 @@ class Lave extends Api
             }
             $info['jsConfig'] = $jsConfig;
 //            增加参与人数
-            $count=WechatPlanRecord::where('uid', $where1['user_id'])->where('plan_id',$plan_id)->count();
+
             @file_put_contents("quanju.txt", $count."-参与次数\r\n", 8);
             if ($count==0){
                 $num=WechatPlan::where('plan_id', $plan_id)->value('num');