diff --git a/public/pages/Dashboard/components/DashboardEmptyPrompt/DashboardEmptyPrompt.js b/public/pages/Dashboard/components/DashboardEmptyPrompt/DashboardEmptyPrompt.js
index edb18a595..554256c7f 100644
--- a/public/pages/Dashboard/components/DashboardEmptyPrompt/DashboardEmptyPrompt.js
+++ b/public/pages/Dashboard/components/DashboardEmptyPrompt/DashboardEmptyPrompt.js
@@ -10,6 +10,7 @@ import { EuiSmallButton, EuiSmallButtonEmpty, EuiEmptyPrompt, EuiText } from '@e
import { APP_PATH } from '../../../../utils/constants';
import { MONITORS_NAV_ID } from '../../../../../utils/constants';
import { getUseUpdatedUx } from '../../../../services';
+import { getURL } from '../../../utils/helpers';
const createMonitorText =
'There are no existing alerts. Create a monitor to add triggers and actions. Once an alarm is triggered, the state will show in this table.';
@@ -18,10 +19,13 @@ const createTriggerText =
const editTriggerConditionsText =
'There are no existing alerts. Adjust trigger conditions to start alerting. Once an alarm is triggered, the state will show in this table.';
-const getCreateMonitorButton = () => (
+const getCreateMonitorButton = (landingDataSourceId) => (
Create monitor
@@ -30,7 +34,7 @@ const editMonitorButton = (onCreateTrigger) => (
Edit monitor
);
-const DashboardEmptyPrompt = ({ onCreateTrigger, isModal = false }) => {
+const DashboardEmptyPrompt = ({ onCreateTrigger, landingDataSourceId, isModal = false }) => {
const inMonitorDetails = typeof onCreateTrigger === 'function';
const displayText = isModal
? editTriggerConditionsText
@@ -41,7 +45,7 @@ const DashboardEmptyPrompt = ({ onCreateTrigger, isModal = false }) => {
? undefined
: isModal
? editMonitorButton(onCreateTrigger)
- : getCreateMonitorButton();
+ : getCreateMonitorButton(landingDataSourceId);
return (
{
DashboardEmptyPrompt.propTypes = {
onCreateTrigger: PropTypes.func,
+ landingDataSourceId: PropTypes.string
};
export default DashboardEmptyPrompt;
diff --git a/public/pages/Dashboard/containers/Dashboard.js b/public/pages/Dashboard/containers/Dashboard.js
index 2005bee81..c29ea303b 100644
--- a/public/pages/Dashboard/containers/Dashboard.js
+++ b/public/pages/Dashboard/containers/Dashboard.js
@@ -581,7 +581,12 @@ export default class Dashboard extends Component {
isSelectable={true}
selection={selection}
onChange={this.onTableChange}
- noItemsMessage={}
+ noItemsMessage={
+
+ }
data-test-subj={'alertsDashboard_table'}
/>