Exemplo n.º 1
0
        public async Task <IActionResult> Edit(int id, [Bind("Id,FechaHora,Tipo")] EntrevistaEntity entrevistaEntity)
        {
            if (id != entrevistaEntity.Id)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    _context.Update(entrevistaEntity);
                    await _context.SaveChangesAsync();
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!EntrevistaEntityExists(entrevistaEntity.Id))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction(nameof(Index)));
            }
            return(View(entrevistaEntity));
        }
Exemplo n.º 2
0
        public async Task <IActionResult> Create([Bind("Id,FechaHora,Tipo")] EntrevistaEntity entrevistaEntity)
        {
            if (ModelState.IsValid)
            {
                _context.Add(entrevistaEntity);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(entrevistaEntity));
        }
Exemplo n.º 3
0
        public Business.Entity.EntrevistaEntity NuevaCabeceraEntrevista(EntrevistaEntity cabecera)
        {
            string Token = ActionContext.Request.Headers.GetValues("Token").First();

            return(Business.Data.PerfilEmpresasDataAccess.InsertaNuevoCabEntrevista(Token, cabecera.RutEmpresa, cabecera.FechaEntrevista, cabecera.NombreContacto, cabecera.Estamento, cabecera.Cargo, cabecera.Comentarios, cabecera.TelefonoContacto, cabecera.CorreoContacto, cabecera.IdAnexo));
        }