Exemplo n.º 1
0
 public RatingResponse(RatingInput input)
 {
     UserId       = input.UserId;
     ProductId    = input.ProductId;
     LocationName = input.LocationName;
     Rating       = input.Rating;
     UserNotes    = input.UserNotes;
     Id           = Guid.NewGuid().ToString();
     Timestamp    = DateTime.UtcNow;
     PartitionKey = "RATING";
     RowKey       = Id;
 }
Exemplo n.º 2
0
        private static async Task <RatingResponse> WriteToTable(CloudTable outputTable, RatingInput input)
        {
            var response          = new RatingResponse(input);
            var addEntryOperation = TableOperation.Insert(response);
            await outputTable.ExecuteAsync(addEntryOperation);

            return(response);
        }