Index: trunk/kernel/units/config_search/config_search_event_handler.php =================================================================== diff -u -N -r4000 -r4043 --- trunk/kernel/units/config_search/config_search_event_handler.php (.../config_search_event_handler.php) (revision 4000) +++ trunk/kernel/units/config_search/config_search_event_handler.php (.../config_search_event_handler.php) (revision 4043) @@ -13,63 +13,35 @@ { $object =& $event->getObject(); - $module_owner=$this->Application->GetVar('module'); - if ($module_owner===false) { - $module_owner=$this->myUrlDecode($this->Application->GetVar('confs_module')); - $this->Application->SetVar("module", $module_owner); - } - - $section=$this->Application->GetVar('section'); - if ($section===false){ - $section=$this->myUrlDecode($this->Application->GetVar('confs_section')); - $this->Application->SetVar("section", $section); - } - - $object->addFilter('module_filter', '%1$s.ModuleName = "'.$module_owner.'"'); - + $module_owner = $this->Application->GetLinkedVar('module'); + $this->Application->LinkVar('section'); + $object->addFilter('module_filter', '%1$s.ModuleName = '.$this->Conn->qstr($module_owner)); } + /** + * Enter description here... + * + * @param kEvent $event + */ function OnUpdate(&$event) { if (!$this->Application->CheckPermission('SYSTEM_ACCESS.READONLY', 0)) { parent::OnUpdate($event); + + $conf_update = new kEvent('conf:OnUpdate'); + $conf_update->redirect = false; + $this->Application->HandleEvent($conf_update); } - $module_owner=$this->Application->GetVar('module'); - $module_section=$this->Application->GetVar('section'); - - $conf_update = new kEvent( ); - $conf_update->Init('conf'); - $conf_update->Name = 'OnUpdate'; - $conf_update->redirect = false; - $this->Application->HandleEvent($conf_update); - $event->redirect_params = Array('opener' => 's','confs_module'=>$this->myUrlEncode($module_owner),'confs_section'=>$this->myUrlEncode($module_section),'conf_module'=>$this->myUrlEncode($module_owner),'conf_section'=>$this->myUrlEncode($module_section),'pass'=>'all,confs,conf'); //stay! - + $event->SetRedirectParam('opener', 's'); } function OnCancel(&$event) { parent::OnCancel($event); - $module_owner=$this->Application->GetVar('module'); - $module_section=$this->Application->GetVar('section'); - - $event->redirect_params = Array('opener' => 's','confs_module'=>$this->myUrlEncode($module_owner),'confs_section'=>$this->myUrlEncode($module_section),'conf_module'=>$this->myUrlEncode($module_owner),'conf_section'=>$this->myUrlEncode($module_section),'pass'=>'all,confs,conf'); //stay! - - + $event->SetRedirectParam('opener', 's'); } - - function myUrlDecode($str){ - $str=str_replace(';',':', $str); - $str=str_replace('!','-', $str); - return $str; - } - function myUrlEncode($str){ - $str=str_replace('-', '!', $str); - $str=str_replace(':', ';', $str); - return $str; - } - /** * Enter description here... *