What is a rich behaviour? A template just display some values built by
the application model and extracted by the controller.
> --
> You received this message because you are subscribed to the Google Groups "play-framework" group.
> To post to this group, send email to play-fr...@googlegroups.com.
> To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.
>
>
--
Guillaume Bort, http://guillaume.bort.fr
For anything work-related, use g...@zenexity.fr; for everything else,
write guillau...@gmail.com
public static void anyAction() {
BreadCrumb bc = BreadCrumb.forAction("...");
ShoppingCart cart = getShoppingCart();
... // extract more data from your application here
render(bc, cart, ...);
}
Or like Julien advice, you can sometimes write some code only once in
a @Before filter. The important thing to remember is that you don't
write business code neither in template nor Controller.
The application model provides some data, the controller extract some
data needed for a particular request, the template display these data.
--
Guillaume Bort, http://guillaume.bort.fr
For anything work-related, use g...@zenexity.fr; for everything else,
write guillau...@gmail.com
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.