Exemple #1
0
 public ActionResult Delete(int?id, nilPengetahuanKognitifKI3 per)
 {
     try
     {
         // TODO: Add delete logic here
         nilPengetahuanKognitifKI3 nilPengetahuanKognitifKI3Db = new nilPengetahuanKognitifKI3();
         if (ModelState.IsValid)
         {
             if (id == null)
             {
                 return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
             }
             nilPengetahuanKognitifKI3Db = db.nilPengetahuanKognitifKI3Ct.Find(id);
             if (nilPengetahuanKognitifKI3Db == null)
             {
                 return(HttpNotFound());
             }
             db.nilPengetahuanKognitifKI3Ct.Remove(nilPengetahuanKognitifKI3Db);
             db.SaveChanges();
             return(RedirectToAction("Index"));
         }
         return(View(nilPengetahuanKognitifKI3Db));
     }
     catch
     {
         return(View());
     }
 }
Exemple #2
0
        //
        // GET: /nilPengetahuanKognitifKI3/Details/5
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            nilPengetahuanKognitifKI3 nilPengetahuanKognitifKI3Db = db.nilPengetahuanKognitifKI3Ct.Find(id);

            if (nilPengetahuanKognitifKI3Db == null)
            {
                return(HttpNotFound());
            }
            return(View(nilPengetahuanKognitifKI3Db));
        }
Exemple #3
0
 public ActionResult Edit(nilPengetahuanKognitifKI3 nilPengetahuanKognitifKI3Db)
 {
     try
     {
         // TODO: Add update logic here
         if (ModelState.IsValid)
         {
             db.Entry(nilPengetahuanKognitifKI3Db).State = System.Data.Entity.EntityState.Modified;
             db.SaveChanges();
             return(RedirectToAction("Index"));
         }
         return(View(nilPengetahuanKognitifKI3Db));
     }
     catch
     {
         return(View());
     }
 }
Exemple #4
0
 public ActionResult Create(nilPengetahuanKognitifKI3 nilPengetahuanKognitifKI3Db)
 {
     try
     {
         // TODO: Add insert logic here
         if (ModelState.IsValid)
         {
             nilPengetahuanKognitifKI3Db.KI3nilaiTotal = (nilPengetahuanKognitifKI3Db.KI3nilaiSatu + nilPengetahuanKognitifKI3Db.KI3nilaiDua + nilPengetahuanKognitifKI3Db.KI3nilaiTiga + nilPengetahuanKognitifKI3Db.KI3nilaiEmpat) / 4;
             db.nilPengetahuanKognitifKI3Ct.Add(nilPengetahuanKognitifKI3Db);
             db.SaveChanges();
             return(RedirectToAction("Index"));
         }
         return(View(nilPengetahuanKognitifKI3Db));
     }
     catch
     {
         return(View());
     }
 }
Exemple #5
0
        //
        // GET: /nilPengetahuanKognitifKI3/Edit/5
        public ActionResult Edit(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            nilPengetahuanKognitifKI3 nilPengetahuanKognitifKI3Db = db.nilPengetahuanKognitifKI3Ct.Find(id);

            if (nilPengetahuanKognitifKI3Db == null)
            {
                return(HttpNotFound());
            }
            dropDownSekolah(nilPengetahuanKognitifKI3Db.sekolahCode);
            dropDownKelas(nilPengetahuanKognitifKI3Db.kelasCode);
            dropDownSiswa(nilPengetahuanKognitifKI3Db.nis);
            dropDownMapel(nilPengetahuanKognitifKI3Db.mapelCode);
            dropDownGuru(nilPengetahuanKognitifKI3Db.nik);
            return(View(nilPengetahuanKognitifKI3Db));
        }