Skip to content

Instantly share code, notes, and snippets.

@kutliev
Created February 11, 2018 19:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kutliev/a8499d442a0d5c7d07cde815349e7daa to your computer and use it in GitHub Desktop.
Save kutliev/a8499d442a0d5c7d07cde815349e7daa to your computer and use it in GitHub Desktop.
Spot save
saveSpot(spot: Spot): Observable<any> {
let apiEndPoint = this.settings.ApiEndPoint + "add-object";
let payload = {
"write_key": this.settings.ApiWriteKey,
"title": spot.title,
"type_slug": "spots",
"content": spot.content,
"metafields": [
{
"key": "type",
"title": "Type",
"value": spot.type
},
{
"key": "floor",
"value": spot.floor
},
{
"key": "customer",
"value": spot.customer
}
]
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment