2024-09-09 10:29:41 +02:00
|
|
|
import type { AuditLog } from '$lib/types/audit-log.type';
|
2025-01-11 20:14:12 +01:00
|
|
|
import type { Paginated, SearchPaginationSortRequest } from '$lib/types/pagination.type';
|
2024-09-09 10:29:41 +02:00
|
|
|
import APIService from './api-service';
|
|
|
|
|
|
|
|
|
|
class AuditLogService extends APIService {
|
2025-01-11 20:14:12 +01:00
|
|
|
async list(options?: SearchPaginationSortRequest) {
|
2024-09-09 10:29:41 +02:00
|
|
|
const res = await this.api.get('/audit-logs', {
|
2025-01-11 20:14:12 +01:00
|
|
|
params: options
|
2024-09-09 10:29:41 +02:00
|
|
|
});
|
|
|
|
|
return res.data as Paginated<AuditLog>;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default AuditLogService;
|