Exemple #1
0
        public async Task <List> Upsert(List list)
        {
            var group = await groupClient.GetItem(Group.EntityPartitionKey, list.GroupId);

            var upsertedList = await client.UpsertItem(list);

            if (!group.ListIdExists(list.Id))
            {
                group.AddListId(list.Id);
                await groupClient.UpsertItem(group);
            }

            return(upsertedList);
        }
Exemple #2
0
 public Task <User> Get(string id)
 => client.GetItem(User.EntityPartitionKey, id);
Exemple #3
0
 public Task <Group> GetGroup(string id) => repository.GetItem(Group.EntityPartitionKey, id);