Exemplo n.º 1
0
        private void BTNKAYDET3_Click(object sender, EventArgs e)
        {
            EntityClassKulup ent = new EntityClassKulup();

            ent.KULUPAD = TXTKULUPAD.Text;
            LogicClassKulup.EKLE(ent);
        }
Exemplo n.º 2
0
        private void BTNGUNCELLE3_Click(object sender, EventArgs e)
        {
            EntityClassKulup ent = new EntityClassKulup();

            ent.KULUPAD = TXTKULUPAD.Text;
            ent.KULUPID = Convert.ToInt16(TXTKULUPID.Text);
            LogicClassKulup.GUNCELLE(ent);
            KulupListesi();
        }
Exemplo n.º 3
0
 public static bool GUNCELLE(EntityClassKulup entKulup)
 {
     if (entKulup.KULUPAD != "")
     {
         return(FacadeClassKulup.GUNCELLE(entKulup));
     }
     else
     {
         return(false);
     }
 }
Exemplo n.º 4
0
 public static int EKLE(EntityClassKulup entKulup)
 {
     if (entKulup.KULUPAD != "")
     {
         return(FacadeClassKulup.EKLE(entKulup));
     }
     else
     {
         return(-1);
     }
 }
Exemplo n.º 5
0
        public static int EKLE(EntityClassKulup entKulup)
        {
            SqlCommand cm1 = new SqlCommand("KULUPEKLE", ConnectionClass.cn);

            cm1.CommandType = CommandType.StoredProcedure;
            if (cm1.Connection.State != ConnectionState.Open)
            {
                cm1.Connection.Open();
            }
            cm1.Parameters.AddWithValue("KULUPAD", entKulup.KULUPAD);
            return(cm1.ExecuteNonQuery());
        }
Exemplo n.º 6
0
        public static List <EntityClassKulup> KULUPLISTESI()
        {
            List <EntityClassKulup> values = new List <EntityClassKulup>();
            SqlCommand cm4 = new SqlCommand("KULUPLISTESI", ConnectionClass.cn);

            cm4.CommandType = CommandType.StoredProcedure;
            if (cm4.Connection.State != ConnectionState.Open)
            {
                cm4.Connection.Open();
            }
            SqlDataReader dr = cm4.ExecuteReader();

            while (dr.Read())
            {
                EntityClassKulup ent = new EntityClassKulup();
                ent.KULUPID = Convert.ToInt16(dr["KULUPID"]);
                ent.KULUPAD = dr["KULUPAD"].ToString();
                values.Add(ent);
            }
            dr.Close();
            return(values);
        }