1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-24 20:36:40 +07:00

added optional sorting to lab

This commit is contained in:
Fedor Katurov 2022-03-23 17:08:41 +07:00
parent 04ea68d94e
commit 566e1192cd
5 changed files with 21 additions and 9 deletions

View file

@ -7,9 +7,9 @@ import {
} from '~/types/lab';
import { api, cleanResult } from '~/utils/api';
export const getLabNodes = ({ after }: GetLabNodesRequest) =>
export const getLabNodes = ({ after, sort }: GetLabNodesRequest) =>
api
.get<GetLabNodesResult>(API.LAB.NODES, { params: { after } })
.get<GetLabNodesResult>(API.LAB.NODES, { params: { after, sort } })
.then(cleanResult);
export const getLabStats = () => api.get<GetLabStatsResult>(API.LAB.STATS).then(cleanResult);