feat: 初始提交

This commit is contained in:
siujamo
2025-12-25 16:12:01 +08:00
commit faff32475f
77 changed files with 6123 additions and 0 deletions
+13
View File
@@ -0,0 +1,13 @@
import webClient from "@/service/web-client"
import type { TreeNode } from "@/types/tree"
import type { Department } from "@/types/entity"
export async function fetchDepartmentTree(): Promise<TreeNode<Department>> {
const { data } = await webClient.get<TreeNode<Department>>("/departments/tree")
return data
}
export async function fetchDepartments(): Promise<Department[]> {
const { data } = await webClient.get<Department[]>("/departments")
return data
}