Hello guys,
I'm between this two data structures: I would like to have a DataTable but i would like to give the possibility to order the rows like in a OrderList, not just sorting it, but put the row in any possible sequence...is there a way?
thanks
Hello guys, here the issue:
I need to update the disable attribute of a commandButton based of the number of item in the picklist target, in particular if the target size is 0 the button must be disabled.
here my code (i'm using PrimeFaces 3.4):
Face:
Bean:
The idea was to use the setter method of the pickSize component in a non-ortodox way...
So, when an user transfer an item, the ajax will execute the hidden inputText trought its setter that in turn will set the size value in the pickSize, and finally it will change the value of the disabled attribute of the button.
...I have this is the track error:
any suggestion? thanks guys.
But i don't understand the need of the second one, infact in both I can write what i want inside the method.
I mean, what is customizable in the second one that is not possible in the first one?
thanks
Massimo
The request scope bean is created, referenced, and destroyed when the page is initially displayed
Does It mean that the bean is destroyed after the page rendering? (always speaking about request beans)
Or it'll be destroyed when a new request occurs?
thanks
Thanks for the answer, I still have a doubt....
A very simple scenario could be this one:
index.xhtml
page2.xhtml
model.java
Well, I Have noted that the bean is first created when I access to the page (during the rendering, ok) but than it is acreated again again after i click on the commundButton, even though in the page02 there isn't any bean reference, and so it should not be a request...why?
Hello,
Since I have still a lot to learn, i always use System.out.println("something") in the code to understand its flow...for example i put System.out.println("Bean created") to the bean constructor to better follow the bean lifecycle.
Where i can write System.out.println("Bean created") to know where it's destroyed?
thanks
Thanks for the answer,
I have implemented the @ManagedProperty in my request bean and in this way I can use the viewSoped bean method, but I have noted that when i call the page linked to the requestScope bean, toghether with its constructor, it is also called the viewScoped constructor...so when I try to get the values that i had previously saved obviously I get an empty field.
In fact I "lose" the view and then the viewScoped is "distroyed".
It's possible to avoid this "distruction" and get those values or do exist some other technics ?
thanks
Thanks for the answer,
I would like to add an other important detail.
In my request bean i don't want to create a new view scoped bean, but i would like to get a value that was previously setted.
thanks
Massimo