Exemplo n.º 1
0
        public virtual OperationResult <List <Service> > List()
        {
            try
            {
                using var transactionScope = new TransactionScope(TransactionScopeOption.Required, transactionOptions, TransactionScopeAsyncFlowOption.Enabled);
                var result = _dao.List();
                transactionScope.Complete();

                return(new OperationResult <List <Service> >()
                {
                    Success = true, Result = result
                });
            }
            catch (Exception e)
            {
                return(new OperationResult <List <Service> >()
                {
                    Success = false, Exception = e
                });
            }
        }