SuranS2 / TEST

🔥먼저 생각하는 사람
0 stars 0 forks source link

validation 처리 위치 , 폼 공백값 String => int 처리 문제 #179

Closed SuranS2 closed 2 weeks ago

SuranS2 commented 3 weeks ago

In GitLab by @SuranS2 on Aug 28, 2024, 10:53

SuranS2 commented 3 weeks ago

changed due date to August 29, 2024

SuranS2 commented 3 weeks ago
Wed Aug 28 13:18:20 KST 2024
There was an unexpected error (type=Internal Server Error, status=500).
Validation failed for classes [com.example.team1.Prometheus.entity.Item] during persist time for groups [jakarta.validation.groups.Default, ] List of constraint violations:[ ConstraintViolationImpl{interpolatedMessage='상품 이름을 제대로 등록해주세요.', propertyPath=name, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='상품 이름을 제대로 등록해주세요.'} ConstraintViolationImpl{interpolatedMessage='내용을 입력해주세요.', propertyPath=description, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='내용을 입력해주세요.'} ConstraintViolationImpl{interpolatedMessage='상품 이름은 공백으로 두시면 안됩니다.', propertyPath=name, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='상품 이름은 공백으로 두시면 안됩니다.'} ]
jakarta.validation.ConstraintViolationException: Validation failed for classes [com.example.team1.Prometheus.entity.Item] during persist time for groups [jakarta.validation.groups.Default, ]
List of constraint violations:[
    ConstraintViolationImpl{interpolatedMessage='상품 이름을 제대로 등록해주세요.', propertyPath=name, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='상품 이름을 제대로 등록해주세요.'}
    ConstraintViolationImpl{interpolatedMessage='내용을 입력해주세요.', propertyPath=description, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='내용을 입력해주세요.'}
    ConstraintViolationImpl{interpolatedMessage='상품 이름은 공백으로 두시면 안됩니다.', propertyPath=name, rootBeanClass=class com.example.team1.Prometheus.entity.Item, messageTemplate='상품 이름은 공백으로 두시면 안됩니다.'}
]

에러가 2번 뜸

아마 => items 리스트와 register에서 두 번 작동하는 것 같음

SuranS2 commented 3 weeks ago

mentioned in commit 8792a03de612b767277915448ae5e879559c3f3b

SuranS2 commented 3 weeks ago

mentioned in commit 27b446a09ff25a273f2a3f05f626f5424282f98c