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