X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;f=lib%2FMaypole%2FView%2FTT.pm;h=a1960bacca977100da054681f082ba365bde05a0;hb=22ed66cbefd7c1bae9c2710e88b080b811e98778;hp=4bd7c0ebb836af2acd0817aba039b1da8b58b7e1;hpb=81b617ffe75c0d5924595fc5b832733c7bfbcc28;p=maypole.git diff --git a/lib/Maypole/View/TT.pm b/lib/Maypole/View/TT.pm index 4bd7c0e..a1960ba 100644 --- a/lib/Maypole/View/TT.pm +++ b/lib/Maypole/View/TT.pm @@ -1,5 +1,4 @@ package Maypole::View::TT; -use Apache::Constants; use Lingua::EN::Inflect; use Template; use File::Spec; @@ -34,6 +33,7 @@ sub _args { if ($class) { $args{classmetadata} = { name => $class, + table => $class->table, columns => [ $class->display_columns ], colnames => { $class->column_names }, related_accessors => [ $class->related($r) ], @@ -71,7 +71,7 @@ sub process { sub error { my ($self, $r, $error) = @_; warn $error; - if ($error =~ /not found$/) { return DECLINED } + if ($error =~ /not found$/) { return -1 } $r->{content_type} = "text/plain"; $r->{output} = $error; $r->send_output;