Implement complete API routes and mock authentication for full CMS functionality
- Add comprehensive nested route structure with proper authentication layers - Implement UpdateContent and ReorderCollectionItems handlers with repository pattern - Add automatic mock JWT token fetching for seamless development workflow - Restore content editing and collection reordering functionality broken after database refactoring - Provide production-ready authentication architecture with development convenience - Enable full CMS operations in browser with proper CRUD and bulk transaction support
This commit is contained in:
@@ -202,6 +202,14 @@ func (c *HTTPClient) CreateCollectionItemAtomic(ctx context.Context, siteID, col
|
||||
return nil, fmt.Errorf("collection operations not implemented in HTTPClient")
|
||||
}
|
||||
|
||||
func (c *HTTPClient) UpdateContent(ctx context.Context, siteID, contentID, htmlContent, lastEditedBy string) (*db.ContentItem, error) {
|
||||
return nil, fmt.Errorf("content update operations not implemented in HTTPClient")
|
||||
}
|
||||
|
||||
func (c *HTTPClient) ReorderCollectionItems(ctx context.Context, siteID, collectionID string, items []db.CollectionItemPosition, lastEditedBy string) error {
|
||||
return fmt.Errorf("collection reordering not implemented in HTTPClient")
|
||||
}
|
||||
|
||||
// WithTransaction executes a function within a transaction (not supported for HTTP client)
|
||||
func (c *HTTPClient) WithTransaction(ctx context.Context, fn func(db.ContentRepository) error) error {
|
||||
return fmt.Errorf("transactions not supported for HTTP client")
|
||||
|
||||
Reference in New Issue
Block a user