Beispiel #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            kuruduvadi kuruduvadi = db.kuruduvadis.Find(id);

            db.kuruduvadis.Remove(kuruduvadi);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Beispiel #2
0
 public ActionResult Edit([Bind(Include = "Train_number,Train_name,Source_stn,Dest_stn,Arrival,Depart,halt,Su,Mo,Tu,We,Th,Fr,Sa,train_priority,platform")] kuruduvadi kuruduvadi)
 {
     if (ModelState.IsValid)
     {
         db.Entry(kuruduvadi).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(kuruduvadi));
 }
Beispiel #3
0
        // GET: kuruduvadis/Delete/5
        public ActionResult Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            kuruduvadi kuruduvadi = db.kuruduvadis.Find(id);

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