I have a command link and on its click i have a dialog in JSF 2.0 as:
<p:commandLink value="(.3%)" style="font-size:10px;" onclick="lrDlg.show()" id="percentchange"/>
Now on the dialog i want the value of command link value as:
<h:outputText value="Change Value" />
<h:panelGroup>
<p:inputText size="10" value="#{bean.changeValue}" required="false"
styleClass=" ui-inputfield ui-widget ui-state-default ui-corner-all " />
<h:outputText value="" style="font-size:10px;" />
</h:panelGroup>
My Question is how i update the value in inputtext so as to reflect in commandlink value(shown as "(.3%)".
Make it a bean property.
private String commandLinkValue;
public Bean() {
commandLinkValue = "(.3%)";
}
// ...
with
<p:commandLink value="#{bean.commandLinkValue}" ...>
and
<h:inputText value="#{bean.commandLinkValue}" ...>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With