From eb6bb65ef2c8dba86e26b80f3f426f6bed79bf09 Mon Sep 17 00:00:00 2001 From: umidar Date: Fri, 13 Jan 2023 10:31:31 -0500 Subject: [PATCH 01/14] Created update RSVP endpoint --- handlers/events.go | 53 +++++++++++++++++++++++- main.go | 3 ++ models/events.go | 8 ++++ sql/make_comment_id_nullable_in_rsvp.sql | 12 ++++-- 4 files changed, 71 insertions(+), 5 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index 6ac029b5..00bcfda2 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -73,4 +73,55 @@ func CreateRSVP(c *gin.Context) { return } c.JSON(201, rsvp) //success -} \ No newline at end of file +} + +func UpdateResponse(c *gin.Context) { + var rsvp models.UpdateResponse + var response []models.GetRSVP + + id := c.Param("RSVPID") + rsvpinfo, err := dbmap.Query( + "SELECT event_id, response_id, name, rsvp, contact_info FROM rsvp WHERE rsvp_id=?;", + id) + + + for rsvpinfo.Next() { + var userResponse models.GetRSVP + // for each row, scan into the event struct + err = rsvpinfo.Scan(&rsvp.EventID, &rsvp.ResponderName, &rsvp.RSVP) + if err != nil { + fmt.Println(err) + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + // append the event into events array + response = append(response, userResponse) + } + + // Call BindJSON to bind the received JSON to event +add error handling later + if err = c.BindJSON(&rsvp); err != nil { + c.IndentedJSON(http.StatusBadRequest, nil) //bad data + return + } + + if rsvp.ResponderName == ""{ + rsvp.ResponderName = response[0].ResponderName + } + if rsvp.ContactInfo == ""{ + rsvp.ContactInfo = response[0].ContactInfo + } + if rsvp.RSVP == ""{ + rsvp.RSVP = response[0].RSVP + } + + _, err = dbmap.Query( + "UPDATE rsvp SET name = ?, contact_info = ?, rsvp = ? WHERE rsvp_id = ?;", + rsvp.ResponderName, rsvp.ContactInfo, rsvp.RSVP) + + if err != nil { + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + + c.JSON(200, rsvp) //success +} diff --git a/main.go b/main.go index 75bd76dd..5ab526cc 100644 --- a/main.go +++ b/main.go @@ -35,6 +35,9 @@ func main() { api.GET("/event/:eventID", handlers.GetEvent) api.POST("/event/:eventID/rsvp", handlers.CreateRSVP) + + api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) + // Start and run the server router.Run(":3000") } diff --git a/models/events.go b/models/events.go index dcdeecba..29aeaff5 100644 --- a/models/events.go +++ b/models/events.go @@ -32,4 +32,12 @@ type CreateRSVP struct { EventID int `json:"event_id" binding:"required"` ResponderName string `json:"name" binding:"required"` RSVP string `json:"rsvp" binding:"required"` +} + +type UpdateResponse struct { + EventID int `json:"event_id" binding:"required"` + ResponderName string `json:"name" binding:"required"` + RSVP string `json:"rsvp" binding:"required"` + ContactInfo string `json:"contact_info" binding:"required"` + } \ No newline at end of file diff --git a/sql/make_comment_id_nullable_in_rsvp.sql b/sql/make_comment_id_nullable_in_rsvp.sql index df6eb85b..de4ecae1 100644 --- a/sql/make_comment_id_nullable_in_rsvp.sql +++ b/sql/make_comment_id_nullable_in_rsvp.sql @@ -3,7 +3,11 @@ use events; ALTER TABLE rsvp MODIFY comment_id integer DEFAULT NULL; -ALTER TABLE event -DROP COLUMN #_of_RSVP; -ALTER TABLE event -ADD COLUMN num_of_RSVP integer; +-- ALTER TABLE event +-- DROP COLUMN #_of_RSVP; +-- ALTER TABLE event +-- ADD COLUMN num_of_RSVP integer; + + +ALTER TABLE rsvp +ADD COLUMN contact_info text; \ No newline at end of file From 7a1ec11448e3c10530e9fdc22bb8a44b66766685 Mon Sep 17 00:00:00 2001 From: noshin07 Date: Thu, 12 Jan 2023 10:01:47 -0500 Subject: [PATCH 02/14] Created an endpoint to get a RSVP. --- handlers/events.go | 24 ++++++++++++++++++++++++ main.go | 1 + models/events.go | 8 +++++++- 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/handlers/events.go b/handlers/events.go index 00bcfda2..7172ab16 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -125,3 +125,27 @@ func UpdateResponse(c *gin.Context) { c.JSON(200, rsvp) //success } +func GetRSVP(c *gin.Context) { + var rsvp1 []models.GetRSVP + + see_row := c.Param("responseID") + RSVProw, err := dbmap.Query( + "SELECT response_id, event_id, name, rsvp, comment_id FROM RSVP WHERE response_id=?;", + see_row) + + fmt.Printf("%+v", RSVProw) + +for RSVProw.Next() { + var rsvp models.GetRSVP + // for each row, scan into the event struct + err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID) + if err != nil { + fmt.Println(err) + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return +} + // append the event into events array + rsvp1 = append(rsvp1, rsvp) +} + c.JSON(201, rsvp1) //success +} diff --git a/main.go b/main.go index 5ab526cc..001a7314 100644 --- a/main.go +++ b/main.go @@ -38,6 +38,7 @@ func main() { api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) + api.GET("/RSVP/:responseID", handlers.GetRSVP) // Start and run the server router.Run(":3000") } diff --git a/models/events.go b/models/events.go index 29aeaff5..045c7618 100644 --- a/models/events.go +++ b/models/events.go @@ -39,5 +39,11 @@ type UpdateResponse struct { ResponderName string `json:"name" binding:"required"` RSVP string `json:"rsvp" binding:"required"` ContactInfo string `json:"contact_info" binding:"required"` - +} +type GetRSVP struct { + ResponseID int `json:"response_id"` + EventID int `json:"event_id"` + Name string `json:"name` + RSVP string `json:"rsvp" ` + CommentID int `json:"comment_id" ` } \ No newline at end of file From 33a73076bb1981959e539542bc3bca6dabfaeb9e Mon Sep 17 00:00:00 2001 From: noshin07 Date: Thu, 12 Jan 2023 13:21:22 -0500 Subject: [PATCH 03/14] Cleaned up the files. --- handlers/events.go | 45 +++++++++++++++++++++------------------------ 1 file changed, 21 insertions(+), 24 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index 7172ab16..878ed73d 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -20,7 +20,7 @@ func CreateEvent(c *gin.Context) { _, err := dbmap.Query( "INSERT INTO event (title, date, time, location, host_name, description, contact_info, public_private, num_of_RSVP, max_attendees) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?);", event.EventTitle, event.Date, event.Time, event.Location, event.HostName, event.Description, event.ContactInfo, event.PublicPrivate, event.NumRSVP, event.MaxAttendees) - + if err != nil { c.IndentedJSON(http.StatusInternalServerError, nil) //server error return @@ -37,17 +37,17 @@ func GetEvent(c *gin.Context) { see_row) fmt.Printf("%+v", eventrow) - + for eventrow.Next() { var event models.GetEvent - // for each row, scan into the event struct + // for each row, scan into the event struct err = eventrow.Scan(&event.EventID, &event.EventTitle, &event.Date, &event.Time, &event.Location, &event.HostName, &event.Description, &event.ContactInfo, &event.PublicPrivate, &event.NumRSVP, &event.MaxAttendees) if err != nil { - fmt.Println(err) - c.IndentedJSON(http.StatusInternalServerError, nil) //server error - return - } - // append the event into events array + fmt.Println(err) + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + // append the event into events array events = append(events, event) } c.JSON(201, events) //success @@ -126,26 +126,23 @@ func UpdateResponse(c *gin.Context) { c.JSON(200, rsvp) //success } func GetRSVP(c *gin.Context) { - var rsvp1 []models.GetRSVP + var rsvpList []models.GetRSVP see_row := c.Param("responseID") RSVProw, err := dbmap.Query( "SELECT response_id, event_id, name, rsvp, comment_id FROM RSVP WHERE response_id=?;", - see_row) + seeRow) - fmt.Printf("%+v", RSVProw) - -for RSVProw.Next() { - var rsvp models.GetRSVP - // for each row, scan into the event struct - err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID) - if err != nil { - fmt.Println(err) - c.IndentedJSON(http.StatusInternalServerError, nil) //server error - return -} - // append the event into events array - rsvp1 = append(rsvp1, rsvp) -} + for RSVProw.Next() { + var rsvp models.GetRSVP + // for each row, scan into the event struct + err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID) + if err != nil { + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + // append the event into events array + rsvpList = append(rsvpList, rsvp) + } c.JSON(201, rsvp1) //success } From 157bd0c1f5e375cd65ff614b2b3542e5f7e983fe Mon Sep 17 00:00:00 2001 From: noshin07 Date: Fri, 13 Jan 2023 09:25:10 -0500 Subject: [PATCH 04/14] Resolved rebase conflicts --- handlers/events.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index 878ed73d..c29c543e 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -128,7 +128,7 @@ func UpdateResponse(c *gin.Context) { func GetRSVP(c *gin.Context) { var rsvpList []models.GetRSVP - see_row := c.Param("responseID") + seeRow := c.Param("responseID") RSVProw, err := dbmap.Query( "SELECT response_id, event_id, name, rsvp, comment_id FROM RSVP WHERE response_id=?;", seeRow) @@ -144,5 +144,5 @@ func GetRSVP(c *gin.Context) { // append the event into events array rsvpList = append(rsvpList, rsvp) } - c.JSON(201, rsvp1) //success + c.JSON(201, rsvpList) //success } From 992ae2befd9941dcb28f3a5c80e9e0ee45bb7e37 Mon Sep 17 00:00:00 2001 From: umidar Date: Fri, 13 Jan 2023 11:29:14 -0500 Subject: [PATCH 05/14] Null commentID --- handlers/events.go | 1 + models/events.go | 2 +- sql/make_comment_id_nullable_in_rsvp.sql | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index c29c543e..aa147f3d 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -139,6 +139,7 @@ func GetRSVP(c *gin.Context) { err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID) if err != nil { c.IndentedJSON(http.StatusInternalServerError, nil) //server error + fmt.Println(err) return } // append the event into events array diff --git a/models/events.go b/models/events.go index 045c7618..d7d7340e 100644 --- a/models/events.go +++ b/models/events.go @@ -45,5 +45,5 @@ type GetRSVP struct { EventID int `json:"event_id"` Name string `json:"name` RSVP string `json:"rsvp" ` - CommentID int `json:"comment_id" ` + CommentID *int `json:"comment_id" ` } \ No newline at end of file diff --git a/sql/make_comment_id_nullable_in_rsvp.sql b/sql/make_comment_id_nullable_in_rsvp.sql index de4ecae1..2472899b 100644 --- a/sql/make_comment_id_nullable_in_rsvp.sql +++ b/sql/make_comment_id_nullable_in_rsvp.sql @@ -10,4 +10,4 @@ MODIFY comment_id integer DEFAULT NULL; ALTER TABLE rsvp -ADD COLUMN contact_info text; \ No newline at end of file +ADD COLUMN contact_info text; From 614635d55c516825cc37ebe99c80476e58e150ba Mon Sep 17 00:00:00 2001 From: umidar Date: Fri, 13 Jan 2023 11:47:30 -0500 Subject: [PATCH 06/14] Merged Get RSVP endpoint --- handlers/events.go | 51 ++++++++++++++++++++++++++++++++++++++++++++++ main.go | 3 +++ models/events.go | 8 ++++++++ 3 files changed, 62 insertions(+) diff --git a/handlers/events.go b/handlers/events.go index aa147f3d..895273b0 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -147,3 +147,54 @@ func GetRSVP(c *gin.Context) { } c.JSON(201, rsvpList) //success } + +func UpdateResponse(c *gin.Context) { + var rsvp models.UpdateResponse + var response []models.GetRSVP + + id := c.Param("RSVPID") + rsvpinfo, err := dbmap.Query( + "SELECT event_id, response_id, name, rsvp, contact_info FROM rsvp WHERE rsvp_id=?;", + id) + + + for rsvpinfo.Next() { + var userResponse models.GetRSVP + // for each row, scan into the event struct + err = rsvpinfo.Scan(&rsvp.EventID, &rsvp.ResponderName, &rsvp.RSVP) + if err != nil { + fmt.Println(err) + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + // append the event into events array + response = append(response, userResponse) + } + + // Call BindJSON to bind the received JSON to event +add error handling later + if err = c.BindJSON(&rsvp); err != nil { + c.IndentedJSON(http.StatusBadRequest, nil) //bad data + return + } + + if rsvp.ResponderName == ""{ + rsvp.ResponderName = response[0].ResponderName + } + if rsvp.ContactInfo == ""{ + rsvp.ContactInfo = response[0].ContactInfo + } + if rsvp.RSVP == ""{ + rsvp.RSVP = response[0].RSVP + } + + _, err = dbmap.Query( + "UPDATE rsvp SET name = ?, contact_info = ?, rsvp = ? WHERE rsvp_id = ?;", + rsvp.ResponderName, rsvp.ContactInfo, rsvp.RSVP) + + if err != nil { + c.IndentedJSON(http.StatusInternalServerError, nil) //server error + return + } + + c.JSON(200, rsvp) //success +} diff --git a/main.go b/main.go index 001a7314..39800f4c 100644 --- a/main.go +++ b/main.go @@ -39,6 +39,9 @@ func main() { api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) api.GET("/RSVP/:responseID", handlers.GetRSVP) + + api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) + // Start and run the server router.Run(":3000") } diff --git a/models/events.go b/models/events.go index d7d7340e..f91e23bd 100644 --- a/models/events.go +++ b/models/events.go @@ -46,4 +46,12 @@ type GetRSVP struct { Name string `json:"name` RSVP string `json:"rsvp" ` CommentID *int `json:"comment_id" ` +} + +type UpdateResponse struct { + EventID int `json:"event_id" binding:"required"` + ResponderName string `json:"name" binding:"required"` + RSVP string `json:"rsvp" binding:"required"` + ContactInfo string `json:"contact_info" binding:"required"` + } \ No newline at end of file From e5fc49ec99727a69e506bf64e5acf66a833b6a28 Mon Sep 17 00:00:00 2001 From: umidar Date: Fri, 13 Jan 2023 15:32:08 -0500 Subject: [PATCH 07/14] Update response endpoint ready to test --- handlers/events.go | 29 +++++++++++++++++------------ models/events.go | 11 ++++++----- 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index 895273b0..8a4203b7 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -130,13 +130,13 @@ func GetRSVP(c *gin.Context) { seeRow := c.Param("responseID") RSVProw, err := dbmap.Query( - "SELECT response_id, event_id, name, rsvp, comment_id FROM RSVP WHERE response_id=?;", + "SELECT response_id, event_id, name, rsvp, comment_id, contact_info FROM RSVP WHERE response_id=?;", seeRow) for RSVProw.Next() { var rsvp models.GetRSVP // for each row, scan into the event struct - err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID) + err = RSVProw.Scan(&rsvp.ResponseID, &rsvp.EventID, &rsvp.Name, &rsvp.RSVP, &rsvp.CommentID, &rsvp.ContactInfo) if err != nil { c.IndentedJSON(http.StatusInternalServerError, nil) //server error fmt.Println(err) @@ -152,16 +152,16 @@ func UpdateResponse(c *gin.Context) { var rsvp models.UpdateResponse var response []models.GetRSVP - id := c.Param("RSVPID") + id := c.Param("rsvpID") rsvpinfo, err := dbmap.Query( - "SELECT event_id, response_id, name, rsvp, contact_info FROM rsvp WHERE rsvp_id=?;", + "SELECT response_id, name, rsvp, contact_info FROM rsvp WHERE response_id=?", id) - + fmt.Printf("%+v", rsvpinfo) for rsvpinfo.Next() { var userResponse models.GetRSVP // for each row, scan into the event struct - err = rsvpinfo.Scan(&rsvp.EventID, &rsvp.ResponderName, &rsvp.RSVP) + err = rsvpinfo.Scan(&rsvp.ResponseID, &rsvp.Name, &rsvp.RSVP, &rsvp.ContactInfo) if err != nil { fmt.Println(err) c.IndentedJSON(http.StatusInternalServerError, nil) //server error @@ -173,28 +173,33 @@ func UpdateResponse(c *gin.Context) { // Call BindJSON to bind the received JSON to event +add error handling later if err = c.BindJSON(&rsvp); err != nil { + fmt.Println(err) c.IndentedJSON(http.StatusBadRequest, nil) //bad data return } - if rsvp.ResponderName == ""{ - rsvp.ResponderName = response[0].ResponderName + if rsvp.Name == ""{ + rsvp.Name = response[0].Name } - if rsvp.ContactInfo == ""{ + if rsvp.ContactInfo == nil{ rsvp.ContactInfo = response[0].ContactInfo } if rsvp.RSVP == ""{ rsvp.RSVP = response[0].RSVP } + if rsvp.ResponseID == 0{ + rsvp.ResponseID = response[0].ResponseID + } _, err = dbmap.Query( - "UPDATE rsvp SET name = ?, contact_info = ?, rsvp = ? WHERE rsvp_id = ?;", - rsvp.ResponderName, rsvp.ContactInfo, rsvp.RSVP) + "UPDATE rsvp SET name = ?, contact_info = ?, rsvp = ? WHERE response_id = ?;", + rsvp.Name, rsvp.ContactInfo, rsvp.RSVP, id) if err != nil { + fmt.Println(err) c.IndentedJSON(http.StatusInternalServerError, nil) //server error return } - c.JSON(200, rsvp) //success + c.JSON(201, rsvp) //success } diff --git a/models/events.go b/models/events.go index f91e23bd..4b285799 100644 --- a/models/events.go +++ b/models/events.go @@ -45,13 +45,14 @@ type GetRSVP struct { EventID int `json:"event_id"` Name string `json:"name` RSVP string `json:"rsvp" ` - CommentID *int `json:"comment_id" ` + CommentID *int `json:"comment_id" ` + ContactInfo *string `json:"contact_info"` } type UpdateResponse struct { - EventID int `json:"event_id" binding:"required"` - ResponderName string `json:"name" binding:"required"` - RSVP string `json:"rsvp" binding:"required"` - ContactInfo string `json:"contact_info" binding:"required"` + ResponseID int `json:"response_id"` + Name string `json:"name"` + RSVP string `json:"rsvp"` + ContactInfo *string `json:"contact_info"` } \ No newline at end of file From eef261416c595add7e50e904850d6819996118f0 Mon Sep 17 00:00:00 2001 From: umidar Date: Fri, 13 Jan 2023 15:49:30 -0500 Subject: [PATCH 08/14] Fixed errors, ready for test --- handlers/events.go | 50 ---------------------------------------------- main.go | 2 -- models/events.go | 7 +------ 3 files changed, 1 insertion(+), 58 deletions(-) diff --git a/handlers/events.go b/handlers/events.go index 8a4203b7..00920747 100644 --- a/handlers/events.go +++ b/handlers/events.go @@ -75,56 +75,6 @@ func CreateRSVP(c *gin.Context) { c.JSON(201, rsvp) //success } -func UpdateResponse(c *gin.Context) { - var rsvp models.UpdateResponse - var response []models.GetRSVP - - id := c.Param("RSVPID") - rsvpinfo, err := dbmap.Query( - "SELECT event_id, response_id, name, rsvp, contact_info FROM rsvp WHERE rsvp_id=?;", - id) - - - for rsvpinfo.Next() { - var userResponse models.GetRSVP - // for each row, scan into the event struct - err = rsvpinfo.Scan(&rsvp.EventID, &rsvp.ResponderName, &rsvp.RSVP) - if err != nil { - fmt.Println(err) - c.IndentedJSON(http.StatusInternalServerError, nil) //server error - return - } - // append the event into events array - response = append(response, userResponse) - } - - // Call BindJSON to bind the received JSON to event +add error handling later - if err = c.BindJSON(&rsvp); err != nil { - c.IndentedJSON(http.StatusBadRequest, nil) //bad data - return - } - - if rsvp.ResponderName == ""{ - rsvp.ResponderName = response[0].ResponderName - } - if rsvp.ContactInfo == ""{ - rsvp.ContactInfo = response[0].ContactInfo - } - if rsvp.RSVP == ""{ - rsvp.RSVP = response[0].RSVP - } - - _, err = dbmap.Query( - "UPDATE rsvp SET name = ?, contact_info = ?, rsvp = ? WHERE rsvp_id = ?;", - rsvp.ResponderName, rsvp.ContactInfo, rsvp.RSVP) - - if err != nil { - c.IndentedJSON(http.StatusInternalServerError, nil) //server error - return - } - - c.JSON(200, rsvp) //success -} func GetRSVP(c *gin.Context) { var rsvpList []models.GetRSVP diff --git a/main.go b/main.go index 39800f4c..1398375a 100644 --- a/main.go +++ b/main.go @@ -36,8 +36,6 @@ func main() { api.POST("/event/:eventID/rsvp", handlers.CreateRSVP) - api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) - api.GET("/RSVP/:responseID", handlers.GetRSVP) api.PATCH("/rsvp/:rsvpID", handlers.UpdateResponse) diff --git a/models/events.go b/models/events.go index 4b285799..cc95cf4d 100644 --- a/models/events.go +++ b/models/events.go @@ -34,12 +34,7 @@ type CreateRSVP struct { RSVP string `json:"rsvp" binding:"required"` } -type UpdateResponse struct { - EventID int `json:"event_id" binding:"required"` - ResponderName string `json:"name" binding:"required"` - RSVP string `json:"rsvp" binding:"required"` - ContactInfo string `json:"contact_info" binding:"required"` -} + type GetRSVP struct { ResponseID int `json:"response_id"` EventID int `json:"event_id"` From d5b25640374d38a67e18035a226a3c62d459a1c4 Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:52:23 -0500 Subject: [PATCH 09/14] Format changes --- models/events.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/models/events.go b/models/events.go index cc95cf4d..721d619f 100644 --- a/models/events.go +++ b/models/events.go @@ -45,9 +45,9 @@ type GetRSVP struct { } type UpdateResponse struct { - ResponseID int `json:"response_id"` - Name string `json:"name"` - RSVP string `json:"rsvp"` - ContactInfo *string `json:"contact_info"` + ResponseID int `json:"response_id"` + Name string `json:"name"` + RSVP string `json:"rsvp"` + ContactInfo *string `json:"contact_info"` } \ No newline at end of file From f37db256b1564a3bf25a2db1dd0c7fb3b2babb72 Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:54:49 -0500 Subject: [PATCH 10/14] Format changes (2) --- models/events.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/models/events.go b/models/events.go index 721d619f..3db913b6 100644 --- a/models/events.go +++ b/models/events.go @@ -45,9 +45,9 @@ type GetRSVP struct { } type UpdateResponse struct { - ResponseID int `json:"response_id"` - Name string `json:"name"` - RSVP string `json:"rsvp"` - ContactInfo *string `json:"contact_info"` + ResponseID int `json:"response_id"` + Name string `json:"name"` + RSVP string `json:"rsvp"` + ContactInfo *string `json:"contact_info"` } \ No newline at end of file From 8844daf4af5c07e50a85e935b0c868aa09bb1814 Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:55:55 -0500 Subject: [PATCH 11/14] Format changes (3) --- models/events.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/events.go b/models/events.go index 3db913b6..faea4747 100644 --- a/models/events.go +++ b/models/events.go @@ -46,7 +46,7 @@ type GetRSVP struct { type UpdateResponse struct { ResponseID int `json:"response_id"` - Name string `json:"name"` + Name string `json:"name"` RSVP string `json:"rsvp"` ContactInfo *string `json:"contact_info"` From f8a6e70567ecdd78661ed9d53c254459a4b7eb59 Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:57:16 -0500 Subject: [PATCH 12/14] Format changes (4) --- models/events.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/events.go b/models/events.go index faea4747..2b48c9e1 100644 --- a/models/events.go +++ b/models/events.go @@ -46,7 +46,7 @@ type GetRSVP struct { type UpdateResponse struct { ResponseID int `json:"response_id"` - Name string `json:"name"` + Name string `json:"name"` RSVP string `json:"rsvp"` ContactInfo *string `json:"contact_info"` From f0ee245e640615584624a006c6a7b136b05e56d0 Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:58:07 -0500 Subject: [PATCH 13/14] Format changes (5) --- models/events.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/events.go b/models/events.go index 2b48c9e1..faea4747 100644 --- a/models/events.go +++ b/models/events.go @@ -46,7 +46,7 @@ type GetRSVP struct { type UpdateResponse struct { ResponseID int `json:"response_id"` - Name string `json:"name"` + Name string `json:"name"` RSVP string `json:"rsvp"` ContactInfo *string `json:"contact_info"` From 09af679844194e0ae69446b9d71d6e426c27f0dc Mon Sep 17 00:00:00 2001 From: umidar Date: Tue, 17 Jan 2023 12:59:47 -0500 Subject: [PATCH 14/14] Format changes (6) --- models/events.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/models/events.go b/models/events.go index faea4747..3db913b6 100644 --- a/models/events.go +++ b/models/events.go @@ -46,7 +46,7 @@ type GetRSVP struct { type UpdateResponse struct { ResponseID int `json:"response_id"` - Name string `json:"name"` + Name string `json:"name"` RSVP string `json:"rsvp"` ContactInfo *string `json:"contact_info"`