mirror of
				https://github.com/open-metadata/OpenMetadata.git
				synced 2025-11-04 04:29:13 +00:00 
			
		
		
		
	Fixed #868 For Owner already set to a team, "Select owner" list should open with teams tab as active. (#870)
This commit is contained in:
		
							parent
							
								
									3c21edbe75
								
							
						
					
					
						commit
						047c70bc25
					
				@ -70,6 +70,15 @@ const DropDownList: FunctionComponent<DropDownListProp> = ({
 | 
			
		||||
    );
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  const setCurrentTabOnMount = () => {
 | 
			
		||||
    const owner = dropDownList.find((l) => l.value === value);
 | 
			
		||||
    if (owner) {
 | 
			
		||||
      const index = listGroups.indexOf(owner.group as string);
 | 
			
		||||
 | 
			
		||||
      setActiveTab(index >= 0 ? index + 1 : 1);
 | 
			
		||||
    }
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  useEffect(() => {
 | 
			
		||||
    setSearchText(searchString);
 | 
			
		||||
  }, [searchString]);
 | 
			
		||||
@ -100,6 +109,7 @@ const DropDownList: FunctionComponent<DropDownListProp> = ({
 | 
			
		||||
 | 
			
		||||
  useEffect(() => {
 | 
			
		||||
    isMounted.current = true;
 | 
			
		||||
    setCurrentTabOnMount();
 | 
			
		||||
  }, []);
 | 
			
		||||
 | 
			
		||||
  return (
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user