Пример #1
0
        //EMOCION
        async Task <Int32> IDataInjector.CreateEmocion(Ekilibrate.Model.Entity.Participante.clsEmocionBase Data)
        {
            using (var scope = Ekilibrate.Data.Access.Common.ContainerConfig.ProxyContainer.BeginLifetimeScope("a"))
            {
                try
                {
                    var objController = new Ekilibrate.BL.Controller.Participante.clsEmocion(scope);
                    var result        = await objController.Create(Data);

                    var DBContext = scope.Resolve <DBTrnContext>();
                    DBContext.CommitTransaction();
                    return(result);
                }
                catch (FaultException ex)
                {
                    throw ex;
                }
                catch (Exception)
                {
                    throw new FaultException("Error al registrar los datos de area de emocion.");
                }
            }
        }
Пример #2
0
        async Task IDataInjector.DeleteEmocion(int ID_PARTICIPANTE)
        {
            using (var scope = Ekilibrate.Data.Access.Common.ContainerConfig.ProxyContainer.BeginLifetimeScope("a"))
            {
                try
                {
                    var objController = new Ekilibrate.BL.Controller.Participante.clsEmocion(scope);
                    await objController.Delete(ID_PARTICIPANTE);

                    var DBContext = scope.Resolve <DBTrnContext>();
                    DBContext.CommitTransaction();
                }
                catch (FaultException ex)
                {
                    throw ex;
                }
                catch (Exception ex)
                {
                    var objController = new Ekilibrate.BL.Common.clsLog(scope);
                    objController.GuardarLog(ex);
                    throw new FaultException("Error al eliminar datos del area de Emocion.");
                }
            }
        }
Пример #3
0
        async Task IDataInjector.UpdateEmocion(Ekilibrate.Model.Entity.Participante.clsEmocionBase Data)
        {
            using (var scope = Ekilibrate.Data.Access.Common.ContainerConfig.ProxyContainer.BeginLifetimeScope("a"))
            {
                try
                {
                    var objController = new Ekilibrate.BL.Controller.Participante.clsEmocion(scope);
                    await objController.Update(Data);

                    var DBContext = scope.Resolve <DBTrnContext>();
                    DBContext.CommitTransaction();
                }
                catch (FaultException ex)
                {
                    throw ex;
                }
                catch (Exception ex)
                {
                    var objController = new Ekilibrate.BL.Common.clsLog(scope);
                    objController.GuardarLog(ex);
                    throw new FaultException("Error al actualizar datos del area de emoción.");
                }
            }
        }