diff --git a/src/main/java/com/poseidon/user/web/controller/UserController.java b/src/main/java/com/poseidon/user/web/controller/UserController.java index e1e77fd6..870e0356 100644 --- a/src/main/java/com/poseidon/user/web/controller/UserController.java +++ b/src/main/java/com/poseidon/user/web/controller/UserController.java @@ -100,10 +100,10 @@ public String listByPage(final @PathVariable(name = "pageNumber") int pageNumber @PostMapping("/user/saveUser") public @ResponseBody Set saveUser( - @RequestParam(value = "thumbnail", required = false) final MultipartFile thumbnail, - @RequestParam("selectName") final String name, - @RequestParam("selectLogin") final String email, - @RequestParam("selectRole") final Set roles, + @RequestParam(name = "thumbnail", value = "thumbnail", required = false) final MultipartFile thumbnail, + @RequestParam(name = "selectName") final String name, + @RequestParam(name = "selectLogin") final String email, + @RequestParam(name = "selectRole") final Set roles, final RedirectAttributes redirectAttributes) throws IOException { logger.info("SaveUser method of user controller "); logger.info("inputs are : name {}, email {}, role {}", name, email, roles); @@ -205,11 +205,12 @@ private User removePassword(final User user) { @PutMapping("/user/updateUser") public @ResponseBody - Set updateUser(@RequestParam(value = "thumbnail", required = false) final MultipartFile thumbnail, - @RequestParam("id") final String id, - @RequestParam("name") final String name, - @RequestParam("email") final String email, - @RequestParam("roles") final Set roles, + Set updateUser(@RequestParam(name = "thumbnail", value = "thumbnail", required = false) + final MultipartFile thumbnail, + @RequestParam(name = "id") final String id, + @RequestParam(name = "name") final String name, + @RequestParam(name = "email") final String email, + @RequestParam(name = "roles") final Set roles, final RedirectAttributes redirectAttributes) { var sanitizedId = CommonUtils.sanitizedString(id); var sanitizedName = CommonUtils.sanitizedString(name); diff --git a/src/main/resources/templates/model/list.html b/src/main/resources/templates/model/list.html index dfa02d32..1eafd940 100644 --- a/src/main/resources/templates/model/list.html +++ b/src/main/resources/templates/model/list.html @@ -13,6 +13,7 @@ + Make and Model List @@ -108,6 +109,7 @@ id Make Name Model Name + @@ -116,6 +118,17 @@ th:value="${model.id}" /> + + +   + +