fix: 3D 模块数字输入限制
This commit is contained in:
@@ -189,7 +189,7 @@
|
|||||||
:min="1"
|
:min="1"
|
||||||
:max="100000"
|
:max="100000"
|
||||||
:value="configTemp.show_time"
|
:value="configTemp.show_time"
|
||||||
@update:value="(val) => configTemp.show_time = Number(val).toFixed(0)"
|
@update:value="updateShowTime"
|
||||||
:formatter="value => `${value}秒`"
|
:formatter="value => `${value}秒`"
|
||||||
:parser="value => value.replace('秒', '')"
|
:parser="value => value.replace('秒', '')"
|
||||||
style="width: 80px; border-radius: 4px;"
|
style="width: 80px; border-radius: 4px;"
|
||||||
@@ -219,7 +219,7 @@
|
|||||||
<a-input-number
|
<a-input-number
|
||||||
:min="2"
|
:min="2"
|
||||||
:value="configTemp.disable_lines_same"
|
:value="configTemp.disable_lines_same"
|
||||||
@update:value="(val) => configTemp.disable_lines_same = Number(val).toFixed(0)"
|
@update:value="updateDisableLinesSame"
|
||||||
:formatter="value => `${value}次`"
|
:formatter="value => `${value}次`"
|
||||||
:parser="value => value.replace('次', '')"
|
:parser="value => value.replace('次', '')"
|
||||||
style="width: 80px; border-radius: 4px;"
|
style="width: 80px; border-radius: 4px;"
|
||||||
@@ -449,6 +449,18 @@ export default {
|
|||||||
this.onUpdate();
|
this.onUpdate();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// 限制时间 更新
|
||||||
|
updateShowTime(val) {
|
||||||
|
if(!val) return;
|
||||||
|
this.configTemp.show_time = Number(val).toFixed(0);
|
||||||
|
},
|
||||||
|
|
||||||
|
// 连选次数 更新
|
||||||
|
updateDisableLinesSame(val) {
|
||||||
|
if(!val) return;
|
||||||
|
this.configTemp.disable_lines_same = Number(val).toFixed(0);
|
||||||
|
},
|
||||||
|
|
||||||
onUpdate() {
|
onUpdate() {
|
||||||
this.$emit("update:config", this.configTemp);
|
this.$emit("update:config", this.configTemp);
|
||||||
this.$emit("changeConfig", this.configTemp);
|
this.$emit("changeConfig", this.configTemp);
|
||||||
|
|||||||
Reference in New Issue
Block a user