mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-12-30 02:36:16 -06:00
Webviews for status threads
This commit is contained in:
parent
64bd689e55
commit
d553b445f5
6 changed files with 241 additions and 13 deletions
|
|
@ -59,11 +59,7 @@ func (m *Module) baseHandler(c *gin.Context) {
|
|||
|
||||
// FIXME: fill in more variables?
|
||||
c.HTML(http.StatusOK, "index.tmpl", gin.H{
|
||||
"instance": instance,
|
||||
"countUsers": 3,
|
||||
"countStatuses": 42069,
|
||||
"version": "1.0.0",
|
||||
"adminUsername": "@admin",
|
||||
"instance": instance,
|
||||
})
|
||||
}
|
||||
|
||||
|
|
@ -101,6 +97,9 @@ func (m *Module) Route(s router.Router) error {
|
|||
// serve front-page
|
||||
s.AttachHandler(http.MethodGet, "/", m.baseHandler)
|
||||
|
||||
// serve statuses
|
||||
s.AttachHandler(http.MethodGet, "/:user/statuses/:id", m.statusTemplateHandler)
|
||||
|
||||
// 404 handler
|
||||
s.AttachNoRouteHandler(m.NotFoundHandler)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue