diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2011-04-29 07:38:24 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2011-04-29 07:38:24 +0000 |
commit | fab0774c4beecaf6472777a6502a1818edc26927 (patch) | |
tree | ff0db46334135666986d60c5a77782f74a3d75b8 | |
parent | 93c0b120decf3cc4442cd6da188d58172d94ba81 (diff) | |
download | redmine-fab0774c4beecaf6472777a6502a1818edc26927.tar.gz redmine-fab0774c4beecaf6472777a6502a1818edc26927.zip |
Fixes Prototypejs Form.serialize() for multiple selects (#7954).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/1.1-stable@5586 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | public/javascripts/prototype.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/public/javascripts/prototype.js b/public/javascripts/prototype.js index db86961e4..f84a52e2a 100644 --- a/public/javascripts/prototype.js +++ b/public/javascripts/prototype.js @@ -4993,7 +4993,13 @@ var Form = { key = element.name; value = $(element).getValue(); if (value != null && element.type != 'file' && (element.type != 'submit' || (!submitted && submit !== false && (!submit || key == submit) && (submitted = true)))) { - result = accumulator(result, key, value); + if (Object.isArray(value)){ + value.each(function(value) { + result = accumulator(result, key, value); + }); + } else { + result = accumulator(result, key, value); + } } } return result; |