Exemple #1
0
        public bool Remover(Guid id)
        {
            TEntity obj = _repository.Consultar(id);

            obj.Ativo        = false;
            obj.DataExclusao = DateTime.Now;

            _repository.Alterar(obj);

            return(_unitOfWork.Commit());
        }
        public bool Alterar(TViewModel obj)
        {
            obj.DataAlteracao = DateTime.Now;

            _repository.Alterar(_mapper.Map <TModel>(obj));

            return(_unitOfWork.Commit());
        }