fix:修复部分bug

This commit is contained in:
xcool
2022-10-12 00:02:29 +08:00
parent 96b2fea5cf
commit ab09f5a046
3 changed files with 13 additions and 3 deletions

View File

@@ -321,6 +321,9 @@ watch(() => props.info, (info) => {
// 处理表格data数据
d1.value = info.raw_data.data.map((item, index) => {
for (let i in item) {
if (childrenlist.indexOf(i) > -1 && item[i].value == 0) {
item[i] ="0"
}
if (childrenlist.indexOf(i) > -1 && item[i].value) {
item[i] = item[i].value
}
@@ -350,6 +353,9 @@ watch(() => props.info, (info) => {
})
d2.value = info.zero_data.data.map((item, index) => {
for (let i in item) {
if (childrenlist2.indexOf(i) > -1 && item[i].value == 0) {
item[i] ="0"
}
if (childrenlist2.indexOf(i) > -1 && item[i].value) {
item[i] = item[i].value
}

View File

@@ -451,9 +451,13 @@ export default {
e,
e?.path?.[0]?.getClientRects()[0] || e?.path?.[0]?.getClientRects()
);
try{
rect.value = JSON.parse(
JSON.stringify(e?.path?.[0]?.getClientRects()[0] || e?.path?.[0]?.getClientRects())
);
}
catch{}
if (photoAreaRef2.value) {
photoAreaRef2.value.setRect(rect.value);
}

View File

@@ -64,7 +64,7 @@
<a-input-number
block
class="input-number BPTO-footer-title"
:max="5"
:max="10"
:min="2"
@change="versionInput(infoConfig.config.version)"
v-model:value="infoConfig.config.version"
@@ -340,8 +340,8 @@ export default {
};
const versionInput = (value) => {
if (value < 2 || value > 5) {
return message.error("版本数取值范围为2~5");
if (value < 2 || value > 10) {
return message.error("版本数取值范围为2~10");
}
};