优化 稿件预览

This commit is contained in:
YuanFeng 2024-10-09 10:15:53 +08:00
parent 0828d7376b
commit 932fbf9015
2 changed files with 16 additions and 2 deletions

View File

@ -394,7 +394,14 @@ const changeData = (index: number, key: string) => {
for (let i = 0; i < that.propInfo[key].dataInfo.length; i++) {
for (let j = 0; j < mapping.length; j++) {
if (that.propInfo[key].dataInfo[i].locale === mapping[j].locale) {
that.propInfo[key].dataInfo[i].label = mapping[j].value
let str = that.propInfo[key].dataInfo[0].ratio;
if (str === null || str === undefined || str === -1) {
str = ''
}
const value = `${mapping[j].value}`.replaceAll('${r}', str)
console.log("value",value)
that.propInfo[key].dataInfo[i].label = value
break;
}
}

View File

@ -394,7 +394,14 @@ const changeData = (index: number, key: string) => {
for (let i = 0; i < that.propInfo[key].dataInfo.length; i++) {
for (let j = 0; j < mapping.length; j++) {
if (that.propInfo[key].dataInfo[i].locale === mapping[j].locale) {
that.propInfo[key].dataInfo[i].label = mapping[j].value
let str = that.propInfo[key].dataInfo[0].ratio;
if (str === null || str === undefined || str === -1) {
str = ''
}
const value = `${mapping[j].value}`.replaceAll('${r}', str)
console.log("value",value)
that.propInfo[key].dataInfo[i].label = value
break;
}
}