From: Nicolas Boisselier Date: Sun, 25 Dec 2016 23:00:56 +0000 (+0000) Subject: fix bug limit X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=fe37f0a03059f7ed46edea92913a4aab9d8a4989;p=nb.git fix bug limit --- diff --git a/lib/php/db.php b/lib/php/db.php index 1d728740..ea6f62e4 100644 --- a/lib/php/db.php +++ b/lib/php/db.php @@ -122,7 +122,7 @@ class Db extends nb { public $format = 'json'; public $formats = [ 'table','div','csv','xml','json','yaml','sh','sql','php' ]; public $limits = ['20','50','100','500','1000']; - public $limit; + public $limit; # Here not in Table becouse of Db::out() # Classes public $out; diff --git a/lib/php/db/table.php b/lib/php/db/table.php index ddbd44fd..4f203022 100644 --- a/lib/php/db/table.php +++ b/lib/php/db/table.php @@ -887,9 +887,9 @@ Class Table extends nb { } public function rows(&$opt=[],$opt_by_val=null) { - if (empty($this->db()->limit)) { - $this->db()->limit = $this->db()->limits[0]; - } +# NB 25.12.16 if (empty($this->db()->limit)) { +# NB 25.12.16 $this->db()->limit = $this->db()->limits[0]; +# NB 25.12.16 } # # Run query