feat: 添加banner页面 添加菜单

This commit is contained in:
ZhuRui
2026-07-25 09:39:56 +08:00
parent 03f1b6c220
commit 3b4dd72b11
25 changed files with 2561 additions and 157 deletions
+27
View File
@@ -0,0 +1,27 @@
import { get } from '@/utils/request';
import type { OssUploadTypeValue } from '@/utils/oss';
/** OSS 签名数据 */
export interface OssSignData {
host: string;
dir: string;
policy: string;
signature: string;
x_oss_credential: string;
x_oss_date: string;
security_token: string;
}
/**
* 获取 OSS 上传签名
* @param type 上传类型(参见 OssUploadType
*/
export async function fetchOssSign(type: OssUploadTypeValue): Promise<OssSignData> {
// 后端签名接口地址(待对接时调整)
const res: any = await get('/sys/oss/getUploadSign', { type });
const data = res?.data as OssSignData;
if (!data?.host) {
throw new Error(res?.msg || '获取上传凭证失败');
}
return data;
}