Add web UI to enable/disable plugins

GET /api/plugins now lists all discovered plugins (enabled or not) with status;
PUT /api/plugins/<name> toggles enabled (persists to plugins.json). New
Settings > Plugins admin page with per-plugin toggles. Route changes apply on
next restart. Replaces CLI-only enable/disable for self-serve admin.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
cproudlock
2026-06-26 15:01:14 -04:00
parent 4f1638bda0
commit 59ef0220b5
5 changed files with 200 additions and 20 deletions

View File

@@ -674,6 +674,15 @@ export const employeesApi = {
export const businessUnitsApi = businessunitsApi
// System Settings API
export const pluginsApi = {
list() {
return api.get('/plugins')
},
setEnabled(name, enabled) {
return api.put(`/plugins/${name}`, { enabled })
}
}
export const settingsApi = {
list(params = {}) {
return api.get('/settings', { params })