feat: map初始化
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import { ElMessageBox } from 'element-plus'
|
||||
import i18n from '@/i18n'
|
||||
import _ from 'lodash'
|
||||
|
||||
export const tableSort = {
|
||||
// 是否需要排序
|
||||
@@ -376,3 +377,11 @@ export function calculateTextWidth (text, fontSize = 14) {
|
||||
html.innerText = text
|
||||
return html.offsetWidth
|
||||
}
|
||||
|
||||
/* url占位符处理 */
|
||||
export function replaceUrlPlaceholder (url, params) {
|
||||
_.forIn(params, (value, key) => {
|
||||
url = url.replace('{{' + key + '}}', value)
|
||||
})
|
||||
return url
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user