aboutsummaryrefslogtreecommitdiff
path: root/id/ConfigWebTool/src/main/webapp/js/common.js
diff options
context:
space:
mode:
Diffstat (limited to 'id/ConfigWebTool/src/main/webapp/js/common.js')
-rw-r--r--id/ConfigWebTool/src/main/webapp/js/common.js57
1 files changed, 51 insertions, 6 deletions
diff --git a/id/ConfigWebTool/src/main/webapp/js/common.js b/id/ConfigWebTool/src/main/webapp/js/common.js
index 384e40509..d31a65d87 100644
--- a/id/ConfigWebTool/src/main/webapp/js/common.js
+++ b/id/ConfigWebTool/src/main/webapp/js/common.js
@@ -22,17 +22,33 @@
*******************************************************************************/
function oaBusinessService() {
if ($('#OAisbusinessservice').attr('checked') == 'checked') {
-
- $('#oa_config_businessservice').css('display', "block");
+ $('#OAisstorkservice').attr('checked',false);
+ $('#oa_config_storkservice').css('display', "none");
+ $('#oa_config_businessservice').css('display', "block");
$('#oa_config_publicservice').css('display', "none");
} else {
-
- $('#oa_config_businessservice').css('display', "none");
+ $('#oa_config_storkservice').css('display', "none");
+ $('#oa_config_businessservice').css('display', "none");
$('#oa_config_publicservice').css('display', "block");
}
}
+function oaStorkService() {
+ if ($('#OAisstorkservice').attr('checked') == 'checked') {
+ $('#OAisbusinessservice').attr('checked',false);
+ $('#oa_config_storkservice').css('display', "block");
+ $('#oa_config_businessservice').css('display', "none");
+ $('#oa_config_publicservice').css('display', "none");
+
+ } else {
+ $('#oa_config_storkservice').css('display', "none");
+ $('#oa_config_businessservice').css('display', "none");
+ $('#oa_config_publicservice').css('display', "block");
+
+ }
+}
+
function oaSSOService() {
if ($('#OAuseSSO').attr('checked') == 'checked') {
@@ -45,12 +61,23 @@ function oaSSOService() {
}
}
function oaStork() {
- if ($('#OAuseSTORKLogon').attr('checked') == 'checked') {
+ if ($('#OAuseSTORKLogon').is(':checked')) {
$('#stork_block').css('display', "block");
} else {
$('#stork_block').css('display', "none");
}
}
+function oaVIDP() {
+ if ($('#oa_vidp_area').css('display') == "none") {
+ $('#oa_vidp_area').css('display', "block");
+ $('#button_vidp_show').css('display', "none");
+ $('#button_vidp_hidden').css('display', "block");
+ } else {
+ $('#oa_vidp_area').css('display', "none");
+ $('#button_vidp_show').css('display', "block");
+ $('#button_vidp_hidden').css('display', "none");
+ }
+}
function oaSAML1() {
if ($('#oa_saml1_area').css('display') == "block") {
$('#oa_saml1_area').css('display', "none");
@@ -187,12 +214,16 @@ function userOnLoad() {
return true;
}
function oaOnLoad() {
+ oaStorkService();
oaBusinessService();
oaSSOService();
oaLegacyService();
+ oaStork();
AdminTarget();
oaTargetSubSector();
+ oaVIDP();
+
$(".colorfield").each(
function() {
$(this).ColorPicker({
@@ -210,7 +241,12 @@ function oaOnLoad() {
function newPeps() {
var target = $(document.getElementById("stork_pepslist").getElementsByTagName("tr")).last()[0];
var clone = target.cloneNode(true);
- var lastindex = parseInt(clone.innerHTML.match(/name="storkconfig.cpepslist\[(\d)/)[1]);
+ try {
+ var lastindex = parseInt(clone.innerHTML.match(/name="storkconfig.cpepslist\[(\d)/)[1]);
+ } catch (err) {
+
+ var lastindex = 1;
+ }
var nextindex = lastindex + 1;
clone.innerHTML = clone.innerHTML.replace(/name="storkconfig.cpepslist\[\d/g, 'name="storkconfig.cpepslist[' + nextindex);
clone.innerHTML = clone.innerHTML.replace(/(.*" value=").*?(".*)/g, '$1$2');
@@ -224,4 +260,13 @@ function newStorkAttribute() {
clone.innerHTML = clone.innerHTML.replace(/name="storkconfig.attributes\[\d/g, 'name="storkconfig.attributes[' + nextindex);
clone.innerHTML = clone.innerHTML.replace(/(.*" value=").*?(".*)/g, '$1$2');
target.parentNode.appendChild(clone);
+}
+function newAp() {
+ var target = $(document.getElementById("stork_aplist").getElementsByTagName("tr")).last()[0];
+ var clone = target.cloneNode(true);
+ var lastindex = parseInt(clone.innerHTML.match(/name="storkOA.attributeProviderPlugins\[(\d)/)[1]);
+ var nextindex = lastindex + 1;
+ clone.innerHTML = clone.innerHTML.replace(/name="storkOA.attributeProviderPlugins\[\d/g, 'name="storkOA.attributeProviderPlugins[' + nextindex);
+ clone.innerHTML = clone.innerHTML.replace(/(.*" value=").*?(".*)/g, '$1$2');
+ target.parentNode.appendChild(clone);
} \ No newline at end of file