fix radio

This commit is contained in:
cookfront 2017-03-14 16:58:20 +08:00
parent f6c2eec07a
commit 7674d8d562
2 changed files with 10 additions and 2 deletions

View File

@ -6,7 +6,6 @@
}">
<span class="zan-checkbox__input">
<input
ref="input"
v-model="currentValue"
type="checkbox"
class="zan-checkbox__control"

View File

@ -17,7 +17,7 @@
}">
</span>
</span>
<span class="zan-radio__label">
<span class="zan-radio__label" @click="handleLabelClick">
<slot></slot>
</span>
</div>
@ -61,6 +61,15 @@ export default {
? this.parentGroup.disabled || this.disabled
: this.disabled;
}
},
methods: {
handleLabelClick() {
if (this.isDisabled) {
return;
}
this.currentValue = this.name;
}
}
};
</script>