update 搬迁树节点页面

This commit is contained in:
2021-06-13 19:24:46 +08:00
parent 1db0ce888b
commit 39b46e7959
10 changed files with 841 additions and 33 deletions

View File

@@ -40,5 +40,11 @@ export const toCamelCase = (str) => {
* @param {String} str
*/
export const toUnderScoreCase = (str) => {
if (typeof str === 'string') {
str = str.replace(/[A-Z]/g, (match) => {
return `_${match}`
}).toLowerCase()
return str.startsWith('_') ? str.slice(1) : str
}
return str
}