Possibility to preselect choice tab (#2115)
This commit is contained in:
parent
465b848913
commit
9620e6870a
|
@ -413,6 +413,7 @@ sub display {
|
|||
AUTH_LOOP => $authLoop,
|
||||
CHOICE_PARAM => $self->conf->{authChoiceParam},
|
||||
CHOICE_VALUE => $req->data->{_authChoice},
|
||||
DISPLAY_TAB => scalar( $req->param("tab") ),
|
||||
DISPLAY_FORM => 0,
|
||||
DISPLAY_OPENID_FORM => 0,
|
||||
DISPLAY_YUBIKEY_FORM => 0,
|
||||
|
|
|
@ -256,6 +256,9 @@ $(window).on 'load', () ->
|
|||
# Authentication choice tabs
|
||||
authMenuTabs = $("#authMenu").tabs
|
||||
active: 0
|
||||
authMenuIndex = $('#authMenu a[href="#' + datas['displaytab'] + '"]').parent().index()
|
||||
authMenuIndex = 0 if authMenuIndex < 0
|
||||
authMenuTabs.tabs "option", "active", authMenuIndex
|
||||
|
||||
# TODO: cookie
|
||||
# $("#authMenu").tabs
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
// Generated by CoffeeScript 1.12.7
|
||||
// Generated by CoffeeScript 1.12.8
|
||||
|
||||
/*
|
||||
LemonLDAP::NG Portal jQuery scripts
|
||||
|
@ -223,7 +223,7 @@ LemonLDAP::NG Portal jQuery scripts
|
|||
datas = {};
|
||||
|
||||
$(window).on('load', function() {
|
||||
var action, al, authMenuTabs, back_url, i, l, lang, langdiv, langs, langs2, len, len1, len2, len3, link, m, menuIndex, menuTabs, method, n, nl, nlangs, re, ref, ref1, ref2;
|
||||
var action, al, authMenuIndex, authMenuTabs, back_url, i, l, lang, langdiv, langs, langs2, len, len1, len2, len3, link, m, menuIndex, menuTabs, method, n, nl, nlangs, re, ref, ref1, ref2;
|
||||
datas = getValues();
|
||||
window.datas = datas;
|
||||
$("#appslist").sortable({
|
||||
|
@ -250,6 +250,11 @@ LemonLDAP::NG Portal jQuery scripts
|
|||
authMenuTabs = $("#authMenu").tabs({
|
||||
active: 0
|
||||
});
|
||||
authMenuIndex = $('#authMenu a[href="#' + datas['displaytab'] + '"]').parent().index();
|
||||
if (authMenuIndex < 0) {
|
||||
authMenuIndex = 0;
|
||||
}
|
||||
authMenuTabs.tabs("option", "active", authMenuIndex);
|
||||
if (datas['choicetab']) {
|
||||
authMenuTabs.tabs("option", "active", $('#authMenu a[href="#' + datas['choicetab'] + '"]').parent().index());
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user