Hi,
I was wondering if it was possible to call a controller method using the <s:eval> tag from a JSP page, a bit like the way it's done in JSF.
Code:@Controller(value="planesController") @RequestMapping({"/planes"}) public class PlanesController { @Autowired private PlanesDAO planesDAO; public List<Plane> allPlanes(){ return planesDAO.getAll(); }
Code:<sf:form> <s:eval expression="planesController.allPlanes()" var="planes" /> <sf:checkboxes items="${planes}" path="planes" id="avions"/> </sf:form>
I keep getting the exception :
I know I can use model.addAttribute but I call this method from several JSP pages and I thought one of the of the <s:eval> tag was to allow access to beans from views.Code:org.springframework.expression.spel.SpelEvaluationException: EL1007E:(pos 0): Field or property 'planesController' cannot be found on null
I'm using Spring 3.0.5
Thanks in Advance


Reply With Quote
