[Perl] DAQ system for the FAPG.
refactor move status page under /probes/status
Probe status is now nested under the probes top-level page at /probes/status. Breadcrumbs reflect the hierarchy: Home > Probes > Status. The navbar highlights 'Probes' when viewing status.
Changed files
roles/dashboard/lib/FAPG/DAQ/Dashboard.pm
@@ -135,7 +135,7 @@
135
135
my $r = $self->routes;
136
136
137
137
$r->get('/')->to('pages#index');
138
Removed:
$r->get('/status')->to('pages#status');
138
Added:
$r->get('/probes/status')->to('pages#status');
139
139
$r->get('/probes')->to('pages#probe_list');
140
140
$r->get('/insights')->to('pages#insights');
141
141
$r->get('/downloads')->to('pages#downloads');
roles/dashboard/lib/FAPG/DAQ/Dashboard/Controller/Pages.pm
@@ -15,9 +15,12 @@
15
15
$self->render(
16
16
template => 'dashboard/status',
17
17
items => $self->status_items,
18
Removed:
nav_page => 'status',
19
Removed:
breadcrumbs =>
20
Removed:
[ { label => 'Home', href => '/' }, { label => 'Status' }, ],
18
Added:
nav_page => 'probes',
19
Added:
breadcrumbs => [
20
Added:
{ label => 'Home', href => '/' },
21
Added:
{ label => 'Probes', href => '/probes' },
22
Added:
{ label => 'Status' },
23
Added:
],
21
24
);
22
25
}
23
26
roles/dashboard/t/05-status-page.t
@@ -9,7 +9,7 @@
9
9
10
10
my $t = test_app();
11
11
12
Removed:
$t->get_ok('/status')
12
Added:
$t->get_ok('/probes/status')
13
13
->status_is(200)
14
14
->element_exists(
15
15
'nav[aria-label="Breadcrumb"] a[href="/"]')