We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f12aa4 commit f63de5bCopy full SHA for f63de5b
1 file changed
src/uni_modules/wot-design-uni/components/wd-drop-menu-item/wd-drop-menu-item.vue
@@ -128,9 +128,10 @@ function choose(index: number) {
128
if (props.disabled) return
129
const { valueKey } = props
130
const item = props.options[index]
131
- emit('update:modelValue', item[valueKey] !== '' && item[valueKey] !== undefined ? item[valueKey] : item)
+ const newValue = item[valueKey] !== undefined ? item[valueKey] : item
132
+ emit('update:modelValue', newValue)
133
emit('change', {
- value: item[valueKey] !== '' && item[valueKey] !== undefined ? item[valueKey] : item,
134
+ value: newValue,
135
selectedItem: item
136
})
137
close()
0 commit comments