diff --git a/src/PresentationalComponents/PathwaysTable/PathwaysTable.cy.js b/src/PresentationalComponents/PathwaysTable/PathwaysTable.cy.js
index dbcb542d9..d66e1e384 100644
--- a/src/PresentationalComponents/PathwaysTable/PathwaysTable.cy.js
+++ b/src/PresentationalComponents/PathwaysTable/PathwaysTable.cy.js
@@ -67,6 +67,14 @@ describe('Pathways table tests', () => {
it('renders table header', () => {
checkTableHeaders(TABLE_HEADERS);
});
+ it('links to the pathway detail page', () => {
+ cy.get('tbody tr:first [data-label=Name] a')
+ .should('have.attr', 'href')
+ .and('include', `/recommendations/pathways/${fixtures.data[0].slug}`);
+ cy.get('tbody tr:first [data-label=Systems] a')
+ .should('have.attr', 'href')
+ .and('include', `/recommendations/pathways/${fixtures.data[0].slug}`);
+ });
});
describe('defaults', () => {
diff --git a/src/PresentationalComponents/PathwaysTable/PathwaysTable.js b/src/PresentationalComponents/PathwaysTable/PathwaysTable.js
index d6b48e4ea..8612d7cfe 100644
--- a/src/PresentationalComponents/PathwaysTable/PathwaysTable.js
+++ b/src/PresentationalComponents/PathwaysTable/PathwaysTable.js
@@ -186,9 +186,12 @@ const PathwaysTable = ({ isTabActive }) => {
},
{
title: (
-
{`${pathway.impacted_systems_count.toLocaleString()}`}
+ to={`/recommendations/pathways/${pathway.slug}`}
+ >
+ {`${pathway.impacted_systems_count.toLocaleString()}`}
+
),
},
{
diff --git a/src/PresentationalComponents/RulesTable/RulesTable.cy.js b/src/PresentationalComponents/RulesTable/RulesTable.cy.js
index fa9a55b88..968275936 100644
--- a/src/PresentationalComponents/RulesTable/RulesTable.cy.js
+++ b/src/PresentationalComponents/RulesTable/RulesTable.cy.js
@@ -129,6 +129,14 @@ describe('defaults', () => {
const column = 'Total risk';
tableIsSortedBy(column);
});
+ it('links to the recommendations detail page', () => {
+ cy.get('tbody tr:first [data-label=Name] a')
+ .should('have.attr', 'href')
+ .and('include', `/recommendations/${fixtures.data[0].rule_id}`);
+ cy.get('tbody tr:first [data-label=Systems] a')
+ .should('have.attr', 'href')
+ .and('include', `/recommendations/${fixtures.data[0].rule_id}`);
+ });
it('applies total risk "Enabled" and systems impacted "1 or more" filters', () => {
hasChip('Status', 'Enabled');
diff --git a/src/PresentationalComponents/RulesTable/helpers.js b/src/PresentationalComponents/RulesTable/helpers.js
index 000cd2e64..e8c415b92 100644
--- a/src/PresentationalComponents/RulesTable/helpers.js
+++ b/src/PresentationalComponents/RulesTable/helpers.js
@@ -415,9 +415,9 @@ export const buildRows = (
{intl.formatMessage(messages.nA)}
) : (
- {`${value.impacted_systems_count.toLocaleString()}`}
+
+ {`${value.impacted_systems_count.toLocaleString()}`}
+
),
},
{
diff --git a/src/PresentationalComponents/TopicsTable/TopicsTable.cy.js b/src/PresentationalComponents/TopicsTable/TopicsTable.cy.js
index 849465891..31aec2143 100644
--- a/src/PresentationalComponents/TopicsTable/TopicsTable.cy.js
+++ b/src/PresentationalComponents/TopicsTable/TopicsTable.cy.js
@@ -58,6 +58,15 @@ describe('renders correctly', () => {
it('renders table header', () => {
checkTableHeaders(TABLE_HEADERS);
});
+
+ it('links to the topic detail page', () => {
+ cy.get('tbody tr:first [data-label=Name] a')
+ .should('have.attr', 'href')
+ .and('include', `/topics/${fixtures[0].slug}`);
+ cy.get('tbody tr:first [data-label="Affected systems"] a')
+ .should('have.attr', 'href')
+ .and('include', `/topics/${fixtures[0].slug}`);
+ });
});
describe('defaults', () => {
diff --git a/src/PresentationalComponents/TopicsTable/TopicsTable.js b/src/PresentationalComponents/TopicsTable/TopicsTable.js
index dd02f55e3..9059cf702 100644
--- a/src/PresentationalComponents/TopicsTable/TopicsTable.js
+++ b/src/PresentationalComponents/TopicsTable/TopicsTable.js
@@ -80,8 +80,10 @@ const TopicsTable = ({ props }) => {
{
title: (
- {' '}
- {value.impacted_systems_count}
+
+ {' '}
+ {value.impacted_systems_count}
+
),
},