RE: Need Ideas for This Puzzle

2004-10-22 Thread Wiebe de Jong
before sending back the response. Wiebe -Original Message- From: Caroline Jen [mailto:[EMAIL PROTECTED] Sent: Friday, October 22, 2004 10:59 AM To: Struts Users Mailing List Subject: RE: Need Ideas for This Puzzle What about something like: <% boolean checked = isChecked("a&q

Re: Need Ideas for This Puzzle

2004-10-22 Thread Michael McGrady
Hi, Caroline, Just a little follow up to all these good suggestions. I agree that if you use the Action, then you should definitely use helper classes and hopefully decouple them from the action. I like to use multithreading in the helper classes generally. The suggestions about using the Ac

RE: Need Ideas for This Puzzle

2004-10-22 Thread Caroline Jen
What about something like: <% boolean checked = isChecked("a"); // check if the value should be checked by default if(showCheckbox(user, "a")) { // check if, for this user, the checkbox should be visible %> > <% } else { // show disabled checkbox (or leave that out to show nothing...) %> disabled

Re: Need Ideas for This Puzzle

2004-10-22 Thread Wendy Smoak
From: "Caroline Jen" <[EMAIL PROTECTED]> > The challege comes as the "roles" of the web site > users are introduced. According to the role of the > web site user, I have to display certain groups (not > all the groups) and certain sub-groups (not all > sub-groups within a group) to him/her. > How

RE: Need Ideas for This Puzzle

2004-10-22 Thread Wiebe de Jong
Here's my idea: Create a bean that has multiple Boolean fields, with each corresponding to a checkbox you might want to display. In the action that loads data for this page, process the user's role and set the bean's Boolean values accordingly. Store the bean so that the jsp can read it. For all

RE: Need Ideas for This Puzzle

2004-10-22 Thread Varley, Roger
> > There are at least two good solutions. I like the second one best. > > > 1. Tag Conditional Logic Solution > > Just use the , and tags. I assume, > Caroline, > that you are using JSTL. If not, then there are equivalent solutions > with Struts logic tags. > > > 2 Action Condition

Re: Need Ideas for This Puzzle

2004-10-22 Thread Michael McGrady
There are at least two good solutions. I like the second one best. 1. Tag Conditional Logic Solution Just use the , and tags. I assume, Caroline, that you are using JSTL. If not, then there are equivalent solutions with Struts logic tags. 2 Action Conditional Delivery Solution Or, you can