-
+
diff --git a/controller/new_order.go b/controller/new_order.go index 06b3bce..08d7849 100644 --- a/controller/new_order.go +++ b/controller/new_order.go @@ -18,5 +18,9 @@ func (c *Controller) postNewOrder(w http.ResponseWriter, r *http.Request) { func (c *Controller) getNewOrder(w http.ResponseWriter, r *http.Request) { fmt.Println("received Get request: ", r) - _ = c.tmpl["order/get_new"].Execute(w, nil) + type cake struct { + Name string + ID int + } + _ = c.tmpl["order/get_new"].Execute(w, struct{ Cakes []cake }{Cakes: []cake{cake{"Hello", 1}, cake{"World", 2}}}) } diff --git a/public/index.html b/public/index.html index 683e99c..e405e6c 100644 --- a/public/index.html +++ b/public/index.html @@ -6,6 +6,7 @@