The various smart "options" tags should allow smarter handling of the "id" 
attribute
------------------------------------------------------------------------------------

                 Key: STS-700
                 URL: http://www.stripesframework.org/jira/browse/STS-700
             Project: Stripes
          Issue Type: Improvement
          Components: Tag Library
    Affects Versions: Release 1.5.1
         Environment: Linux/Jetty (doesn't matter)
            Reporter: Mike McNally
            Priority: Minor


The "options-collection", "options-enumeration", and "options-map" tags all 
allow for an HTML "pass-through" value for the "id" attribute. Well, if you 
think about it at all, that's not really useful - almost of necessity that'll 
wind you up with every generation option element having the same "id" value, 
which would rarely be desirable (it's not really even valid).

I think that instead it should be possible to apply the same capabilities that 
those tags provide for option value and label to the "id" attribute. For 
options-collection, the "id" attribute (or a new one, to leave the old one 
around for whatever bizarre purposes it's already serving) should interpret the 
value as a property reference for the collection objects. For 
"options-enumeration", it might be nice to have the choice of enumeration value 
ordinal, or name, or possibly an arbitrary property for bean-enhanced enums. 
For "options-map", you might want to use the map key for the "id" or maybe a 
map entry value sub-property.

Giving the options elements unique "id" values allows for simpler client-side 
code, to (for example) hide/reveal portions of a form based on the value of the 
pull-down.
That can be done with the option value too, but the "id" would be somewhat more 
robust.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://www.stripesframework.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development

Reply via email to