private Fpagos buildFpago(MySqlDataReader data) { Fpagos item = new Fpagos( Convert.ToInt16(data.GetInt16("c_formapago")), data.GetString("descripcion") ); return(item); }
public List <Fpagos> getpagosbyidlike(string codigo) { string query = "select c_formapago,descripcion from zz33_formapago where c_formapago like '" + codigo + "'"; MySqlDataReader data = runQuery(query); List <Fpagos> result = new List <Fpagos>(); if (data.HasRows) { while (data.Read()) { Fpagos item = buildFpago(data); result.Add(item); } } return(result); }