// GET: TipoexameController/Delete/5
        public ActionResult Delete(int id)
        {
            Tipoexame      tipoExame      = _tipoexameService.Obter(id);
            TipoexameModel tipoExameModel = _mapper.Map <TipoexameModel>(tipoExame);

            return(View(tipoExameModel));
        }
예제 #2
0
        // GET: ExameController/Details/5
        public ActionResult Details(int id)
        {
            Exame     exame     = _exameService.Obter(id);
            Consulta  consulta  = _consultaService.Obter(exame.IdConsulta);
            Animal    animal    = _animalService.Obter(exame.IdAnimal);
            Tipoexame tipoExame = _tipoexameService.Obter(exame.IdTipoExame);

            ViewBag.IdConsulta  = consulta.Descricao;
            ViewBag.IdAnimal    = animal.Nome;
            ViewBag.IdTipoExame = tipoExame.Tipo;

            ExameModel exameModel = _mapper.Map <ExameModel>(exame);

            return(View(exameModel));
        }
예제 #3
0
 public int Inserir(Tipoexame tipoexame)
 {
     _context.Add(tipoexame);
     _context.SaveChanges();
     return(tipoexame.IdTipoExame);
 }
예제 #4
0
 public void Editar(Tipoexame tipoexame)
 {
     _context.Update(tipoexame);
     _context.SaveChanges();
 }