feat(channels): 渠道管理 - 可视化排序与别名并修复注册及外观清理 (#444)

This commit is contained in:
Ray authored and GitHub committed 2026-09-08 20:56:42 +08:00
1 parent 381edf37e3
commit 8360b2c933
41 files changed
+1485 -148

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
import { apiClient, request } from "./request";
export type ChannelOrderItem = { id: string; name: string; enabled: boolean };
const pathFor = (channelId?: string) => (channelId ? `/admin/channels/${encodeURIComponent(channelId)}/models/order` : "/admin/channels/order");
export const getChannelOrder = (channelId?: string) => request<{ items: ChannelOrderItem[] }>(apiClient.get(pathFor(channelId)));
export const saveChannelOrder = (channelId: string | undefined, ids: string[], expectedIds: string[]) => request<{ saved: boolean }>(apiClient.put(pathFor(channelId), { ids, expectedIds }));