public List <BE_Reclamo> f_buscaBoletoPasajero(String nroboleto, string dni) { List <BE_Reclamo> lst = new List <BE_Reclamo>(); SqlParameter[] param = new SqlParameter[2]; param[0] = new SqlParameter("pNROBOLETO", SqlDbType.VarChar); param[0].Value = nroboleto; param[0].Direction = ParameterDirection.Input; param[1] = new SqlParameter("pDNI", SqlDbType.VarChar); param[1].Value = dni; param[1].Direction = ParameterDirection.Input; DataSet ds = SqlHelper.ExecuteDataSet(Conexion.CadenaConexion, System.Data.CommandType.StoredProcedure, "SP_BOLETOCONSULTARRECLAMO", param); int ColumnCount = ds.Tables.Count; DataTable dt = ds.Tables[0]; foreach (DataRow dr in dt.Rows) { //Object of the propery class BE_Reclamo objReclamo = new BE_Reclamo(); //asign values objReclamo.NroBoleto = dr["CHR_NUMEROBOLETO"].ToString(); objReclamo.Pasajero = dr["PASAJERO"].ToString(); objReclamo.Direccion = dr["VCH_DIRECCION"].ToString(); objReclamo.Telefono = dr["VCH_TELEFONO"].ToString(); objReclamo.FechaActual = dr["FECHAACTUAL"].ToString(); objReclamo.HoraActual = dr["HORAACTUAL"].ToString(); //add one row to the list lst.Add(objReclamo); } return(lst); }
private void RegistrarReclamo() { IBL_Reclamo carga = new BL_Reclamo(); BE_Reclamo objReclamo = carga.f_registrarReclamo(txtNroBoleto.Text, Convert.ToInt32(dlTipoSolicitud.SelectedValue), Convert.ToInt32(dlArea.SelectedValue), txtMotivo.Text); lblInfo.Text = "Se ha registrado correctamente su reclamo, en breve se estará enviando a su correo personal la solicitud del reclamo. Gracias por confiar en Cruz del Sur"; lblTipoSolicitud.Visible = false; lblArea.Visible = false; lblMotivo.Visible = false; dlTipoSolicitud.Visible = false; dlArea.Visible = false; txtMotivo.Visible = false; btnRegistrar.Visible = false; gv1.Visible = false; txtNroBoleto.Text = ""; txtDNI.Text = ""; txtMotivo.Text = ""; LlenarTipoSolicitud(); LlenarArea(); //string message = "Se ha registrado correctamente su reclamo, en breve se estara enviado a su correo personal la solicitud del reclamo."; //System.Text.StringBuilder sb = new System.Text.StringBuilder(); //sb.Append("<script type = 'text/javascript'>"); //sb.Append("window.onload=function(){"); //sb.Append("alert('"); //sb.Append(message); //sb.Append("')};"); //sb.Append("</script>"); //ClientScript.RegisterClientScriptBlock(this.GetType(), "alert", sb.ToString()); }