mirror of
https://github.com/pterodactyl/panel.git
synced 2026-12-05 22:05:47 -05:00
ui(admin): fix server startup variables
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Model, UUID, WithRelationships, withRelationships } from '@/api/admin/index';
|
||||
import { Location } from '@/api/admin/location';
|
||||
import http from '@/api/http';
|
||||
import http, { QueryBuilderParams, withQueryBuilderParams } from '@/api/http';
|
||||
import { AdminTransformers } from '@/api/admin/transformers';
|
||||
import { Server } from '@/api/admin/server';
|
||||
|
||||
@@ -66,3 +66,11 @@ export const getNode = async (id: string | number): Promise<WithRelationships<No
|
||||
|
||||
return withRelationships(AdminTransformers.toNode(data.data), 'location');
|
||||
};
|
||||
|
||||
export const searchNodes = async (params: QueryBuilderParams<'name'>): Promise<Node[]> => {
|
||||
const { data } = await http.get('/api/application/nodes', {
|
||||
params: withQueryBuilderParams(params),
|
||||
});
|
||||
|
||||
return data.data.map(AdminTransformers.toNode);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user