Example #1
0
        public void Delete(int id)
        {
            Eveniment model = _evenimentRepository.Find(id);

            _evenimentRepository.Delete(model);
            _evenimentRepository.SaveChanges();
        }
Example #2
0
        public EvenimentDto Find(int id)
        {
            EvenimentDto model  = null;
            Eveniment    entity = _evenimentRepository.Find(id);

            if (entity != null)
            {
                model = Mapper.Map <EvenimentDto>(entity);
            }
            return(model);
        }