Commit cbf8e834 authored by 肖重湘's avatar 肖重湘

解决鸿蒙设备 type=digit二次渲染输入无效bug

parent cbce2ba9
......@@ -54,7 +54,9 @@
<view class="item-view">
<view class="label-view">单价</view>
<view class="value-view">
<!-- v-if="show" 解决鸿蒙设备 type="digit"二次渲染输入无效bug-->
<u-input
v-if="show"
type="digit"
:clearable="false"
:custom-style="customStyle"
......@@ -159,7 +161,7 @@ export default {
},
disabled() {
let flag = false;
this.rules.map(item => {
this.rules.map((item) => {
if (!this.form[item.value]) {
flag = true;
}
......@@ -168,7 +170,7 @@ export default {
}
},
created() {
uni.$on('charge-selected', res => {
uni.$on('charge-selected', (res) => {
var form = JSON.parse(res || {});
this.form.unit = form.unit;
this.form.name = form.serviceName;
......@@ -180,17 +182,13 @@ export default {
methods: {
open(detail) {
if (detail && detail.uid) {
this.form = {
...detail
};
}else{
this.form = {
...this.defaultInfo
};
this.form = JSON.parse(JSON.stringify(detail));
} else {
this.form = JSON.parse(JSON.stringify(this.defaultInfo));
}
// this.$nextTick(() => {
this.$nextTick(() => {
this.show = true;
// });
});
},
close() {
this.show = false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment