Ejemplo n.º 1
0
 public ActionResult EditConfirmed([Bind(Include = "assetCategoryId,dossierId,isAsset,description")] POCO.assetCategory assetCategory)
 {
     if (ModelState.IsValid)
     {
         POCO.assetCategory.UpdateCategory(assetCategory);
         return(RedirectToAction("Index", "AssetCategory", new { dossierId = assetCategory.dossierId }));
     }
     return(View(assetCategory));
 }
Ejemplo n.º 2
0
        // GET: AssetCategory/Create
        public ActionResult Create(int dossierId)
        {
            POCO.assetCategory model = new POCO.assetCategory {
                dossierId = dossierId
            };

            ViewBag.Action = "Create";
            return(View("Details", model));
            //return View();
        }
Ejemplo n.º 3
0
        public static void AddCategory(assetCategory cat)
        {
            PersonalFinancesDBEntities db = new PersonalFinancesDBEntities();

            var catEntity = new PersonalFinances.DATA.DataModel.assetCategory {
                dossierId   = cat.dossierId,
                isAsset     = cat.isAsset,
                description = cat.description
            };



            db.assetCategories.Add(catEntity);
            db.SaveChanges();
        }
Ejemplo n.º 4
0
 public ActionResult Edit([Bind(Include = "assetCategoryId,dossierId,isAsset,description")] POCO.assetCategory assetCategory)
 {
     ViewBag.Action = "Edit";
     return(View("Details", assetCategory));
 }