public int uspINS_RRHH_FORMATIVO_FASE(BE_RRHH_FORMATIVO_FASE obj) { try { return(new DA_RRHH_FORMATIVO_FICHA().uspINS_RRHH_FORMATIVO_FASE(obj)); } catch (Exception ex) { throw ex; } }
public int uspINS_RRHH_FORMATIVO_FASE(BE_RRHH_FORMATIVO_FASE obj) { object[] Parametros = new[] { (object)UC_FormWeb.mSQLFieldOrNull(obj.IDE_FASE, tgSQLFieldType.NUMERIC), (object)UC_FormWeb.mSQLFieldOrNull(obj.PROYECTO, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.JEFE, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.FECHA_INICIO, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.FECHA_FIN, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.UBICACION, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.CARGO, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.USER_REGISTRO, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.IDE_FICHA, tgSQLFieldType.NUMERIC), (object)UC_FormWeb.mSQLFieldOrNull(obj.OBSERVACIONES, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.CORREO_JEFE, tgSQLFieldType.TEXT), (object)UC_FormWeb.mSQLFieldOrNull(obj.ID_EMPRESA, tgSQLFieldType.NUMERIC), }; return(Convert.ToInt32(new Utilitarios().ExecuteScalar("uspINS_RRHH_FORMATIVO_FASE", Parametros))); }
protected void GuardarFase(int IDE_FASE) { string cleanMessage = string.Empty; if (lblCodigoFicha.Text == string.Empty) { capturarDatos(); //cleanMessage = "Falta registrar ficha"; //ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else { if (ddlEmpresa.SelectedIndex < 1) { cleanMessage = "Seleccionar empresa"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (ddlProyecto.SelectedIndex < 1) { cleanMessage = "Seleccionar centro costo"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtInicio.Text == string.Empty) { cleanMessage = "Ingresar fecha de inicio"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtTermino.Text == string.Empty) { cleanMessage = "Ingresar fecha final"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtUbicacion.Text == string.Empty) { cleanMessage = "Ingresar ubicación"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtCargoPracticante.Text == string.Empty) { cleanMessage = "Ingresar cargo"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtJefe.Text == string.Empty) { cleanMessage = "Ingresar jefe directo"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else if (txtCorreoJefe.Text == string.Empty) { cleanMessage = "Ingresar correo jefe"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } else { capturarDatos(); if (lblCodigoFicha.Text != string.Empty) { BE_RRHH_FORMATIVO_FASE obj = new BE_RRHH_FORMATIVO_FASE(); obj.IDE_FASE = IDE_FASE; obj.PROYECTO = ddlProyecto.SelectedValue.ToString(); obj.JEFE = txtJefe.Text; obj.FECHA_INICIO = txtInicio.Text; obj.FECHA_FIN = txtTermino.Text; obj.UBICACION = txtUbicacion.Text; obj.CARGO = txtCargoPracticante.Text; obj.USER_REGISTRO = Session["IDE_USUARIO"].ToString(); obj.IDE_FICHA = Convert.ToInt32(lblCodigoFicha.Text); obj.OBSERVACIONES = txtObjetivos.Text; obj.CORREO_JEFE = txtCorreoJefe.Text.Trim(); obj.ID_EMPRESA = Convert.ToInt32(ddlEmpresa.SelectedValue); int rpta = 0; rpta = new BL_RRHH_FORMATIVO_FICHA().uspINS_RRHH_FORMATIVO_FASE(obj); if (rpta > 0) { lblIDE_FASE.Text = string.Empty; txtJefe.Text = string.Empty; txtInicio.Text = string.Empty; txtTermino.Text = string.Empty; txtUbicacion.Text = string.Empty; txtCargoPracticante.Text = string.Empty; txtObjetivos.Text = string.Empty; txtCorreoJefe.Text = string.Empty; ListarFases(); cleanMessage = "Registro satisfactorio"; ScriptManager.RegisterStartupScript(this, typeof(Page), "invocarfuncion", "doAlert('" + cleanMessage + "');", true); } } } } }