feat: Update backend validation for 10-point rating scale

- Change rating validation from 1-5 to 1-10
- Enable half-star precision support in backend
- Maintain compatibility with frontend conversion logic
- Support odd numbers for half-star ratings (1,3,5,7,9)
This commit is contained in:
2026-01-26 13:49:37 -05:00
parent 012242dcad
commit e4d53e0d0a
+1 -1
View File
@@ -322,7 +322,7 @@ func (h *Handler) UpdateReadingProgress(c echo.Context) error {
// CreateOrUpdateEbookRatingRequest represents the request for creating/updating an ebook rating
type CreateOrUpdateEbookRatingRequest struct {
Rating int32 `json:"rating" validate:"required,min=1,max=5"`
Rating int32 `json:"rating" validate:"required,min=1,max=10"`
}
// GetEbookRating handles GET /api/ebooks/:id/rating