public ActionResult DeleteConfirmed(int id)
        {
            tbl_personel tbl_personel = db.tbl_personel.Find(id);

            db.tbl_personel.Remove(tbl_personel);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
 public ActionResult Edit([Bind(Include = "id,name,family,father,meli,bdate,pic,emza,sematId,bakhshId,active")] tbl_personel tbl_personel)
 {
     if (ModelState.IsValid)
     {
         db.Entry(tbl_personel).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(tbl_personel));
 }
        public ActionResult Create([Bind(Include = "id,name,family,father,meli,bdate,pic,emza,sematId,bakhshId,active")] tbl_personel tbl_personel)
        {
            if (ModelState.IsValid)
            {
                db.tbl_personel.Add(tbl_personel);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(tbl_personel));
        }
        // GET: personel/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            tbl_personel tbl_personel = db.tbl_personel.Find(id);

            if (tbl_personel == null)
            {
                return(HttpNotFound());
            }
            return(View(tbl_personel));
        }