コード例 #1
0
        //
        // GET: /Left/

        public ActionResult Index()
        {
			IList<CCode> listTree = new List<CCode>();
			try
			{
				DaoCode daoTree = new DaoCode();
				listTree = daoTree.getCodeList("leftmenu", 0, null, 2);
				ViewBag.listTree = listTree;
			}
			catch (Exception e)
			{
				throw new Exception(e.Message);
			}

			return PartialView("~/views/layout/LeftMenu.cshtml", listTree);
        }
コード例 #2
0
		public ActionResult StatusList(string tree_type, int tree_level, string tree_value)
		{
			IList<CCode> listCode = new List<CCode>();
			try
			{
				DaoCode daoTree = new DaoCode();
				listCode = daoTree.getCodeList(tree_type, 0, null, tree_level);
				ViewBag.listCode = listCode;
				ViewBag.tree_value = (tree_value == null || tree_value == "") ? "" : tree_value;
			}
			catch (Exception e)
			{
				UtilityController.WriteLog(e.Message);
				throw new Exception(e.Message);
			}

			return PartialView("~/Views/PartialView/StatusView.cshtml", listCode);
		}
コード例 #3
0
		public JsonResult getCodeOne(int tree_code)
		{
			CCode code = new CCode();
			JsonResult json = new JsonResult();

			HttpContext.GetGlobalResourceObject("c", "s");

			try
			{
				DaoCode daoTree = new DaoCode();

				code = daoTree.getCodeOne(tree_code);
				json.Data = code;
			}
			catch (Exception e)
			{
				throw new Exception(e.Message);
			}

			return json;
		}
コード例 #4
0
		public ActionResult CodePreview(string tree_type)
		{
			IList<CCode> listCode = new List<CCode>();
			try
			{
				if (tree_type == null || tree_type == "")
				{
					tree_type = "company";
				}

				DaoCode daoCode = new DaoCode();
				listCode = daoCode.getCodeList(tree_type, 0, null, 0);
				ViewBag.listCode = listCode;
				ViewBag.listCodeType = daoCode.getCodeTypeList();
			}
			catch (Exception e)
			{
				throw new Exception(e.Message);
			}

			return PartialView("~/Views/Code/CodePreview.cshtml", listCode);
		}