Leszek Gawron wrote:
> don't we have a pluggable object model ? :))
>
> function doIt() {
> var objectModel = {};
>
> objectModel.pluggedIn1 = entityFromDatabase();
> objectModel.pluggedIn2 = request.getParameter( "skin" );
>
> cocoon.sendPage( "view/myview.jx", objectModel );
> }
>
> Other data that is not directly available from flow (like authentication
> context can be accessed with input modules that are already available).
>
And this is exactly my problem :)
With this approach you have to get all the data for each
cocoon.sendPage() and store it somewhere. If you use a lot of flow this
creates a maintenance nightmare. Of course you could provide your own
sendPage() function that does all the work, but it's not a nice way of
doing it.
So why not defining plugins for the object model somewhere and as soon
as you use them in your template they are queried to provide information.
Carsten
|