Schema-Setup-Button + Deploy-Fix-Notiz
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -46,7 +46,8 @@
|
|||||||
"mcp__directus__read-fields",
|
"mcp__directus__read-fields",
|
||||||
"mcp__directus__create-field",
|
"mcp__directus__create-field",
|
||||||
"mcp__directus__update-field",
|
"mcp__directus__update-field",
|
||||||
"mcp__directus__read-collections"
|
"mcp__directus__read-collections",
|
||||||
|
"mcp__directus__create-item"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -315,6 +315,22 @@ export default function GenerateIt() {
|
|||||||
{generateError}
|
{generateError}
|
||||||
</span>
|
</span>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
<div style={{ width: 1, height: 24, background: 'var(--border)' }} />
|
||||||
|
|
||||||
|
<button
|
||||||
|
className="btn-ghost btn-sm"
|
||||||
|
title="Directus-Schema einmalig konfigurieren (M2M-Relationen)"
|
||||||
|
onClick={async () => {
|
||||||
|
if (!token) return
|
||||||
|
const res = await fetch('/api/setup-schema', { method: 'POST', headers: { Authorization: `Bearer ${token}` } })
|
||||||
|
const d = await res.json()
|
||||||
|
alert(`Setup: ${d.total} Schritte, ${d.failed} Fehler.\nSiehe Konsole für Details.`)
|
||||||
|
console.log('[setup-schema]', d)
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
⚙ Schema
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user