v0.2.4: fix ad key-words comma split + deleteAdFiles entry for extensions only

This commit is contained in:
root
2026-05-16 19:49:58 +08:00
parent e38adee8ff
commit b5d3620273
30 changed files with 1458 additions and 335 deletions

View File

@@ -320,6 +320,38 @@ export interface SaveRecord {
}
// ===== 系统配置 =====
/** Save/update per-config notification settings */
export async function saveConfigNotify(
configId: number,
settings: Record<string, any>
): Promise<{ success: boolean; message: string }> {
const { data } = await api.put(`/admin/cloud-configs/${configId}/notify`, settings)
return data
}
/** Get per-config notification settings */
export async function getConfigNotify(
configId: number
): Promise<Record<string, any>> {
const { data } = await api.get(`/admin/cloud-configs/${configId}/notify`)
return data
}
/** Test a notification channel (global or per-config) */
export async function getAllNotifierProviders(): Promise<Record<string, { name: string; label: string; params: { key: string; label: string; type: string; required: boolean; placeholder?: string; default?: any }[] }>> {
const { data } = await api.get('/admin/notify/providers')
return data
}
export async function testNotifyChannel(
channelType: string,
configId?: number
): Promise<{ success: boolean; message: string }> {
const { data } = await api.post('/admin/notify/test', { channelType, configId })
return data
}
export async function getSystemConfigs(): Promise<{ key: string; value: string; description: string }[]> {
const { data } = await api.get('/admin/system-configs')
return data
@@ -438,4 +470,4 @@ export async function emptyAllTrash(): Promise<{
}> {
const { data } = await api.post('/admin/cleanup/empty-trash')
return data
}
}