public override void KullanicilariAl() { if (sqlConnection.State == System.Data.ConnectionState.Closed) { sqlConnection.Open(); } SqlCommand cmd = new SqlCommand("select trim(KullaniciAdi),trim(KullaniciSifre),SuankiKullanici from kullanici", sqlConnection); SqlDataReader dr = cmd.ExecuteReader(); while (dr.Read()) { Kullanicilar.Add(new Kullanıcı(dr[0].ToString(), dr[1].ToString())); } sqlConnection.Close(); }
public MockData() { this.Kullanicilar = new List <Kullanici>(); Kullanicilar.Add(new Kullanici() { Ad = "Kamil", Email = "*****@*****.**", Soyad = "Fidil" }); Kullanicilar.Add(new Kullanici() { Ad = "Hakkı", Email = "*****@*****.**", Soyad = "Fidil" }); Kullanicilar.Add(new Kullanici() { Ad = "Kerim", Email = "*****@*****.**", Soyad = "Fidil" }); }