Skip to content

Commit

Permalink
checklist: fix default selected item missing issue #2122
Browse files Browse the repository at this point in the history
  • Loading branch information
airyland committed Oct 26, 2017
1 parent c897d42 commit 32bd393
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/components/checklist/index.vue
Expand Up @@ -72,7 +72,7 @@ export default {
return {
currentValue: [],
currentOptions: this.options,
tempValue: ''
tempValue: '' // used only for radio mode
}
},
beforeUpdate () {
Expand All @@ -89,7 +89,9 @@ export default {
this.handleChangeEvent = true
if (this.value) {
this.currentValue = this.value
this.tempValue = this.value ? this.value[0] : ''
if (this.isRadio) {
this.tempValue = this.isRadio ? this.value[0] : this.value
}
}
if (this.randomOrder) {
this.currentOptions = shuffle(this.options)
Expand Down
5 changes: 5 additions & 0 deletions src/components/checklist/metas.yml
Expand Up @@ -71,6 +71,11 @@ events:
en: emits when value changes, param:label is supported after v2.5.7
zh-CN: 值变化时触发,参数为 (value, label),其中 label 参数在 v2.5.7 后支持
changes:
next:
en:
- '[fix] fix default selected item missing issue #2122'
zh-CN:
- '[fix] 修复默认选中项缺失问题 #2122'
v2.6.5:
en:
- '[fix] fix missing icon style when using checklist along #2041'
Expand Down

0 comments on commit 32bd393

Please sign in to comment.