Exemplo n.º 1
0
        public async Task UpdateQueueAsync(QueueBm queueBm)
        {
            var queue = new Queue
            {
                Id        = queueBm.Id,
                Name      = queueBm.Name,
                AccountId = queueBm.AccountId,
                Address   = queueBm.Address,
                IsActive  = false
            };

            _storage.Queues.Update(queue);

            await _storage.SaveAsync();
        }
Exemplo n.º 2
0
        public async Task <QueueBm> CreateQueueAsync(QueueBm queueBm)
        {
            var queue = new Queue
            {
                Name      = queueBm.Name,
                AccountId = queueBm.AccountId,
                Address   = queueBm.Address,
                IsActive  = false
            };

            await _storage.Queues.CreateAsync(queue);

            await _storage.SaveAsync();

            return(_mapper.Map <QueueBm>(queue));
        }