Make "want read" button work

This commit is contained in:
2025-11-06 15:53:24 +01:00
parent 6bfd3ae2da
commit a8f83db83f
14 changed files with 268 additions and 100 deletions

View File

@@ -14,11 +14,12 @@ import (
)
type bookUserGet struct {
BookId uint `json:"id"`
Title string `json:"title" binding:"required,max=300"`
Author string `json:"author" binding:"max=100"`
Rating int `json:"rating" binding:"min=0,max=10"`
Read bool `json:"read"`
BookId uint `json:"id"`
Title string `json:"title" binding:"required,max=300"`
Author string `json:"author" binding:"max=100"`
Rating int `json:"rating" binding:"min=0,max=10"`
Read bool `json:"read"`
WantRead bool `json:"wantread"`
}
func TestGetBooksHandler_Demo(t *testing.T) {