feat: add CategoryImportController for bulk JSON import and export of categories
- Implemented export functionality to retrieve all rows from specified category tables. - Developed import functionality with strict validation and referential integrity checks. - Added error handling for various import scenarios including invalid formats and duplicate entries. - Introduced tests for import functionality to ensure correct behavior and validation.
This commit is contained in:
@@ -247,3 +247,10 @@ Legacy endpoint that proxies to the new endpoints.
|
||||
|
||||
> ⚠️ Response is **triple-nested**: `data?.data?.data ?? []`
|
||||
> Note: `categorys` (not `categories`) is intentional — legacy route name.
|
||||
|
||||
---
|
||||
|
||||
## Bulk import / export
|
||||
|
||||
Full-table JSON export and strict wipe+replace import for this category live under
|
||||
`/api/v1/admin/categories/{bundle}/{export|import}` — see [category-import.md](category-import.md).
|
||||
|
||||
Reference in New Issue
Block a user