12f37ec14e
- 清理任务面板/SPA 化改造遗留的未使用变量与函数(模板管理配套 6 函数、 payloadForDisplay/showTip/hasRunning/schedulePoll/removeMatchedRowLocally 等 30+ 处) - 清理未使用 import(getBrandTemplateXlsxUrl/uploadTempFileToJava/getProductRiskTasksBatch 等) - useTaskProgressLoop 改为仅类型导入;progress/task-request 缓存未用参数精简 - DeleteBrandRunService 删除永不执行的 taskItems 死分支 - 全量 vue-tsc(含 --noUnusedLocals/--noUnusedParameters)0 错误;648 测试全过
15 lines
552 B
TypeScript
15 lines
552 B
TypeScript
/**
|
|
* 页面路径环境适配
|
|
*
|
|
* SPA 化(2026-09-08)后所有页面统一为无 .html 后缀的路径(/home、/dedupe …),
|
|
* 生产(https://api.aishufu.top)与 vite dev 前缀一致,无需再区分环境。
|
|
* 旧 MPA 链接形式 /new_web_source/xxx.html 由本模块归一为 /xxx。
|
|
*/
|
|
|
|
/** 归一页面链接:/new_web_source/xxx.html → /xxx;其余原样返回 */
|
|
export function resolvePageHref(rawHref?: string): string {
|
|
if (!rawHref) return ''
|
|
return rawHref.replace(/^\/new_web_source\/(.+)\.html$/, '/$1')
|
|
}
|
|
|