mirror of
https://github.com/Dvorinka/MyClubServer.git
synced 2026-06-04 10:42:57 +00:00
upload
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
import api from '../../services/api';
|
||||
|
||||
export type PrefetchStatus = {
|
||||
lastUpdated?: string;
|
||||
intervalMinutes: number;
|
||||
fastMode: boolean;
|
||||
nextApproximate: string;
|
||||
};
|
||||
|
||||
export async function getPrefetchStatus(): Promise<PrefetchStatus> {
|
||||
const { data } = await api.get('/admin/prefetch/status');
|
||||
return data as PrefetchStatus;
|
||||
}
|
||||
|
||||
export async function triggerPrefetch(): Promise<{ message: string }>{
|
||||
const { data } = await api.post('/admin/prefetch/trigger');
|
||||
return data as { message: string };
|
||||
}
|
||||
Reference in New Issue
Block a user