[ https://issues.apache.org/jira/browse/WW-5240?focusedWorklogId=823632&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-823632 ]
ASF GitHub Bot logged work on WW-5240: -------------------------------------- Author: ASF GitHub Bot Created on: 05/Nov/22 07:44 Start Date: 05/Nov/22 07:44 Worklog Time Spent: 10m Work Description: sonarcloud[bot] commented on PR #631: URL: https://github.com/apache/struts/pull/631#issuecomment-1304433864 Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_struts&pullRequest=631) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/security_hotspots?id=apache_struts&pullRequest=631&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_struts&pullRequest=631&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_struts&pullRequest=631&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_struts&pullRequest=631&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/component_measures?id=apache_struts&pullRequest=631&metric=coverage&view=list) No Coverage information [](https://sonarcloud.io/component_measures?id=apache_struts&pullRequest=631&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_struts&pullRequest=631&metric=new_duplicated_lines_density&view=list) Issue Time Tracking ------------------- Worklog Id: (was: 823632) Time Spent: 20m (was: 10m) > doubleOnchange attribute of the doubleselect tag is not supported > ----------------------------------------------------------------- > > Key: WW-5240 > URL: https://issues.apache.org/jira/browse/WW-5240 > Project: Struts 2 > Issue Type: Improvement > Affects Versions: 6.0.0 > Reporter: James Hartleroad > Priority: Minor > Fix For: 6.1.0 > > Time Spent: 20m > Remaining Estimate: 0h > > When setting up a doubleselect tag with a call to a java script on the > doubleOnchange attribute, the java script is not called. > For example a jsp with the following doubleselect > {code} > <s:doubleselect label="relbuild" > id="selectapp" name="selectapp" > list="appreleaseMap.keySet()" onchange="app2select()" > doubleId="selectrel" doubleName="selectrel" > doubleList="appreleaseMap.get(top)" > doubleOnchange="rel2select()" /> > {code} > and a java script file with (alerts added for debugging) > {code:javascript} > function app2select() { > alert('app2select'); > var elmnt = document.getElementById('selectapp'); > var value = elmnt.value; > alert('value is:' + value); > document.getElementById('applid').value = value; > document.getElementById('release').value = ''; > } > function rel2select() { > alert('rel2select'); > var elmnt = document.getElementById('selectrel'); > var value = elmnt.value; > alert('value=' + value); > document.getElementById('release').value = value; > } > {code} > The app2select is called when selecting the first element, but the rel2select > is not called when selecting the 2nd element. > Per information I found on the web I updated the > template/simple2/doubleselect.ftl by adding the following and then it worked. > {code} > <#if parameters.doubleOnchange??><#t/> > onchange="<#outputformat > 'JavaScript'>${parameters.doubleOnchange}</#outputformat>" > </#if><#t/> > {code} -- This message was sent by Atlassian Jira (v8.20.10#820010)