From 964cc68b46c3cee049582bec4febb172d4ecf308 Mon Sep 17 00:00:00 2001 From: Enderlin Philippe Date: Wed, 20 Apr 2016 12:01:18 +0200 Subject: [PATCH] Add WHERE parameters to dropdown() --- core/MY_Model.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/core/MY_Model.php b/core/MY_Model.php index 05add98..3998b2f 100644 --- a/core/MY_Model.php +++ b/core/MY_Model.php @@ -513,7 +513,13 @@ function dropdown() { $args = func_get_args(); - if(count($args) == 2) + if(count($args) == 3) + { + list($key, $value, $where) = $args; + + $this->_set_where($where); + } + else if(count($args) == 2) { list($key, $value) = $args; }