feat(tags): match add-tag modal to tauri design (preset swatches + active toggle)
- TagsSettingsPage modal: replace native color input with 4 preset swatches, add 'وضعیت برچسب' active toggle, update labels and submit button to mirror tauri AddPurchaseSubTabModal - TenantTagController::create now honors an optional 'active' flag (defaults true, non-breaking for existing callers) - tests: backend active-flag case, frontend preset-color + inactive case - docs/api/tag.md: document the new create 'active' field Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+2
-1
@@ -158,12 +158,13 @@ Without `sort`, the default ordering (weight/name) is unchanged.
|
||||
|
||||
### POST `/api/v1/tenant-tag`
|
||||
```json
|
||||
{ "name": "فوری", "color": "#FF0000" }
|
||||
{ "name": "فوری", "color": "#FF0000", "active": true }
|
||||
```
|
||||
| Field | Type | Required | Validation |
|
||||
|-------|------|----------|------------|
|
||||
| `name` | string | ✅ | غیرخالی، حداکثر ۶۰ |
|
||||
| `color` | string | ❌ | هگز `#RRGGBB` یا `#RRGGBBAA` (پیشفرض `#5559CE`) |
|
||||
| `active` | bool | ❌ | وضعیت اولیه (پیشفرض `true`) |
|
||||
|
||||
Response `201`: TenantTag object.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user