16 lines
393 B
TypeScript
16 lines
393 B
TypeScript
|
|
import {
|
||
|
|
httpGetInterceptor,
|
||
|
|
httpPostInterceptor,
|
||
|
|
} from "../http-config/http-interceptor-service";
|
||
|
|
|
||
|
|
export async function listContest(size: number, page: number) {
|
||
|
|
return await httpGetInterceptor(
|
||
|
|
`contest/pagination?enablePage=1&size=${size}&page=${page}`
|
||
|
|
);
|
||
|
|
}
|
||
|
|
|
||
|
|
export async function createTask(data: any) {
|
||
|
|
const url = "assignment";
|
||
|
|
return httpPostInterceptor(url, data);
|
||
|
|
}
|