mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-01 02:56:10 +00:00
parent
b781c66206
commit
079f78c558
@ -109,12 +109,15 @@ const GlossaryTermsV1 = ({
|
||||
tab !== 'assets' && activeTabHandler('assets');
|
||||
}, [assetTabRef, tab]);
|
||||
|
||||
const onExtensionUpdate = async (updatedTable: GlossaryTerm) => {
|
||||
await handleGlossaryTermUpdate({
|
||||
...glossaryTerm,
|
||||
extension: updatedTable.extension,
|
||||
});
|
||||
};
|
||||
const onExtensionUpdate = useCallback(
|
||||
async (updatedTable: GlossaryTerm) => {
|
||||
await handleGlossaryTermUpdate({
|
||||
...glossaryTerm,
|
||||
extension: updatedTable.extension,
|
||||
});
|
||||
},
|
||||
[glossaryTerm, handleGlossaryTermUpdate]
|
||||
);
|
||||
|
||||
const tabItems = useMemo(() => {
|
||||
const items = [
|
||||
@ -241,6 +244,7 @@ const GlossaryTermsV1 = ({
|
||||
isVersionView,
|
||||
assetPermissions,
|
||||
handleAssetSave,
|
||||
onExtensionUpdate,
|
||||
]);
|
||||
|
||||
const fetchGlossaryTermAssets = async () => {
|
||||
|
||||
@ -34,6 +34,7 @@ import {
|
||||
getDiffByFieldName,
|
||||
getUpdatedExtensionDiffFields,
|
||||
} from '../../../utils/EntityVersionUtils';
|
||||
import { getDecodedFqn } from '../../../utils/StringsUtils';
|
||||
import { showErrorToast } from '../../../utils/ToastUtils';
|
||||
import { usePermissionProvider } from '../../PermissionProvider/PermissionProvider';
|
||||
import {
|
||||
@ -67,11 +68,12 @@ export const CustomPropertyTable = <T extends ExtentionEntitiesKeys>({
|
||||
const [entityTypeDetailLoading, setEntityTypeDetailLoading] =
|
||||
useState<boolean>(false);
|
||||
const { fqn } = useParams<{ fqn: string; tab: string; version: string }>();
|
||||
const decodedeFqn = getDecodedFqn(fqn);
|
||||
|
||||
const fetchExtentiondetails = async () => {
|
||||
const response = await getEntityExtentionDetailsFromEntityType<T>(
|
||||
entityType,
|
||||
fqn
|
||||
decodedeFqn
|
||||
);
|
||||
|
||||
setExtentionDetails(response as ExtentionEntities[T]);
|
||||
@ -79,7 +81,7 @@ export const CustomPropertyTable = <T extends ExtentionEntitiesKeys>({
|
||||
|
||||
useEffect(() => {
|
||||
fetchExtentiondetails();
|
||||
}, [fqn]);
|
||||
}, [decodedeFqn]);
|
||||
|
||||
const [typePermission, setPermission] = useState<OperationPermission>();
|
||||
const versionDetails = entityDetails ?? extentionDetails;
|
||||
@ -128,7 +130,7 @@ export const CustomPropertyTable = <T extends ExtentionEntitiesKeys>({
|
||||
setExtentionDetails(updatedData);
|
||||
}
|
||||
},
|
||||
[versionDetails]
|
||||
[versionDetails, handleExtensionUpdate]
|
||||
);
|
||||
|
||||
const extensionObject: {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user