Add migrations

This commit is contained in:
structix committed 2020-10-09 15:10:13 +02:00
1 parent 135cd976d0
commit 011619d3c3
8 files changed
+81 -9

No files matched your search

+10
View File
@@ -12,3 +12,13 @@ func MainPage(pool *pgxpool.Pool) gin.HandlerFunc {
c.HTML(http.StatusAccepted, "index.html", database.DbMainpage(pool))
}
}
func UploadName(pool *pgxpool.Pool) gin.HandlerFunc {
return func(c *gin.Context) {
selectedID := c.PostForm("names")
washID := c.PostForm("washid")
database.UploadName(pool, selectedID, washID)
c.Redirect(302, "/")
}
}