16 lines
438 B
TypeScript
16 lines
438 B
TypeScript
import { client } from "@/shared/api";
|
|
import { ENDPOINT } from "@/shared/config";
|
|
|
|
import type { CnstpSeMngTreeDto, CnstpService } from "../model/cnstp-interface";
|
|
|
|
async function findTree(): Promise<CnstpSeMngTreeDto[]> {
|
|
const response = await client.get<CnstpSeMngTreeDto[]>(
|
|
`${ENDPOINT.AS_COMMON_SERVICE.CNSTP_SE}/list/tree`,
|
|
);
|
|
return response.data;
|
|
}
|
|
|
|
export const cnstpService = {
|
|
findTree,
|
|
} satisfies CnstpService;
|