Ejemplo n.º 1
0
        public async Task <bool> UpdateCustomTaskAsync(CustomTask customTaskToUpdate)
        {
            var cosmosCustomTask = new CosmosCustomTaskDto
            {
                Title       = customTaskToUpdate.Title,
                Description = customTaskToUpdate.Description
            };

            var response = await _cosmosStore.UpdateAsync(cosmosCustomTask);

            return(response.IsSuccess);
        }
Ejemplo n.º 2
0
        public async Task <bool> CreateCustomTaskAsync(CustomTask customTask)
        {
            var cosmosCustomTask = new CosmosCustomTaskDto
            {
                Title       = customTask.Title,
                Description = customTask.Description
            };

            var response = await _cosmosStore.AddAsync(cosmosCustomTask);

            customTask.Title = cosmosCustomTask.Title;
            return(response.IsSuccess);
        }