stuff
This commit is contained in:
20
lib/CW/Template/Error/404.pm
Normal file
20
lib/CW/Template/Error/404.pm
Normal file
@@ -0,0 +1,20 @@
|
||||
package CW::Template::Error::404;
|
||||
|
||||
use Moo;
|
||||
|
||||
extends 'CW::Template';
|
||||
|
||||
sub render {
|
||||
return [
|
||||
h2 => { style => "margin: 0" } =>
|
||||
[q[You are searching for something that seemingly doesn't exist.]],
|
||||
div => [
|
||||
p => { style => "margin: 0" } =>
|
||||
["Perhaps this is the sign you needed to create it yourself?"],
|
||||
img =>
|
||||
{ class => 'alexandria', src => "/static/images/alexandria.jpg" }
|
||||
]
|
||||
];
|
||||
}
|
||||
|
||||
1;
|
||||
28
lib/CW/Template/Error/500.pm
Normal file
28
lib/CW/Template/Error/500.pm
Normal file
@@ -0,0 +1,28 @@
|
||||
package CW::Template::Error::500;
|
||||
|
||||
use Moo;
|
||||
|
||||
extends 'CW::Template';
|
||||
|
||||
sub render {
|
||||
my ($self) = @_;
|
||||
return [
|
||||
h2 => { style => "margin: 0" } =>
|
||||
[q[Something has gone terribly wrong.]],
|
||||
div => [
|
||||
p => { style => "margin: 0" } =>
|
||||
["Please re-try whatever it is you were doing, later."],
|
||||
img => {
|
||||
class => 'alexandria',
|
||||
src => "/static/images/alexandria_fire.jpg"
|
||||
},
|
||||
(
|
||||
$self->ctx->{show_errors}
|
||||
? ( p => [ $self->ctx->{error} ] )
|
||||
: ()
|
||||
)
|
||||
]
|
||||
];
|
||||
}
|
||||
|
||||
1;
|
||||
Reference in New Issue
Block a user