summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2019-05-11 01:29:21 +0200
committerDaniel Friesel <derf@finalrewind.org>2019-05-11 01:29:21 +0200
commitb0397e50b422fd99fc6903be2dd598a8280d1381 (patch)
treeae5a6c8702646b6897f86089fe118a07e5ada45e
parentfc4cfade14bfaa053db48f6896f32d0340b65854 (diff)
add custom not_found and exception templates
-rw-r--r--templates/exception.html.ep27
-rw-r--r--templates/not_found.html.ep10
2 files changed, 37 insertions, 0 deletions
diff --git a/templates/exception.html.ep b/templates/exception.html.ep
new file mode 100644
index 0000000..e4daf9a
--- /dev/null
+++ b/templates/exception.html.ep
@@ -0,0 +1,27 @@
+<div class="row">
+ <div class="col s12">
+ <div class="card red darken-4">
+ <div class="card-content white-text">
+ <span class="card-title">500 Internal Server Error</span>
+ <p>Das hätte nicht passieren sollen.</p>
+ </div>
+ <div class="card-action">
+ <a href="https://github.com/derf/travelynx/issues" class="waves-effect waves-light btn-flat white-text">
+ <i class="material-icons left">bug_report</i>Bug melden
+ </a>
+ </div>
+ </div>
+ </div>
+</div>
+<div class="row">
+ <div class="col s12">
+ <p>Angaben für einen Bug-Report:</p>
+ <p style="font-family: monospace;">
+ Timestamp:
+ %= DateTime->now(time_zone => 'Europe/Berlin')->strftime("%d/%b/%Y:%H:%M:%S %z")
+ <br/><br/>
+ Message:
+ %= (split(qr{\n}, $exception->message))[0]
+ </p>
+ </div>
+</div>
diff --git a/templates/not_found.html.ep b/templates/not_found.html.ep
new file mode 100644
index 0000000..de0d533
--- /dev/null
+++ b/templates/not_found.html.ep
@@ -0,0 +1,10 @@
+<div class="row">
+ <div class="col s12">
+ <div class="card red darken-4">
+ <div class="card-content white-text">
+ <span class="card-title">404 Not Found</span>
+ <p>Diese Seite gibt es hier nicht.</p>
+ </div>
+ </div>
+ </div>
+</div>