Esempio n. 1
0
        public Result InsertLogisticsData(tblLogistics logisticsList)
        {
            IProduction iProductionSelect = new WCMS_DAL_Production();
            var         result            = new Result();

            using (
                var transaction = new TransactionScope(TransactionScopeOption.Required,
                                                       ApplicationState.TransactionOptions))
                try
                {
                    result.IsSuccess = iProductionSelect.tblLogistics(logisticsList);

                    if (result.IsSuccess)
                    {
                        transaction.Complete();
                    }
                    else
                    {
                        transaction.Dispose();
                    }
                }
                catch (Exception ex)
                {
                    throw ex;
                }
            return(result);
        }