如果不是"processContext.targetUpdate"
,我想将'update'
中的值从托管bean传递到commandButton
中的null
标记。
所以我做了:
<p:commandButton
update="@(.painelInfoDer)
@(.msgsDialogAltDer)
@(.opValorAtualDer)
@(.outputPanel)
@(.#{processContext.targetUpdate != null?processContext.targetUpdate:@none})"
但我收到了一个错误:
Caused by: com.sun.el.parser.ParseException: Encountered "@" at line 1, column 157.
Was expecting one of:
<INTEGER_LITERAL> ...
<FLOATING_POINT_LITERAL> ...
<STRING_LITERAL> ...
"true" ...
"false" ...
"null" ...
"(" ...
"!" ...
"not" ...
"empty" ...
"-" ...
<IDENTIFIER> ...
这个表达有什么问题?会像我期望的那样传递像这样的参数吗?
我认为问题是@none,现在我改为:
<p:commandButton
update="@(.painelInfoDer)
@(.msgsDialogAltDer)
@(.opValorAtualDer)
@(.outputPanel)
@(.#{processContext.targetUpdate != null?processContext.targetUpdate:''})"
现在按钮消失了。