1
0
Fork 0

Prefix all manually created routes with "app"

This commit is contained in:
Krzysztof Sikorski 2022-03-20 19:47:51 +01:00
parent 181230d605
commit 5f647e1f9f
Signed by: krzysztof-sikorski
GPG Key ID: 4EB564BD08FE8476
5 changed files with 6 additions and 6 deletions

View File

@ -10,7 +10,7 @@ use Symfony\Component\Routing\Annotation\Route;
final class FaviconController
{
#[Route(path: '/favicon.ico', name: 'favicon_ico', methods: [Request::METHOD_GET])]
#[Route(path: '/favicon.ico', name: 'app_favicon_ico', methods: [Request::METHOD_GET])]
public function favicon(): Response
{
return new Response(null, Response::HTTP_GONE, []);

View File

@ -15,7 +15,7 @@ final class HomeController
{
}
#[Route(path: '/', name: 'home', methods: [Request::METHOD_GET])]
#[Route(path: '/', name: 'app_home', methods: [Request::METHOD_GET])]
public function index(): Response
{
$content = $this->twigEnvironment->render('home/index.html.twig', [

View File

@ -27,7 +27,7 @@ final class SubmitJsonController
) {
}
#[Route(path: '/submit-json', name: 'submit_json', methods: [Request::METHOD_GET, Request::METHOD_POST])]
#[Route(path: '/submit-json', name: 'app_submit_json', methods: [Request::METHOD_GET, Request::METHOD_POST])]
public function json(Request $request): Response
{
if ($request->isMethod(method: Request::METHOD_POST)) {

View File

@ -16,8 +16,8 @@
<header>
<nav>
<menu>
<li><a href="{{ path('home') }}">Home</a></li>
<li><a href="{{ path('submit_json') }}">Submit JSON</a></li>
<li><a href="{{ path('app_home') }}">Home</a></li>
<li><a href="{{ path('app_submit_json') }}">Submit JSON</a></li>
<li><a href="https://www.nexusclash.com/" rel="external">Nexus Clash</a></li>
<li><a href="https://discord.gg/zBVwzD3f8v" rel="external">Discord</a></li>
</menu>

View File

@ -3,7 +3,7 @@
{% block title %}Submit request log as JSON - Nexus Archive{% endblock %}
{% block body %}
<form action="{{ path(name='submit_json') }}" method="post">
<form action="{{ path(name='app_submit_json') }}" method="post">
<p><label>User access token: <input name="userAccessToken" type="text" required size="64"></label></p>
<p><label>JSON data: <textarea name="jsonData" required cols="64" rows="16"></textarea></label></p>
<p><button type="submit">Submit</button></p>