From 8510c36ded85740885e67b59ee2ec2360986c0a9 Mon Sep 17 00:00:00 2001 From: Alexander Kavon Date: Tue, 23 Jan 2024 01:40:39 -0500 Subject: new tables: tags, post_tags, generated sqlboiler tags model, updated posts/get template, updated posts table to take nullable description and user_id foreign key --- ui/pages/post/get.tmpl.html | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'ui') diff --git a/ui/pages/post/get.tmpl.html b/ui/pages/post/get.tmpl.html index f705f65..b32bd1c 100644 --- a/ui/pages/post/get.tmpl.html +++ b/ui/pages/post/get.tmpl.html @@ -1,19 +1,23 @@ -{{define "title"}}{{.Title}}{{end}} +{{define "title"}}{{.post.Title}}{{end}} {{define "main"}} - {{.Title}} - {{.Tags}} - {{.UrlDomainName}} - by {{.Username}} - {{.CreatedAt}} + {{.post.Title}} + + {{range $tag := .post.R.Tags}} + + {{end}} + + {{.post.URL.String}} (Pretty URL) + by {{.post.R.User.Username}} + {{.post.CreatedAt.Format "Jan 02, 2006 15:04"}} Flag Hide - {{ if and .Description not .Url }} -

{{.Description}}

+ {{ if .post.Description.Valid }} +

{{.post.Description.String}}

{{end}} -
+ -- cgit v1.2.3