frontend to backend communication working, starting on locations page

This commit is contained in:
2021-12-08 23:11:50 -05:00
parent ce38e21dca
commit 41f6b5873c
18 changed files with 341 additions and 124 deletions

View File

@@ -11,6 +11,7 @@ import (
//Get Server Config
func (s *Server) GetServerConfig(c *fiber.Ctx) error {
fmt.Println("SENDING CONFIG!")
return c.Status(fiber.StatusOK).JSON(fiber.Map{"BasicAuth": s.Config.Authentication.BasicAuth, "Timezone": s.Config.Timezone})
}
@@ -90,8 +91,8 @@ func (s *Server) GetAllLocationsHandler(c *fiber.Ctx) error {
testLoc := Location{
ID: 1,
Description: "This is a description of the location",
Name: "testName",
CoverPhoto: "testString", // A "cover photo" for the location
Name: "Location1",
CoverPhoto: "testCover.png", // A "cover photo" for the location
Notes: "Notes String",
}
testLoc2 := Location{