X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;f=resources%2Fjs%2Fcomponents%2Ftournament%2FDetail.js;h=bb9b9284461ebe85ea7c4a818cb417c8c7df43f6;hb=a5d038197b7a31c2d354fed242985cb604c4f8a8;hp=cdc9b601bd3b3c81448b1e3015e57b312f3922bc;hpb=cd36cb0ba2718e6bfa08765e7702d57dfe7fd733;p=alttp.git diff --git a/resources/js/components/tournament/Detail.js b/resources/js/components/tournament/Detail.js index cdc9b60..bb9b928 100644 --- a/resources/js/components/tournament/Detail.js +++ b/resources/js/components/tournament/Detail.js @@ -5,6 +5,8 @@ import { withTranslation } from 'react-i18next'; import ApplyButton from './ApplyButton'; import Scoreboard from './Scoreboard'; +import ScoreChartButton from './ScoreChartButton'; +import SettingsButton from './SettingsButton'; import ApplicationsButton from '../applications/Button'; import Protocol from '../protocol/Protocol'; import Rounds from '../rounds/List'; @@ -12,12 +14,14 @@ import Box from '../users/Box'; import { isRunner, mayAddRounds, + mayUpdateTournament, mayViewProtocol, } from '../../helpers/permissions'; import { getTournamentAdmins, getTournamentMonitors, hasRunners, + hasScoreboard, hasTournamentAdmins, hasTournamentMonitors, } from '../../helpers/Tournament'; @@ -49,6 +53,9 @@ const Detail = ({
+ {mayUpdateTournament(user, tournament) ? + + : null} {mayViewProtocol(user, tournament) ? : null} @@ -59,12 +66,17 @@ const Detail = ({
-
-

{i18n.t('tournaments.scoreboard')}

-
- {hasRunners(tournament) ? - - : null} + {hasScoreboard(tournament) ? <> +
+

{i18n.t('tournaments.scoreboard')}

+ {hasRunners(tournament) && tournament.rounds.length > 2 ? + + : null} +
+ {hasRunners(tournament) ? + + : null} + : null} {hasTournamentAdmins(tournament) ? <>