Build [v1.4.0] - Audit Dashboard & LDAP Restoration

This commit is contained in:
Daniel Bedeleanu
2026-04-12 09:39:17 +03:00
parent 5cceba21f4
commit f3d861b1a2
23 changed files with 973 additions and 382 deletions

View File

@@ -164,5 +164,31 @@ export const inventoryApi = {
deleteCategory: async (id: number) => {
const res = await axiosInstance.delete(`/categories/${id}`);
return res.data;
},
// Database Management
getDbBackups: async () => {
const res = await axiosInstance.get('/admin/db/backups');
return res.data;
},
getDbStats: async () => {
const res = await axiosInstance.get('/admin/db/stats');
return res.data;
},
triggerBackup: async () => {
const res = await axiosInstance.post('/admin/db/backup');
return res.data;
},
restoreDatabase: async (filename: string) => {
const res = await axiosInstance.post('/admin/db/restore', { filename, confirm: true });
return res.data;
},
getDbSettings: async () => {
const res = await axiosInstance.get('/admin/db/settings');
return res.data;
},
updateDbSettings: async (settings: any) => {
const res = await axiosInstance.patch('/admin/db/settings', settings);
return res.data;
}
};