diff options
author | Christopher Baines <mail@cbaines.net> | 2019-11-24 20:42:37 +0000 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2019-11-24 20:42:37 +0000 |
commit | 2a3ee20a9973657b9cf0b4514ad42e3414d6b57e (patch) | |
tree | ccadeca7227b3f68211c3fad67ab832d01c2c680 /guix-data-service/web/view | |
parent | 33ecb7448eeb9e224b163f2b232630c8733a7cb6 (diff) | |
download | data-service-2a3ee20a9973657b9cf0b4514ad42e3414d6b57e.tar data-service-2a3ee20a9973657b9cf0b4514ad42e3414d6b57e.tar.gz |
Extract the builds page in to it's own set of modules
To allow for expanding it, without cluttering the root controller.
Diffstat (limited to 'guix-data-service/web/view')
-rw-r--r-- | guix-data-service/web/view/html.scm | 58 |
1 files changed, 0 insertions, 58 deletions
diff --git a/guix-data-service/web/view/html.scm b/guix-data-service/web/view/html.scm index c514f4f..487954f 100644 --- a/guix-data-service/web/view/html.scm +++ b/guix-data-service/web/view/html.scm @@ -345,64 +345,6 @@ "No information yet"))))))))) branches-with-most-recent-commits)))) -(define (view-builds stats builds) - (layout - #:body - `(,(header) - (div - (@ (class "container")) - (div - (@ (class "row")) - (div - (@ (class "col-sm-12")) - (h1 "Builds") - (table - (@ (class "table")) - (thead - (tr - (th (@ (class "col-md-2")) "Status") - (th (@ (class "col-md-2")) "Count"))) - (tbody - ,@(map - (match-lambda - ((status count) - `(tr - (td ,(build-status-span status)) - (td ,count)))) - stats))))) - (div - (@ (class "row")) - (div - (@ (class "col-sm-12")) - (table - (@ (class "table")) - (thead - (tr - (th (@ (class "col-xs-2")) "Status") - (th (@ (class "col-xs-9")) "Derivation") - (th (@ (class "col-xs-1")) "Started at") - (th (@ (class "col-xs-1")) "Finished at") - (th (@ (class "col-xs-1")) ""))) - (tbody - ,@(map - (match-lambda - ((build-id build-server-url derivation-file-name - timestamp status) - `(tr - (td (@ (class "text-center")) - ,(build-status-span status)) - (td (a (@ (href ,derivation-file-name)) - ,(display-store-item-short derivation-file-name))) - (td ,timestamp) - (td (a (@ (href ,(simple-format - #f "~Abuild/~A" - build-server-url - (string-drop - derivation-file-name - (string-length "/gnu/store/"))))) - "View build on " ,build-server-url))))) - builds))))))))) - (define (build-status-value->display-string value) (assoc-ref '(("scheduled" . "Scheduled") |