diff --git a/src/components/GuipSwitch.vue b/src/components/GuipSwitch.vue index 65cdc21..4792c09 100644 --- a/src/components/GuipSwitch.vue +++ b/src/components/GuipSwitch.vue @@ -59,17 +59,15 @@ export default { loading: false, // 加载状态 }; }, - // watch: { - // modelValue(newVal) { - // console.log(newVal,'newVal---'); - // this.internalValue = newVal; - // }, - // }, watch: { value(newVal) { this.internalValue = newVal; }, + modelValue(newVal) { + this.internalValue = newVal; + }, internalValue(newVal) { + this.internalValue = newVal; this.$emit('input', newVal); }, },