Index: trunk/core/units/relationship/relationship_event_handler.php =================================================================== diff -u -N -r6625 -r7391 --- trunk/core/units/relationship/relationship_event_handler.php (.../relationship_event_handler.php) (revision 6625) +++ trunk/core/units/relationship/relationship_event_handler.php (.../relationship_event_handler.php) (revision 7391) @@ -82,8 +82,11 @@ // place correct template in opener stack $source_prefix = $this->Application->getUnitOption($event->Prefix, 'ParentPrefix'); $template = $this->Application->getUnitOption($source_prefix, 'AdminTemplatePath').'/relations_edit'; - $redirect_params = Array($event->Prefix.'_event' => 'OnNew', 'target_id' => $target_id, 'target_type' => $target_type); + + $redirect_params = Array($event->Prefix.'_event' => 'OnNew', 'target_id' => $target_id, 'm_opener' => 's', 'target_type' => $target_type); $this->Application->EventManager->openerStackPush($template, $redirect_params, 'all,'.$event->Prefix); + +// $event->SetRedirectParam('popup_stay', 1); // if popup mode, then set this } } else { @@ -232,6 +235,8 @@ if ($prefix == 'm') { $prefix = 'c'; } + if (!$this->Application->prefixRegistred($prefix)) continue; + $configs[$prefix] = $this->Application->getUnitOptions($prefix); if($configs[$prefix] === false) unset($configs[$prefix]); if(!isset($configs[$prefix]['CatalogItem']) || !$configs[$prefix]['CatalogItem']) unset($configs[$prefix]);