From 3531b8b47042558e08929535e652074cc38f306e Mon Sep 17 00:00:00 2001 From: Syofyan Zuhad Date: Sun, 27 Jun 2021 08:42:57 +0700 Subject: [PATCH 1/2] make link for the GET route --- views/routes.blade.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/views/routes.blade.php b/views/routes.blade.php index f785ced..ac4eedd 100644 --- a/views/routes.blade.php +++ b/views/routes.blade.php @@ -59,7 +59,13 @@ @endforeach {{ $route->domain() }} - {!! preg_replace('#({[^}]+})#', '$1', $route->uri()) !!} + + @if ($method=='GET') + {!! "$route->uri" !!} + @else + {!! preg_replace('#({[^}]+})#', '$1', $route->uri()) !!} + @endif + {{ $route->getName() }} {!! preg_replace('#(@.*)$#', '$1', $route->getActionName()) !!} From c1e81c207d1110cd06af0cfd0c357d716734a952 Mon Sep 17 00:00:00 2001 From: Syofyan Zuhad Date: Wed, 30 Jun 2021 13:40:34 +0700 Subject: [PATCH 2/2] additional condition specify toute for only get route without any parameters --- views/routes.blade.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/routes.blade.php b/views/routes.blade.php index ac4eedd..4ffd28b 100644 --- a/views/routes.blade.php +++ b/views/routes.blade.php @@ -60,7 +60,7 @@ {{ $route->domain() }} - @if ($method=='GET') + @if ($method=='GET' && ! strpos($route->uri, "{")) {!! "$route->uri" !!} @else {!! preg_replace('#({[^}]+})#', '$1', $route->uri()) !!}