Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.3.1.2
-
None
-
Microsoft Windows 7 (32-bit)
Eclipse Helios Service Release 2
Java JDK 1.6.0_17
Description
When I use to set the attribute "doubleOnmouseover" to the optiontransferselect tag, the generated html code doesn't include the "onmouseover" attribute for the second (or right) select box.
For example:
<s:optiontransferselect
id="language_left"
name="language.blackList"
list="language.blackList"
listValue="productDetails[top].name" size="20"
doubleId="language_right"
doubleName="language.whiteList"
doubleList="language.whiteList"
doubleListValue="productDetails[top].name"
doubleSize="20"
formName="languageForm"
allowSelectAll="false"
allowUpDownOnLeft="false"
allowUpDownOnRight="false"
addToLeftLabel="%
"
addAllToLeftLabel="%
"
addToRightLabel="%
"
addAllToRightLabel="%
"
leftTitle="%
"
rightTitle="%
"
onmouseover="showTooltip('language_left', event.target.value)"
doubleOnmouseover="showTooltip('language_right', event.target.value)" />
...will be transformed into:
<script src="/BackOffice/struts/optiontransferselect.js" type="text/javascript"></script>
<table border="0">
<tbody>
<tr>
<td>
<select
onmouseover="showTooltip('language_left', event.target.value)"
multiple="multiple"
id="language_left"
size="20"
name="language.blackList">
<option selected="selected" value="1962">F-Kachel</option>
<%-- further options have been removed due to readability --%>
</select>
<input type="hidden" value="" name="_multiselect_language.blackList" id="_multiselect_language_left">
</td>
<td valign="middle" align="center">
<%-- buttons have been removed due to readability --%>
</td>
<td>
<select
id="language_right"
multiple="multiple"
size="20"
name="language.whiteList">
<option selected="selected" value="1590">kms100</option>
<%-- further options have been removed due to readability --%>
</select>
<input type="hidden" value="" name="_multiselect_language.whiteList" id="_multiselect_language_right">
</td>
</tr>
</tbody>
</table>
As you can see, the second select tag is missing the "onmouseover" attribute, while the first select tag correctly contains it's "onmouseover" attribute.
I could also find out, why this is happening: the freemarker template optiontransferselect.ftl contains 2 errors. The first is the one, that is described above, which is related to the fact that the following lines of codes are missing:
<#if parameters.doubleOnmouseover??><#t/>
onmouseover="${parameters.doubleOnmouseover?html}"
</#if><#t/>
The second error that I've found is that at line 217 the parameter is misspelled:
217: onmouseup="${parameters.doubleMnmouseup?html}"
...should be...
217: onmouseup="${parameters.doubleOnmouseup?html}"
After I changed these lines, the OptionTransferSelect tag worked properly.
I hope, that I could help you with this bug report.
Kind regards, Daniel