update 优化用户选择组件 返回值

This commit is contained in:
LiuHao 2024-01-27 18:00:55 +08:00
parent a1526f86cf
commit 6070390a8b

View File

@ -153,14 +153,8 @@ const queryParams = ref<UserQuery>({
});
const confirm = () => {
if (prop.multiple) {
emit('update:modelValue', selectUserList.value);
emit('confirmCallBack', selectUserList.value);
} else {
const data = selectUserList.value.length > 0 ? selectUserList.value[0] : undefined;
emit('update:modelValue', data);
emit('confirmCallBack', data);
}
userDialog.closeDialog();
};