Example #1
0
        public Role Update(Role ro)
        {
            dbconn.Entry(ro).State = EntityState.Modified;
            dbconn.SaveChanges();


            return(ro);
        }
Example #2
0
 public ActionResult Edit([Bind(Include = "ID,EmpID,SkillD,SkillLevelID")] EmpSkill empSkill)
 {
     if (ModelState.IsValid)
     {
         db.Entry(empSkill).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.EmpID        = new SelectList(db.Employees, "ID", "Name", empSkill.EmpID);
     ViewBag.SkillD       = new SelectList(db.Skills, "ID", "Name", empSkill.SkillD);
     ViewBag.SkillLevelID = new SelectList(db.SkillLevels, "ID", "Name", empSkill.SkillLevelID);
     return(View(empSkill));
 }
Example #3
0
 public ActionResult Edit([Bind(Include = "ID,Name,RoleID,Alias,WorkloadID,JoiningDate,ManagerID")] Employee employee)
 {
     if (ModelState.IsValid)
     {
         db.Entry(employee).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.ManagerID  = new SelectList(db.Employees, "ID", "Name", employee.ManagerID);
     ViewBag.RoleID     = new SelectList(db.Roles, "ID", "Name", employee.RoleID);
     ViewBag.WorkloadID = new SelectList(db.Workloads, "ID", "Name", employee.WorkloadID);
     return(View(employee));
 }
Example #4
0
 public TrackSkill Update(TrackSkill emp)    // Update Function
 {
     dbconn.Entry(emp).State = EntityState.Modified;
     dbconn.SaveChanges();
     return(emp);
 }
Example #5
0
 public Workload Update(Workload emp)
 {
     dbconn.Entry(emp).State = EntityState.Modified;
     dbconn.SaveChanges();
     return(emp);
 }
Example #6
0
 public EmpSubsidary Update(EmpSubsidary emp)    // Update Function
 {
     dbconn.Entry(emp).State = EntityState.Modified;
     dbconn.SaveChanges();
     return(emp);
 }
Example #7
0
 public Track Update(Track emp)
 {
     dbconn.Entry(emp).State = EntityState.Modified;
     dbconn.SaveChanges();
     return(emp);
 }
Example #8
0
 public Skill Update(Skill sk)
 {
     dbconn.Entry(sk).State = EntityState.Modified;
     dbconn.SaveChanges();
     return(sk);
 }