Skip to content

Instantly share code, notes, and snippets.

@moosebay
Created May 15, 2017 11:08
Show Gist options
  • Save moosebay/87d5ac88ed408f2fb40d76b8d9ad2b16 to your computer and use it in GitHub Desktop.
Save moosebay/87d5ac88ed408f2fb40d76b8d9ad2b16 to your computer and use it in GitHub Desktop.
Salada example
let post = Post()
post.userId = currentUser.uid
post.city = place.city
post.location = CLLocation(latitude: place.location.latitude, longitude: place.location.longitude
post.sportType = SportType.soccer
post.venue = venueName
post.zipCode = place.zip
post.placeName = place.placeName
post.save { (ref, error) in
DataService.ds.GEO_SPORTTYPE_LOCATION(sporttype: post.sportType).setLocation(post.location, forKey: ref?.key)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment