From f691a603954ebdd04234707d31898b5b91e01133 Mon Sep 17 00:00:00 2001 From: Michael Vasseur <14887731+vmcj@users.noreply.github.com> Date: Sun, 29 Oct 2023 14:03:29 +0100 Subject: [PATCH] Use dynamic URL to simplify upgrading to latest CLICS version Doing this for the tex/doc files is much harder. The documentation still refers to the old standard. --- webapp/src/Command/ImportEventFeedCommand.php | 3 ++- webapp/src/Controller/Jury/JuryMiscController.php | 2 ++ webapp/templates/jury/index.html.twig | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/webapp/src/Command/ImportEventFeedCommand.php b/webapp/src/Command/ImportEventFeedCommand.php index e024335243..594a6fb611 100644 --- a/webapp/src/Command/ImportEventFeedCommand.php +++ b/webapp/src/Command/ImportEventFeedCommand.php @@ -2,6 +2,7 @@ namespace App\Command; +use App\Controller\API\GeneralInfoController as GI; use App\Entity\Contest; use App\Entity\ExternalContestSource; use App\Entity\User; @@ -51,7 +52,7 @@ protected function configure(): void $this ->setHelp( 'Import contest data from an event feed following the Contest API specification:' . PHP_EOL . - 'https://ccs-specs.icpc.io/2023-06/contest_api or any version starting from "2021-11"' . PHP_EOL . PHP_EOL . + GI::CCS_SPEC_API_URL . ' or any version starting from "2021-11"' . PHP_EOL . PHP_EOL . 'Note the following assumptions and caveats:' . PHP_EOL . '- Configuration data will only be verified.' . PHP_EOL . '- Team members will not be imported.' . PHP_EOL . diff --git a/webapp/src/Controller/Jury/JuryMiscController.php b/webapp/src/Controller/Jury/JuryMiscController.php index dc419804b5..a0d35aab5e 100644 --- a/webapp/src/Controller/Jury/JuryMiscController.php +++ b/webapp/src/Controller/Jury/JuryMiscController.php @@ -2,6 +2,7 @@ namespace App\Controller\Jury; +use App\Controller\API\GeneralInfoController as GI; use App\Controller\BaseController; use App\Entity\Contest; use App\Entity\Judging; @@ -45,6 +46,7 @@ public function indexAction(ConfigurationService $config): Response { return $this->render('jury/index.html.twig', [ 'adminer_enabled' => $config->get('adminer_enabled'), + 'CCS_SPEC_API_URL' => GI::CCS_SPEC_API_URL, ]); } diff --git a/webapp/templates/jury/index.html.twig b/webapp/templates/jury/index.html.twig index 3cd04a22b4..4b5184ec58 100644 --- a/webapp/templates/jury/index.html.twig +++ b/webapp/templates/jury/index.html.twig @@ -106,7 +106,7 @@
  • DOMjudge manual
  • Team manual
  • API documentation
    - See also the ICPC Contest API.
  • + See also the ICPC Contest API.