diff --git a/admin/inc/class.admin_categories.inc.php b/admin/inc/class.admin_categories.inc.php index 34bab5ff65..a007aaff12 100644 --- a/admin/inc/class.admin_categories.inc.php +++ b/admin/inc/class.admin_categories.inc.php @@ -221,7 +221,7 @@ class admin_categories if ($button == 'save') { - Framework::refresh_opener($msg, $refresh_app, $content['id'], $change_color ? null : 'update', $this->appname); + Framework::refresh_opener($msg, $this->appname, $content['id'], $change_color ? null : 'update', $refresh_app); Framework::window_close(); } break; @@ -244,7 +244,7 @@ class admin_categories break; } // This should probably refresh the application $this->appname in the target tab $refresh_app, but that breaks pretty much everything - Framework::refresh_opener($msg, $refresh_app, $content['id'], $change_color ? null : 'update', $this->appname); + Framework::refresh_opener($msg, $this->appname, $content['id'], $change_color ? null : 'update', $refresh_app); } $content['msg'] = $msg; if(!$content['appname']) $content['appname'] = $appname; diff --git a/api/js/framework/fw_base.js b/api/js/framework/fw_base.js index cea5a6c83a..bcc7b19a55 100644 --- a/api/js/framework/fw_base.js +++ b/api/js/framework/fw_base.js @@ -927,6 +927,11 @@ var fw_base = (function(){ "use strict"; return Class.extend( } // Call appropriate default / fallback refresh var win = window; + + // Preferences app is running under admin app, we need to trigger admin refersh + // in order to refresh categories list + _app = _app === 'preferences'?'admin':_app; + var app = this.getApplicationByName(_app); if (app) { diff --git a/api/js/jsapi/egw_preferences.js b/api/js/jsapi/egw_preferences.js index 0803bbf0f1..e3440956b9 100644 --- a/api/js/jsapi/egw_preferences.js +++ b/api/js/jsapi/egw_preferences.js @@ -150,8 +150,10 @@ egw.extend('preferences', egw.MODULE_GLOBAL, function() } else { + delete query.current_app; query.menuaction='preferences.preferences_categories_ui.index'; query.cats_app=current_app; + query.ajax = true; } egw.link_handler(egw.link(url, query), current_app); break;