From f80c82597ffcf3a65cc49ffca8f3b7ffa8117c27 Mon Sep 17 00:00:00 2001 From: Colin Okay Date: Thu, 27 Oct 2022 14:51:23 -0500 Subject: Add: navigation header --- user.lisp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'user.lisp') diff --git a/user.lisp b/user.lisp index 6f95b2c..c0ec8a6 100644 --- a/user.lisp +++ b/user.lisp @@ -26,17 +26,15 @@ (new-playlist (session-user parent) :title (value pl-title)) (reload (location (connection-body parent))))))) -(defun url-to-playlist (pl location) - (format nil "~a//~a/playlist/~a" - (protocol location) - (host location) +(defun url-to-playlist (pl) + (format nil "/playlist/~a" (key pl))) (defun create-playlist-listing (parent &rest args) (declare (ignorable args)) (dolist (pl (user-playlists (session-user parent))) (let ((url - (url-to-playlist pl (location (connection-body parent))))) + (url-to-playlist pl))) (with-clog-create parent (div () (section (:h4) @@ -50,6 +48,7 @@ (defun user-home-page (body) (with-clog-create body (div () + (navigation-header ()) (p (:content (format nil "Welcome ~a" (user-name (session-user body))))) (new-playlist-form ()) (playlist-listing ())))) -- cgit v1.2.3