Dynamic Options for Select Control
----------------------------------
Key: MAGNOLIA-766
URL: http://jira.magnolia.info/browse/MAGNOLIA-766
Project: magnolia
Type: Improvement
Components: admininterface
Versions: 2.1.5
Reporter: Bert Schulzki
Assigned to: Boris Kraft
Priority: Minor
If you use selections in magnolia dialogs, the options must be static defined
in the dialog properties. Though this is straight forward, it has serious
limitations:
* when using the same options in multiple dialogs, you must copy and paste, and
if one option changes, you have to start over
* you cant provide "dynamic" options, for instance:
o select a user from the repository
o select a page with a specific template below a certain content tree
o retrieve options from elsewhere (filesystem, jdbc, ...)
I could not solve this without changing magnolia. If someone knows a better
way, please tell me. Otherwise i would suggest to build my (or a similiar
solution) into the product. The source is attached to this page and in the
wiki.
The solution works like this:
* if a "options" contentnode in a select field is found, its static options
will be used
* if "options" contentnode is missing, it will look for a nodedata called
"optionClass"
* if this nodedata is found, it will instantiate this class
* this class must implement the interface OptionHook and provides a single
method "getOptions(...)"
Using this pattern, you are fully backward compatible to existing dialog
definitions, with the ability to create dynamic options.
The code is ready and can be found ready here:
http://www.magnolia.info/wiki/Wiki.jsp?page=DynamicOptions
If there are some supporters for this issue, i would like to see it integrated
into the magnolia source tree.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.magnolia.info/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
----------------------------------------------------------------
for list details see
http://www.magnolia.info/en/magnolia/developer.html
----------------------------------------------------------------