RE : Input Suggest - Ajax Suggest
I did try the inputSuggest. It works globally well except some small issues (its in sandbox ...). Theres somes JIRA issues opened on it. Did someone try the ajaxInputSuggest ? -Message d'origine- De : Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé : vendredi 9 septembre 2005 17:14 À : MyFaces Discussion; [EMAIL PROTECTED] Objet : Re: Input Suggest - Ajax Suggest Input suggest is pure client side - ajax suggest goes back to the server to fetch its data. Choose the one you need! Currently, there are some known issues with inputSuggest afaik. As to ajaxInputSuggest, there seem to be no open issues right now, doesn't mean that there are none ;) regards, Martin On 9/9/05, Vladimir Coutinho [EMAIL PROTECTED] wrote: What is better Input Suggest or Ajax Suggest (sandbox)? They work fine? -- Vladimir M Coutinho -- http://www.irian.at Your JSF powerhouse - JSF Trainings in English and German
RE : [ANNOUNCE] MyFaces passed the JSF TCK 1.1
MyFaces ROCKS :D:D:D Clément Maignien -Message d'origine- De : Manfred Geiler [mailto:[EMAIL PROTECTED] Envoyé : lundi 12 septembre 2005 15:12 À : MyFaces Development; MyFaces Discussion Objet : [ANNOUNCE] MyFaces passed the JSF TCK 1.1 The MyFaces team is very proud to announce the fact, that the current codebase has just passed *all* JSF TCK 1.1 tests! This is a great milestone (actually the greatest since MyFaces has started in 2003) and we are all looking forward to releasing the first official certified free open source JSF implementation Apache MyFaces 1.1.0 soon (after clarifying some legal and technical stuff). Thanks to every single contributor, who helped making MyFaces another open source success story. applause ... ... ... bowThank you very much!/bow /applause Let's head for the next challenges: beat ALL bugs :), JSF 1.2, JSF 2.0, ... Manfred Geiler
RE : inputHtml question
Title: Message Hi, I also noticed this issue. Impossible to specify any value for the "type" propertie. Clément. -Message d'origine-De: Vesa Lindfors [mailto:[EMAIL PROTECTED] Envoyé: lundi 5 septembre 2005 11:17À: users@myfaces.apache.orgObjet: x:inputHtml questionHi,I have tried to get t:inputHtml working (with latest nightly build) so that it would handle the whole HTML document, not just fragment of it.From tld I found the 'type' : t:inputHtml value="String"style="CSSClass"fallback="{true|false}"type="Constant" ... type - The type of the value. It can be either fragment for an HTML fragment (default) or document for a full HTML document, with head, title, body, ... tags. ...When trying to set it to document or fragment (or true or false) I got exception:'Could not set property type of component HTMLeditor'I took a short look to code, and if I understood correctly it the 'type' is first handled as boolean but later as string... In InputHtmlTag:protected void setProperties(UIComponent component) { super.setProperties(component); setStringProperty(component, "style", style); setStringProperty(component, "styleClass", styleClass); setStringProperty(component, "fallback", fallback); setBooleanProperty(component, "type", type);In InputHtml.java:public String getType(){ if (_type != null) return _type; ValueBinding vb = getValueBinding("type"); return vb != null ? (String)vb.getValue(getFacesContext()) : "fragment";}Is that the problem?--- VLi ---
Which class to prepare database data to be displayed in JSF components
Title: Message Hi everyone, Here is the situation : I have to display in JSF components data(what ever it is)that come from a database (what ever it is). Which class is supposed to format data so it can be displayed in JSF component ? For example insome SelectItem objects. According to me, the DAO souldn't do that as it is done in the MyFaces Wiki page http://wiki.apache.org/myfaces/HibernateAndMyFacesin the last example, because it links data model to UI. The services (Spring for example) classes shouldn't do that either as the service could be called by WebService or RMI for a Swing application for example. It could be done ManagedBean class (Form Bean), but this time it links UI data to model Data. So in my opinion this should be done BeanAction class,am Iwrong ? Thx for your support. Clément.
RE : export dataTable in excel
Sorry but what is a POI ? Clément -Message d'origine- De : Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé : vendredi 2 septembre 2005 16:17 À : MyFaces Discussion Objet : Re: export dataTable in excel You can try something like this: use an actionListener - and then: public myListener(ActionEvent ev) { //Have the commandLink in the header or footer facet of the table (not fully sure if this works though) UIData dataTable = (UIData) ev.getComponent().getParent().getParent(); //call POI and render to FacesContext.getCurrentInstance().responseWriter() finall call FacesContext.getCurrentInstance().responseComplete(); } or whatever you want to do... regards, Martin On 9/2/05, ::SammyRulez:: [EMAIL PROTECTED] wrote: hi I read a old post about how export dataTable data in excel format http://www.mail-archive.com/users@myfaces.apache.org/msg03873.html It seems there is no solution except building a custom POI servlet with sepcific code (read duplicated code! ) for each datatable(my actual solution). Isn0t any convinient method to pass a full dataTable Object to an actionMethod... I have some code thath would be useful http://sourceforge.net/projects/spreadobjects see ya -- ::SammyRulez:: http://sammyprojectz.blogspot.com -- http://www.irian.at Your JSF powerhouse - JSF Trainings in English and German
RE : Thanks and a best practice question in regard to set up of backing bean Actions
Could someone who have a clear view of those best practices sumup everything that have bean said in here ? What are managed bean roles ? What are action bean roles ? What are Value Object roles ? What are DAO roles ? How do they communicate ? Who have reference to who ? So much questions that I used to believe the answer, but since this discussion nothing is really clear anymore. Thx Clément -Message d'origine- De : CONNER, BRENDAN (SBCSI) [mailto:[EMAIL PROTECTED] Envoyé : mercredi 31 août 2005 21:55 À : MyFaces Discussion Objet : RE: Thanks and a best practice question in regard to set up of backing bean Actions You'll also want an EmployeeBean as a managed bean, which can be defined as having type EmployeeVO. Then you'll want your EmployeeAction to have a managed reference to EmployeeBean, and don't instantiate that; let JSF do that. And don't instantiate it; let JSF do that. Then, when the user hits Save, JSF will automatically populate your EmployeeBean with the correct values (assuming your JSF page uses EmployeeBean), and your save() method can just refer to the EmployeeBean values. - Brendan -Original Message- From: Rick Reumann [mailto:[EMAIL PROTECTED] Sent: Wednesday, August 31, 2005 12:48 PM To: MyFaces Discussion Subject: Thanks and a best practice question in regard to set up of backing bean Actions Thanks everyone for your help with the crud demo app I've been working with. (Special thanks to Brendan for his fine Car example code that he posted in another thread). I want to start out on the right foot doing things in a 'correct' way before I get into some bad practices. Currently, I have a list of employees in a table you click on the employee and a backing bean method gets the correct row, grabs the id, gets the true larger Employee object back, then forwards to an Employee form where you can edit the employee info. What I'm debating about his how to best set up the backing bean that supports the 'save' of this form. Currently it's part of an EmployeeAction object and the pertinent code looks like: EmployeeAction.java -- private EmployeeVO employee = new EmployeeVO(); private EmployeesListBean empListBean; public EmployeesListBean getEmployeesListBean() { return empListBean; } public void setEmployeesListBean(EmployeesListBean empListBean) { this.empListBean = empListBean; } public EmployeeVO getEmployee() { return employee; } public void setEmployee(EmployeeVO employee) { this.employee = employee; } public String prepareForEdit() { log.debug(prepareForEdit); this.employee = (EmployeeVO)getEmployeesListBean().getEmployeesModel().getRowData(); //get Employee from backend this.employee = EmployeeService.getEmployee( employee.getId() ); log.debug(returned employee = +employee ); return success; } public String saveAction() { //need way to tell update vs insert ? log.debug(In saveAction ); EmployeeService.updateEmployee(employee); return success; } The prepareForEdit method is called from a link next to the name of each employee on the employees.jsp. After clicking the link the success result will navigate you to emloyeeForm.jsp... The part I'm not so sure about is the setup of the EmployeeAction.. I'm having to initialize EmployeeVO employee = new EmployeeVO(); because if I don't have this, I'll end up with conversion errors since the employee is null when the form submits. Is it better to not create this new instance and maybe use saveState on the form instead? Also on the form I'm doing... h:inputText value=#{employeeAction.employee.name}/ I like the above since it saves me from having to add extra set/gets in my EmployeeAction class to deal with the EmployeeVO nested inside of EmployeeAction.However maybe there are some major drawbacks to doing it that way I've implemented it? Thanks for any comments.
dataTable headers
Title: Message Hi, I'm looking for a way to display headers of headers in a dataTable. Each column have its own header, but I want to put "super header" to group columns that display the samekind of informations. Is there a simple way to do that ? I tried it many ways but they are not good looking. Thx in advance Clément. _ ClémentMaignien[EMAIL PROTECTED] E D I C/ GROUPE SYLIANCE 123, quai de Brazza - 33100 Bordeaux Tél : 05 57 80 93 00 - Fax : 05 57 80 93 09 ¯
RE : Navigation bug through browser previous button
Title: Message Should I understand this big participation as a :"No there isn't any solution !" ? Regards, Clément. -Message d'origine-De: Clément Maignien Envoyé: vendredi 26 août 2005 11:06À: MyFaces DiscussionObjet: Navigation bug through browser previous button Hi everybody, there's a bug in my webapp when I use the browser "previous page"navigation button instead of my custom links : When clicking "previous page" the button, the previous page displays well but redisplays as soon a I do an action in the page and as a consequence skip it. In my opinion, this could comes from the SERVER_STATE saving method associated to the redirect instruction in my faces-config.xml. Does it comes from that ? if yes, is there a solution to this problem without switching tothe CLIENT_STATE saving method ? if no, where does it comes from ? Thanks for your help Clément.
RE : Setting error page
Title: Message OK thx Paul this works fine for the redirect on error. I'll look at thelink for the session timeout redirection. Thx again. Clément. -Message d'origine-De: Keel, Paul [mailto:[EMAIL PROTECTED] Envoyé: jeudi 25 août 2005 16:20À: MyFaces DiscussionObjet: RE: Setting error page To Set the error page, put the following entry in your web.xml file: error-page error-code500/error-code location/errorPage.jsf/location /error-page I believe you can set a page for each type of error but this seems to redirect on all exceptions. In order to redirect to a page when the session ends, you will have to write a session filter. I found this article very useful: http://www.jguru.com/forums/view.jsp?EID=1248692 Paul From: Clément Maignien [mailto:[EMAIL PROTECTED] Sent: Thursday, August 25, 2005 8:42 AMTo: MyFaces DiscussionSubject: Setting error page Hi, I would like to know how to set a JSFerror page that will be displayed instead of the default Tomcat one. Is it possible to redirect the navigation to a specific page when the user session times out ? Thx. Clément
TR : Dynamic Locale change
Title: Message Sorry for asking so much questions but I'll have to present my webapp very soon and I need the multi-language to works fine. Has anybody any idea ? Why the locale is reset to the default one ? Could it comes from a redirect/ instruction in my faces-config.xml ? Ty for your help :D Clément -Message d'origine-De: Clément Maignien Envoyé: lundi 22 août 2005 18:18À: MyFaces DiscussionObjet: Dynamic Locale change Hi, I'm trying to allow the application user to change the language of my web app. I did it the way it is done in the myFaces 1.0.9 examples : a selectOneMenu with a choice of languages and an action button with that code : OptionBean { ... public String action { ... FacesUtil.setLocale(selectedLocale); ... } ... } FacesUtil { ... public static void setLocale(Locale l) { FacesContext.getCurrentInstance().getFacesContext().getViewRoot().setLocale(l); } ... } It works fine when the action is executed (the language change), but as soonas I navigate to another page of the App, the language is resetted to the default one. Why ? NB: I'm trying not to use the locale parameter of the f:view tag ... Thx, Clément.
RE : new panelTabbedPane problems
Hi, I use the same nightly build than yours and I can use a dataTable in every tab of my tabbedPane ... Maybe theres an error in your code. Regards, Clément -Message d'origine- De : Bogdan Sava [mailto:[EMAIL PROTECTED] Envoyé : vendredi 26 août 2005 10:20 À : MyFaces Discussion Objet : new panelTabbedPane problems I used until now myFaces 1.0.9 version. Now I use tomahawk.jar lib nightly (20050824) . Problems are : 1. panelTabbedPane from simple example does not work with h:commandLink instead of h:commandButton. If you are in second or third tab, after click h:commandLink, panelTabbedPane will displays first tab. 2. I cannot use dataTable inside of an tab (other than first tab) of panelTabbedPane, like I used in previews version (myfaces.jar 1.0.9). After click to change the page of dataTable , panelTabbedPane displays fist tab. Is there a possibility to have server side switch of tabs of panelTabbedPane like in previous version ? In tomahawk is client side. Bogdan Sava
Navigation bug through browser previous button
Title: Message Hi everybody, there's a bug in my webapp when I use the browser "previous page"navigation button instead of my custom links : When clicking "previous page" the button, the previous page displays well but redisplays as soon a I do an action in the page and as a consequence skip it. In my opinion, this could comes from the SERVER_STATE saving method associated to the redirect instruction in my faces-config.xml. Does it comes from that ? if yes, is there a solution to this problem without switching tothe CLIENT_STATE saving method ? if no, where does it comes from ? Thanks for your help Clément.
RE : TR : Dynamic Locale change
Thx Udo but look at the NB of my first message --- NB : I'm trying not to use the locale parameter of the f:view tag This solution works (I've tried it) but not so clean in my opinion. The use of FacesContext.getCurrentInstance().getFacesContext().getViewRoot().setLocale(l) should work as it work in the myfaces1.0.9 examples. Anybody ? Other ideas ? Thx again Udo Regards, Clément -Message d'origine- De : Udo Schnurpfeil [mailto:[EMAIL PROTECTED] Envoyé : vendredi 26 août 2005 15:20 À : MyFaces Discussion Objet : Re: TR : Dynamic Locale change If you set the locale in the UIViewRoot manually, I don't know if it will be passed on to the next UIViewRoot. One solution for you might be putting the users locale in the session (e.g. the key locale or user.locale if your have a user object) and use the locale attribute f:view locale=#{locale} or f:view locale=#{user.locale} on all of your JSF pages. regards, Udo Clément Maignien wrote: Sorry for asking so much questions but I'll have to present my webapp very soon and I need the multi-language to works fine. Has anybody any idea ? Why the locale is reset to the default one ? Could it comes from a redirect/ instruction in my faces-config.xml ? Ty for your help :D Clément -Message d'origine- *De :* Clément Maignien *Envoyé :* lundi 22 août 2005 18:18 *À :* MyFaces Discussion *Objet :* Dynamic Locale change Hi, I'm trying to allow the application user to change the language of my web app. I did it the way it is done in the myFaces 1.0.9 examples : a selectOneMenu with a choice of languages and an action button with that code : OptionBean { ... public String action { ... FacesUtil.setLocale(selectedLocale); ... } ... } FacesUtil { ... public static void setLocale(Locale l) { FacesContext.getCurrentInstance().getFacesContext().getViewRoot().setLocale(l); } ... } It works fine when the action is executed (the language change), but as soon as I navigate to another page of the App, the language is resetted to the default one. Why ? NB : I'm trying not to use the /locale/ parameter of the /f:view/ tag ... Thx, Clément.
RE : TR : Dynamic Locale change
OK thx Gianni. So if I sum up things : 2 solutions to dynamically change your application locale : *1- If you use the server STATE_SAVING_METHOD with somes /redirect instructions : Create a bean to save the locale choice This bean must be in session scope or request + saveState Then in each page of your application that needs to be localized, add the locale parameter to them : f:view locale=#{localeBean.locale} *2- If you use the client STATE_SAVING_METHOD ( - no /redirect instructions) : Use the UIViewRoot.setLocale(Locale l) method. For example : FacesContext.getCurrentInstance().getFacesContext().getViewRoot.().setLocale(l); Regards, Clément -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Envoyé : vendredi 26 août 2005 15:48 À : MyFaces Discussion Objet : Re: TR : Dynamic Locale change I suggest you take a look at the list archives for Maintain locale across views. I had a similar issue and it seems the locale is not maintained across views when a redirect/ is used. In the end I set f:view locale=#{visit.locale}, where visit is a session scoped bean. Gianni Sorry for asking so much questions but I'll have to present my webapp very soon and I need the multi-language to works fine. Has anybody any idea ? Why the locale is reset to the default one ? Could it comes from a redirect/ instruction in my faces- config.xml ? Ty for your help :D Clément -Message d'origine- *De :* Clément Maignien *Envoyé :* lundi 22 août 2005 18:18 *À :* MyFaces Discussion *Objet :* Dynamic Locale change Hi, I'm trying to allow the application user to change the language of my web app. I did it the way it is done in the myFaces 1.0.9 examples : a selectOneMenu with a choice of languages and an action button with that code : OptionBean { ... public String action { ... FacesUtil.setLocale(selectedLocale); ... } ... } FacesUtil { ... public static void setLocale(Locale l) { FacesContext.getCurrentInstance().getFacesContext().getViewRoot ().setLocale(l); } ... } It works fine when the action is executed (the language change), but as soon as I navigate to another page of the App, the language is resetted to the default one. Why ? NB : I'm trying not to use the /locale/ parameter of the / f:view/ tag ... Thx, Clément.
RE : RE : TR : Dynamic Locale change
Another solution provided by Martin : -Message d'origine- De : Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé : vendredi 26 août 2005 16:37 À : MyFaces Discussion Objet : Re: TR : Dynamic Locale change The solution would be quite similar to what was done in a collaborative effort on the mailing list - install a phaselistener, store it in the session, restore it from the session after the redirect. regards, Martin -Message d'origine- De : Clément Maignien Envoyé : vendredi 26 août 2005 16:37 À : MyFaces Discussion Objet : RE : TR : Dynamic Locale change OK thx Gianni. So if I sum up things : 2 solutions to dynamically change your application locale : *1- If you use the server STATE_SAVING_METHOD with somes /redirect instructions : Create a bean to save the locale choice This bean must be in session scope or request + saveState Then in each page of your application that needs to be localized, add the locale parameter to them : f:view locale=#{localeBean.locale} *2- If you use the client STATE_SAVING_METHOD ( - no /redirect instructions) : Use the UIViewRoot.setLocale(Locale l) method. For example : FacesContext.getCurrentInstance().getFacesContext().getViewRoot.().setLocale(l); Regards, Clément -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Envoyé : vendredi 26 août 2005 15:48 À : MyFaces Discussion Objet : Re: TR : Dynamic Locale change I suggest you take a look at the list archives for Maintain locale across views. I had a similar issue and it seems the locale is not maintained across views when a redirect/ is used. In the end I set f:view locale=#{visit.locale}, where visit is a session scoped bean. Gianni Sorry for asking so much questions but I'll have to present my webapp very soon and I need the multi-language to works fine. Has anybody any idea ? Why the locale is reset to the default one ? Could it comes from a redirect/ instruction in my faces- config.xml ? Ty for your help :D Clément -Message d'origine- *De :* Clément Maignien *Envoyé :* lundi 22 août 2005 18:18 *À :* MyFaces Discussion *Objet :* Dynamic Locale change Hi, I'm trying to allow the application user to change the language of my web app. I did it the way it is done in the myFaces 1.0.9 examples : a selectOneMenu with a choice of languages and an action button with that code : OptionBean { ... public String action { ... FacesUtil.setLocale(selectedLocale); ... } ... } FacesUtil { ... public static void setLocale(Locale l) { FacesContext.getCurrentInstance().getFacesContext().getViewRoot ().setLocale(l); } ... } It works fine when the action is executed (the language change), but as soon as I navigate to another page of the App, the language is resetted to the default one. Why ? NB : I'm trying not to use the /locale/ parameter of the / f:view/ tag ... Thx, Clément.
RE : RE : inputSuggest : some others improvement to do
Title: Message What about the #3 problem ? Is it really the expected behaviour of this component ? Thanks Clément -Message d'origine-De: Clément Maignien Envoyé: mercredi 24 août 2005 11:34À: MyFaces DiscussionObjet: RE : inputSuggest : some others improvement to do Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with manyitems into and the white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't addthe inputSuggestin the page ... wierd ... Bye, Clément. -Message d'origine-De: Clément Maignien Envoyé: mercredi 24 août 2005 10:37À: MyFaces DiscussionObjet: s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. 2- It also seems that under Firefox (not IE), the page vertical lenght is increaseddepending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? 3- When you click inside the inputSuggest and then click outside without typing anything or choosing an item, I get a value of "-1" in the model. In fact, a new suggest is added to the component with an empty stringas label and -1 as value. Is this the expected behaviour of the inputSuggest component ? Thx, Clément.
Setting error page
Title: Message Hi, I would like to know how to set a JSFerror page that will be displayed instead of the default Tomcat one. Is it possible to redirect the navigation to a specific page when the user session times out ? Thx. Clément
RE : RE : RE : inputSuggest : some others improvement to do
OK I'll add all my observations as commentaries on the JIRA issue I already opened previously. Regards, Clément -Message d'origine- De : Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé : jeudi 25 août 2005 15:33 À : MyFaces Discussion Objet : Re: RE : RE : inputSuggest : some others improvement to do inputSuggest is still very rough as var as the JSF part goes. So its entirely possible. I will try and turn my attention to it once we get the release done. Someone should add a JIRA issue for now. sean On 8/25/05, Matt Blum [EMAIL PROTECTED] wrote: No, that wouldn't seem to me to be the expected behavior. Sean coded that piece, so I can't be 100% sure, but I'd think the expected behavior should be that, if the user doesn't enter anything (either by picking from the list of suggestions or typing in something not on the list), a null value would be submitted to the model, just as it would be for a normal text box left blank. So, to my mind, that would also be a bug. Sean, any comments? -Matt On 8/25/05, Clément Maignien [EMAIL PROTECTED] wrote: What about the #3 problem ? Is it really the expected behaviour of this component ? Thanks Clément -Message d'origine- De : Clément Maignien Envoyé : mercredi 24 août 2005 11:34 À : MyFaces Discussion Objet : RE : inputSuggest : some others improvement to do Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with many items into and the white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't add the inputSuggest in the page ... wierd ... Bye, Clément. -Message d'origine- De : Clément Maignien Envoyé : mercredi 24 août 2005 10:37 À : MyFaces Discussion Objet : s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. 2- It also seems that under Firefox (not IE), the page vertical lenght is increased depending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? 3- When you click inside the inputSuggest and then click outside without typing anything or choosing an item, I get a value of -1 in the model. In fact, a new suggest is added to the component with an empty string as label and -1 as value. Is this the expected behaviour of the inputSuggest component ? Thx, Clément.
RE : Let's write that doc!
Title: Message +1 -Message d'origine-De: ir. ing. Jan Dockx [mailto:[EMAIL PROTECTED] Envoyé: jeudi 25 août 2005 16:16À: MyFaces DiscussionObjet: Let's write that doc!I suggest that we make this a user effort. Everybody, make an account in the wiki, and a href=""let's start documenting those components/a. If everybody writes a little piece (what is it for, how to use it), we'll have full documentation by Monday.I just added a little grain. More to come, I promise.On 25 Aug 2005, at 15:30, Sean Schofield wrote: Thanks so much for pointing out that messages tag. I was just aboutto write something similar because I didn't know about it. Is itlisted somewhere on the MyFaces website? I don't see it here:http://myfaces.apache.org/tomahawk/overview.htmlUnfortunately that page is woefully out of date. Updating it is on myshortlist of things to do. Regarding your comment on it being specific to MyFaces: Isn't it onlyspecific to the MyFaces extensions? In other words, couldn't I use itwith the RI as long as I included the myfaces-extensions-1.0.9.jar andreferenced the taglib?Right you can use tomahawk with the RI and if you want thatfunctionality use t:message instead of h:message. -KenseanMet vriendelijke groeten,Jan DockxPeopleWare NV - Head OfficeCdt.Weynsstraat 85 B-2660 Hoboken Tel: +32 3 448.33.38 Fax: +32 3 448.32.66 PeopleWare NV - Branch Office GeelKleinhoefstraat 5B-2440 GeelTel: +32 14 57.00.90Fax: +32 14 58.13.25http://www.peopleware.be/http://www.mobileware.be/
s:inputSuggest : some others improvement to do
Title: Message I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. 2- It also seems that under Firefox (not IE), the page vertical lenght is increaseddepending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? 3- When you click inside the inputSuggest and then click outside without typing anything or choosing an item, I get a value of "-1" in the model. In fact, a new suggest is added to the component with an empty stringas label and -1 as value. Is this the expected behaviour of the inputSuggest component ? Thx, Clément.
RE : inputSuggest : some others improvement to do
Title: Message Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with manyitems into and the white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't addthe inputSuggestin the page ... wierd ... Bye, Clément. -Message d'origine-De: Clément Maignien Envoyé: mercredi 24 août 2005 10:37À: MyFaces DiscussionObjet: s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. 2- It also seems that under Firefox (not IE), the page vertical lenght is increaseddepending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? 3- When you click inside the inputSuggest and then click outside without typing anything or choosing an item, I get a value of "-1" in the model. In fact, a new suggest is added to the component with an empty stringas label and -1 as value. Is this the expected behaviour of the inputSuggest component ? Thx, Clément.
RE : RE : inputSuggest : some others improvement to do
Back to the #2 problem : not sure it is a browser issue because I have the same inputSuggest component in 2 of my webapp pages, filled the same way (same number of items into), and the white space appears only in 1 of them ... Very wierd behaviour. Clément -Message d'origine- De : Werner Punz [mailto:[EMAIL PROTECTED] Envoyé : mercredi 24 août 2005 12:21 À : users@myfaces.apache.org Objet : Re: RE : inputSuggest : some others improvement to do Clément Maignien wrote: Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with many items into and the white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't add the inputSuggest in the page ... wierd ... Probably an issue within the browser, see below Bye, Clément. -Message d'origine- *De :* Clément Maignien *Envoyé :* mercredi 24 août 2005 10:37 *À :* MyFaces Discussion *Objet :* s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on the javascript side. 2- It also seems that under Firefox (not IE), the page vertical lenght is increased depending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? both problems are browser specific and have to be targetted at the javascript level.
RE : RE : RE : inputSuggest : some others improvement to do
This #2 behaviour happends with Firefox but not with IE ... True. But it is quite strange that the 2 pages do not render the same way. inputSuggest component + browsers issue ??? -Message d'origine- De : Clément Maignien Envoyé : mercredi 24 août 2005 14:19 À : MyFaces Discussion; [EMAIL PROTECTED] Objet : RE : RE : inputSuggest : some others improvement to do Back to the #2 problem : not sure it is a browser issue because I have the same inputSuggest component in 2 of my webapp pages, filled the same way (same number of items into), and the white space appears only in 1 of them ... Very wierd behaviour. Clément -Message d'origine- De : Werner Punz [mailto:[EMAIL PROTECTED] Envoyé : mercredi 24 août 2005 12:21 À : users@myfaces.apache.org Objet : Re: RE : inputSuggest : some others improvement to do Clément Maignien wrote: Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with many items into and the white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't add the inputSuggest in the page ... wierd ... Probably an issue within the browser, see below Bye, Clément. -Message d'origine- *De :* Clément Maignien *Envoyé :* mercredi 24 août 2005 10:37 *À :* MyFaces Discussion *Objet :* s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests. That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on the javascript side. 2- It also seems that under Firefox (not IE), the page vertical lenght is increased depending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ? both problems are browser specific and have to be targetted at the javascript level.
RE : RE : inputSuggest : some others improvement to do
Title: Message I use the myfaces-20050802 nightly build. Do I should try with a more recent one ? Here is what I found in the source code (it looks likewhat you've talk about, no ?) : if (navigator.appVersion.toLowerCase().indexOf('msie') != -1 navigator.userAgent.toLowerCase().indexOf('opera') == -1)document.writeln('iframe id="libarticle_textShim" src="" scrolling="no" frameborder="0" style="position:absolute; top:0px; left:0px;"/iframe'); Thanks for youe help Matt. Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED] Envoyé: mercredi 24 août 2005 15:50À: MyFaces Discussion; [EMAIL PROTECTED]Objet: Re: RE : inputSuggest : some others improvement to do On 8/24/05, Werner Punz [EMAIL PROTECTED] wrote: Clément Maignien wrote: 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests.That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on the _javascript_ side.Hm. Curious. Are you using the latest version of the component? Sean committed a fix that I implemented for this a while ago, though it's possible it's still buggy. The _javascript_ code *should* detect that you're using IE and, if so, render an iframe in between the panel and anything under it.Can you do a View Source on the rendered page, and look for _javascript_ code that looks like it should generate an iframe with an id ending in the string "Shim"? If it's there, could you check the z-index of the rendered inputDate component? If the iframe's not there, or is there but not rendering, you're either using an old version of the code, or there's a bug I don't know about. If it's there and rendering, but you're still seeing that behavior, I may need to tweak the z-index calculations. Please let me know, as I don't have time at the moment to test it myself.-Matt
RE : RE : RE : RE : inputSuggest : some others improvement to do
Title: Message Thx Matt for helping me :D Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED] Envoyé: mercredi 24 août 2005 15:56À: MyFaces DiscussionObjet: Re: RE : RE : RE : inputSuggest : some others improvement to doThat's very odd. I can understand there being a stylesheet bug, but I can't see why the two pages wouldn't have the same bug on them. I'll look into it when I get a chance, but I'm really busy at work and at home right now, and may not be able to until the weekend.-Matt On 8/24/05, Clément Maignien [EMAIL PROTECTED] wrote: This #2 behaviour happends with Firefox but not with IE ... True. But it is quite strange that the 2 pages do not render the same way.inputSuggest component + browsers issue ???-Message d'origine-De : Clément MaignienEnvoyé : mercredi 24 août 2005 14:19À : MyFaces Discussion; [EMAIL PROTECTED]Objet : RE : RE : inputSuggest : some others improvement to doBack to the #2 problem : not sure it is a browser issue because I have the same inputSuggest component in 2 of my webapp pages, filled the same way (same number of items into), and the "white space" appears only in 1 of them ... Very wierd behaviour.Clément-Message d'origine-De : Werner Punz [mailto:[EMAIL PROTECTED]]Envoyé : mercredi 24 août 2005 12:21À : users@myfaces.apache.orgObjet : Re: RE : inputSuggest : some others improvement to doClément Maignien wrote: Hummm, sorry, the #2 issue is a mistake : I have another page with an inputSuggest with many items into andthe white space isn't there. So I'm asking why it is displayed on my other page and disappier when I don't add the inputSuggest in the page ... wierd ...Probably an issue within the browser, see below Bye, Clément. -Message d'origine----- *De :* Clément Maignien *Envoyé :* mercredi 24 août 2005 10:37 *À :* MyFaces Discussion *Objet :* s:inputSuggest : some others improvement to do I've noticed some more improvements to make on this sandbox component. I don't know if they really comes from the component itself but I here they are : 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests.That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on the _javascript_ side. 2- It also seems that under Firefox (not IE), the page vertical lenght is increased depending on the number of items in the inputSuggest. A white space is displayed under the last element of the page. In my case I try to avoid the use of the page scroller in my webapp pages, and now there is a scroller displayed because of this big white space. Are those problems come from the browsers or the component implementation ?both problems are browser specific and have to be targetted at the_javascript_ level.
RE : RE : RE : inputSuggest : some others improvement to do
Title: Message Sorry but I can't find any z-index in the source ... Here is what I have : tbodytrtdlabel for="" entre le /label/tdtdinput id="receptRechForm:datedebut.day" name="receptRechForm:datedebut.day" size="2" maxlength="2" value="24"/select id="receptRechForm:datedebut.month" name="receptRechForm:datedebut.month" size="1"option value="1"janvier/optionoption value="2"f#233;vrier/optionoption value="3"mars/optionoption value="4"avril/optionoption value="5"mai/optionoption value="6"juin/optionoption value="7"juillet/optionoption value="8" selected="selected"ao#251;t/optionoption value="9"septembre/optionoption value="10"octobre/optionoption value="11"novembre/optionoption value="12"d#233;cembre/option/selectinput id="receptRechForm:datedebut.year" name="receptRechForm:datedebut.year" size="4" maxlength="4" value="2005"/script type="text/_javascript_"jscalendarSetImageDirectory("/cormag/faces/myFacesExtensionResource/calendar.HtmlCalendarRenderer/11230381/DB/")/scriptscript type="text/_javascript_"jscalendarMonthName = new Array("janvier","f#233;vrier","mars","avril","mai","juin","juillet","ao#251;t","septembre","octobre","novembre","d#233;cembre");jscalendarDayName = new Array("lun.","mar.","mer.","jeu.","ven.","sam.","dim.");jscalendarStartAt = 1;/scriptinput type='button' value='...'//td -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED] Envoyé: mercredi 24 août 2005 16:39À: MyFaces DiscussionObjet: Re: RE : RE : inputSuggest : some others improvement to doYep, that's exactly what I was talking about. Could you check the z-index of the rendered inputDate component, please, and let me know what it is?-Matt On 8/24/05, Clément Maignien [EMAIL PROTECTED] wrote: I use the myfaces-20050802 nightly build. Do I should try with a more recent one ? Here is what I found in the source code (it looks likewhat you've talk about, no ?) : if (navigator.appVersion.toLowerCase().indexOf('msie') != -1 navigator.userAgent.toLowerCase().indexOf('opera') == -1)document.writeln('iframe id="libarticle_textShim" src="" scrolling="no" frameborder="0" style="position:absolute; top:0px; left:0px;"/iframe'); Thanks for youe help Matt. Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED]] Envoyé: mercredi 24 août 2005 15:50À: MyFaces Discussion; [EMAIL PROTECTED]Objet: Re: RE : inputSuggest : some others improvement to do On 8/24/05, Werner Punz [EMAIL PROTECTED] wrote: Clément Maignien wrote: 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests.That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on the _javascript_ side.Hm. Curious. Are you using the latest version of the component? Sean committed a fix that I implemented for this a while ago, though it's possible it's still buggy. The _javascript_ code *should* detect that you're using IE and, if so, render an iframe in between the panel and anything under it.Can you do a View Source on the rendered page, and look for _javascript_ code that looks like it should generate an iframe with an id ending in the string "Shim"? If it's there, could you check the z-index of the rendered inputDate component? If the iframe's not there, or is there but not rendering, you're either using an old version of the code, or there's a bug I don't know about. If it's there and rendering, but you're still seeing that behavior, I may need to tweak the z-index calculations. Please let me know, as I don't have time at the moment to test it myself.-Matt
RE : RE : RE : RE : inputSuggest : some others improvement to do
Title: Message I'll try to look at the code, but think I dont have enought skills in _javascript_ to find the bug. But I'll try it. Do you me to add this bug as a commentaryon the JIRA issue I've opened previously ? Thx Matt ;) Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED] Envoyé: mercredi 24 août 2005 17:26À: MyFaces DiscussionObjet: Re: RE : RE : RE : inputSuggest : some others improvement to doThanks. Now that I think about it, and have had another cup of coffee (and am therefore genuinely awake), the z-index of the select list wouldn't matter anyway.There's obviously a bug in the inputSuggest code. I'll try to find some time tonight to look at it, but may not be able to get to it till the weekend. If anyone else feels like taking a crack at it in the meantime, I won't be offended. :)-Matt On 8/24/05, Clément Maignien [EMAIL PROTECTED] wrote: Sorry but I can't find any z-index in the source ... Here is what I have : tbodytrtdlabel for="" entre le /label/tdtdinput id="receptRechForm:datedebut.day" name="receptRechForm:datedebut.day" size="2" maxlength="2" value="24"/select id="receptRechForm:datedebut.month" name="receptRechForm:datedebut.month" size="1"option value="1"janvier/optionoption value="2"f#233;vrier/optionoption value="3"mars/optionoption value="4"avril/optionoption value="5"mai/optionoption value="6"juin/optionoption value="7"juillet/optionoption value="8" selected="selected"ao#251;t/optionoption value="9"septembre/optionoption value="10"octobre/optionoption value="11"novembre/optionoption value="12"d#233;cembre/option/selectinput id="receptRechForm:datedebut.year" name="receptRechForm:datedebut.year" size="4" maxlength="4" value="2005"/script type="text/_javascript_"jscalendarSetImageDirectory("/cormag/faces/myFacesExtensionResource/calendar.HtmlCalendarRenderer/11230381/DB/")/scriptscript type="text/_javascript_"jscalendarMonthName = new Array("janvier","f#233;vrier","mars","avril","mai","juin","juillet","ao#251;t","septembre","octobre","novembre","d#233;cembre");jscalendarDayName = new Array("lun.","mar.","mer.","jeu.","ven.","sam.","dim.");jscalendarStartAt = 1;/scriptinput type='button' value='...'//td -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED]] Envoyé: mercredi 24 août 2005 16:39À: MyFaces DiscussionObjet: Re: RE : RE : inputSuggest : some others improvement to do Yep, that's exactly what I was talking about. Could you check the z-index of the rendered inputDate component, please, and let me know what it is?-Matt On 8/24/05, Clément Maignien [EMAIL PROTECTED] wrote: I use the myfaces-20050802 nightly build. Do I should try with a more recent one ? Here is what I found in the source code (it looks likewhat you've talk about, no ?) : if (navigator.appVersion.toLowerCase().indexOf('msie') != -1 navigator.userAgent.toLowerCase().indexOf('opera') == -1)document.writeln('iframe id="libarticle_textShim" src="" scrolling="no" frameborder="0" style="position:absolute; top:0px; left:0px;"/iframe'); Thanks for youe help Matt. Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED]] Envoyé: mercredi 24 août 2005 15:50À: MyFaces Discussion; [EMAIL PROTECTED]Objet: Re: RE : inputSuggest : some others improvement to do On 8/24/05, Werner Punz [EMAIL PROTECTED] wrote: Clément Maignien wrote: 1- I have a small JSF page with an s:inputSuggest component and an t:inputDate component under it. When clicking inside the inputSuggest a dropdown box open and displays firsts suggests. The problem is that under IE (not Firefox) the dropdown-box is displayed behind the inputDate, hiding some suggests.That is a bug in the IE, the fix is to plug an iframe under the panel... has to be fixed on
RE : help moving from public 1.0.9 to nightly build
Would it be possible to see the java source code of your MainDynamicMenu to see how you instanciate and initialize your navItems ? Thx Clément -Message d'origine- De : Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé : lundi 22 août 2005 18:44 À : 'MyFaces Discussion' Objet : RE: help moving from public 1.0.9 to nightly build Guilherme, I have simplified my page in order to identify what is the problem. Unfotunately, I can't make it running (I need probably further knowledge ;-)). Here is my simple page: f:view hello world h:outputText output text /h:outputText h:panelGroup id=sfooter f:verbatim Copyright (c) 2003-2005 a href=http://myfaces.apache.org; class=pageFooterThe MyFaces Team/a nbsp;nbsp; /f:verbatim/h:panelGroup f:facet name=header f:subview id=header h:panelGrid id=header_group2 columns=1 styleClass=pageHeader2 columnClasses=pageHeader2col1 t:jscookMenu layout=hbr theme=ThemePanel t:navigationMenuItems value=#{MainDynamicMenu.navItems} / /t:jscookMenu /h:panelGrid /f:subview /f:facet /f:view When I use static menu, this works well. By replacing the static by a dynamic, it fails. I unfortunately have no idea about the problem. Did you have any further to identify the problem. Thank you Henri-Philippe -Original Message- From: Guilherme Gomes [mailto:[EMAIL PROTECTED] Sent: lundi 22 août 2005 17:10 To: MyFaces Discussion Subject: RE: help moving from public 1.0.9 to nightly build In your page that has the jscook menu , you have : %@ taglib uri=http://myfaces.apache.org/extensions;; prefix=t% where it should be: %@ taglib uri=http://myfaces.apache.org/tomahawk; prefix=t % Remember : all myfaces - specific components are now in tomahawk, and jscook menu is one of them. You did not specify which page had the jscook menu in the main page, I'm going to assume it is the page_header.jsp in the header facet. I am using tiles instead of a jsp:include page=page_header.jsp / , don't know that much about jsp itself, but if it is just inserting the jsp code before myafces picks it up, it's ok. Otherwise...in my header i have everything inside a f:subview id=iheader /f:subview pair. Might be another possible reason for that exception. On the MainDynamicMenu bean, as far as i can see, it is fine. Also make sure you have the extensionFilter properly configured in the web.xmlit must also be mapped to /faces/* , besides the *.jsf mapping. Let me know if anything helps. Regards Guilherme Gomes Start your day with Yahoo! - make it your home page http://www.yahoo.com/r/hs
RE : Different rendering for disabled menu
Title: Message Huumm, never tried that. There isn't any styleClass attribute for the navigationMenuItem component instead we could do something like : t:navigationMenuItem styleClass="#{menuBean.item[i].disable ? 'disableStyle' 'enableStyle'}" .../ But isn't it rendered another way by default whena menuItem is disabled ? -Message d'origine-De: Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé: mardi 23 août 2005 15:17À: 'users@myfaces.apache.org'Objet: Different rendering for disabled menu When a menu is set as disabled, could someone tell me how is it possible to render it in a different way in order that the user see that the menu is disabled. Thanks Henri-Philippe Delbrouck Siemens Business Services
RE : RE : Different rendering for disabled menu
Title: Message Yes indeed it would be very usefull, but don't know how to do that without modifying the source code of the component. Anyone have any idea ? Regards, Clément -Message d'origine-De: Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé: mardi 23 août 2005 16:52À: 'MyFaces Discussion'Objet: RE: RE : Different rendering for disabled menu Clément, by default, the menu is not rendered in another way when it is disabled. What we can see is the fact that there is no action associated with. It should be very usefull to have a diffenet rendering for disbled menus (especially for dynamic menu). Henri-Philippe -Original Message-From: Clément Maignien [mailto:[EMAIL PROTECTED] Sent: mardi 23 août 2005 16:31To: MyFaces DiscussionSubject: RE : Different rendering for disabled menu Huumm, never tried that. There isn't any styleClass attribute for the navigationMenuItem component instead we could do something like : t:navigationMenuItem styleClass="#{menuBean.item[i].disable ? 'disableStyle' 'enableStyle'}" .../ But isn't it rendered another way by default whena menuItem is disabled ? -Message d'origine-De: Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé: mardi 23 août 2005 15:17À: 'users@myfaces.apache.org'Objet: Different rendering for disabled menu When a menu is set as disabled, could someone tell me how is it possible to render it in a different way in order that the user see that the menu is disabled. Thanks Henri-Philippe Delbrouck Siemens Business Services
RE : Submenu not working
Maybe the java JSF source code would be better to help you Henri-Phillipe. -Message d'origine- De : Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé : lundi 22 août 2005 16:46 À : 'MyFaces Discussion' Objet : Submenu not working Hi all, It seems that when I use only a menu, it works. When I add children, it does not work anymore even with the latest nightly build. I get an exception in the extension filter (see my previous mail on help moving from public 1.0.9 to nightly build). Any idea. Martin, Regarding the discussion with Guilherme, it seems that it should work. Do you have any idea of what could be wrong. Thanks very much Henri-Philippe -Original Message- From: Guilherme Gomes [mailto:[EMAIL PROTECTED] Sent: lundi 22 août 2005 14:09 To: MyFaces Discussion Subject: RE: help moving from public 1.0.9 to nightly build Well, i was wrong, he split parameter also works for NavigationMenuItems other than the top level ones. I only saw it after restarting JBOSS. So you can have a sun-menu with a list of items and have a separator between them Guilherme Gomes __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
Dynamic Locale change
Title: Message Hi, I'm trying to allow the application user to change the language of my web app. I did it the way it is done in the myFaces 1.0.9 examples : a selectOneMenu with a choice of languages and an action button with that code : OptionBean { ... public String action { ... FacesUtil.setLocale(selectedLocale); ... } ... } FacesUtil { ... public static void setLocale(Locale l) { FacesContext.getCurrentInstance().getFacesContext().getViewRoot().setLocale(l); } ... } It works fine when the action is executed (the language change), but as soonas I navigate to another page of the App, the language is resetted to the default one. Why ? NB: I'm trying not to use the locale parameter of the f:view tag ... Thx, Clément.
RE : inputSuggest issue
Title: Message Any idea ? Any answer ? Thanks, Clément -Message d'origine-De: Clément Maignien Envoyé: mercredi 17 août 2005 15:02À: MyFaces DiscussionObjet: s:inputSuggest issue Hi everyone, I'vefound a problem with the sandbox inputSuggest component. I bindits value to a backing bean attribute that way : s:inputSuggest id="artsugg" value="#{receptBean.libArticle}" f:selectItems id="libartselect" value="#{receptBean.libArticleChoices}"//s:inputSuggest The component is filled as I expect it but the value of receptBean.libArticle I get in the the model isn't exactly the right one. In my case, the value is : orm:artsugg_choiceArt1, if Art1 is selected. In other words, it seems that the value equals : orm:componentID_choiceSelectedEntry The problem isn't so bad because I can get the right subString but hope it will be fix as it link the model to the view by the componentID. By the way, is this the right place to ask this question ? is there a specific "sandbox mailin list" ? should I post it in the myfaces dev mailing list ? Thanks Clément.
RE : My Faces documentation and examples
Title: Message Hi, The Java source code of the 1.0.9 examples are availaible, not the nightlyBuilt ones ... there a JIRA issue for that, we have to wait Regards, Clément -Message d'origine-De: Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé: jeudi 18 août 2005 15:27À: 'users@myfaces.apache.org'Objet: My Faces documentation and examples Hi all, Can someone help me getting more detailled documentation of the MyFaces extensions. Is it possible to have access to the source code of the myfaces-examples distribution. Thanks Henri-Philippe Delbrouck Siemens Business Services
RE : RE : inputSuggest issue
Title: Message No problem Matt, yes indeed, Sean said me that he was on vacation this week, lucky Sean ;) Regards, Clément -Message d'origine-De: Matt Blum [mailto:[EMAIL PROTECTED] Envoyé: jeudi 18 août 2005 16:17À: MyFaces DiscussionObjet: Re: RE : inputSuggest issueSean wrote that part of the code, so I had to reread it to jog my memory as to why it was implemented this way.The reason this happens is that the value that's set comes from the rendered HTML id for the choice. In order to allow you to have multiple inputSuggest components on one page with values in common, it is necessary to prepend the component id to ensure the generation of a unique HTML id for every choice.It should be possible to add code to the component so that it can remove what it puts in on the way back to the model. I'm not honestly sure what happens (and don't have time at the moment to test) if the user types something in that's not on the list of choices (i.e., whether it prepends the component id stuff or not).I think Sean must be either really busy or on vacation, since he hasn't posted in a while, and as everyone who reads this list knows, that's not like him. I'll try to get in touch with him to get his input, since I don't feel comfortable trying to fix the issue without it.HTH.-Matt On 8/18/05, Clément Maignien [EMAIL PROTECTED] wrote: Any idea ? Any answer ? Thanks, Clément -Message d'origine-De: Clément Maignien Envoyé: mercredi 17 août 2005 15:02À: MyFaces DiscussionObjet: s:inputSuggest issue Hi everyone, I'vefound a problem with the sandbox inputSuggest component. I bindits value to a backing bean attribute that way : s:inputSuggest id="artsugg" value="#{receptBean.libArticle}" f:selectItems id="libartselect" value="#{receptBean.libArticleChoices}"//s:inputSuggest The component is filled as I expect it but the value of receptBean.libArticle I get in the the model isn't exactly the right one. In my case, the value is : orm:artsugg_choiceArt1, if Art1 is selected. In other words, it seems that the value equals : orm:componentID_choiceSelectedEntry The problem isn't so bad because I can get the right subString but hope it will be fix as it link the model to the view by the componentID. By the way, is this the right place to ask this question ? is there a specific "sandbox mailin list" ? should I post it in the myfaces dev mailing list ? Thanks Clément.
RE : RE : inputSuggest issue
Ok Martin I'll do that as soon as possible. Regards, Clément -Message d'origine- De : Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé : jeudi 18 août 2005 16:20 À : MyFaces Discussion Objet : Re: RE : inputSuggest issue Ok, so it would be great if you, Clement, would open a JIRA issue on this so that we can keep track of this problem. Thanks Matt! regards, Martin On 8/18/05, Matt Blum [EMAIL PROTECTED] wrote: Sean wrote that part of the code, so I had to reread it to jog my memory as to why it was implemented this way. The reason this happens is that the value that's set comes from the rendered HTML id for the choice. In order to allow you to have multiple inputSuggest components on one page with values in common, it is necessary to prepend the component id to ensure the generation of a unique HTML id for every choice. It should be possible to add code to the component so that it can remove what it puts in on the way back to the model. I'm not honestly sure what happens (and don't have time at the moment to test) if the user types something in that's not on the list of choices (i.e., whether it prepends the component id stuff or not). I think Sean must be either really busy or on vacation, since he hasn't posted in a while, and as everyone who reads this list knows, that's not like him. I'll try to get in touch with him to get his input, since I don't feel comfortable trying to fix the issue without it. HTH. -Matt On 8/18/05, Clément Maignien [EMAIL PROTECTED] wrote: Any idea ? Any answer ? Thanks, Clément -Message d'origine- De : Clément Maignien Envoyé : mercredi 17 août 2005 15:02 À : MyFaces Discussion Objet : s:inputSuggest issue Hi everyone, I've found a problem with the sandbox inputSuggest component. I bind its value to a backing bean attribute that way : s:inputSuggest id=artsugg value=#{receptBean.libArticle} f:selectItems id=libartselect value=#{receptBean.libArticleChoices}/ /s:inputSuggest The component is filled as I expect it but the value of receptBean.libArticle I get in the the model isn't exactly the right one. In my case, the value is : orm:artsugg_choiceArt1, if Art1 is selected. In other words, it seems that the value equals : orm:componentID_choiceSelectedEntry The problem isn't so bad because I can get the right subString but hope it will be fix as it link the model to the view by the componentID. By the way, is this the right place to ask this question ? is there a specific sandbox mailin list ? should I post it in the myfaces dev mailing list ? Thanks Clément. -- http://www.irian.at Your JSF powerhouse - JSF Trainings in English and German
RE : inputCalendar and charset
Title: Message Yes indeed ... same problem for me ... It should be "aujourd'hui le jeu., 18 août 2005" I tried tofix it but with no result. Clément -Message d'origine-De: Maxence Dewil [mailto:[EMAIL PROTECTED] Envoyé: jeudi 18 août 2005 17:17À: MyFaces DiscussionObjet: inputCalendar and charset Hi, my web application is configured to use the «french» Locale. For today the inputCalendar gives me Today is jeu., 18 ao 2005 instead of .. 18 août ... What can I do to modify the charset used by the inputCalendar? Thx.
s:inputSuggest issue
Title: Message Hi everyone, I'vefound a problem with the sandbox inputSuggest component. I bindits value to a backing bean attribute that way : s:inputSuggest id="artsugg" value="#{receptBean.libArticle}" f:selectItems id="libartselect" value="#{receptBean.libArticleChoices}"//s:inputSuggest The component is filled as I expect it but the value of receptBean.libArticle I get in the the model isn't exactly the right one. In my case, the value is : orm:artsugg_choiceArt1, if Art1 is selected. In other words, it seems that the value equals : orm:componentID_choiceSelectedEntry The problem isn't so bad because I can get the right subString but hope it will be fix as it link the model to the view by the componentID. By the way, is this the right place to ask this question ? is there a specific "sandbox mailin list" ? should I post it in the myfaces dev mailing list ? Thanks Clément.
s:inputSuggest problem
Title: Message Hi, I'm trying to use the s:inputSuggest sandbox component but with no result. Here is the very simple example I wrote : s:inputSuggest id="libarticle"f:selectItem itemValue="Art1" itemLabel="Article 1"/f:selectItem itemValue="Art11" itemLabel="Article 11"/f:selectItem itemValue="Art12" itemLabel="Article 12"/f:selectItem itemValue="Art2" itemLabel="Article 2"/f:selectItem itemValue="Art21" itemLabel="Article 21"/f:selectItem itemValue="Art22" itemLabel="Article 22"//s:inputSuggest According to the sandbox examples, the s:inputSuggestmust be filled with f:selectItem components (or a f:selectItems). So I'll try it that way, without any value or attribute binding. However it doesn't work well, here is the error stack I get : 09:49:20,627 ERROR [[jsp]] Servlet.service() for servlet jsp threw exceptionjava.lang.NullPointerExceptionat org.apache.myfaces.custom.suggest.InputSuggestRenderer.encodeSuggestions(InputSuggestRenderer.java:147)at org.apache.myfaces.custom.suggest.InputSuggestRenderer.encodeBegin(InputSuggestRenderer.java:112)at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:303)at javax.faces.component.UIInput.encodeBegin(UIInput.java:198) Moreover, according to the javadoc, it looks like it is impossible to bind this component to a bean attribute as there isn't any component class (just the tag and the renderer). By the way, is there somewhere we could have the java source code of the tomahawk and sandbox examples (there was a myfaces-examples-src.jar for the 1.0.9 release) ? Another question : how to know the datatype of the value or the binding, a component is waiting for ? In javadoc ? where ? Thank you all Clément.
RE : commandImg tag?
Hi, You can use the commandButton tag with the image attribute specified with the image of your choice. For example : x:commandButton image=/images/myImage.png / Clément. -Message d'origine- De : Ricardo R. Ramírez Valenzuela [mailto:[EMAIL PROTECTED] Envoyé : vendredi 12 août 2005 14:11 À : MyFaces Discussion Objet : commandImg tag? I wonder if it is possible to link to another page using an image instead of a button or just text... we have a commandLink and a commandButton, is there anything available for linking with an image? I am trying to avoid writing my own custom renderer
RE : commandImg tag?
Yeah as you say WoW ! This mailing list is so cool ! Clément. -Message d'origine- De : Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé : vendredi 12 août 2005 14:16 À : MyFaces Discussion Objet : Re: commandImg tag? Wow, two solutions in two minutes ;) cool! regards, Martin On 8/12/05, Martin Marinschek [EMAIL PROTECTED] wrote: Well, that's an easy one ;) you just use a commandLink tag, don't provide anything for the value attribute, and stuff a grapicImage tag into this tag (as a child) - all set! regards, Martin On 8/12/05, Ricardo R. Ramírez Valenzuela [EMAIL PROTECTED] wrote: I wonder if it is possible to link to another page using an image instead of a button or just text... we have a commandLink and a commandButton, is there anything available for linking with an image? I am trying to avoid writing my own custom renderer -- http://www.irian.at Your JSF powerhouse - JSF Trainings in English and German -- http://www.irian.at Your JSF powerhouse - JSF Trainings in English and German
RE : RE : s:inputSuggest problem
Yes that's it :D WaoW ! I am better and better with MyFaces :D learning every day ;) Clément. -Message d'origine- De : Clément Maignien Envoyé : vendredi 12 août 2005 15:06 À : MyFaces Discussion Objet : RE : s:inputSuggest problem Thanks Sean :D Waiting for Matt and your come back, I've gone into the source code of the InputSuggestRenderer class and it seems that, at this point of the dev, the filling can only be made by a f:selectItems (not many a f:selectItem). Moreover, the values of the f:selectItems must be putted into a Map object. Hopefully, It seems this will be extended to other class (Collection, Object[], etc) I'm going to try this ... Clément. -Message d'origine- De : Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé : vendredi 12 août 2005 14:04 À : MyFaces Discussion Objet : Re: s:inputSuggest problem Hi, I'm trying to use the s:inputSuggest sandbox component but with no result. Here is the very simple example I wrote : s:inputSuggest id=libarticle f:selectItem itemValue=Art1 itemLabel=Article 1/ f:selectItem itemValue=Art11 itemLabel=Article 11/ f:selectItem itemValue=Art12 itemLabel=Article 12/ f:selectItem itemValue=Art2 itemLabel=Article 2/ f:selectItem itemValue=Art21 itemLabel=Article 21/ f:selectItem itemValue=Art22 itemLabel=Article 22/ /s:inputSuggest According to the sandbox examples, the s:inputSuggest must be filled with f:selectItem components (or a f:selectItems). So I'll try it that way, without any value or attribute binding. However it doesn't work well, here is the error stack I get : 09:49:20,627 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception java.lang.NullPointerException at org.apache.myfaces.custom.suggest.InputSuggestRenderer.encodeSuggestions(InputSuggestRenderer.java:147) at org.apache.myfaces.custom.suggest.InputSuggestRenderer.encodeBegin(InputSuggestRenderer.java:112) at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:303) at javax.faces.component.UIInput.encodeBegin(UIInput.java:198) Moreover, according to the javadoc, it looks like it is impossible to bind this component to a bean attribute as there isn't any component class (just the tag and the renderer). Its been a while since I've looked at this one. I'm on vacation for a few days but I will look into it when I get back. Perhaps Matt can help you out if he's around. By the way, is there somewhere we could have the java source code of the tomahawk and sandbox examples (there was a myfaces-examples-src.jar for the 1.0.9 release) ? Apparently this was missing after the svn reorg. Thanks for the heads up - I've added a JIRA issue on this (http://issues.apache.org/jira/browse/MYFACES-411). In the meantime, you can always use subversion checkout ;-) Another question : how to know the datatype of the value or the binding, a component is waiting for ? In javadoc ? where ? Again I will look into this when I get back. Thank you all Clément. sean
RE : Datatable and Hibernate query
Hi, Your code seems to be good ... But having the error code would be easier to solve your problem. Maybe you can check the type of database datas your are getting so they can't be outputed in the t:dataTable. Other thing, you seems to use the HibernateTemplate of the Spring Framework, but I advise you to use an hibernateSession object (get it with org.springframework.orm.hibernate3.SessionFactoryUtils class) instead. This way, you will be able to use all the hibernate API (Criteria, Query, Collection, etc). The HibernateTemplate is a good solution for only very simple query. Hope this helps ;) Clément. -Message d'origine- De : Johannes Hiemer [mailto:[EMAIL PROTECTED] Envoyé : jeudi 11 août 2005 09:19 À : users@myfaces.apache.org Objet : Datatable and Hibernate query Hi, I am getting into trouble with a bit adavanced hibernate query that I want to show up in a datatable. That is my hibernate query: public List getRequests() { return getHibernateTemplate() .find(from Request request, Customer customer, Employee employee, System system, + Systemerror systemerror, Customee customee WHERE request.Rcustomer = customer.Cid + AND request.Rscheduler = employee.Eid AND request.Rfieldengineer = employee.Eid + AND request.Rtag = system.Sid AND request.Rerror = systemerror.Seid AND + request.Rcustomee = customee.Cid); } And it returns the following structure @see attached picture. So I am loading the query just the normal way I always to into a list @SuppressWarnings(unchecked) private void populateRequestBean() { request = getRequestManager().getRequests(); } Now I try to get the values of the list in my datatable as an output. I tried many ways, but I did not get it till yet. x:dataTable id=data var=request value=#{listrequestsSpringBean.request} h:column f:facet name=header h:outputText value=#{bundle.listrequestsRID} / /f:facet h:outputText value=#{request.object.request.rid} / /h:column Is the way I am doing right or wrong? Did anyone solve a similiar problem? I hope anyone can help me. Thanks a lot Regards Johannes __ Verschicken Sie romantische, coole und witzige Bilder per SMS! Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
RE : MyFaces with Exadel studio
Title: Message I also think that the MyEclipse plugin is better than the Exadel one. For my own I'm using the open source solution : FacesIDE facesConsole andwaiting fora release of the Eclipse WTP. But if you can pay for a plugin, choose the MyEclipse one, more stable and more powerfull than Exadel Studio (In my opinion). Clément. -Message d'origine-De: Delbrouck, Henri-Philippe [mailto:[EMAIL PROTECTED] Envoyé: mercredi 10 août 2005 08:58À: 'users@myfaces.apache.org'Objet: MyFaces with Exadel studio Hi all, Did someone already use Exadel studio with Eclipse to build a web application using MyFaces. What do you think about Exadel studio plugin. Is it a good idea to use it ? Thanks for any advice. Henri-Philippe Delbrouck Siemens Business Services
RE : RE : MyFaces with Exadel studio
Maybe the best solution is the open source one : - FacesIDE Eclipse plugin or FacesConsole - Tomcat (or Jboss IDE) Eclipse plugin - Hibernate Tools Eclipse plugin The only lack with this solution is a DragDrop JSF editor ... I admit it. Will the Eclipse the Web Tool (WTP) include one ? They speak about a JSP editor but it seems not a JSF one ... Someone knows ? Regards, Clément -Message d'origine- De : Werner Punz [mailto:[EMAIL PROTECTED] Envoyé : mercredi 10 août 2005 12:23 À : users@myfaces.apache.org Objet : Re: RE : MyFaces with Exadel studio Clément Maignien wrote: I also think that the MyEclipse plugin is better than the Exadel one. For my own I'm using the open source solution : FacesIDE facesConsole and waiting for a release of the Eclipse WTP. But if you can pay for a plugin, choose the MyEclipse one, more stable and more powerfull than Exadel Studio (In my opinion). Exadel has the better html/jsp/jsf/struts editing (for now, the new myeclipse m3 preview looks promising in this area but probably will not go as far as Exadel drag and dropping wise) but has more critical bugs (although the 3.0.3 final got rid of most of them), the prices of either one is pretty much the same (have in mind that Exadel costs initially more, but you keep the last version as soon as you opt out of the subscription service while in MyEclipse you basically have nothing afterwards as soon as you opt out, so you definitely get more value as soon as you choose not to upgrade anymore and the subscription payment is somewhat smaller) I think both are good at what they try to do, while myeclipse lacks severely in the JSF departement and the drag and drop stuff from exadel is really a timesaver, while myeclipse is better in many other areas. (DB Browsing for instance, while the Hibernate support is inferior) Unfortunately both tools cannot be combined under one Eclipse instance, if the functionality of both could be combined a killer plugin would be the result.
RE : RE : RE : RE : Jump to given page with x:dataTable
Hummm ... Sorry every one, don't read what I've wrote in my previous messages ... Thinks I can't do or say intelligent things yesterday. Mathias gave a solution in a previous message and it works well : When the action of your button is invoked get the current value of the first property of the datatable. You can use binding for this. You have to store this value somewhere and by using a value binding for the first property of the datatable it is possible to provide an inital value (your stored value) for that: x:datatable ... first=#{data.first} binding=#{data.datatable} /x:datatable Sorry again and thank you Mathias. Clément (ashamed). -Message d'origine- De : Clément Maignien Envoyé : lundi 8 août 2005 15:10 À : MyFaces Discussion Objet : RE : RE : RE : Jump to given page with x:dataTable Thanks Mathias but sorry I don't see how binding the dataTable component could help me computing the first property value. Could you please tell me more ? The way I thought is to bind the dataTable.rows (number of rows displayed) property and the dataScroller.pageIndexVar (index of the displayed page of data) in my bean and then computing the first value that way : myBean.firstRowToDisplay = myBean.dataTable_rows * (myBean.dataScroller_pageIndexVar - 1). But, another problem comes : when I am going to update this value ? I really don't know ... Because the scrolling process is made by facets in the dataScroller component : x:dataScroller id=scroll for=stockdatatable ... f:facet name=first x:graphicImage value=../images/arrow-first.gif border=0/ /f:facet f:facet name=last x:graphicImage value=../images/arrow-last.gif border=0/ /f:facet f:facet name=previous x:graphicImage value=../images/arrow-previous.gif border=0/ /f:facet f:facet name=next x:graphicImage value=../images/arrow-next.gif border=0/ /f:facet f:facet name=fastforward x:graphicImage value=../images/arrow-ff.gif border=0/ /f:facet f:facet name=fastrewind x:graphicImage value=../images/arrow-fr.gif border=0/ /f:facet /x:dataScroller As a consequence, I'm unable to associate an action or an actionListener that would update the first value when one of the scroller buttons is clicked ... I'm sure there is a way to do this but still don't know how ... Did someone did it ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 août 2005 13:32 À : MyFaces Discussion Objet : Re: RE : RE : Jump to given page with x:dataTable Most of the value bindings in myfaces are readonly. I´m not sure what the spec says about this but you are right it is better to make those value bindings read/write. One way I see is to use a binding for the datatable and get the first value from there. Regards, Mathias Clément Maignien schrieb: Thanks for the info Mathias. Despite I don't get the ClassCastException anymore, the right page of my dataTable isn't displayed. I have initted the attribute value of my bean to new Integer(0). Then, by displaying its value through the pages scrolling, I see that it keeps its 0 value (normal as I also saw that the setter of the attribute is never called). I can't imagine that it is the programmer's work to update this attribute value ... no ? And if so, where and how ? Regards, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 août 2005 10:47 À : MyFaces Discussion Objet : Re: RE : Jump to given page with x:dataTable Take a look into the javadoc for UIData. It´s just the integer value of the zero based row index for the first row of the table. The instance should be of java.lang.Integer. Regards, Mathias Clément Maignien schrieb: Hi, I also need this possibility, and enjoyed to see that it was possible to do it. However, what I tried doesn't work. Like Mathias said, I try to use the first property of the dataTable, binding it to a backing bean attribute. The problem is that I have a ClassCastException when accessing it : 10:05:55,118 INFO [STDOUT] java.lang.ClassCastException: fr.edic.cormag.view.datastructure.StockData 10:05:55,118 INFO [STDOUT] at javax.faces.component.UIData.getFirst(UIData.java:723) 10:05:55,180 INFO [STDOUT] at org.apache.myfaces.component.html.ext.HtmlDataTable.getFirst(HtmlDataTable.java:324). I thought that the type of the backing bean attribute for the first property should be the same as the data row displayed in the dataTable (in my case : StockData), but it seems not ... So my question is : what is the type of the backing bean attribute to bind the first property of a dataTable component ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : mardi 2 août 2005 10:20 À : MyFaces Discussion Objet : Re: Jump to given page with x:dataTable When the action of your button
x:selectOneRadio Strange behaviour
Title: Message Hi, I use a x:selectOneRadio component inone ofmy application pages. This page allow the user to specify research criteria. The x:selectOneRadio is one of them. My page is divided in a panelGroup whereI add all the criteria components and a form with a commandButton to throw the research. Here is the JSF code snipet of the selectOneRadio : h:outputLabel for="" value="#{res['stock_Etat_Crit_QStock']}"/x:selectOneRadio id="qstockradio" binding="#{stockBean.quantStock}" f:selectItems id="choixqstock" value="#{stockBean.choixQuantStock}"/ /x:selectOneRadio As you can see the component is bind to the quantStock attribute of my stockBean (quantStock is an instance of the HtmlSelectOneRadio class). When the commandButton is clicked by the user, the associated action get all the user criteria to query the database. Here comes the strange behaviour : If I put the selectOneRadio component inside the panelGroup, I'm unable to getits right value (always get the initial value). However, if I put the selectOneRadio component inside the form, I get the right one (the one that the user choose), with exactly the same code in my action ( criteria.add(quantStock.getValue().toString()); ) Is it the good way to get the selected value of a selectOneRadio component ? Why doesn't it behave the same way in both case ? Regards, Clément.
RE : [OT] Is anyone using eclipse 3.1 with WTP 0.7 and Tomcat 5.5 ?
Title: Message Hi, Did you remove the appropriate Jars from the lib directory of your Tomcat as it is explain on the myfaces web site (http://myfaces.apache.org/) ??? Clément -Message d'origine-De: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Envoyé: mardi 9 août 2005 17:03À: MyFaces DiscussionObjet: [OT] Is anyone using eclipse 3.1 with WTP 0.7 and Tomcat 5.5 ?Hi, Is anyone using eclipse 3.1 with WTP 0.7 and Tomcat 5.5 ? I don't get my webapp to start at all... really at the beginning. I can work with wtp and tomcat 5.5 aslong as I don't use myfaces. As soon as I insert the FacesServlet or the startupListener to the web.xml, tomcat behaves strange. what ever page i try to access he gives me back a blank page, doesen't matter if the is a html or a jsf page... Did anyone had this behavior too? Or if someone uses the above combination, maybe he has some tipps for setting up.. chris
RE : Jump to given page with x:dataTable
Hi, I also need this possibility, and enjoyed to see that it was possible to do it. However, what I tried doesn't work. Like Mathias said, I try to use the first property of the dataTable, binding it to a backing bean attribute. The problem is that I have a ClassCastException when accessing it : 10:05:55,118 INFO [STDOUT] java.lang.ClassCastException: fr.edic.cormag.view.datastructure.StockData 10:05:55,118 INFO [STDOUT] at javax.faces.component.UIData.getFirst(UIData.java:723) 10:05:55,180 INFO [STDOUT] at org.apache.myfaces.component.html.ext.HtmlDataTable.getFirst(HtmlDataTable.java:324). I thought that the type of the backing bean attribute for the first property should be the same as the data row displayed in the dataTable (in my case : StockData), but it seems not ... So my question is : what is the type of the backing bean attribute to bind the first property of a dataTable component ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : mardi 2 août 2005 10:20 À : MyFaces Discussion Objet : Re: Jump to given page with x:dataTable When the action of your button is invoked get the current value of the first property of the datatable. You can use binding for this. You have to store this value somewhere and by using a value binding for the first property of the datatable it is possible to provide an inital value (your stored value) for that: x:datatable ... first=#{data.first} binding=#{data.datatable} /x:datatable Regards, Mathias Michael Hartman schrieb: I have a page displaying data using both the x:dataTable and x:dataScroller tags. I'd like to know if it is possible when I visit the page that it jump or remember to goto a particular page, say page 2 instead of page 1. For example, I have 100 items to display with a pagesize of 10 (i.e. rows = 10). That would give me 10 pages to scroll through (100 / 10 = 10).From this page a user may click on an item in order to the view another page with another table displaying details. From the details page they'd like to go back to the summary page and return to viewing the same page there were on. The users cannot use the browser's back button. The back function is current a h:commandLink button tied to a navigation-rule that points to the summary page. When they click on it they go back but the summary dataTable jumps back to the first page. I am using the nightly build from 31-Jul-2005. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
RE : RE : Jump to given page with x:dataTable
Thanks for the info Mathias. Despite I don't get the ClassCastException anymore, the right page of my dataTable isn't displayed. I have initted the attribute value of my bean to new Integer(0). Then, by displaying its value through the pages scrolling, I see that it keeps its 0 value (normal as I also saw that the setter of the attribute is never called). I can't imagine that it is the programmer's work to update this attribute value ... no ? And if so, where and how ? Regards, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 août 2005 10:47 À : MyFaces Discussion Objet : Re: RE : Jump to given page with x:dataTable Take a look into the javadoc for UIData. It´s just the integer value of the zero based row index for the first row of the table. The instance should be of java.lang.Integer. Regards, Mathias Clément Maignien schrieb: Hi, I also need this possibility, and enjoyed to see that it was possible to do it. However, what I tried doesn't work. Like Mathias said, I try to use the first property of the dataTable, binding it to a backing bean attribute. The problem is that I have a ClassCastException when accessing it : 10:05:55,118 INFO [STDOUT] java.lang.ClassCastException: fr.edic.cormag.view.datastructure.StockData 10:05:55,118 INFO [STDOUT] at javax.faces.component.UIData.getFirst(UIData.java:723) 10:05:55,180 INFO [STDOUT] at org.apache.myfaces.component.html.ext.HtmlDataTable.getFirst(HtmlDataTable.java:324). I thought that the type of the backing bean attribute for the first property should be the same as the data row displayed in the dataTable (in my case : StockData), but it seems not ... So my question is : what is the type of the backing bean attribute to bind the first property of a dataTable component ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : mardi 2 août 2005 10:20 À : MyFaces Discussion Objet : Re: Jump to given page with x:dataTable When the action of your button is invoked get the current value of the first property of the datatable. You can use binding for this. You have to store this value somewhere and by using a value binding for the first property of the datatable it is possible to provide an inital value (your stored value) for that: x:datatable ... first=#{data.first} binding=#{data.datatable} /x:datatable Regards, Mathias Michael Hartman schrieb: I have a page displaying data using both the x:dataTable and x:dataScroller tags. I'd like to know if it is possible when I visit the page that it jump or remember to goto a particular page, say page 2 instead of page 1. For example, I have 100 items to display with a pagesize of 10 (i.e. rows = 10). That would give me 10 pages to scroll through (100 / 10 = 10).From this page a user may click on an item in order to the view another page with another table displaying details. From the details page they'd like to go back to the summary page and return to viewing the same page there were on. The users cannot use the browser's back button. The back function is current a h:commandLink button tied to a navigation-rule that points to the summary page. When they click on it they go back but the summary dataTable jumps back to the first page. I am using the nightly build from 31-Jul-2005. __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
RE : RE : RE : Jump to given page with x:dataTable
Thanks Mathias but sorry I don't see how binding the dataTable component could help me computing the first property value. Could you please tell me more ? The way I thought is to bind the dataTable.rows (number of rows displayed) property and the dataScroller.pageIndexVar (index of the displayed page of data) in my bean and then computing the first value that way : myBean.firstRowToDisplay = myBean.dataTable_rows * (myBean.dataScroller_pageIndexVar - 1). But, another problem comes : when I am going to update this value ? I really don't know ... Because the scrolling process is made by facets in the dataScroller component : x:dataScroller id=scroll for=stockdatatable ... f:facet name=first x:graphicImage value=../images/arrow-first.gif border=0/ /f:facet f:facet name=last x:graphicImage value=../images/arrow-last.gif border=0/ /f:facet f:facet name=previous x:graphicImage value=../images/arrow-previous.gif border=0/ /f:facet f:facet name=next x:graphicImage value=../images/arrow-next.gif border=0/ /f:facet f:facet name=fastforward x:graphicImage value=../images/arrow-ff.gif border=0/ /f:facet f:facet name=fastrewind x:graphicImage value=../images/arrow-fr.gif border=0/ /f:facet /x:dataScroller As a consequence, I'm unable to associate an action or an actionListener that would update the first value when one of the scroller buttons is clicked ... I'm sure there is a way to do this but still don't know how ... Did someone did it ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 août 2005 13:32 À : MyFaces Discussion Objet : Re: RE : RE : Jump to given page with x:dataTable Most of the value bindings in myfaces are readonly. I´m not sure what the spec says about this but you are right it is better to make those value bindings read/write. One way I see is to use a binding for the datatable and get the first value from there. Regards, Mathias Clément Maignien schrieb: Thanks for the info Mathias. Despite I don't get the ClassCastException anymore, the right page of my dataTable isn't displayed. I have initted the attribute value of my bean to new Integer(0). Then, by displaying its value through the pages scrolling, I see that it keeps its 0 value (normal as I also saw that the setter of the attribute is never called). I can't imagine that it is the programmer's work to update this attribute value ... no ? And if so, where and how ? Regards, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : lundi 8 août 2005 10:47 À : MyFaces Discussion Objet : Re: RE : Jump to given page with x:dataTable Take a look into the javadoc for UIData. It´s just the integer value of the zero based row index for the first row of the table. The instance should be of java.lang.Integer. Regards, Mathias Clément Maignien schrieb: Hi, I also need this possibility, and enjoyed to see that it was possible to do it. However, what I tried doesn't work. Like Mathias said, I try to use the first property of the dataTable, binding it to a backing bean attribute. The problem is that I have a ClassCastException when accessing it : 10:05:55,118 INFO [STDOUT] java.lang.ClassCastException: fr.edic.cormag.view.datastructure.StockData 10:05:55,118 INFO [STDOUT] at javax.faces.component.UIData.getFirst(UIData.java:723) 10:05:55,180 INFO [STDOUT] at org.apache.myfaces.component.html.ext.HtmlDataTable.getFirst(HtmlDataTable.java:324). I thought that the type of the backing bean attribute for the first property should be the same as the data row displayed in the dataTable (in my case : StockData), but it seems not ... So my question is : what is the type of the backing bean attribute to bind the first property of a dataTable component ? Thanks, Clément. -Message d'origine- De : Mathias Broekelmann [mailto:[EMAIL PROTECTED] Envoyé : mardi 2 août 2005 10:20 À : MyFaces Discussion Objet : Re: Jump to given page with x:dataTable When the action of your button is invoked get the current value of the first property of the datatable. You can use binding for this. You have to store this value somewhere and by using a value binding for the first property of the datatable it is possible to provide an inital value (your stored value) for that: x:datatable ... first=#{data.first} binding=#{data.datatable} /x:datatable Regards, Mathias Michael Hartman schrieb: I have a page displaying data using both the x:dataTable and x:dataScroller tags. I'd like to know if it is possible when I visit the page that it jump or remember to goto a particular page, say page 2 instead of page 1. For example, I have 100 items to display with a pagesize of 10 (i.e. rows = 10). That would give me 10 pages to scroll through (100 / 10 = 10).From this page a user may click on an item in order to the view another page with another table displaying details
RE : dataTable : RowOnevent attributes
Title: Message It seems I don't give enought details or that noboby knows what I'm talking about (can't be that ...), So ... more details : First, here is theJSF code part for the dataTabletrying using CSSstyle: x:dataTable id="receptdatatable" styleClass="dataTable" headerClass="dataTable_Header" footerClass="dataTable_Footer" rowClasses="dataTable_Row" columnClasses="dataTable_ColumnLeftWhite" rowOnMouseOver="dataTable_RowOnMouseOver" rowOnMouseOut="dataTable_RowOnMouseOut" var="recept" value="#{receptBean.receptData}" rows="#{receptBean.nbResParPageInt}" sortColumn="#{receptBean.sort}" sortAscending="#{receptBean.ascending}" preserveSort="true" preserveDataModel="false" rowIndexVar="numRow" x:column ... x:column/ ... x:column ... x:column/ x:dataTable the CSS styleclass: .dataTable_RowOnMouseOver { background-color: #A5CBFF; } .dataTable_RowOnMouseOut { background-color: #FF; } Then , the other solution I tried is like in the MyFaces simple.war example (openDataTable.jsp) : x:dataTable id="receptdatatable" styleClass="dataTable" headerClass="dataTable_Header" footerClass="dataTable_Footer" rowClasses="dataTable_Row" columnClasses="dataTable_ColumnLeftWhite" rowOnMouseOver="this.style.backgroundColor='#A5CBFF'" rowOnMouseOut="this.style.backgroundColor='#FF'" var="recept" value="#{receptBean.receptData}" rows="#{receptBean.nbResParPageInt}" sortColumn="#{receptBean.sort}" sortAscending="#{receptBean.ascending}" preserveSort="true" preserveDataModel="false" rowIndexVar="numRow" x:column ... x:column/ ... x:column ... x:column/ x:dataTable The both don't work : the rows of my dataTable stay White. Finally, what is this type of _expression_ : this.xx.yy='value' (like this.style.backgroundColor='#FF') ... never seen that before. Please help, thanks. Clément. -Message d'origine-De: Clément Maignien Envoyé: vendredi 5 août 2005 09:52À: MyFaces DiscussionObjet: x:dataTable : RowOnevent attributes Hi, I trying to use the RowOnMouseOver RowOnMouseOut attributes of the x:dataTable Tomahawk component, but with no result. I first tried to do it like in the simple.jar tomahawk example : rowOnMouseOver="this.style.backgroundColor='#A5CBFF'", rowOnMouseOut="this.style.backgroundColor='#E0'" but it didn't work for me. Besides, what is this new kind of _expression_ " this.XX.YY='value' " ? Then I tried it "the old way" with a CSS style : rowOnMouseOver="dataTable_RowOnMouseOver" , rowOnMouseOut="dataTable_RowOnMouseOut", with CSS style class defining background-color attribute, but it didn't work either. My dataTable component is quite simple. Let me know if you want to see myJSF code. Thanks, Clément.
RE : RE : dataTable : RowOnevent attributes
It won't work for me ... Maybe there is an incompatibility with specifying multiple styles in the columnClasses attribute ? Thanks for your help Regards, Clément -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Envoyé : vendredi 5 août 2005 15:16 À : users@myfaces.apache.org Objet : Re: RE : dataTable : RowOnevent attributes Hi, rowOn... works for me very well. rowOn.. can not have CSS styles. rowOn.. needs JavaScript. this is the current html-object in JavaScript. Here is an example which runs ok. x:dataTable rowOnMouseOver=this.bgColor='blue'; rowOnMouseOut=this.bgColor='#5683B2'; styleClass=standardTable headerClass=standardHeader columnClasses=standardColumn rows=10 id=data border=1 var=currentRow value=#{posBean.pos} rowOn.. can not have CSS-Code. rowOn.. needs JavaScript. this is the current html-object in JavaScript. Hope this helps Regards Wolfgang Clément Maignien sagte: It seems I don't give enought details or that noboby knows what I'm talking about (can't be that ...), So ... more details : First, here is the JSF code part for the dataTable trying using CSS style : x:dataTable id=receptdatatable styleClass=dataTable headerClass=dataTable_Header footerClass=dataTable_Footer rowClasses=dataTable_Row columnClasses=dataTable_ColumnLeftWhite rowOnMouseOver=dataTable_RowOnMouseOver rowOnMouseOut=dataTable_RowOnMouseOut var=recept value=#{receptBean.receptData} rows=#{receptBean.nbResParPageInt} sortColumn=#{receptBean.sort} sortAscending=#{receptBean.ascending} preserveSort=true preserveDataModel=false rowIndexVar=numRow x:column ... x:column/ ... x:column ... x:column/ x:dataTable the CSS styleclass : .dataTable_RowOnMouseOver { background-color: #A5CBFF; } .dataTable_RowOnMouseOut { background-color: #FF; } Then , the other solution I tried is like in the MyFaces simple.war example (openDataTable.jsp) : x:dataTable id=receptdatatable styleClass=dataTable headerClass=dataTable_Header footerClass=dataTable_Footer rowClasses=dataTable_Row columnClasses=dataTable_ColumnLeftWhite rowOnMouseOver=this.style.backgroundColor='#A5CBFF' rowOnMouseOut=this.style.backgroundColor='#FF' var=recept value=#{receptBean.receptData} rows=#{receptBean.nbResParPageInt} sortColumn=#{receptBean.sort} sortAscending=#{receptBean.ascending} preserveSort=true preserveDataModel=false rowIndexVar=numRow x:column ... x:column/ ... x:column ... x:column/ x:dataTable The both don't work : the rows of my dataTable stay White. Finally, what is this type of expression : this.xx.yy='value' (like this.style.backgroundColor='#FF') ... never seen that before. Please help, thanks. Clément. -Message d'origine- De : Clément Maignien Envoyé : vendredi 5 août 2005 09:52 À : MyFaces Discussion Objet : x:dataTable : RowOnevent attributes Hi, I trying to use the RowOnMouseOver RowOnMouseOut attributes of the x:dataTable Tomahawk component, but with no result. I first tried to do it like in the simple.jar tomahawk example : rowOnMouseOver=this.style.backgroundColor='#A5CBFF', rowOnMouseOut=this.style.backgroundColor='#E0' but it didn't work for me. Besides, what is this new kind of expression this.XX.YY='value' ? Then I tried it the old way with a CSS style : rowOnMouseOver=dataTable_RowOnMouseOver , rowOnMouseOut=dataTable_RowOnMouseOut, with CSS style class defining background-color attribute, but it didn't work either. My dataTable component is quite simple. Let me know if you want to see my JSF code. Thanks, Clément.
Shift in browser url bar
Title: Message Hi, I notice a problem in my web application. This is quite wierd : I have a welcome page "index.jsp" that redirect to a login page "login.jsp". This works fine at that point : the url in my browser displays "http://localhost:8080/myApp/faces/login.jsp" The problem comes after the login action : In case of login success, the welcome.jsp page is displayed as expected but the url in my browser is still "http://localhost:8080/myApp/faces/login.jsp"instead of "http://localhost:8080/myApp/faces/welcome.jsp" Then during all the navigation this shift between the previous and the actual page still occurs : if the current.jsp page is displayed I have "http://localhost:8080/myApp/faces/previous.jsp" in the url bar of my browser. Then if I click on link to "next.jsp" in my menu, the url bar will be "http://localhost:8080/myApp/faces/current.jsp" ... hope this is clear (... not sure :D ) This is quite cumbersome, because on a relaod browser button click the previous page is redisplayed instead of the current one. The problem occurs in every browser I tried. Does anyone encounter this problem before ? Which files of my webapp do you need to see where the problem could come from ? Thanks a lot Clément.
RE : Shift in browser url bar
Cool ! This works perfect :D Thanks a lot Johannes ;) Clément - Loves when problems solve so quickly, thx again. -Message d'origine- De : Johannes Hiemer [mailto:[EMAIL PROTECTED] Envoyé : jeudi 4 août 2005 12:28 À : MyFaces Discussion Objet : Re: Shift in browser url bar Hi, did you add the redirect/ in your faces-config.xml? Something like that as example: navigation-rule from-view-id*/from-view-id navigation-case from-outcomesuccess/from-outcome to-view-id/success.jsp/to-view-id redirect / /navigation-case /navigation-rule Hope that helps. Regards Johannes MyFaces Discussion users@myfaces.apache.org schrieb am 04.08.05 11:26:12: Hi, I notice a problem in my web application. This is quite wierd : I have a welcome page index.jsp that redirect to a login page login.jsp. This works fine at that point : the url in my browser displays http://localhost:8080/myApp/faces/login.jsp; The problem comes after the login action : In case of login success, the welcome.jsp page is displayed as expected but the url in my browser is still http://localhost:8080/myApp/faces/login.jsp; instead of http://localhost:8080/myApp/faces/welcome.jsp; Then during all the navigation this shift between the previous and the actual page still occurs : if the current.jsp page is displayed I have http://localhost:8080/myApp/faces/previous.jsp; in the url bar of my browser. Then if I click on link to next.jsp in my menu, the url bar will be http://localhost:8080/myApp/faces/current.jsp; ... hope this is clear (... not sure :D ) This is quite cumbersome, because on a relaod browser button click the previous page is redisplayed instead of the current one. The problem occurs in every browser I tried. Does anyone encounter this problem before ? Which files of my webapp do you need to see where the problem could come from ? Thanks a lot Clément. __ Mit WEB.DE FreePhone mit hoechster Qualitaet ab 0 Ct./Min. weltweit telefonieren! http://freephone.web.de/?mc=021201
RE : RE : Shift in browser url bar
Title: Message Thanks for the advise Martin, but the problem is that when I don'tputa redirect/ inany of mynavigation-case I get the problem again ... Am I doing something wrong in the navigation of my webApp ? What do you mean by "where it is necessary" ? in which case ? What does actually do this redirect/ tag ? Thanks for your helpMartin. Regards, Clément -Message d'origine-De: Martin Marinschek [mailto:[EMAIL PROTECTED] Envoyé: jeudi 4 août 2005 14:30À: MyFaces DiscussionObjet: Re: RE : Shift in browser url barYou need to know though that this means an actual redirect (=roundtrip to the client) - so use it were it is necessary, but not in all navigation rules if you want to keep performance at its best level ;)regards,Martin On 8/4/05, Clément Maignien [EMAIL PROTECTED] wrote: Cool ! This works perfect :DThanks a lot Johannes ;)Clément - Loves when problems solve so quickly, thx again.-Message d'origine-De : Johannes Hiemer [mailto: [EMAIL PROTECTED]]Envoyé : jeudi 4 août 2005 12:28À : MyFaces DiscussionObjet : Re: Shift in browser url barHi,did you add the redirect/ in your faces-config.xml?Something like that as example: navigation-rulefrom-view-id*/from-view-idnavigation-casefrom-outcomesuccess/from-outcometo-view-id/success.jsp/to-view-id redirect //navigation-case/navigation-ruleHope that helps.Regards Johannes"MyFaces Discussion" users@myfaces.apache.org schrieb am 04.08.05 11:26:12:Hi, I notice a problem in my web application. This is quite wierd : I have a welcome page "index.jsp" that redirect to a login page "login.jsp". This works fine at that point : the url in my browser displays "http://localhost:8080/myApp/faces/login.jsp" The problem comes after the login action : In case of login success, the welcome.jsp page is displayed as expected but the url in my browser is still "http://localhost:8080/myApp/faces/login.jsp" instead of "http://localhost:8080/myApp/faces/welcome.jsp " Then during all the navigation this shift between the previous and the actual page still occurs : if the current.jsp page is displayed I have "http://localhost:8080/myApp/faces/previous.jsp" in the url bar of my browser. Then if I click on link to "next.jsp" in my menu, the url bar will be "http://localhost:8080/myApp/faces/current.jsp" ... hope this is clear (... not sure :D ) This is quite cumbersome, because on a relaod browser button click the previous page is redisplayed instead of the current one. The problem occurs in every browser I tried. Does anyone encounter this problem before ? Which files of my webapp do you need to see where the problem could come from ? Thanks a lot Clément.__Mit WEB.DE FreePhone mit hoechster Qualitaet ab 0 Ct./Min.weltweit telefonieren! http://freephone.web.de/?mc=021201
RE : commandLink and onClick javascript popup window problem
Someone has made it (the onclick popup) ! You can find it there : http://www.jenia.org Or view a demo here : http://www.jenia.org/TestPopup/jsp/index.jsp That don't solve my problem entirely, because I want my page to be opened in a browser window, but I think I gone use it somewhere else in my application. Thanks for the contribution ;) Clément -Message d'origine- De : Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé : jeudi 21 juillet 2005 16:12 À : MyFaces Discussion Objet : Re: commandLink and onClick javascript popup window problem I think your problem is that you are opening the window with an *onclick* javascript even. This has nothing to do with the JSF lifecycle. The regular commandLink approach (without using onclick) works because you post back (via a form) to the same page. In your case you are just opening the page in a new window. How would JSF know the new values from that? sean On 7/21/05, Clément Maignien [EMAIL PROTECTED] wrote: Here is the situation : I have a JSF page (result.jsp) with dataTable component with a commandLink in one of his columns. When clicking on this commandLink, I would like to open a popup window (detailStockInv.jsp) to display detail informations about the line that has been clicked. Here is the code I wrote : x:dataTable id=stockdatatable rowIndexVar=numRow ... h:column ... /h:column ... h:column f:facet name=header h:outputText value=#{res['stock_Etat_Visu_Stockinv']} / /f:facet h:commandLink styleClass=linkRed actionListener=#{stockBean.updateDetailStock} onclick=window.open('detailStockInv.jsp','','width=700,height=400,top=100,left=100') h:outputText value=#{stock.stockInv}/ f:param name=numLineClicked value=#{numRow}/ /h:commandLink /h:column ... /x:dataTable I've put an actionListener to update datas (a bean property) that are displayed in the popup page (detailStockInv.jsp) in a dataTable component. My popup is opened and displayed when I click one of the commandLink of my results dataTable, but the problem is that the bean values that are read by my popup page are the previous ones : the first time I click a commandLink, the values displayed by the popup are not the ones updated by my actionListener but the initial ones (inited in the bean constructor). The second time I click a commandLink, the values of the line I cliked before are displayed. In my opinion, the popup is displayed before the update model value phase of the JSF life cycle occurs. As a consequence, the previous bean values are displayed in my popup page. To confirm that, I tried not to display this page in a popup, but in the same window (normal flow) with the action property of the commandLink : h:commandLink styleClass=linkRed action=#{stockBean.showDetailAction} h:outputText value=#{stock.stockInv}/ f:param name=numLigneClicked value=#{numRow}/ /h:commandLink The showDetailAction action and the updateDetailStock actionListener are doing exactly the same work (updating the detail values of my bean), except that it return a navigation result to display the detailStockInv.jsp page In this way, the values that are displayed in the detailStockInv.jsp are the good ones (the bean's ones). Is there a way to force the update value phase before the popup is displayed ? Maybe the way I call the popup isn't the right one ... don't know. Please help, thanks :D Clément Maignien.
RE : RE : commandLink and onClick javascript popup window problem
Thanks Sławek, I'll try it as soon as I can. Thanks again for your help ;) Clément -Message d'origine- De : Slawek [mailto:[EMAIL PROTECTED] Envoyé : vendredi 22 juillet 2005 11:33 À : MyFaces Discussion Objet : Re: RE : commandLink and onClick javascript popup window problem i have made it in #2 way - that was described in my last post it works great (and opens in browser window:P ) Sławek Sobótka Someone has made it (the onclick popup) ! You can find it there : http://www.jenia.org Or view a demo here : http://www.jenia.org/TestPopup/jsp/index.jsp That don't solve my problem entirely, because I want my page to be opened in a browser window, but I think I gone use it somewhere else in my application. Thanks for the contribution ;) Clément -Message d'origine- De : Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé : jeudi 21 juillet 2005 16:12 À : MyFaces Discussion Objet : Re: commandLink and onClick javascript popup window problem I think your problem is that you are opening the window with an *onclick* javascript even. This has nothing to do with the JSF lifecycle. The regular commandLink approach (without using onclick) works because you post back (via a form) to the same page. In your case you are just opening the page in a new window. How would JSF know the new values from that? sean On 7/21/05, Clément Maignien [EMAIL PROTECTED] wrote: Here is the situation : I have a JSF page (result.jsp) with dataTable component with a commandLink in one of his columns. When clicking on this commandLink, I would like to open a popup window (detailStockInv.jsp) to display detail informations about the line that has been clicked. Here is the code I wrote : x:dataTable id=stockdatatable rowIndexVar=numRow ... h:column ... /h:column ... h:column f:facet name=header h:outputText value=#{res['stock_Etat_Visu_Stockinv']} / /f:facet h:commandLink styleClass=linkRed actionListener=#{stockBean.updateDetailStock} onclick=window.open('detailStockInv.jsp','','width=700,height=400,top=100,left=100') h:outputText value=#{stock.stockInv}/ f:param name=numLineClicked value=#{numRow}/ /h:commandLink /h:column ... /x:dataTable I've put an actionListener to update datas (a bean property) that are displayed in the popup page (detailStockInv.jsp) in a dataTable component. My popup is opened and displayed when I click one of the commandLink of my results dataTable, but the problem is that the bean values that are read by my popup page are the previous ones : the first time I click a commandLink, the values displayed by the popup are not the ones updated by my actionListener but the initial ones (inited in the bean constructor). The second time I click a commandLink, the values of the line I cliked before are displayed. In my opinion, the popup is displayed before the update model value phase of the JSF life cycle occurs. As a consequence, the previous bean values are displayed in my popup page. To confirm that, I tried not to display this page in a popup, but in the same window (normal flow) with the action property of the commandLink : h:commandLink styleClass=linkRed action=#{stockBean.showDetailAction} h:outputText value=#{stock.stockInv}/ f:param name=numLigneClicked value=#{numRow}/ /h:commandLink The showDetailAction action and the updateDetailStock actionListener are doing exactly the same work (updating the detail values of my bean), except that it return a navigation result to display the detailStockInv.jsp page In this way, the values that are displayed in the detailStockInv.jsp are the good ones (the bean's ones). Is there a way to force the update value phase before the popup is displayed ? Maybe the way I call the popup isn't the right one ... don't know. Please help, thanks :D Clément Maignien.
commandLink and onClick javascript popup window problem
Here is the situation: I have a JSF page (result.jsp) with dataTable component with a commandLink in one of his columns. When clicking on this commandLink, I would like to open a popup window (detailStockInv.jsp) to display detail informations about the line that has been clicked. Here is the code I wrote : x:dataTable id=stockdatatable rowIndexVar=numRow ... h:column ... /h:column ... h:column f:facet name=header h:outputText value=#{res['stock_Etat_Visu_Stockinv']} / /f:facet h:commandLink styleClass=linkRed actionListener=#{stockBean.updateDetailStock} > h:outputText value=#{stock.stockInv}/ f:param name=numLineClicked value=#{numRow}/ /h:commandLink /h:column ... /x:dataTable Ive put an actionListener to update datas (a bean property) that are displayed in the popup page (detailStockInv.jsp) in a dataTable component. My popup is opened and displayed when I click one of the commandLink of my results dataTable, but the problem is that the bean values that are read by my popup page are the previous ones : the first time I click a commandLink, the values displayed by the popup are not the ones updated by my actionListener but the initial ones (inited in the bean constructor). The second time I click a commandLink, the values of the line I cliked before are displayed. In my opinion, the popup is displayed before the update model value phase of the JSF life cycle occurs. As a consequence, the previous bean values are displayed in my popup page. To confirm that, I tried not to display this page in a popup, but in the same window (normal flow) with the action property of the commandLink : h:commandLink styleClass=linkRed action="" h:outputText value=#{stock.stockInv}/ f:param name=numLigneClicked value=#{numRow}/ /h:commandLink The showDetailAction action and the updateDetailStock actionListener are doing exactly the same work (updating the detail values of my bean), except that it return a navigation result to display the detailStockInv.jsp page In this way, the values that are displayed in the detailStockInv.jsp are the good ones (the beans ones). Is there a way to force the update value phase before the popup is displayed ? Maybe the way I call the popup isnt the right one ... dont know. Please help, thanks :D Clément Maignien.
RE : commandLink and onClick javascript popup window problem
Yes indeeed Sean. That's is exactly what I said at the end of my post. But my question is : is it possible to open a popup window (with or without javascript) to display my detailed informations ? if yes, how ? Thanks. -Message d'origine- De : Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé : jeudi 21 juillet 2005 16:12 À : MyFaces Discussion Objet : Re: commandLink and onClick javascript popup window problem I think your problem is that you are opening the window with an *onclick* javascript even. This has nothing to do with the JSF lifecycle. The regular commandLink approach (without using onclick) works because you post back (via a form) to the same page. In your case you are just opening the page in a new window. How would JSF know the new values from that? sean On 7/21/05, Clément Maignien [EMAIL PROTECTED] wrote: Here is the situation : I have a JSF page (result.jsp) with dataTable component with a commandLink in one of his columns. When clicking on this commandLink, I would like to open a popup window (detailStockInv.jsp) to display detail informations about the line that has been clicked. Here is the code I wrote : x:dataTable id=stockdatatable rowIndexVar=numRow ... h:column ... /h:column ... h:column f:facet name=header h:outputText value=#{res['stock_Etat_Visu_Stockinv']} / /f:facet h:commandLink styleClass=linkRed actionListener=#{stockBean.updateDetailStock} onclick=window.open('detailStockInv.jsp','','width=700,height=400,top=100,left=100') h:outputText value=#{stock.stockInv}/ f:param name=numLineClicked value=#{numRow}/ /h:commandLink /h:column ... /x:dataTable I've put an actionListener to update datas (a bean property) that are displayed in the popup page (detailStockInv.jsp) in a dataTable component. My popup is opened and displayed when I click one of the commandLink of my results dataTable, but the problem is that the bean values that are read by my popup page are the previous ones : the first time I click a commandLink, the values displayed by the popup are not the ones updated by my actionListener but the initial ones (inited in the bean constructor). The second time I click a commandLink, the values of the line I cliked before are displayed. In my opinion, the popup is displayed before the update model value phase of the JSF life cycle occurs. As a consequence, the previous bean values are displayed in my popup page. To confirm that, I tried not to display this page in a popup, but in the same window (normal flow) with the action property of the commandLink : h:commandLink styleClass=linkRed action=#{stockBean.showDetailAction} h:outputText value=#{stock.stockInv}/ f:param name=numLigneClicked value=#{numRow}/ /h:commandLink The showDetailAction action and the updateDetailStock actionListener are doing exactly the same work (updating the detail values of my bean), except that it return a navigation result to display the detailStockInv.jsp page In this way, the values that are displayed in the detailStockInv.jsp are the good ones (the bean's ones). Is there a way to force the update value phase before the popup is displayed ? Maybe the way I call the popup isn't the right one ... don't know. Please help, thanks :D Clément Maignien.
RE : RE : commandLink and onClick javascript popup window problem
Yes I tried to use the x:popup component but it is not appropriate for what I want to do. Having a onclick behaviour ont it would be great :D The solution you propose is actually what I tried to do. But the problem is that I use javascript to open the new window. It brakes the JSF flow and my backing bean values are not the update ones. Thanks for your help ;) -Message d'origine- De : Bruno Aranda [mailto:[EMAIL PROTECTED] Envoyé : jeudi 21 juillet 2005 16:42 À : MyFaces Discussion Objet : Re: RE : commandLink and onClick javascript popup window problem There is a component x:popup wich you could use, but it shows only onmouseover (if someone had the time to adapt this component to show onclick it would be great, the possibility to choose if the popup should be shown on onmouseover or onclick). Regarding your problem, maybe you can use a session bean with the information of your table and open a new jsf page in a new window which used the same bean...). HTH, Bruno 2005/7/21, Clément Maignien [EMAIL PROTECTED]: Yes indeeed Sean. That's is exactly what I said at the end of my post. But my question is : is it possible to open a popup window (with or without javascript) to display my detailed informations ? if yes, how ? Thanks. -Message d'origine- De: Sean Schofield [mailto:[EMAIL PROTECTED] Envoyé: jeudi 21 juillet 2005 16:12 À: MyFaces Discussion Objet: Re: commandLink and onClick javascript popup window problem I think your problem is that you are opening the window with an *onclick* javascript even. This has nothing to do with the JSF lifecycle. The regular commandLink approach (without using onclick) works because you post back (via a form) to the same page. In your case you are just opening the page in a new window. How would JSF know the new values from that? sean On 7/21/05, Clément Maignien [EMAIL PROTECTED] wrote: Here is the situation : I have a JSF page (result.jsp) with dataTable component with a commandLink in one of his columns. When clicking on this commandLink, I would like to open a popup window (detailStockInv.jsp) to display detail informations about the line that has been clicked. Here is the code I wrote : x:dataTable id=stockdatatable rowIndexVar=numRow ... h:column ... /h:column ... h:column f:facet name=header h:outputText value=#{res['stock_Etat_Visu_Stockinv']} / /f:facet h:commandLink styleClass=linkRed actionListener=#{stockBean.updateDetailStock} onclick=window.open('detailStockInv.jsp','','width=700,height=400,top=100,left=100') h:outputText value=#{stock.stockInv}/ f:param name=numLineClicked value=#{numRow}/ /h:commandLink /h:column ... /x:dataTable I've put an actionListener to update datas (a bean property) that are displayed in the popup page (detailStockInv.jsp) in a dataTable component. My popup is opened and displayed when I click one of the commandLink of my results dataTable, but the problem is that the bean values that are read by my popup page are the previous ones : the first time I click a commandLink, the values displayed by the popup are not the ones updated by my actionListener but the initial ones (inited in the bean constructor). The second time I click a commandLink, the values of the line I cliked before are displayed. In my opinion, the popup is displayed before the update model value phase of the JSF life cycle occurs. As a consequence, the previous bean values are displayed in my popup page. To confirm that, I tried not to display this page in a popup, but in the same window (normal flow) with the action property of the commandLink : h:commandLink styleClass=linkRed action=#{stockBean.showDetailAction} h:outputText value=#{stock.stockInv}/ f:param name=numLigneClicked value=#{numRow}/ /h:commandLink The showDetailAction action and the updateDetailStock actionListener are doing exactly the same work (updating the detail values of my bean), except that it return a navigation result to display the detailStockInv.jsp page In this way, the values that are displayed in the detailStockInv.jsp are the good ones (the bean's ones). Is there a way to force the update value phase before the popup is displayed ? Maybe the way I call the popup isn't the right one ... don't know. Please help, thanks :D Clément Maignien.