From c933196f742716d1c73087966cd14dceacc6069c Mon Sep 17 00:00:00 2001 From: Edward Date: Thu, 7 Mar 2019 14:49:10 +0800 Subject: [PATCH] DataObjects/I18n.php --- DataObjects/I18n.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/DataObjects/I18n.php b/DataObjects/I18n.php index 58ececb6..ecf2a37e 100644 --- a/DataObjects/I18n.php +++ b/DataObjects/I18n.php @@ -172,7 +172,14 @@ class Pman_Core_DataObjects_I18n extends DB_DataObject "); if(!empty($q['_hide_unused'])) { - $this->having("no_of_division > 0"); + $this->whereAdd("( + SELECT + COUNT(geoip_division.id) + FROM + geoip_division + WHERE + geoip_division.country = i18n.lkey + ) > 0"); } } -- 2.39.2