From ca9f17d6e1f9bc928e6dea4b5d6dcd7a8d073dd9 Mon Sep 17 00:00:00 2001 From: Denis Flaven Date: Fri, 29 Jul 2011 10:09:14 +0000 Subject: [PATCH] Fixed a bug when using a hierarchy of locations, since locatins genreally depends on the object's organization SVN:trunk[1385] --- application/ui.extkeywidget.class.inc.php | 4 ++-- pages/ajax.render.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/application/ui.extkeywidget.class.inc.php b/application/ui.extkeywidget.class.inc.php index 4ff9fcfd5..d8d095492 100644 --- a/application/ui.extkeywidget.class.inc.php +++ b/application/ui.extkeywidget.class.inc.php @@ -336,7 +336,7 @@ EOF /** * Display the hierarchy of the 'target' class */ - public function DisplayHierarchy(WebPage $oPage, $sFilter, $currValue) + public function DisplayHierarchy(WebPage $oPage, $sFilter, $currValue, $oObj) { $sDialogTitle = addslashes(Dict::Format('UI:HierarchyOf_Class', MetaModel::GetName($this->sTargetClass))); $oPage->add('
'); @@ -348,7 +348,7 @@ EOF try { $oFilter = DBObjectSearch::FromOQL($sFilter); - $oSet = new DBObjectSet($oFilter); + $oSet = new DBObjectSet($oFilter, array(), array('this' => $oObj)); } catch(MissingQueryArgument $e) { diff --git a/pages/ajax.render.php b/pages/ajax.render.php index 063d35405..9c35163d4 100644 --- a/pages/ajax.render.php +++ b/pages/ajax.render.php @@ -278,7 +278,7 @@ try $oObj = null; } $oWidget = new UIExtKeyWidget($sTargetClass, $sInputId); - $oWidget->DisplayHierarchy($oPage, $sFilter, $currValue); + $oWidget->DisplayHierarchy($oPage, $sFilter, $currValue, $oObj); break; ////////////////////////////////////////////////////