Exemplo n.º 1
0
        public ActionResult DeleteConfirmed(int id)
        {
            Resource_Allocation resource_Allocation = db.Resource_Allocation.Find(id);

            db.Resource_Allocation.Remove(resource_Allocation);
            db.SaveChanges();
            return(RedirectToAction("Index"));
        }
Exemplo n.º 2
0
 public ActionResult Edit([Bind(Include = "allocId,resIdFK,skillIdFK")] Resource_Allocation resource_Allocation)
 {
     if (ModelState.IsValid)
     {
         db.Entry(resource_Allocation).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.resIdFK   = new SelectList(db.Resources, "resId", "resName", resource_Allocation.resIdFK);
     ViewBag.skillIdFK = new SelectList(db.Skills, "skillId", "skillName", resource_Allocation.skillIdFK);
     return(View(resource_Allocation));
 }
Exemplo n.º 3
0
        // GET: Resource_Allocation/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            Resource_Allocation resource_Allocation = db.Resource_Allocation.Find(id);

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