コード例 #1
0
        public void Update(UpdateMatterViewModel matter)
        {
            Matter updateMatter = db.Matters.Find(matter.Matter_Id);

            updateMatter.Matter_Code = matter.Matter_Code;
            updateMatter.Due_Client_Date = matter.Due_Client_Date;
            updateMatter.Due_File_Date = matter.Due_File_Date;
            updateMatter.Bar_Date = matter.Bar_Date;
            updateMatter.Client_Id = matter.Client_Id;

            db.SaveChanges();
        }
コード例 #2
0
        public ActionResult Edit(UpdateMatterViewModel matter)
        {
            if (ModelState.IsValid)
            {
                mattersService.Update(matter);

                return RedirectToAction("Index");
            }

            ViewBag.Client_Id = selectListService.Clients(matter.Client_Id);

            return View(matter);
        }