diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-04-30 18:41:39 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2020-04-30 18:41:39 +0200 |
commit | c74486cbb2efda112dc2631aa3ed84824fc61c8a (patch) | |
tree | e4369351dd510907c648d12db485077ec604f49b /module/output | |
parent | Update ical parts to use app context. (diff) | |
download | calp-c74486cbb2efda112dc2631aa3ed84824fc61c8a.tar.gz calp-c74486cbb2efda112dc2631aa3ed84824fc61c8a.tar.xz |
Update HTML to use app.
Diffstat (limited to '')
-rw-r--r-- | module/output/html.scm | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/module/output/html.scm b/module/output/html.scm index 8a932fd0..740be7b9 100644 --- a/module/output/html.scm +++ b/module/output/html.scm @@ -7,6 +7,7 @@ #:use-module (vcomponent group) #:use-module (vcomponent datetime) #:use-module (util) + #:use-module (util app) #:use-module (util exceptions) #:use-module (util config) #:use-module (util tree) @@ -745,7 +746,11 @@ ,@(stream->list (stream-map fmt-day evs)))))))) -(define-public (html-chunked-main count calendars events start-date chunk-length) +(define-method (html-chunked-main count start-date chunk-length) + + (define calendars (getf app 'calendars)) + (define events (getf app 'event-set)) + ;; TODO This still doesn't account for PWD, file existing but is of ;; wrong type, html directory existing but static symlink missing, ;; static being a different file type, and probably something else @@ -778,7 +783,12 @@ (cdr ms)))))))) -(define-public (html-table-main count calendars events start-date) + +(define-method (html-table-main count start-date) + + (define calendars (getf app 'calendars)) + (define events (getf app 'event-set)) + ;; TODO same file creation as in html-chunked-main (stream-for-each (lambda (start-of-month) |