diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Pagination.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Pagination.spec.ts index abd2acf954ad..679a833d0a9f 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Pagination.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Pagination.spec.ts @@ -381,13 +381,10 @@ test.describe('Pagination Tests', PLAYWRIGHT_BASIC_TEST_TAG_OBJ, () => { page, }) => { await page.goto('/settings/notifications/alerts'); - // Skip row count validation because ActivityFeedAlert system alert is added on page 1 await testPaginationNavigation( page, '/api/v1/events/subscriptions', - 'table', - true, - false + 'table' ); }); }); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/NotificationBox/NotificationBox.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/NotificationBox/NotificationBox.interface.ts index b68af01004fd..5be1aeb549ad 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/NotificationBox/NotificationBox.interface.ts +++ b/openmetadata-ui/src/main/resources/ui/src/components/NotificationBox/NotificationBox.interface.ts @@ -19,3 +19,4 @@ export interface NotificationBoxProp { onMarkTaskNotificationRead: () => void; onTabChange: (key: string) => void; } + diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx index 1e9c432e6529..194d8fe7b078 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx @@ -150,15 +150,17 @@ const NotificationListPage = () => { async (params?: Partial) => { setLoadingCount((count) => count + 1); try { + const isFirstPage = + isUndefined(params?.after) && isUndefined(params?.before); const { data, paging } = await getAllAlerts({ after: params?.after, before: params?.before, - limit: pageSize, + limit: isFirstPage ? pageSize - 1 : pageSize, alertType: AlertType.Notification, }); - if (isUndefined(params?.after)) { - // Fetch and show the system created activity feed alert when fetching results fro page 1 + if (isFirstPage) { + // Fetch and show the system created activity feed alert on page 1 const activityFeedAlert = await getAlertsFromName( 'ActivityFeedAlert' );