mirror of
https://github.com/Floriansylvain/RenewCMS.git
synced 2026-08-19 11:43:22 +02:00
fix: typos and posts dates format
This commit is contained in:
@@ -8,8 +8,11 @@
|
||||
<main>
|
||||
<p>You or someone tried to create a GoCMS admin account with this e-mail address. If you are not responsible for
|
||||
this, please do not validate the account creation.</p>
|
||||
<p><b>If you want to validate the account creation, please <a href="{{.Host}}/register/validate?c={{.VerificationCode}}" target="_blank">click HERE</a>.</b>
|
||||
<p><b>If you want to validate the account creation, please <a
|
||||
href="{{.Host}}/register/validate?c={{.VerificationCode}}" target="_blank">click HERE</a>.</b>
|
||||
</p>
|
||||
<p>If you can't click the link:</p>
|
||||
<p>{{.Host}}/register/validate?c={{.VerificationCode}}</p>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<h2>Verify your email</h2>
|
||||
</div>
|
||||
<p>An e-mail with the validation link was sent to the address you just registered.</p>
|
||||
<p>If you misspelled theF address or just didn't receive any e-mails, please check your spams or cancel the
|
||||
<p>If you misspelled the address or just didn't receive any e-mails, please check your spams or cancel the
|
||||
account creation.</p>
|
||||
<form action="" method="post" class="d-flex">
|
||||
<button class="btn btn-outline-primary w-100" type="submit">
|
||||
|
||||
+13
-1
@@ -7,11 +7,23 @@ import (
|
||||
|
||||
func GetPostsPage(w http.ResponseWriter, _ *http.Request) {
|
||||
posts := Container.ListPostsUseCase.ListPosts()
|
||||
|
||||
var formattedPosts []map[string]interface{}
|
||||
for _, post := range posts {
|
||||
formattedPosts = append(formattedPosts, map[string]interface{}{
|
||||
"ID": post.ID,
|
||||
"Title": post.Title,
|
||||
"CreatedAt": post.CreatedAt.Format("2006-01-02 15:04:05"),
|
||||
"UpdatedAt": post.UpdatedAt.Format("2006-01-02 15:04:05"),
|
||||
})
|
||||
}
|
||||
|
||||
navbarTmpl, _ := Container.GetPageUseCase.GetPage("componentNavbar", nil)
|
||||
postsTmpl, _ := Container.GetPageUseCase.GetPage("posts", map[string]interface{}{
|
||||
"Navbar": template.HTML(navbarTmpl),
|
||||
"Head": headTmpl,
|
||||
"Posts": posts,
|
||||
"Posts": formattedPosts,
|
||||
})
|
||||
|
||||
_, _ = w.Write(postsTmpl)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user