コード例 #1
0
        public void SetViewBags(int?id, int?selectedId = null)
        {
            var dao   = new  MenuDAO();
            var menus = dao.GeList(id);

            ViewBag.ParentID = new  SelectList(menus, "ID", "Name", selectedId);
            ViewBag.Location = new SelectList(new [] { "Header", "Footer" });
        }