mirror of
https://github.com/dataease/dataease.git
synced 2026-05-14 21:12:33 +08:00
fix: 嵌入式div方式在动态访问路径场景下静态资源路径错误
This commit is contained in:
@@ -99,6 +99,10 @@ htmlStream.pipe(parserStream).on('finish', () => {
|
||||
}
|
||||
if (url.includes(suffix)) {
|
||||
prefix = new URL(url).origin
|
||||
const index = url.indexOf(\`/js/div_import_${suffix}\`)
|
||||
if (index > 0) {
|
||||
prefix = url.substring(0, index)
|
||||
}
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,6 +37,10 @@ const getPrefix = (): string => {
|
||||
}
|
||||
if (url.includes(suffix)) {
|
||||
prefix = new URL(url).origin
|
||||
const index = url.indexOf(`/js/div_import_${suffix}`)
|
||||
if (index > 0) {
|
||||
prefix = url.substring(0, index)
|
||||
}
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user