Commit 50ca3386 authored by Nicolas Wavrant's avatar Nicolas Wavrant

runner: fix the bug which can transform parameters to undefined

bug described here: https://nexedi.erp5.net/bug_module/20140718-1A93B96
parent d673a731
...@@ -89,9 +89,12 @@ $(document).ready(function () { ...@@ -89,9 +89,12 @@ $(document).ready(function () {
} }
xml += '<instance>\n'; xml += '<instance>\n';
if (size > 1) { if (size > 1) {
for (i = 2; i <= size; i += 1) { // we have to remove the 1st line, which just diplay column names
if ($('input#txt_' + i).val() !== '') { for (i = 0; i < size - 1; i += 1) {
xml += '<parameter id="' + $('input#txt_' + i).val() + '">' + $('textarea#value_' + i).val() + '</parameter>\n'; var parameter_name = $("#partitionParameter tr").find("input")[i].value;
var parameter_value = $("#partitionParameter tr").find("textarea")[i].value;
if (parameter_name !== '') {
xml += '<parameter id="' + parameter_name + '">' + parameter_value + '</parameter>\n';
} }
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment