mirror of
https://github.com/dataease/dataease.git
synced 2025-02-27 13:52:53 +08:00
8 lines
240 B
JavaScript
8 lines
240 B
JavaScript
![]() |
// 替换所有 标准模板格式 为 $panelName$
|
||
|
export function pdfTemplateReplaceAll(content, source, target) {
|
||
|
const pattern = '\\$' + source + '\\$'
|
||
|
content = content.replace(new RegExp(pattern, 'gm'), target)
|
||
|
return content
|
||
|
}
|
||
|
|