Skip to content

Commit

Permalink
HTPL table TOP
Browse files Browse the repository at this point in the history
  • Loading branch information
Pomog committed Dec 7, 2023
1 parent cf31097 commit 1bed01d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion internal/handler/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ func (m *Repository) ThemeHandler(w http.ResponseWriter, r *http.Request) {
data["creatorName"] = creator.UserName
data["creatorImg"] = creator.Picture
data["mainThreadName"] = mainThread.Subject
data["mainThreadCreatedTime"] = mainThread.Created
data["mainThreadCreatedTime"] = mainThread.Created.Format("2006-01-02 15:04:05")

renderer.RendererTemplate(w, "theme.page.html", &models.TemplateData{
Data: data,
Expand Down
8 changes: 5 additions & 3 deletions template/theme.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,15 +91,17 @@
<table class="table-borderless forumTable whiteLink mt-3">
<thead class="containerHead">
<tr >
{{/* info related to the main(mother)Thread */}}
<th class="forumFirstColTheme" scope="col" colspan="2">
<img src="{{ .PictureUserWhoCreatedPost}}" class="logo_img" alt="/static/logo/message_icon2.png"><strong>&nbsp;{{ .Subject }} </strong>

{{index .Data "mainThreadName"}} <br>
Created: {{index .Data "mainThreadCreatedTime"}}
</th>

<th></th>

</tr>
</thead>
<tbody class="containerBody">
<!-- placeholder for posts -->
<tr>
<td>
<img src="static\ava\pomogadryg_ava.png" class="ava_img" alt="ava"><strong> &nbsp; Pomogadryg </strong><br>Date of Registration: 10.05.2015 <br> Total Messages: 211
Expand Down

0 comments on commit 1bed01d

Please sign in to comment.