You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by bu...@apache.org on 2002/11/29 19:58:58 UTC
DO NOT REPLY [Bug 14968] New: -
Improvement for component state management
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14968>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=14968
Improvement for component state management
Summary: Improvement for component state management
Product: Struts
Version: Unknown
Platform: Other
OS/Version: Other
Status: NEW
Severity: Normal
Priority: Other
Component: Custom Tags
AssignedTo: struts-dev@jakarta.apache.org
ReportedBy: david.gagnon@cgi.ca
CC: david.gagnon@cgi.ca
Hi,
I posted on a mailing list a while ago regarding a way to manage
buttons/fields that must be disable/enabled at any given time in an web
application. My conclusion was that they where no easy way handle that (Am I
wrong?).
So I implement my state management this way:
<input type="button" name="btnCcNumber"
<%htmlComponentController.paccButton.getAccessAttributes(request)%>/>
NOTE: I didn't use tag lib for input .. I probably got a problem with it ..
anyway ...
The HtmlcomponentController returns a HTML string to disable/enable the button
base on application current state and user's role/permission.
I would have liked to do it this way, which is more clean:-)
<html:button property="btnCcNumber" stateManaged=true>
In this solution you must provide a handler (maybe put it in the session as
application attribute). When the stateManaged attribute is set, the taglib get
the pre-defined handler and calls a method (like getStateAttribute ) with the
button name as argument and get the button current state (This one return
true/false).
Maybe it already been asked before.. or maybe I didn't address my problem the
right way ... Anyway I'm asking just to be sure ... :-)
If you need more inputs just tell me
Best Regards
/David GAgnon
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>