panlumeng 3 years ago
parent
commit
36e872ccec
1 changed files with 1 additions and 1 deletions
  1. 1 1
      application/Home/controller/Order.php

+ 1 - 1
application/Home/controller/Order.php

@@ -111,7 +111,7 @@ class Order extends Base
             $zl = Db::name('order_log')->where(["unit_id"=>$id,"accountid"=>$this->userinfo['id']])->sum('num');
             $zl = Db::name('order_log')->where(["unit_id"=>$id,"accountid"=>$this->userinfo['id']])->sum('num');
           // var_dump(Db::name('order_log')->getLastSql());
           // var_dump(Db::name('order_log')->getLastSql());
 
 
-            if($zl['num']+$num>$kg['limit_num']){
+            if($zl+$num>$kg['limit_num']){
                 return error_show(1004,"购买数量超过限额");
                 return error_show(1004,"购买数量超过限额");
             }
             }
         }
         }