Contracts for buyer

This commit is contained in:
Nedim
2023-10-03 18:26:57 +02:00
parent 7df0c64d15
commit 2cfac4a023
9 changed files with 283 additions and 70 deletions

View File

@@ -133,7 +133,7 @@ func GetDeviceData(c *gin.Context) {
}
// Respond with the GeoJSON feature collection
c.JSON(http.StatusOK, featureCollection)
c.JSON(http.StatusOK, gin.H{"data": featureCollection})
}
func GetDevicesByContract(c *gin.Context) {
@@ -161,5 +161,5 @@ func GetDevicesByContract(c *gin.Context) {
return
}
// Respond with the devices
c.JSON(http.StatusOK, devices)
c.JSON(http.StatusOK,gin.H{"data" : devices})
}