コード例 #1
0
ファイル: Folder.ashx.cs プロジェクト: 15989655205/ljj
        /// <summary>
        /// 获取文件夹列表,编辑添加页面
        /// </summary>
        /// <returns></returns>
        public string GetCombotree()
        {
            DataTable dt = new DataTable();

            string where = "1=1";
            dt           = new BLL.folder().GetList(where).Tables[0];
            DataRow dr = dt.NewRow();

            dr["folder_name"]  = "主文件夹";
            dr["ID"]           = 0;
            dr["folder_level"] = -1;
            dt.Rows.Add(dr);
            return(DataTable2Json_Tree(dt, "ID", "folder_name", "folder_level", -1, "", ""));
        }
コード例 #2
0
ファイル: Folder.ashx.cs プロジェクト: 15989655205/ljj
        /// <summary>
        /// 获取文件夹列表,编辑添加页面
        /// </summary>
        /// <returns></returns>
        public string GetCopyCombotree(HttpContext context)
        {
            string    copyid = context.Request["copy_id"] == null ? "" : context.Request["copy_id"].Trim();
            DataTable dt     = new DataTable();

            string where = "1=1 and id!=" + copyid;
            dt           = new BLL.folder().GetList(where).Tables[0];
            DataRow dr = dt.NewRow();

            dr["folder_name"]  = "主文件夹";
            dr["ID"]           = 0;
            dr["folder_level"] = -1;
            dt.Rows.Add(dr);
            return(DataTable2Json_Tree(dt, "ID", "folder_name", "folder_level", -1, "", ""));
        }