Question

I want to switch from PF4.0 to PF5.0, in my console I see a lot of Reference error, because the widgetVars of my elements are no longer exists. However I can call for example the confirmDialogVar widget as PF('confirmDialogVar').show() but not with confirmDialogVar.show() as before.

Is it possible to bring back the 'old' functionality?

Thanks in advance!

Was it helpful?

Solution

The old method was already deprecated in 4.0 and they removed it in 5.0.

Now I have a lot to refactor :D

OTHER TIPS

For those who have come across this, there is another global solution if you do not want to refactor everything. Taken from the User Guide for Primefaces 5.1, you can add a context parameter which will allow the legacy method of referencing widgets to work:

<context-param>
  <param-name>primefaces.LEGACY_WIDGET_NAMESPACE</param-name>
  <param-value>true</param-value>
</context-param>

Doug.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top