示例#1
0
 public ActionResult Edit([Bind(Include = "AssessmentTypeID,Type")] AssessmentType assessmentType)
 {
     if (ModelState.IsValid)
     {
         db.Entry(assessmentType).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(assessmentType));
 }
示例#2
0
 public ActionResult Edit([Bind(Include = "SemesterID,Name,year,ShortName,StartDate,EndDate")] Semester semester)
 {
     if (ModelState.IsValid)
     {
         db.Entry(semester).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(semester));
 }
示例#3
0
 public ActionResult Edit([Bind(Include = "DepartmentID,Name,FullName")] Department department)
 {
     if (ModelState.IsValid)
     {
         db.Entry(department).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(department));
 }
 public ActionResult Edit([Bind(Include = "GradeDistributionID,Name,EffectiveDate")] GradeDistribution gradeDistribution)
 {
     if (ModelState.IsValid)
     {
         db.Entry(gradeDistribution).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(gradeDistribution));
 }
示例#5
0
 public ActionResult Edit([Bind(Include = "LetterGradeID,Grade,MinGrade,MaxGrade")] LetterGrade letterGrade)
 {
     if (ModelState.IsValid)
     {
         db.Entry(letterGrade).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     return(View(letterGrade));
 }
示例#6
0
 public ActionResult Edit([Bind(Include = "CourseID,Code,Title,Credits,DepartmentID")] Course course)
 {
     if (ModelState.IsValid)
     {
         db.Entry(course).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.DepartmentID = new SelectList(db.Departments, "DepartmentID", "Name", course.DepartmentID);
     return(View(course));
 }
示例#7
0
 public ActionResult Edit([Bind(Include = "LOID,LearningOutcome,LODesc,DepartmentID")] LO lO)
 {
     if (ModelState.IsValid)
     {
         db.Entry(lO).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.DepartmentID = new SelectList(db.Departments, "DepartmentID", "Name", lO.DepartmentID);
     return(View(lO));
 }
示例#8
0
 public ActionResult Edit([Bind(Include = "PIID,LOID,PILetter,PINo,PIDesc")] PI pI)
 {
     if (ModelState.IsValid)
     {
         db.Entry(pI).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.LOID = new SelectList(db.LOs, "LOID", "LearningOutcome", pI.LOID);
     return(View(pI));
 }
示例#9
0
 public ActionResult Edit([Bind(Include = "InstructorID,FirstMidName,LastName,DepartmentID,HireDate")] Instructor instructor)
 {
     if (ModelState.IsValid)
     {
         db.Entry(instructor).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.DepartmentID = new SelectList(db.Departments, "DepartmentID", "Name", instructor.DepartmentID);
     return(View(instructor));
 }
示例#10
0
 public ActionResult Edit([Bind(Include = "StudentID,FirstMidName,LastName,DepartmentID,EnrollmentDate,Status")] Student student)
 {
     if (ModelState.IsValid)
     {
         db.Entry(student).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.DepartmentID = new SelectList(db.Departments, "DepartmentID", "Name", student.DepartmentID);
     return(View(student));
 }
示例#11
0
 public ActionResult Edit([Bind(Include = "GradeItemID,Name,AssessmentTypeID,AssessmentTNo,CrNo,Weight,GradeDistributionID")] GradeItem gradeItem)
 {
     if (ModelState.IsValid)
     {
         db.Entry(gradeItem).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.AssessmentTypeID    = new SelectList(db.AssessmentTypes, "AssessmentTypeID", "Type", gradeItem.AssessmentTypeID);
     ViewBag.GradeDistributionID = new SelectList(db.GradeDistributions, "GradeDistributionID", "Name", gradeItem.GradeDistributionID);
     return(View(gradeItem));
 }
示例#12
0
 public ActionResult Edit([Bind(Include = "AssessmentGradeID,Grade,Grade4,GradeP,GradeS,GradeItemID,EnrollID")] AssessmentGrade assessmentGrade)
 {
     if (ModelState.IsValid)
     {
         db.Entry(assessmentGrade).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.EnrollID    = new SelectList(db.Enrolls, "EnrollID", "EnrollID", assessmentGrade.EnrollID);
     ViewBag.GradeItemID = new SelectList(db.GradeItems, "GradeItemID", "Name", assessmentGrade.GradeItemID);
     return(View(assessmentGrade));
 }
示例#13
0
 public ActionResult Edit([Bind(Include = "EnrollmentID,SectionID,StudentID,LetterGradeID,EnrollmentDate,Status")] Enrollment enrollment)
 {
     if (ModelState.IsValid)
     {
         db.Entry(enrollment).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.LetterGradeID = new SelectList(db.LetterGrades, "LetterGradeID", "Grade", enrollment.LetterGradeID);
     ViewBag.SectionID     = new SelectList(db.Sections, "SectionID", "Code", enrollment.SectionID);
     ViewBag.StudentID     = new SelectList(db.Students, "StudentID", "FirstMidName", enrollment.Student_ID);
     return(View(enrollment));
 }
示例#14
0
 public ActionResult Edit([Bind(Include = "PIMappingID,SemesterID,PIID,CourseID,GradeItemID,Active,Type,CType")] PIMapping pIMapping)
 {
     if (ModelState.IsValid)
     {
         db.Entry(pIMapping).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.CourseID    = new SelectList(db.Courses, "CourseID", "Code", pIMapping.CourseID);
     ViewBag.GradeItemID = new SelectList(db.GradeItems, "GradeItemID", "Name", pIMapping.GradeItemID);
     ViewBag.PIID        = new SelectList(db.PIs, "PIID", "PILetter", pIMapping.PIID);
     ViewBag.SemesterID  = new SelectList(db.Semesters, "SemesterID", "ShortName", pIMapping.SemesterID);
     return(View(pIMapping));
 }
示例#15
0
 public ActionResult Edit([Bind(Include = "SectionID,Code,CourseID,SemesterID,Room,ClassInstructorID,LabInstructorID,GradeDistributionID")] Section section)
 {
     if (ModelState.IsValid)
     {
         db.Entry(section).State = EntityState.Modified;
         db.SaveChanges();
         return(RedirectToAction("Index"));
     }
     ViewBag.ClassInstructorID   = new SelectList(db.Instructors, "InstructorID", "FirstMidName", section.ClassInstructorID);
     ViewBag.CourseID            = new SelectList(db.Courses, "CourseID", "Code", section.CourseID);
     ViewBag.GradeDistributionID = new SelectList(db.GradeDistributions, "GradeDistributionID", "Name", section.GradeDistributionID);
     ViewBag.LabInstructorID     = new SelectList(db.Instructors, "InstructorID", "FirstMidName", section.LabInstructorID);
     ViewBag.SemesterID          = new SelectList(db.Semesters, "SemesterID", "ShortName", section.SemesterID);
     return(View(section));
 }