refactor(admin): remove separate sidebar, integrate admin nav into main sidebar
- Delete AdminSidebar component entirely - Add Administration section (Dashboard, Libraries, Users, Settings) to header sidebar, visible only for admin users - Remove Admin Panel link from user dropdown - Strip admin chrome (sidebar wrapper, back buttons) from all 5 admin page templates - Fix activeClass to handle trailing-slash routes correctly - Add isUserVisible helper for library visibility toggles - Fix processing issues page: remove dead Alpine JS, wire HTMX dismiss with proper mediaItemId, add issue ID swap targets - Add processing issue resolve/delete routes to library router - Add GetProcessingIssueStatsData context-based method - Fix users page: remove broken hx-headers auth, simplify role select - Fix settings page: remove dead adminSettings Alpine ref
This commit is contained in:
@@ -2,6 +2,7 @@ package handlers
|
||||
|
||||
import (
|
||||
"bookhoard/internal/database"
|
||||
"context"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
@@ -139,3 +140,8 @@ func (h *ProcessingIssuesHandler) DeleteProcessingIssue(c *echo.Context) error {
|
||||
"message": "Issue deleted",
|
||||
})
|
||||
}
|
||||
|
||||
// GetProcessingIssueStatsData returns stats for SSR (not JSON response)
|
||||
func (h *ProcessingIssuesHandler) GetProcessingIssueStatsData(ctx context.Context, libraryID pgtype.UUID) (database.GetProcessingIssueStatsRow, error) {
|
||||
return h.db.GetProcessingIssueStats(ctx, libraryID)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user