parcoursmob/renderer/support.go

21 lines
481 B
Go
Raw Permalink Normal View History

2022-10-31 09:39:43 +00:00
package renderer
import (
"net/http"
)
const commentMenu = "comment"
2022-11-01 10:54:59 +00:00
//const commentsend = "sendComment"
2022-10-31 09:39:43 +00:00
func (renderer *Renderer) SupportSend(w http.ResponseWriter, r *http.Request, comment any, admins any) {
2022-11-01 10:54:59 +00:00
files := renderer.ThemeConfig.GetStringSlice("views.support.request.files")
2022-10-31 09:39:43 +00:00
state := NewState(r, renderer.ThemeConfig, commentMenu)
state.ViewState = map[string]any{
"comment": comment,
"admins": admins,
}
renderer.Render("comment", w, r, files, state)
}