lib/CrashTest.pm
changeset 131 bb5fad5d66b8
parent 124 12da024402d2
equal deleted inserted replaced
130:81932c723dfd 131:bb5fad5d66b8
    64 
    64 
    65     # Router
    65     # Router
    66     my $r = $self->routes;
    66     my $r = $self->routes;
    67 
    67 
    68     # Normal route to controller
    68     # Normal route to controller
    69     $r->get('/')->to('crash_reports#index')->name('index');
    69     $r->get('/' => [format => ['html', 'atom']])->to('crash_reports#index', format => undef)->name('index');
    70     $r->get('/reports')->to('crash_reports#index')->name('reports');
    70     $r->get('/reports' => [format => ['html', 'atom']])->to('crash_reports#index', format => undef)->name('reports');
    71     $r->get('/groups')->to('crash_groups#index')->name('groups');
    71     $r->get('/groups')->to('crash_groups#index')->name('groups');
    72     $r->get('/groups/:uuid' => [ uuid => qr/[0-9a-fA-F-]+/ ])->to('crash_groups#show')->name('group');
    72     $r->get('/groups/:uuid' => [ uuid => qr/[0-9a-fA-F-]+/ ])->to('crash_groups#show')->name('group');
    73     $r->get('/report/:uuid' => [ uuid => qr/[0-9a-fA-F-]+/ ])->to('crash_reports#show')->name('report');
    73     $r->get('/report/:uuid' => [ uuid => qr/[0-9a-fA-F-]+/ ])->to('crash_reports#show')->name('report');
    74 
    74 
    75     $r->post('/submit')->to('crash_inserter#insert');
    75     $r->post('/submit')->to('crash_inserter#insert');