Beispiel #1
0
 // PUT request to edit a Restaurant.
 public static async Task<Document> EditRestaurant(string id, Restaurant item)
 {
     Document doc = GetDocument(id);
     return await Client.ReplaceDocumentAsync(doc.SelfLink, item);
 }
Beispiel #2
0
 // POST request to make a new Restaurant
 public static async Task<dynamic> CreateRestaurantAsync(Restaurant rest)
 {
     return await Client.CreateDocumentAsync(Collection.SelfLink, rest);
 }