// // GET: /AdminKullanicilar/Edit/5 public ActionResult Edit(int id) { Tbl_Kullanicilar tbl_kullanicilar = db.Tbl_Kullanicilar.Single(t => t.KullaniciID == id); ViewBag.YetkiID = new SelectList(db.Tbl_Yetkiler, "YetkiKodu", "Yetki", tbl_kullanicilar.YetkiID); return(View(tbl_kullanicilar)); }
public ActionResult DeleteConfirmed(int id) { Tbl_Kullanicilar tbl_kullanicilar = db.Tbl_Kullanicilar.Single(t => t.KullaniciID == id); db.Tbl_Kullanicilar.DeleteObject(tbl_kullanicilar); db.SaveChanges(); return(RedirectToAction("Index")); }
public ActionResult Edit(Tbl_Kullanicilar tbl_kullanicilar) { if (ModelState.IsValid) { db.Tbl_Kullanicilar.Attach(tbl_kullanicilar); db.ObjectStateManager.ChangeObjectState(tbl_kullanicilar, EntityState.Modified); db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.YetkiID = new SelectList(db.Tbl_Yetkiler, "YetkiKodu", "Yetki", tbl_kullanicilar.YetkiID); return(View(tbl_kullanicilar)); }
public ActionResult Create(Tbl_Kullanicilar tbl_kullanicilar) { if (ModelState.IsValid) { db.Tbl_Kullanicilar.AddObject(tbl_kullanicilar); db.SaveChanges(); return(RedirectToAction("Index")); } ViewBag.YetkiID = new SelectList(db.Tbl_Yetkiler, "YetkiKodu", "Yetki", tbl_kullanicilar.YetkiID); return(View(tbl_kullanicilar)); }
public ActionResult GirisYap(Tbl_Kullanicilar p) { var bilgiler = db.Tbl_Kullanicilar.FirstOrDefault(x => x.SICIL == p.SICIL && x.SIFRE == p.SIFRE); if (bilgiler != null) { FormsAuthentication.SetAuthCookie(bilgiler.SICIL, false); Session["SICIL"] = bilgiler.SICIL.ToString(); return(RedirectToAction("Index", "Mahkeme")); } else { return(View()); } }
public bool KullaniciKaydi(string ad, string soyad, string email, string sifre, string telefon) { if (string.IsNullOrEmpty(ad) || string.IsNullOrEmpty(soyad) || string.IsNullOrEmpty(email) || string.IsNullOrEmpty(sifre) || string.IsNullOrEmpty(telefon)) { return(false); } else { Tbl_Kullanicilar kullaniciEkle = new Tbl_Kullanicilar { KullaniciAdi = ad, KullaniciSoyadi = soyad, KullaniciEmail = email, KullaniciSifre = sifre, KullaniciTelefon = telefon, CreatedDate = DateTime.Now, IsActive = true, }; db.Tbl_Kullanicilar.Add(kullaniciEkle); db.SaveChanges(); return(true); } }
// // GET: /AdminKullanicilar/Delete/5 public ActionResult Delete(int id) { Tbl_Kullanicilar tbl_kullanicilar = db.Tbl_Kullanicilar.Single(t => t.KullaniciID == id); return(View(tbl_kullanicilar)); }
// // GET: /AdminKullanicilar/Details/5 public ViewResult Details(int id) { Tbl_Kullanicilar tbl_kullanicilar = db.Tbl_Kullanicilar.Single(t => t.KullaniciID == id); return(View(tbl_kullanicilar)); }
public PartialViewResult KullaniciPaneli() { Tbl_Kullanicilar kullanici = (Tbl_Kullanicilar)Session["LoginUser"]; return(PartialView(kullanici)); }