Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

반려동물 등록 시 모든 parameter가 null로 넘어오는 에러 #10

Closed
Anna-Jin opened this issue Mar 19, 2022 · 2 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@Anna-Jin
Copy link
Owner

반려동물 등록 시 모든 parameter가 null로 넘어오는 에러

  • PetRestController.java

@ModelAttribute 어노테이션으로 파라미터를 받아오고 있음
userId와 newuter는 잘 받아오는 것으로 보아 add_pet.jsp 에서 formData에 해당 값들이 제대로 들어가지 않았을 확률이 있음.

@Anna-Jin Anna-Jin added the bug Something isn't working label Mar 19, 2022
@Anna-Jin Anna-Jin self-assigned this Mar 19, 2022
Anna-Jin pushed a commit that referenced this issue Mar 19, 2022
Anna-Jin pushed a commit that referenced this issue Mar 19, 2022
@Anna-Jin
Copy link
Owner Author

모든 LocalDate 타입에 @DateTimeFormat 어노테이션을 붙여줬더니 해결됐다..??

Repository owner deleted a comment from yujin-Jin Mar 21, 2022
@Anna-Jin
Copy link
Owner Author

파일 가공하는 데에 문제가 있어 @ModelAttribute 어노테이션 대신 @RequestParam 어노테이션으로 대체하면서 pet model에 @DateTimeFormat을 붙여주는 대신 파라미터에 붙여주었음. 해결!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant