SelectOneMenu becomes unusable after update

UI Components for JSF
Post Reply
azro
Posts: 12
Joined: 12 Jun 2018, 11:31

15 Jun 2018, 10:55

JSF 2.2
PrimeFaces 5
GlassFish 4.1


Very simple to explain, I got multiple selectOneMenu items to perform filtering on several kind of objects, when i change one, the other are being update, and sometimes, I got somes that "change width" and I can't use them anymore :

I got also a reset button, and when i click, sometimes everything ok, sometimes somes broke, sometimes all broke

Image

When I remove the update part, don't have this problem but not very usefull
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
they all are like :

Code: Select all

<p:selectOneMenu id="firstFilter"
          value="#{bean.f1}" 
          style="width:200px">
        <p:ajax event="change" update'="secondFilter" />
     <f:selectItem itemValue="#{null}" noSelectionOption="true" />
     <f:selectItems itemValue="#{bean.listFilter1}" />
</p:selectOneMenu>

I check that if a longer word what not inside, by the Dom and no
There is only:

Code: Select all

<select ... >
    <option value="7ds6f4-s5vf-vs5dv4fds-vfdgv4d" selected="selected"></option>
    <option value="6vdf17-fdsg-1d413f89loi4l8zca"> 1 </option>
    <option value="4v81z-g641-dsu7k4k1z89q94b"> 2 </option>
</select>
EDIT : after Dom inspection, the selectOneMenu which are not working have a element that the other does not have

Code: Select all

<script id="myid_s">$(function(){PrimaFaces.cw("SelectOneMenu", "widget_myid", {id:"myid", widgetVar:"widget_myid"});});</script>
Last edited by azro on 15 Jun 2018, 15:44, edited 1 time in total.

tandraschko
PrimeFaces Core Developer
Posts: 3979
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

15 Jun 2018, 11:49

Try a newer version, 5.0 is very old.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

azro
Posts: 12
Joined: 12 Jun 2018, 11:31

15 Jun 2018, 14:56

I tried to update to 6.2

But I got when I deploy (clean/stop/start done):

NoSuchMethodError : org.primefaces.context.ApplicationContext.getConfig()

And i did not find why, and find nothing similar on the web to help me

tandraschko
PrimeFaces Core Developer
Posts: 3979
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

15 Jun 2018, 14:58

You can just upgrade by replacing the dependency, a library changes over the years and 5.0 is very old.
We have a migration-guide in github.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

azro
Posts: 12
Joined: 12 Jun 2018, 11:31

15 Jun 2018, 15:10

The dependency ?

It just dowload the 2 .jar files (--6.2.jar and --6.2-sources.jar) and add them as a new libray to my project in NetBeans, and remove the 5.0 one

It's not the good way ?

My dev' computer is not connected to the internet, so i don't use like maven and its dependencies

tandraschko
PrimeFaces Core Developer
Posts: 3979
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

15 Jun 2018, 16:05

You upgraded PF, it doesn't matter if you do it manually or via maven/gradle/else.

You still need to migrate your code.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

azro
Posts: 12
Joined: 12 Jun 2018, 11:31

18 Jun 2018, 09:06

I read the migration guide of github and see nothing related to what I got

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: thealanmc and 39 guests