Open yoshelb opened 3 months ago
res.body ----- { "Spots": [ { "id": 1, "ownerId": 1, "address": "123 Disney Lane", "city": "San Francisco", "state": "California", "country": "United States of America", "lat": 37.7645358, "lng": -122.4730327, "name": "App Academy", "description": "Place where web developers are created", "price": 123, "createdAt": "2021-11-19 20:39:36", "updatedAt": "2021-11-19 20:39:36", "avgRating": 4.5, "previewImage": "image url" } ] }
THis needs to return an AVG rating which will need access to reviews and a little function to total the ratings. It will also return an image which belongs to SpotImages
Returns all the spots.
id
,ownerId
,address
,city
,state
,country
,lat
,lng
,name
,description
,price
,createdAt
,updatedAt
,previewImage
, andavgRating