Esempio n. 1
0
        public ActionResult DeleteConfirmed(short id)
        {
            SET_CLIENTS set_clients = db.SET_CLIENTS.Single(s => s.CLIENT_NO == id);

            db.SET_CLIENTS.DeleteObject(set_clients);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Esempio n. 2
0
        //
        // GET: /Clients/Delete/5

        public ActionResult Delete(short id = 0)
        {
            SET_CLIENTS set_clients = db.SET_CLIENTS.Single(s => s.CLIENT_NO == id);

            if (set_clients == null)
            {
                return(HttpNotFound());
            }
            return(View(set_clients));
        }
Esempio n. 3
0
 public ActionResult Edit(SET_CLIENTS set_clients)
 {
     if (ModelState.IsValid)
     {
         db.SET_CLIENTS.Attach(set_clients);
         db.ObjectStateManager.ChangeObjectState(set_clients, EntityState.Modified);
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(set_clients));
 }
Esempio n. 4
0
        public ActionResult Create(SET_CLIENTS set_clients)
        {
            if (ModelState.IsValid)
            {
                db.SET_CLIENTS.AddObject(set_clients);
                db.SaveChanges();
                return(RedirectToAction("Index"));
            }

            return(View(set_clients));
        }