aboutsummaryrefslogtreecommitdiff
path: root/id/ConfigWebTool/src/main/webapp/js
diff options
context:
space:
mode:
authorFlorian Reimair <florian.reimair@iaik.tugraz.at>2013-12-13 09:13:50 +0100
committerFlorian Reimair <florian.reimair@iaik.tugraz.at>2014-01-27 16:34:14 +0100
commit9786de6a3b5886437d23d9cce06ae76ab440ff51 (patch)
treea9d57378407b182664825a6c2ba43e9e9f8ba298 /id/ConfigWebTool/src/main/webapp/js
parent9c46233d2fc5f81908addac6a5ec28046a1bc618 (diff)
downloadmoa-id-spss-9786de6a3b5886437d23d9cce06ae76ab440ff51.tar.gz
moa-id-spss-9786de6a3b5886437d23d9cce06ae76ab440ff51.tar.bz2
moa-id-spss-9786de6a3b5886437d23d9cce06ae76ab440ff51.zip
new peps list entry can be created
Diffstat (limited to 'id/ConfigWebTool/src/main/webapp/js')
-rw-r--r--id/ConfigWebTool/src/main/webapp/js/common.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/id/ConfigWebTool/src/main/webapp/js/common.js b/id/ConfigWebTool/src/main/webapp/js/common.js
index ff9509895..e6fcdf977 100644
--- a/id/ConfigWebTool/src/main/webapp/js/common.js
+++ b/id/ConfigWebTool/src/main/webapp/js/common.js
@@ -177,4 +177,13 @@ function oaOnLoad() {
);
return true;
-} \ No newline at end of file
+}
+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]);
+ 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');
+ target.parentNode.appendChild(clone);
+}