Browse Source

add snapshot data passed to template from /danger/manage-snapshots.

This data is just a list of the directory names for each snapshot stored in the
/snapshots directory -- only deals with HTTP GET here.
stable
Craig Oates 2 years ago
parent
commit
fdf43c2b01
  1. 14
      src/web.lisp

14
src/web.lisp

@ -1667,12 +1667,14 @@
(append (auth:auth-user-data) (append (auth:auth-user-data)
`(:alert ,alert `(:alert ,alert
:system-data ,(nera:system-data) :system-data ,(nera:system-data)
;; Snapshot data goes here... :snapshots
)))) ,(reverse
;; Not Authorised (storage::get-directory-names
(progn (storage::get-raw-directories "snapshots/")))))))
(utils:set-alert "You are not authorised to view this page." "error") ;; Not Authorised
(redirect "/login")))) (progn
(utils:set-alert "You are not authorised to view this page." "error")
(redirect "/login"))))
(defroute ("/danger/take-snapshot" :method :POST) () (defroute ("/danger/take-snapshot" :method :POST) ()
(destructuring-bind (destructuring-bind

Loading…
Cancel
Save