Current state
This commit is contained in:
45
docs/categories.md
Normal file
45
docs/categories.md
Normal file
@@ -0,0 +1,45 @@
|
||||
# SkinBase – Category System (NEW SQL Structure)
|
||||
|
||||
This document defines the **new category & taxonomy system** for SkinBase.
|
||||
Copilot AI Agent must follow this structure strictly and MUST NOT reuse legacy logic.
|
||||
|
||||
---
|
||||
|
||||
## 🎯 Goals
|
||||
|
||||
- SEO-friendly URLs (no IDs in public routes)
|
||||
- Clear separation of content types (Photography, Skins, Wallpapers, etc.)
|
||||
- Unlimited category nesting
|
||||
- Laravel-friendly (Eloquent, migrations, relations)
|
||||
- Ready for sitemap, breadcrumbs, translations
|
||||
|
||||
---
|
||||
|
||||
## 🚫 Legacy System (DO NOT USE)
|
||||
|
||||
The old table `artworks_categories` is deprecated.
|
||||
|
||||
DO NOT:
|
||||
- use `section_id`
|
||||
- use `rootid`
|
||||
- use `num_artworks`
|
||||
- expose IDs in URLs
|
||||
- infer hierarchy from numeric hacks
|
||||
|
||||
---
|
||||
|
||||
## ✅ New Database Structure
|
||||
|
||||
### 1️⃣ content_types
|
||||
|
||||
Top-level sections (URL level 1)
|
||||
|
||||
```sql
|
||||
CREATE TABLE content_types (
|
||||
id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
|
||||
name VARCHAR(64) NOT NULL,
|
||||
slug VARCHAR(64) NOT NULL UNIQUE,
|
||||
description TEXT NULL,
|
||||
created_at TIMESTAMP NULL,
|
||||
updated_at TIMESTAMP NULL
|
||||
) ENGINE=InnoDB;
|
||||
Reference in New Issue
Block a user