mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-03 12:08:31 +00:00
fix(ui): supported announcement in pending entities (#13414)
* supported announcement in pending entities * added announcement support in database, database schema and entity services
This commit is contained in:
parent
5a3d759b48
commit
eb89d789bf
@ -114,6 +114,7 @@ const FeedCardHeader: FC<FeedHeaderProp> = ({
|
||||
{t('message.made-announcement-for-entity', { entity: entityType })}{' '}
|
||||
<EntityPopOverCard entityFQN={entityFQN} entityType={entityType}>
|
||||
<Link
|
||||
className="break-all"
|
||||
data-testid="entitylink"
|
||||
to={prepareFeedLink(entityType, entityFQN)}>
|
||||
{entityDisplayName(entityType, entityFQN)}
|
||||
|
||||
@ -254,9 +254,11 @@ export const DataAssetsHeader = ({
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
if (dataAsset.fullyQualifiedName && !isTourPage && !excludeEntityService) {
|
||||
if (dataAsset.fullyQualifiedName && !isTourPage) {
|
||||
fetchActiveAnnouncement();
|
||||
fetchTaskCount();
|
||||
if (!excludeEntityService) {
|
||||
fetchTaskCount();
|
||||
}
|
||||
}
|
||||
if (entityType === EntityType.CONTAINER) {
|
||||
const asset = dataAsset as Container;
|
||||
|
||||
@ -60,10 +60,11 @@ const AnnouncementDrawer: FC<Props> = ({
|
||||
|
||||
const title = (
|
||||
<Space
|
||||
align="start"
|
||||
className="justify-between"
|
||||
data-testid="title"
|
||||
style={{ width: '100%' }}>
|
||||
<Typography.Text className="font-medium">
|
||||
<Typography.Text className="font-medium break-all">
|
||||
{t('label.announcement-on-entity', { entity: entityName })}
|
||||
</Typography.Text>
|
||||
<CloseOutlined onClick={onClose} />
|
||||
|
||||
@ -19,7 +19,20 @@ export const ANNOUNCEMENT_ENTITIES = [
|
||||
EntityType.TOPIC,
|
||||
EntityType.PIPELINE,
|
||||
EntityType.MLMODEL,
|
||||
EntityType.CONTAINER,
|
||||
EntityType.DASHBOARD_DATA_MODEL,
|
||||
EntityType.STORED_PROCEDURE,
|
||||
EntityType.SEARCH_INDEX,
|
||||
EntityType.DATABASE,
|
||||
EntityType.DATABASE_SCHEMA,
|
||||
EntityType.DATABASE_SERVICE,
|
||||
EntityType.MESSAGING_SERVICE,
|
||||
EntityType.DASHBOARD_SERVICE,
|
||||
EntityType.PIPELINE_SERVICE,
|
||||
EntityType.MLMODEL_SERVICE,
|
||||
EntityType.STORAGE_SERVICE,
|
||||
EntityType.METADATA_SERVICE,
|
||||
EntityType.SEARCH_SERVICE,
|
||||
];
|
||||
|
||||
export const isActiveAnnouncement = (startTime: number, endTime: number) => {
|
||||
|
||||
@ -570,6 +570,10 @@ export const entityDisplayName = (entityType: string, entityFQN: string) => {
|
||||
EntityType.DASHBOARD_SERVICE,
|
||||
EntityType.MESSAGING_SERVICE,
|
||||
EntityType.PIPELINE_SERVICE,
|
||||
EntityType.MLMODEL_SERVICE,
|
||||
EntityType.METADATA_SERVICE,
|
||||
EntityType.STORAGE_SERVICE,
|
||||
EntityType.SEARCH_SERVICE,
|
||||
EntityType.TYPE,
|
||||
EntityType.MLMODEL,
|
||||
].includes(entityType as EntityType)
|
||||
|
||||
@ -242,6 +242,10 @@ export const getEntityLink = (
|
||||
case EntityType.DASHBOARD_SERVICE:
|
||||
case EntityType.MESSAGING_SERVICE:
|
||||
case EntityType.PIPELINE_SERVICE:
|
||||
case EntityType.MLMODEL_SERVICE:
|
||||
case EntityType.METADATA_SERVICE:
|
||||
case EntityType.STORAGE_SERVICE:
|
||||
case EntityType.SEARCH_SERVICE:
|
||||
return getServiceDetailsPath(fullyQualifiedName, `${indexType}s`);
|
||||
|
||||
case EntityType.WEBHOOK:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user