mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 04:46:40 +07:00
loading node
This commit is contained in:
parent
da9ac62584
commit
a0272f5baa
4 changed files with 28 additions and 5 deletions
|
@ -23,3 +23,13 @@ export const getNodes = ({
|
|||
.get(API.NODE.GET, { params: { skip } })
|
||||
.then(resultMiddleware)
|
||||
.catch(errorMiddleware);
|
||||
|
||||
export const getNode = ({
|
||||
id,
|
||||
}: {
|
||||
id: string | number;
|
||||
}): Promise<IResultWithStatus<{ nodes: INode[] }>> =>
|
||||
api
|
||||
.get(API.NODE.GET_NODE(id))
|
||||
.then(resultMiddleware)
|
||||
.catch(errorMiddleware);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue