summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2024-07-23 17:59:26 +0300
committerThanos Apollo <[email protected]>2024-07-23 18:36:16 +0300
commit383fef6289d74ad819976b4ba18ce820bcf71ce7 (patch)
tree46dff351ecd1077e57f5b8a10622853740eebcc9
parent2afc62757d40b3420bf3ff0cda34d7fc9324c35e (diff)
New function: dashboard-month-overview.
* Add 3 month overview. This is currently used for testing purposes.
-rw-r--r--gnosis-dashboard.el11
1 files changed, 11 insertions, 0 deletions
diff --git a/gnosis-dashboard.el b/gnosis-dashboard.el
index d42b759..4569ac7 100644
--- a/gnosis-dashboard.el
+++ b/gnosis-dashboard.el
@@ -128,6 +128,17 @@ Optionally, use REMOVE-SPACES when using multiple months."
(when (and (/= (forward-line 1) 0) (eobp))
(insert "\n")
(forward-line 0)))))
+;; TODO: Refactor this!
+(defun gnosis-dashboard-month-overview ()
+ "Insert the 3 month overview."
+ (let ((point (point)))
+ (gnosis-dashboard-reviews-graph (gnosis-dashboard-month-reviews 7) 0)
+ (goto-char point)
+ (end-of-line)
+ (gnosis-dashboard-reviews-graph (gnosis-dashboard-month-reviews 8) 15)
+ (goto-char point)
+ (end-of-line)
+ (gnosis-dashboard-reviews-graph (gnosis-dashboard-month-reviews 9) 46)))
(defun gnosis-dashboard-output-note (id)
"Output contents for note with ID, formatted for gnosis dashboard."
(cl-loop for item in (append (gnosis-select '[main options answer tags type] 'notes `(= id ,id) t)