Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Ingresando los Datos Get para mi vista Parcial
- public ActionResult _Empresas()
- {
- try
- {
- return PartialView();
- }
- catch (Exception e)
- {
- throw;
- }
- }
- [HttpPost]
- [ValidateAntiForgeryToken]
- [ChildActionOnly]
- public ActionResult _Empresas([Bind(Include = "empresa_id,nombre_empresa,nombre_responsable,activa,telefono,email,fecha_registro")] cat_empresas cat_empresas)
- {
- try
- {
- if (ModelState.IsValid)
- {
- db.cat_empresas.Add(cat_empresas);
- db.SaveChanges();
- }
- return PartialView();
- }
- catch (Exception ex)
- {
- throw;
- }
- }
Add Comment
Please, Sign In to add comment