Esempio n. 1
0
        //*************************************** REF TAGS **********************************************************
        // GET: /Admin/RefTags
        public ActionResult RefTags(string selTag)
        {
            var model = new vmAdminRefTags
            {
                tags = db_Ref.GetT_OE_REF_TAGS_ByCategory(selTag),
            };

            if (!string.IsNullOrEmpty(selTag))
            {
                model.sel_tag_cat = selTag;
            }

            return(View(model));
        }
Esempio n. 2
0
        public ActionResult RefTagEdit(vmAdminRefTags model)
        {
            int UserIDX = db_Accounts.GetUserIDX();

            int SuccID = db_Ref.InsertUpdatetT_OE_REF_TAGS(model.edit_tag_idx, model.edit_tag, model.sel_tag_cat, UserIDX);

            if (SuccID > 0)
            {
                TempData["Success"] = "Update successful.";
            }
            else
            {
                TempData["Error"] = "Error updating data.";
            }

            //return View(model);
            return(RedirectToAction("RefTags", new { selTag = model.sel_tag_cat }));
        }