summaryrefslogtreecommitdiff
path: root/mumi
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2020-04-22 18:29:25 +0200
committerRicardo Wurmus <rekado@elephly.net>2020-04-22 18:29:25 +0200
commitcd989b9a1285b206b4a857049522460b02b3a9b1 (patch)
treea0940512f108a3eaed8d66cf80ceb51be1e0ece6 /mumi
parente4b0a7d7585fd40f1a7bd0d3f5a503d6a1b410a4 (diff)
view: Add list-of-recent-issues.
Diffstat (limited to 'mumi')
-rw-r--r--mumi/web/view/html.scm21
1 files changed, 20 insertions, 1 deletions
diff --git a/mumi/web/view/html.scm b/mumi/web/view/html.scm
index aa5479c..aac0d1b 100644
--- a/mumi/web/view/html.scm
+++ b/mumi/web/view/html.scm
@@ -31,7 +31,8 @@
unknown
error-page
issue-page
- list-of-matching-bugs))
+ list-of-matching-bugs
+ list-of-recent-issues))
(define (bug-subject* bug)
(or (bug-subject bug) "(no subject)"))
@@ -566,6 +567,24 @@ m1 3H6v5h2V4zm0 6H6v2h2v-2z")))))
(bugs-by-severity "important" "open"))
(lambda (a b) (< (bug-num a) (bug-num b))))))
+(define* (list-of-recent-issues #:optional (max 100))
+ (layout
+ #:body
+ `(,(header #:search-bar? #f)
+ (div
+ (@ (class "container"))
+ (h1 "Recent issues")
+ (table
+ (@ (class "table table-borderless table-hover js-sort-table"))
+ (thead
+ (tr (@ (class "heading"))
+ (th (@ (class "js-sort-number")) "ID")
+ (th "Subject")
+ (th "Date submitted")
+ (th "Status")))
+ (tbody
+ ,@(list-of-bugs (recent-bugs max))))))))
+
(define (list-of-matching-bugs query bugs)
(layout
#:body