List of usage examples for org.springframework.ui Model addAttribute
Model addAttribute(String attributeName, @Nullable Object attributeValue);
From source file:com.training.controller.IndexController.java
@RequestMapping(value = "/input", method = RequestMethod.POST) public String inputNamePost(@RequestParam(value = "data") String data, Model model) { model.addAttribute("message", data); return "users/index"; }
From source file:com.training.controller.IndexController.java
@RequestMapping(value = "/input", method = RequestMethod.GET) public String inputNameGet(@RequestParam(value = "data") String data, Model model) { model.addAttribute("message", data + " lihat url, data dipasringkan dan terlihat karena method GET"); return "users/index"; }
From source file:jp.pigumer.sso.Application.java
@RequestMapping("/") String index(Model model) { model.addAttribute("hello", "/hello"); return "index"; }
From source file:net.gplatform.sudoor.server.social.controller.ExceptionHandlingControllerAdvice.java
@ExceptionHandler(RateLimitExceededException.class) public String rateLimitExceeded(RateLimitExceededException e, Model model) { model.addAttribute("providerId", e.getProviderId()); return "ratelimit"; }
From source file:nl.tjonahen.javaee7.cdi.springbeans.SpringHelloWorld.java
@RequestMapping("/helloWorld") public String helloWorld(Model model) { model.addAttribute("message", hwb.welcomeMessage()); return "helloWorld"; }
From source file:org.openmrs.module.hospitalcore.web.controller.form.SelectObsPopupController.java
@RequestMapping(method = RequestMethod.GET) public String showForm(@RequestParam("type") String type, Model model) { model.addAttribute("type", type); return "/module/hospitalcore/form/selectObsPopup"; }
From source file:org.openmrs.module.radiology.web.controller.form.SelectObsPopupController.java
@RequestMapping(method = RequestMethod.GET) public String showForm(@RequestParam("type") String type, Model model) { model.addAttribute("type", type); return "/module/radiology/form/selectObsPopup"; }
From source file:org.osmsurround.ra.IndexController.java
@RequestMapping(value = { "", "index" }, method = RequestMethod.GET) public String get(AnalyzeRelationModel analyzeRelationModel, SearchModel searchModel, Model model) { model.addAttribute("tagInfos", tagInfoService.getTagInfos()); return "index"; }
From source file:org.terasoluna.gfw.functionaltest.app.queryescape.QueryEscapeHelper.java
public void bindToModel(String searchPattern, List<Todo> todoList, Model model) { model.addAttribute("searchPattern", searchPattern); model.addAttribute("hitNumber", todoList.size()); model.addAttribute("todoList", todoList); }
From source file:thoughtworks.controller.CalculatorController.java
@RequestMapping(value = "/", method = RequestMethod.GET) public String init(Model model) { model.addAttribute("calculator", new Calculator()); return "index"; }