Skip to content

Commit

Permalink
Admin-UI: Added "Is Empty" option to type=number when filter is true.
Browse files Browse the repository at this point in the history
  • Loading branch information
CaMer0n committed Mar 6, 2018
1 parent 48b3318 commit 1494c18
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 5 deletions.
9 changes: 9 additions & 0 deletions e107_handlers/admin_ui.php
Original file line number Diff line number Diff line change
Expand Up @@ -4058,6 +4058,7 @@ protected function _modifyListQry($raw = false, $isfilter = false, $forceFrom =
{
$searchQry[] = $this->fields[$filterField]['__tableField']." = '' ";
}

else
{

Expand Down Expand Up @@ -7077,6 +7078,14 @@ function renderBatchFilter($type='batch', $selected = '') // Common function use
break;


case 'number';
if($type === 'filter')
{
$option[$key.'___ISEMPTY_'] = LAN_UI_FILTER_IS_EMPTY;
}

break;

case 'bool':
case 'boolean': //TODO modify description based on $val['parm]
if(vartrue($parms['reverse'])) // reverse true/false values;
Expand Down
11 changes: 6 additions & 5 deletions e107_languages/English/admin/lan_admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -487,11 +487,6 @@
define("LAN_UI_FILTER_PAST_MONTH", "Past Month");
define("LAN_UI_FILTER_PAST_YEAR", "Past Year");

define("LAN_UI_FILTER_NEXT_HOUR", "Next Hour");
define("LAN_UI_FILTER_NEXT_24_HOURS", "Next 24 hours");
define("LAN_UI_FILTER_NEXT_WEEK", "Next Week");
define("LAN_UI_FILTER_NEXT_MONTH", "Next Month");
define("LAN_UI_FILTER_NEXT_YEAR", "Next Year");

define("LAN_USER_MANAGEALL", "Manage all User, Userclass and Extended User-Field settings");
define("LAN_USER_LIST", "User List");
Expand Down Expand Up @@ -550,3 +545,9 @@
define("LAN_UI_VIEW_LIST_LABEL", "List view");
define("LAN_CHECKING_FOR_UPDATES", "Checking for updates");

define("LAN_UI_FILTER_NEXT_HOUR", "Next Hour");
define("LAN_UI_FILTER_NEXT_24_HOURS", "Next 24 hours");
define("LAN_UI_FILTER_NEXT_WEEK", "Next Week");
define("LAN_UI_FILTER_NEXT_MONTH", "Next Month");
define("LAN_UI_FILTER_NEXT_YEAR", "Next Year");
define("LAN_UI_FILTER_IS_EMPTY", "Is Empty");

0 comments on commit 1494c18

Please sign in to comment.