当用户单击就地编辑器时,我在数据表中使用 primefaces 就地组件执行 js 函数,该函数将运行远程命令以从支持 bean 获取数据,之后应该使用新获取的数据更新 selectonemnu值,一切正常,但有时当我打开一个 inplace 时,它里面的 selectOneMenu 一直显示以前打开的 inplace
的数据<p:column headerText="Values" styleClass="column-data-table">
<p:inplace editor="true">
<f:facet name="output">
<p:outputLabel id="label2"
value="#{parameter.paramValue}"
onclick="onInplaceClickExecuteFetchData()"/>
<p:remoteCommand name="fetchData"
update="label2 select"
process="@this"
action="#{globalParamView.getDataFromLookup(parameter)}">
</p:remoteCommand>
</f:facet>
<f:facet name="input">
<p:selectOneMenu
id="select"
value="#{globalParamView.selectedValue}">
<f:selectItems
value="#{globalParamView.possibleValues}"
var="multi_val"
itemLabel="#{multi_val}"
itemValue="#{multi_val}"/>
</p:selectOneMenu>
</f:facet>
</p:inplace>
</p:column>