diff options
Diffstat (limited to 'server.go')
-rw-r--r-- | server.go | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -154,6 +154,11 @@ func handleGetPart(ctx *context, raw bool) error { }) } +func handleCompose(ectx echo.Context) error { + ctx := ectx.(*context) + return ctx.Render(http.StatusOK, "compose.html", nil) +} + func New(imapURL string) *echo.Echo { e := echo.New() @@ -247,6 +252,9 @@ func New(imapURL string) *echo.Echo { return ctx.Redirect(http.StatusFound, "/login") }) + e.GET("/compose", handleCompose) + e.POST("/compose", handleCompose) + e.Static("/assets", "public/assets") return e |