public JsonResult tree()
        {
            QTree tree1 = new QTree()
            {
                id       = 1,
                url      = "/Test/Test",
                text     = "MenuOne",
                check    = false,
                children = null
            };
            QTree tree2 = new QTree()
            {
                id       = 2,
                text     = "MenuTwo",
                children = null
            };
            List <QTree> tmp = new List <QTree>();

            tmp.Add(tree1);
            tmp.Add(tree2);
            QTree tree3 = new QTree()
            {
                id       = 3,
                text     = "MainMenu",
                children = tmp
            };

            return(Json(new
            {
                success = true,
                msg = "haha",
                type = "Test",
                obj = tree3,
            }));
        }
        public JsonResult tree()
        {
            QTree tree1 = new QTree()
            {
                id = 1,
                url = "/Test/Test",
                text = "MenuOne",
                check = false,
                children = null
            };
            QTree tree2 = new QTree()
            {
                id = 2,
                text = "MenuTwo",
                children = null
            };
            List<QTree> tmp = new List<QTree>();
            tmp.Add(tree1);
            tmp.Add(tree2);
            QTree tree3 = new QTree()
            {
                id = 3,
                text = "MainMenu",
                children = tmp
            };

            return Json(new
            {
                success = true,
                msg = "haha",
                type = "Test",
                obj = tree3,
            });
        }
        public JsonResult tree()
        {
            QTree root = new QTree()
            {
                id       = base.CompanyId,
                url      = null,
                text     = "公司",
                children = GetDepartments(base.CompanyId, base.ConnectionString)
            };

            return(Json(new
            {
                success = true,
                msg = "Get the Department tree structure",
                type = "Tree Structure",
                obj = root
            }));
        }
        /// <树状结构>
        ///
        public JsonResult tree()
        {
            /*查找员工表*/
            /*查找部门表*/


            QTree tree1 = new QTree()
            {
                id    = 1,
                text  = "1",
                check = false,
                // children =
            };
            QTree tree2 = new QTree()
            {
                id       = 2,
                text     = "2",
                check    = false,
                children = null
            };
            List <QTree> tmp = new List <QTree>();

            tmp.Add(tree1);
            tmp.Add(tree2);

            /*获取公司全称*/
            string companyFullName = this.CompanyFullName;
            /*树的根节点*/
            QTree root = new QTree()
            {
                id       = 3,
                text     = companyFullName,/*根节点为公司*/
                children = tmp
            };

            return(Json(
                       new
                       { success = true,
                         msg = "jkjkl",
                         type = "Test",
                         obj = root, }));
        }
        /// <树状结构>
        ///  
        public JsonResult tree()
        {
            /*查找员工表*/
            /*查找部门表*/

            QTree tree1 = new QTree()
            {
                id = 1,
                text = "1",
                check = false,
               // children =
            };
            QTree tree2 = new QTree()
            {
                id = 2,
                text = "2",
                check = false,
                children = null
            };
            List<QTree> tmp = new List<QTree>();
            tmp.Add(tree1);
            tmp.Add(tree2);

            /*获取公司全称*/
            string companyFullName = this.CompanyFullName;
            /*树的根节点*/
            QTree root = new QTree()
            {
                id = 3,
                text = companyFullName,/*根节点为公司*/
                children = tmp
            };

            return Json(
                new
                { success = true,
                    msg="jkjkl",
                    type="Test",
                    obj= root,
                });
        }
 public JsonResult tree()
 {
     QTree root = new QTree()
     {
         id = base.CompanyId,
         url = null,
         text = "公司",
         children = GetDepartments(base.CompanyId, base.ConnectionString)
     };
     return Json(new
     {
         success = true,
         msg = "Get the Department tree structure",
         type = "Tree Structure",
         obj = root
     });
 }