List of usage examples for org.springframework.ui Model addAttribute
Model addAttribute(String attributeName, @Nullable Object attributeValue);
From source file:com.practice.web.controller.MemberAreaController.java
@RequestMapping(value = "/member-area", method = RequestMethod.GET) public String getMemberAreaPage(Model model) { model.addAttribute("listData", personService.getListPerson()); return "member-area"; }
From source file:com.practice.web.controller.MemberAreaController.java
@RequestMapping(value = "/add-data", method = RequestMethod.GET) public String getAddDataPage(Model model) { model.addAttribute("person", new Person()); return "add-data"; }
From source file:kievreclama.task.controllers.EmployeeController.java
@RequestMapping(value = "/") public String getPageTasks(Model model) { model.addAttribute("employees", employeeService.getList("employees")); model.addAllAttributes(employeeService.allCompnents()); return "employees"; }
From source file:org.homiefund.web.controllers.UserController.java
@GetMapping("/") public String getProfile(Model model) { model.addAttribute("userProfile", mapper.map(userService.getProfile(), UserForm.class)); return "profile"; }
From source file:pdl.web.controller.web.GenericController.java
@ModelAttribute public void ajaxAttribute(WebRequest request, Model model) { model.addAttribute("ajaxRequest", AjaxUtils.isAjaxRequest(request)); }
From source file:unalm.startbootstrapSbAdmin.controller.programa.ProgramaController.java
@RequestMapping("nuevo") public String nuevo(Model model) { model.addAttribute("programa", new Programa()); return "programa/formulario"; }
From source file:cn.cdwx.jpa.web.account.UserAdminController.java
@RequestMapping(value = "update/{id}", method = RequestMethod.GET) public String updateForm(@PathVariable("id") String id, Model model) { model.addAttribute("user", accountService.getUser(id)); return "account/adminUserForm"; }
From source file:cn.dsgrp.field.stock.web.account.UserAdminController.java
@RequestMapping(value = "update/{id}", method = RequestMethod.GET) public String updateForm(@PathVariable("id") BigInteger id, Model model) { model.addAttribute("user", accountService.getUser(id)); return "account/adminUserForm"; }
From source file:com.mycompany.loginApp.controller.LoginController.java
@RequestMapping(value = "/main", method = RequestMethod.GET) public String mainPage(Model model) { String username = "ajay"; model.addAttribute("username", username); return "main"; }
From source file:com.util.MyController.java
@RequestMapping(value = "/myPage1.htm") public ModelAndView myMethod1(Model model) { model.addAttribute("name", "XYZ"); return new ModelAndView("page1"); }