refactor: 提示与确认框改用 App 上下文实例
CI / Static checks (push) Has been cancelled
CI / Production build (push) Has been cancelled
CI / API integration (push) Has been cancelled
CI / Taro builds (acheng-campus-food) (push) Has been cancelled
CI / Taro builds (atelier-solopreneur) (push) Has been cancelled
CI / Taro builds (linjing-editorial) (push) Has been cancelled
CI / Browser regression (push) Has been cancelled

This commit is contained in:
que01 committed 2026-10-21 10:34:34 +08:00
1 parent 3a0099e674
commit 06619a191f
22 files changed
+167 -27

No files matched your search

@@ -1,5 +1,5 @@
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import { message } from "antd";
import { App } from "antd";
import { createApiClient } from "../../../lib/api.js";
import { readAdminCapability } from "../types.js";
import type { CapabilityValues } from "../types.js";
@@ -17,6 +17,7 @@ export function useCapabilityQuery() {
}
export function useCapabilityMutation() {
const { message } = App.useApp();
const queryClient = useQueryClient();
return useMutation({
mutationFn: ({ key, ...values }: { key: string } & CapabilityValues) =>