File tree 2 files changed +28
-3
lines changed
2 files changed +28
-3
lines changed Original file line number Diff line number Diff line change 4
4
class StatusController < ApplicationController
5
5
def index
6
6
authorize! :read_instance_state , nil
7
+ @high_priority_submissions_count = Submission . to_be_reprocessed . where ( processing_priority : 0 ) . count
7
8
@sandbox_queue_length = Submission . to_be_reprocessed . count
8
9
@unprocessed_submissions_count = Submission . where ( processed : false ) . count
9
- @submissions_count = Submission . where ( created_at : Time . current . all_day ) . count
10
+ @submissions_count_minute = Submission . where ( created_at : ( Time . current - 1 . minute ) ..Time . current ) . count
11
+ @submissions_count_five_minutes = Submission . where ( created_at : ( Time . current - 5 . minute ) ..Time . current ) . count
12
+ @submissions_count_hour = Submission . where ( created_at : ( Time . current - 1 . hour ) ..Time . current ) . count
13
+ @submissions_count_today = Submission . where ( created_at : Time . current . all_day ) . count
14
+ @submissions_count_yesterday = Submission . where ( created_at : Time . current . yesterday . all_day ) . count
10
15
@submissions_count_week = Submission . where ( created_at : Time . current . all_week ) . count
11
16
@sandboxes = RemoteSandbox . all + RemoteSandbox . all_experimental
12
17
end
Original file line number Diff line number Diff line change 9
9
< table class ="table ">
10
10
< tbody >
11
11
< tr >
12
- < th scope ="row "> Submission queue </ th scope="row">
12
+ < th scope ="row "> High priority sumbmissions in queue </ th scope="row">
13
+ < td > <%= @high_priority_submissions_count %> </ td >
14
+ </ tr >
15
+ < tr >
16
+ < th scope ="row "> All submissions in queue</ th scope="row">
13
17
< td > <%= @sandbox_queue_length %> </ td >
14
18
</ tr >
15
19
< tr >
16
20
< th scope ="row "> Submissions, processing not complete</ th >
17
21
< td > <%= @unprocessed_submissions_count %> </ td >
18
22
</ tr >
23
+ < tr >
24
+ < th scope ="row "> Submissions during the last minute</ th >
25
+ < td > <%= @submissions_count_minute %> </ td >
26
+ </ tr >
27
+ < tr >
28
+ < th scope ="row "> Submissions during the last five minutes</ th >
29
+ < td > <%= @submissions_count_five_minutes %> </ td >
30
+ </ tr >
31
+ < tr >
32
+ < th scope ="row "> Submissions during the latest hour</ th >
33
+ < td > <%= @submissions_count_hour %> </ td >
34
+ </ tr >
19
35
< tr >
20
36
< th scope ="row "> Submissions today</ th >
21
- < td > <%= @submissions_count %> </ td >
37
+ < td > <%= @submissions_count_today %> </ td >
38
+ </ tr >
39
+ < tr >
40
+ < th scope ="row "> Submissions yesterday</ th >
41
+ < td > <%= @submissions_count_yesterday %> </ td >
22
42
</ tr >
23
43
< tr >
24
44
< th scope ="row "> Submissions this week</ th >
You can’t perform that action at this time.
0 commit comments