Exemple #1
0
 public ActionResult Edit([Bind(Include = "id,Name")] PaymantNames PaymantNames)
 {
     if (ModelState.IsValid)
     {
         db.Update(PaymantNames);
         return(RedirectToAction("Index"));
     }
     return(View(PaymantNames));
 }
Exemple #2
0
        public ActionResult Delete(int id = 0)
        {
            PaymantNames user = db.GetById(id);

            if (user == null)
            {
                return(HttpNotFound());
            }
            return(View(user));
        }
Exemple #3
0
        public ActionResult Create([Bind(Include = "Name")] PaymantNames PaymantNames)
        {
            if (ModelState.IsValid)
            {
                db.Add(PaymantNames);
                return(RedirectToAction("Index"));
            }

            return(View(PaymantNames));
        }
Exemple #4
0
        public ActionResult Details(int id = 0)
        {
            PaymantNames PaymantNames = db.GetById(id);

            if (PaymantNames == null)
            {
                return(HttpNotFound());
            }
            return(View(PaymantNames));
        }
 public void Update(PaymantNames entity)
 {
     rep.Update(entity);
 }
 public PaymantNames Add(PaymantNames entity)
 {
     return(rep.Add(entity));
 }