Hi XWiki devs,
At Mandriva we have the need for a class property type that would be
able to handle dynamic lists. Well, the DBList properties are already
dynamic, but we'd need something more dynamic.
Usage examples:
* apply some filter to a list of results fetched from the database,
* translate the DBList values returned by a SQL query before presenting
them to the user
* build lists from other sources than the database (from a web service
call etc.)
Such lists would be built by a Velocity or Groovy script, declared as an
attribute of the class property. What do you think of the feature? Do
you have any suggestion on the way it should be implemented? We could
either create a new Java type "DynamicList" + new wiki table
xwikidynlistclasses, inspired by the "DBList" Java type, or transform
the DBList into a "DynamicList" that would handle either Hibernate SQL
queries, or Velocity/Groovy scripts. That would be handy also to have
the possibility to specify the name of the document containing the
script to be executed, if the script is to be reused by several classes.
Stéphane and Christophe