From 5c70d43e74bd9f5fd28ada9419e29cb7bfac74d8 Mon Sep 17 00:00:00 2001 From: Howard Edwards Date: Tue, 17 Sep 2024 11:59:56 -0400 Subject: [PATCH] Allow public viewing for conflicts paeg --- .../TestPlanReportStatusDialog/index.jsx | 1 - .../Conflicts/TestConflictsActions.jsx | 43 +++++++++++-------- client/components/TestQueue/index.jsx | 1 - .../common/ReportStatusSummary/index.jsx | 6 --- client/routes/index.js | 6 +-- 5 files changed, 25 insertions(+), 32 deletions(-) diff --git a/client/components/TestPlanReportStatusDialog/index.jsx b/client/components/TestPlanReportStatusDialog/index.jsx index 21d96cca0..7bd981b0b 100644 --- a/client/components/TestPlanReportStatusDialog/index.jsx +++ b/client/components/TestPlanReportStatusDialog/index.jsx @@ -60,7 +60,6 @@ const TestPlanReportStatusDialog = ({ {isSignedIn && isAdmin && !testPlanReport ? ( { +const TestConflictsActions = ({ + issueLink, + isAdmin, + testPlanRuns, + testIndex +}) => { + const openResultsLabel = isAdmin ? 'Open run as...' : 'View Results for...'; + return ( - {isAdmin && ( - - - - Open run as... - - - {testPlanRuns.map(testPlanRun => ( - - {testPlanRun.tester.username} - - ))} - - - )} + + + + {openResultsLabel} + + + {testPlanRuns.map(testPlanRun => ( + + {testPlanRun.tester.username} + + ))} + + ); }; diff --git a/client/components/TestQueue/index.jsx b/client/components/TestQueue/index.jsx index e7404db2b..3cec38396 100644 --- a/client/components/TestQueue/index.jsx +++ b/client/components/TestQueue/index.jsx @@ -332,7 +332,6 @@ const TestQueue = () => { {hasBotRun ? ( diff --git a/client/components/common/ReportStatusSummary/index.jsx b/client/components/common/ReportStatusSummary/index.jsx index 48ab86946..87d2f9251 100644 --- a/client/components/common/ReportStatusSummary/index.jsx +++ b/client/components/common/ReportStatusSummary/index.jsx @@ -8,7 +8,6 @@ import { TestPlanRunPropType, UserPropType } from '../proptypes'; -import { evaluateAuth } from '../../../utils/evaluateAuth'; const IncompleteStatusReport = styled.span` min-width: 5rem; @@ -18,11 +17,8 @@ const IncompleteStatusReport = styled.span` const ReportStatusSummary = ({ testPlanVersion, testPlanReport, - me, fromTestQueue = false }) => { - const { isSignedIn, isAdmin, isTester, isVendor } = evaluateAuth(me); - const renderCompleteReportStatus = testPlanReport => { const formattedDate = dates.convertDateToString( testPlanReport.markedFinalAt, @@ -37,8 +33,6 @@ const ReportStatusSummary = ({ const getConflictsAnchor = conflictsCount => { if (conflictsCount === 0) return null; - if (!isSignedIn) return null; - if (!isTester && !isVendor && !isAdmin) return null; return ( ( - - - } + element={} />