Hi Vincent,
Blossom has a WebArgumenResolver that makes is possible to get the content as
an argument to your @RequestMapping methods.
It's configured in blossom-servlet.xml like this:
<bean
class="org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter">
<property name="customArgumentResolver">
<bean class="info.magnolia.module.blossom.web.BlossomWebArgumentResolver"
/>
</property>
</bean>
And used like this:
@RequestMapping("/bookcategory")
public String render(ModelMap model, Node content) throws
RepositoryException { ... }
Or if you also need access to the page content, you can add two arguments of
type Node, then the first will be the page and the second the content of the
component.
@RequestMapping("/bookcategory")
public String render(ModelMap model, Node page, Node content) throws
RepositoryException { ... }
Hope that helps!
// Tobias
--
Context is everything:
http://forum.magnolia-cms.com/forum/thread.html?threadId=a0450c46-0526-4ce2-a2ab-efe3b98297f8
You are invited to Magnolia Conference. Less than a month to go! Register now:
http://www.magnolia-cms.com/conference/register.html
----------------------------------------------------------------
For list details, see http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------