|
@@ -28,7 +28,7 @@ export default function OrderButtonBar({ order, onViewDetail, onCancelOrder }: O
|
|
|
// 取消订单mutation
|
|
// 取消订单mutation
|
|
|
const cancelOrderMutation = useMutation({
|
|
const cancelOrderMutation = useMutation({
|
|
|
mutationFn: async ({ orderId, reason }: { orderId: number; reason: string }) => {
|
|
mutationFn: async ({ orderId, reason }: { orderId: number; reason: string }) => {
|
|
|
- const response = await orderClient.cancelOrder.$post({
|
|
|
|
|
|
|
+ const response = await orderClient['cancel-order'].$post({
|
|
|
json: {
|
|
json: {
|
|
|
orderId,
|
|
orderId,
|
|
|
reason
|
|
reason
|