Beispiel #1
0
 public List<XObjs.Hwallet> getHwalletByTransID(string transID)
 {
     List<XObjs.Hwallet> list = new List<XObjs.Hwallet>();
     SqlConnection connection = new SqlConnection(hf.ConnectXpay());
     SqlCommand command = new SqlCommand("SELECT * FROM hwallet WHERE transID='" + transID + "' ", connection);
     connection.Open();
     command.CommandTimeout = 0;
     SqlDataReader reader = command.ExecuteReader(CommandBehavior.CloseConnection);
     while (reader.Read())
     {
         XObjs.Hwallet item = new XObjs.Hwallet {
             xid = reader["xid"].ToString(),
             transID = reader["transID"].ToString(),
             fee_detailsID = reader["fee_detailsID"].ToString(),
             used_status = reader["used_status"].ToString(),
             xreg_date = reader["xreg_date"].ToString()
         };
         list.Add(item);
     }
     reader.Close();
     return list;
 }
Beispiel #2
0
 public XObjs.Hwallet getHwalletByID(string xid)
 {
     XObjs.Hwallet hwallet = new XObjs.Hwallet();
     SqlConnection connection = new SqlConnection(hf.ConnectXpay());
     SqlCommand command = new SqlCommand("SELECT * FROM hwallet WHERE xid='" + xid + "' ", connection);
     connection.Open();
     command.CommandTimeout = 0;
     SqlDataReader reader = command.ExecuteReader(CommandBehavior.CloseConnection);
     while (reader.Read())
     {
         hwallet.xid = reader["xid"].ToString();
         hwallet.transID = reader["transID"].ToString();
         hwallet.fee_detailsID = reader["fee_detailsID"].ToString();
         hwallet.used_status = reader["used_status"].ToString();
         hwallet.xreg_date = reader["xreg_date"].ToString();
     }
     reader.Close();
     return hwallet;
 }