summaryrefslogtreecommitdiffstats
path: root/public_html
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2012-02-24 13:55:59 +0100
committerAleksander Machniak <alec@alec.pl>2012-02-24 13:55:59 +0100
commit7caad906bb40ea7f4e73c0aa53b44caff00e33db (patch)
treee921161d8ead4c2488305455b992badb0e4f1c22 /public_html
parentd0b98e875358a700e2837f8517d2fb6a6f9b9508 (diff)
downloadwebadmin-7caad906bb40ea7f4e73c0aa53b44caff00e33db.tar.gz
Functionality related to user-type change
Diffstat (limited to 'public_html')
-rw-r--r--public_html/js/kolab_admin.js8
-rw-r--r--public_html/skins/default/ui.js6
2 files changed, 12 insertions, 2 deletions
diff --git a/public_html/js/kolab_admin.js b/public_html/js/kolab_admin.js
index 7e4839e..29801ef 100644
--- a/public_html/js/kolab_admin.js
+++ b/public_html/js/kolab_admin.js
@@ -531,10 +531,16 @@ function kolab_admin()
this.command('user.list', {page: page});
};
- this.user_save = function()
+ this.user_save = function(reload, section)
{
var data = this.serialize_form('#'+this.env.form_id);
+ if (reload) {
+ data.section = section;
+ this.http_post('user.add', {data: data});
+ return;
+ }
+
this.form_error_clear();
// check password
diff --git a/public_html/skins/default/ui.js b/public_html/skins/default/ui.js
index 9a1b433..c55fb54 100644
--- a/public_html/skins/default/ui.js
+++ b/public_html/skins/default/ui.js
@@ -76,7 +76,11 @@ function init_tabs(id, current)
if (!fs.length)
return;
- current = current ? current : 0;
+ // find active fieldset
+ if (!current) {
+ current = 0;
+ fs.each(function(idx) { if ($(this).hasClass('active')) { current = idx; return false; } });
+ }
// first hide not selected tabs
fs.each(function(idx) { if (idx != current) $(this).hide(); });