Example #1
0
        public IHttpActionResult Update(KullaniciDTO model)
        {
            KullaniciBLL kullaniciBusiness = new KullaniciBLL();

            kullaniciBusiness.Update(model);
            return(Ok());
        }
 public ActionResult Index(string Adi, string Parola)
 {
     if (Adi == "" || Parola == "")
     {
         return(Json("Lütfen boşlukları doldurunuz.", JsonRequestBehavior.AllowGet));
     }
     //else if (GuvenlikKodu != Session["GuvenlikKodu"].ToString())
     //{
     //    return Json("Güvenlik kodunu yanlış girdin.", JsonRequestBehavior.AllowGet);
     //}
     else
     {
         var kontrol = _kullanici.GetFirstOrDefault(g => g.Adi == Adi && g.Parola == Parola);
         if (kontrol != null)
         {
             _kullanici.Update(kontrol);
             Session["Kullanici"] = kontrol;
             return(Json("OK", JsonRequestBehavior.AllowGet));
         }
         else
         {
             return(Json("Kullanıcı bilgisine ulaşılamadı.", JsonRequestBehavior.AllowGet));
         }
     }
 }
        public Kullanici Guncelle([FromBody] Kullanici kullanici, int ID)
        {
            kullanici.Tarih = DateTime.Now;
            kullaniciBLL.Update(kullanici);


            return(kullanici);
        }