forked from DevFW-CICD/spring-petclinic
Removed HTTP PUT method - it is not supported in JSP 2.3
This commit is contained in:
parent
e0be3a39b6
commit
f7498c79df
5 changed files with 4 additions and 29 deletions
|
|
@ -116,7 +116,7 @@ public class OwnerController {
|
|||
return "owners/createOrUpdateOwnerForm";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/owners/{ownerId}/edit", method = RequestMethod.PUT)
|
||||
@RequestMapping(value = "/owners/{ownerId}/edit", method = RequestMethod.POST)
|
||||
public String processUpdateOwnerForm(@Valid Owner owner, BindingResult result, SessionStatus status) {
|
||||
if (result.hasErrors()) {
|
||||
return "owners/createOrUpdateOwnerForm";
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ public class PetController {
|
|||
return "pets/createOrUpdatePetForm";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/owners/{ownerId}/pets/{petId}/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||
@RequestMapping(value = "/owners/{ownerId}/pets/{petId}/edit", method = RequestMethod.POST)
|
||||
public String processUpdateForm(@Valid Pet pet, BindingResult result, SessionStatus status) {
|
||||
if (result.hasErrors()) {
|
||||
return "pets/createOrUpdatePetForm";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue