[BE-API-003] be-api: Implement playlist search endpoint
- Added GET /playlists/search route in router.go - Handler SearchPlaylists and service method already existed - Supports query params: q, user_id, is_public, page, limit - Service handles pagination, access control, and search filtering - Route added to protected playlist group Phase: PHASE-2 Priority: P1 Progress: 13/267 (4.9%)
This commit is contained in:
parent
624e397111
commit
ab37bc3596
2 changed files with 13 additions and 2 deletions
|
|
@ -1197,7 +1197,7 @@
|
|||
"completion": {
|
||||
"completed_at": "2025-12-23T00:48:15Z",
|
||||
"actual_hours": 1.0,
|
||||
"commits": [],
|
||||
"commits": ["624e397"],
|
||||
"files_changed": [
|
||||
"veza-backend-api/migrations/930_add_missing_foreign_keys.sql"
|
||||
],
|
||||
|
|
@ -1258,7 +1258,17 @@
|
|||
"description": "GET /api/v1/playlists/search with query params (q, page, limit, user_id, is_public)",
|
||||
"owner": "backend",
|
||||
"estimated_hours": 4,
|
||||
"status": "todo",
|
||||
"status": "completed",
|
||||
"completion": {
|
||||
"completed_at": "2025-12-23T00:49:14Z",
|
||||
"actual_hours": 0.5,
|
||||
"commits": [],
|
||||
"files_changed": [
|
||||
"veza-backend-api/internal/api/router.go"
|
||||
],
|
||||
"notes": "Added GET /playlists/search route in router.go. Handler SearchPlaylists and service method SearchPlaylists already existed and were fully implemented. Handler supports query params: q (search query), user_id (filter by user), is_public (filter by visibility), page, limit. Service handles pagination, access control (public vs private playlists), and search filtering. Route added to protected playlist group.",
|
||||
"issues_encountered": []
|
||||
},
|
||||
"files_involved": [],
|
||||
"implementation_steps": [
|
||||
{
|
||||
|
|
|
|||
|
|
@ -539,6 +539,7 @@ func (r *APIRouter) setupPlaylistRoutes(router *gin.RouterGroup) {
|
|||
{
|
||||
playlists.GET("", playlistHandler.GetPlaylists)
|
||||
playlists.POST("", playlistHandler.CreatePlaylist)
|
||||
playlists.GET("/search", playlistHandler.SearchPlaylists) // BE-API-003: Playlist search endpoint
|
||||
playlists.GET("/:id", playlistHandler.GetPlaylist)
|
||||
|
||||
// BE-SEC-003: Apply ownership middleware for PUT/DELETE /playlists/:id
|
||||
|
|
|
|||
Loading…
Reference in a new issue