
|
If you were logged in you would be able to see more operations.
|
|
|
|
The IfTag calls findValue(test) and if the return value is a Boolean it uses that to determine if the body should be rendered.
This does not allow usage such as this:
<ww:if test="business.location"> ... </ww:if>
The ognl TypeConverter can coerce any object to a Boolean which would make the WW2 IfTag much more flexible. It would then work with Strings that equal "true", numbers that are non zero etc.
It could be changed to ask for a Boolean like so:
findValue(test, Boolean.class)
I have made this change and it seems to work well so far!
|
|
Description
|
The IfTag calls findValue(test) and if the return value is a Boolean it uses that to determine if the body should be rendered.
This does not allow usage such as this:
<ww:if test="business.location"> ... </ww:if>
The ognl TypeConverter can coerce any object to a Boolean which would make the WW2 IfTag much more flexible. It would then work with Strings that equal "true", numbers that are non zero etc.
It could be changed to ask for a Boolean like so:
findValue(test, Boolean.class)
I have made this change and it seems to work well so far! |
Show » |
|