物业之前,新工作台
This commit is contained in:
@@ -106,7 +106,7 @@ const props = defineProps<{
|
||||
|
||||
// ✅ 手动设置默认值(替代 withDefaults)
|
||||
const isMultiple = computed(() => props.isMultiple ?? false);
|
||||
const returnvalue = computed(() => props.returnvalue ?? 'userId'); // 👈 默认 userId
|
||||
const returnvalue = computed(() => props.returnvalue ?? 'id'); // 👈 默认 userId
|
||||
|
||||
const { userid } = toRefs(props);
|
||||
|
||||
@@ -267,6 +267,7 @@ function confirm() {
|
||||
// ✅ 返回整个对象
|
||||
emit('change', multipleSelection.value[0]);
|
||||
} else {
|
||||
console.log(multipleSelection.value[0], returnvalue.value);
|
||||
// 返回指定字段
|
||||
emit('change', multipleSelection.value[0][returnvalue.value as keyof tableType]);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user