Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-27 Thread Rick Reumann
Thanks Brendan, the description of using t:saveState sounds great. I look forward to trying it out shortly. I'm still a bit confused on how you deal with links that go to backing bean methods for standard links/buttons. As an example, imagine the header on a page [..]=links... John Doe [edit

RE: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Patel, Hitesh \(Exchange\)
You can pass the parameter as you have done and get the value of the parameter as follows FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap().get(empID); From: Rick Reumann [mailto:[EMAIL PROTECTED] Sent: Friday, August 26, 2005 2:49 PM To:

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Mike Kienenberger
You can also use dataTable.getRowData(), provided your model data is consistent, and then you don't need to create or pass a parameter. public void editRecord(ActionEvent event) { dataStore.editRecord(dataTable.getRowData()); } On 8/26/05, Patel, Hitesh (Exchange) [EMAIL

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Dennis Byrne
Do you know of any way to do this if the underlying DataModel is in a property of a request scoped bean and the you couldn't use preserveDataModel=true, t:saveState, or any other things beyond the spec itself ? I am in such a situation and the only solution I see at this time is using

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Mike Kienenberger
Nothing comes to mind, but allowing the end-user to specify the target record by key (generally a database primary key) may cause security issues. You'll have to validate the suitability of key provided when used. On 8/26/05, Dennis Byrne [EMAIL PROTECTED] wrote: Do you know of any way to do

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Dennis Byrne
I found a way to address the security issues when the navigation path is to and from the same JSP . I use a converter where getAsString encrypts and encodes the id on the way out, getAsObject decodes and decrypts the string coming in. This however can't be used when navigating from one view

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Rick Reumann
On 8/26/05, Patel, Hitesh (Exchange) [EMAIL PROTECTED] wrote: You can pass the parameter as you have done and get the value of the parameter as follows FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap().get(empID); I would guess this common to have to

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Rick Reumann
On 8/26/05, Mike Kienenberger [EMAIL PROTECTED] wrote: You can also use dataTable.getRowData(), provided your model data isconsistent, and then you don't need to create or pass a parameter.public void editRecord(ActionEvent event){dataStore.editRecord (dataTable.getRowData());} Can you explain

RE: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread CONNER, BRENDAN \(SBCSI\)
Title: Message There's a goodexample of getting row-specific events inthe O'Reilly book JavaServer Faces (Hans Bergsten), pp. 173 - 178. The example application throughout the book is to build an expense report application, and it makes use of the summary-detaillinks you refer to. However,

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Mike Kienenberger
Not as long as the data model is contained in your component tree or session rather than in some global location. On 8/26/05, Rick Reumann [EMAIL PROTECTED] wrote: On 8/26/05, Mike Kienenberger [EMAIL PROTECTED] wrote: You can also use dataTable.getRowData(), provided your model data is

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Gary VanMatre
I'm a fan of the Struts ActionForm. If you wanted to populate an object with query parameters, you might think about creating a managed bean and use the setter injection stuff. managed-bean managed-bean-nameformBean/managed-bean-name managed-bean-classxxx.FormBean/managed-bean-class

Re: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread Rick Reumann
On 8/26/05, CONNER, BRENDAN (SBCSI) [EMAIL PROTECTED] wrote: However, I believe that, using this mechanism, there's no real way to get around usingsomething liket:saveState or having a session-scoped bean. Just out of curiosity, what is the objection to using t:saveState? Well I haven't

RE: Dealing with links/buttons to fire off an action? confusion on how to set this up

2005-08-26 Thread CONNER, BRENDAN \(SBCSI\)
Title: Message t:saveState is trivially simple to use, but it's a Godsend. Wherever you want the state of a bean to be maintained across requests, just declare the bean with request scope andput a t:saveSave value="#{myBean}" on the pages that use it. The bean's state will be maintained