mirror of
				https://gitee.com/lab1024/smart-admin.git
				synced 2025-11-04 18:33:43 +08:00 
			
		
		
		
	修改DictSelect组件onChange事件
This commit is contained in:
		@@ -102,17 +102,7 @@
 | 
			
		||||
  const emit = defineEmits(['update:value', 'change']);
 | 
			
		||||
 | 
			
		||||
  function onChange(value) {
 | 
			
		||||
    if (!value) {
 | 
			
		||||
      emit('update:value', []);
 | 
			
		||||
      emit('change', []);
 | 
			
		||||
      return;
 | 
			
		||||
    }
 | 
			
		||||
    if (Array.isArray(value)) {
 | 
			
		||||
    emit('update:value', value);
 | 
			
		||||
    emit('change', value);
 | 
			
		||||
    } else {
 | 
			
		||||
      emit('update:value', [value]);
 | 
			
		||||
      emit('change', [value]);
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
</script>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user