]> _ Git - odl.git/commitdiff
wip #4914 @1
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 4 Jan 2022 09:13:51 +0000 (10:13 +0100)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 4 Jan 2022 09:13:51 +0000 (10:13 +0100)
resources/views/components/link.blade.php

index e9a130e9d6231c38c68c65011e695cf68ed53b50..ce1b5b05a6f5724ad5776fda2860b73390d85a5f 100644 (file)
@@ -3,7 +3,10 @@
     use Illuminate\Support\Str;
 
     if (!Str::startsWith($href, 'http') && !Str::startsWith($href, '/tools/')) {
-        // TODO: add adapt local URLs based on environment (whether dynamic or static HTML output)
+        $map=['home'=>'accueil.html','resources'=>'/ressources.html','medialibrary'=>'/mediatheque.html'];
+        if(isset($map[$href])){
+            $href=$map[$href];
+        }
         $href = '/front' . $href; // Prefix URLs for frontend preview
     }
 @endphp