2023-10-08 22:03:41 +08:00
|
|
|
let api = [];
|
|
|
|
const apiDocListSize = 6
|
|
|
|
api.push({
|
|
|
|
name: '通用功能',
|
|
|
|
order: '1',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[0].list.push({
|
|
|
|
alias: 'AuthController',
|
|
|
|
order: '1',
|
|
|
|
link: '登录授权_[auth]',
|
|
|
|
desc: '登录授权 [Auth]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[0].list[0].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/login',
|
|
|
|
desc: '登录[OP]',
|
|
|
|
});
|
|
|
|
api[0].list[0].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/logout',
|
|
|
|
desc: '用户退出',
|
|
|
|
});
|
|
|
|
api[0].list[0].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/check',
|
|
|
|
desc: '检查 Token 状态',
|
|
|
|
});
|
|
|
|
api[0].list.push({
|
|
|
|
alias: 'SysController',
|
|
|
|
order: '2',
|
|
|
|
link: '系统功能_[sys]',
|
|
|
|
desc: '系统功能 [Sys]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[0].list[1].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sys/alive',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: '服务在线检查 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[0].list[1].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sys/osconfig',
|
|
|
|
desc: '对象存储配置',
|
|
|
|
});
|
|
|
|
api[0].list[1].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
2023-10-10 16:44:11 +08:00
|
|
|
url: 'http://127.0.0.1:9999/sys/param/list',
|
|
|
|
desc: '系统参数列表',
|
|
|
|
});
|
|
|
|
api[0].list[1].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sys/param/upd',
|
|
|
|
desc: '修改系统参数',
|
|
|
|
});
|
|
|
|
api[0].list[1].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
2023-10-08 22:03:41 +08:00
|
|
|
url: 'http://127.0.0.1:9999/sys/param/refresh',
|
|
|
|
desc: '刷新系统配置',
|
|
|
|
});
|
|
|
|
api[0].list.push({
|
|
|
|
alias: 'UserController',
|
|
|
|
order: '3',
|
|
|
|
link: '用户_[user]',
|
|
|
|
desc: '用户 [User]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[0].list[2].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/user/info',
|
|
|
|
desc: '用户信息',
|
|
|
|
});
|
|
|
|
api[0].list[2].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/user/info/open',
|
|
|
|
desc: '用户信息 [OP]',
|
|
|
|
});
|
|
|
|
api[0].list[2].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/user/upd',
|
|
|
|
desc: '修改用户',
|
|
|
|
});
|
|
|
|
api[0].list[2].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/user/upd/pwd',
|
|
|
|
desc: '修改密码',
|
|
|
|
});
|
|
|
|
api[0].list[2].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/user/add',
|
|
|
|
desc: '新增用户',
|
|
|
|
});
|
|
|
|
api.push({
|
|
|
|
name: '业务功能',
|
|
|
|
order: '2',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'DocController',
|
|
|
|
order: '1',
|
|
|
|
link: '文档_[doc]',
|
|
|
|
desc: '文档 [Doc]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[0].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/doc/trees',
|
|
|
|
desc: '文档列表',
|
|
|
|
});
|
|
|
|
api[1].list[0].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/doc/trees/open',
|
|
|
|
desc: '文档列表 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'FolderController',
|
|
|
|
order: '2',
|
|
|
|
link: '文件夹_[folder]',
|
|
|
|
desc: '文件夹 [Folder]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/subjects/open',
|
|
|
|
desc: '查询专题列表 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/subjects',
|
|
|
|
desc: '查询专题列表',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/info',
|
|
|
|
desc: '通过ID查询文件夹',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/add',
|
|
|
|
desc: '新增或修改文件夹',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/upd',
|
|
|
|
desc: '修改文件夹',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/open',
|
|
|
|
desc: '公开文件夹',
|
|
|
|
});
|
|
|
|
api[1].list[1].list.push({
|
|
|
|
order: '7',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/folder/del',
|
|
|
|
desc: '删除文件夹',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleController',
|
|
|
|
order: '3',
|
|
|
|
link: '文章_[article]',
|
|
|
|
desc: '文章 [Article]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/list',
|
|
|
|
desc: '查询列表',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/info',
|
|
|
|
desc: '文章详情 [ID]',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/add',
|
|
|
|
desc: '新增文章',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/upd',
|
|
|
|
desc: '修改文章基础信息',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/upd/content',
|
|
|
|
desc: '保存正文内容',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/del',
|
|
|
|
desc: '删除文章',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '7',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/star',
|
|
|
|
desc: '星标文章',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '8',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/download',
|
|
|
|
desc: '下载文章',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '9',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/download/html',
|
|
|
|
desc: '下载文章 Html',
|
|
|
|
});
|
|
|
|
api[1].list[2].list.push({
|
|
|
|
order: '10',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/import',
|
|
|
|
desc: '文章导入',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleOpenController',
|
|
|
|
order: '4',
|
|
|
|
link: '文章公开_[a#open]',
|
|
|
|
desc: '文章公开 [A#Open]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[3].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/open/info',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: '查询公开文章 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[1].list[3].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/open',
|
|
|
|
desc: '公开文章',
|
|
|
|
});
|
|
|
|
api[1].list[3].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/open/sync',
|
|
|
|
desc: '同步公开文章',
|
|
|
|
});
|
|
|
|
api[1].list[3].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/open/qrcode',
|
|
|
|
desc: '生成公开文章二维码',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleReferenceController',
|
|
|
|
order: '5',
|
|
|
|
link: '文章引用_[a#reference]',
|
|
|
|
desc: '文章引用 [A#Reference]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[4].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/ref/list',
|
|
|
|
desc: '文章引用关系',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleLogController',
|
|
|
|
order: '6',
|
|
|
|
link: '文章记录_[a#log]',
|
|
|
|
desc: '文章记录 [A#Log]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[5].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/log',
|
|
|
|
desc: '文章编辑记录',
|
|
|
|
});
|
|
|
|
api[1].list[5].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/log/content',
|
|
|
|
desc: '查文章记录内容',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleBackupController',
|
|
|
|
order: '7',
|
|
|
|
link: '文章备份_[a#backup]',
|
|
|
|
desc: '文章备份 [A#Backup]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[6].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/backup',
|
|
|
|
desc: '执行备份',
|
|
|
|
});
|
|
|
|
api[1].list[6].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/backup/list',
|
|
|
|
desc: '备份记录',
|
|
|
|
});
|
|
|
|
api[1].list[6].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/backup/download',
|
|
|
|
desc: '下载压缩包',
|
|
|
|
});
|
|
|
|
api[1].list[6].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/backup/download/fragment',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: 'head 请求获取分片信息 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[1].list[6].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/backup/download/fragment',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: '分片下载 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'ArticleStatController',
|
|
|
|
order: '8',
|
|
|
|
link: '文章统计_[a#stat]',
|
|
|
|
desc: '文章统计 [A#Stat]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/heatmap/open',
|
|
|
|
desc: '每日编辑热力图 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/heatmap',
|
|
|
|
desc: '每日编辑热力图',
|
|
|
|
});
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/words/open',
|
|
|
|
desc: '文章数和文章字数 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/words',
|
|
|
|
desc: '文章数和文章字数',
|
|
|
|
});
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/line/open',
|
|
|
|
desc: '文章字数折线图 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list[7].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/article/stat/line',
|
|
|
|
desc: '字数折线图',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'PictureController',
|
|
|
|
order: '9',
|
|
|
|
link: '图片_[picture]',
|
|
|
|
desc: '图片 [Picture]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[8].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/page',
|
|
|
|
desc: '分页列表',
|
|
|
|
});
|
|
|
|
api[1].list[8].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/info',
|
|
|
|
desc: '查询图片信息',
|
|
|
|
});
|
|
|
|
api[1].list[8].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/del',
|
|
|
|
desc: '删除图片',
|
|
|
|
});
|
|
|
|
api[1].list[8].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/star',
|
|
|
|
desc: '星标图片',
|
|
|
|
});
|
|
|
|
api[1].list[8].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/stat',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: '统计图片 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'PictureBlosController',
|
|
|
|
order: '10',
|
|
|
|
link: '图片上传查看_[p#blos]',
|
|
|
|
desc: '图片上传查看 [P#Blos]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[9].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/picture/file/upload',
|
|
|
|
desc: '上传文件',
|
|
|
|
});
|
|
|
|
api[1].list[9].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/pic/{filename}/**',
|
|
|
|
desc: '查看图片 [OP]',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'PlanController',
|
|
|
|
order: '11',
|
|
|
|
link: '计划_[plan]',
|
|
|
|
desc: '计划 [Plan]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[10].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/plan/list/day',
|
|
|
|
desc: '每日计划',
|
|
|
|
});
|
|
|
|
api[1].list[10].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/plan/list/daily',
|
|
|
|
desc: '日常计划',
|
|
|
|
});
|
|
|
|
api[1].list[10].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/plan/add/day',
|
|
|
|
desc: '新增每日计划',
|
|
|
|
});
|
|
|
|
api[1].list[10].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/plan/add/daily',
|
|
|
|
desc: '新增日常计划',
|
|
|
|
});
|
|
|
|
api[1].list[10].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/plan/del',
|
|
|
|
desc: '删除计划',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'TodoController',
|
|
|
|
order: '12',
|
|
|
|
link: '待办事项_[todo]',
|
|
|
|
desc: '待办事项 [Todo]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/list',
|
|
|
|
desc: '待办事项列表',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/add/phased',
|
|
|
|
desc: '新增阶段性事项',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/upd/name',
|
|
|
|
desc: '修改阶段性事项名称',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/open',
|
|
|
|
desc: '开启阶段性事项',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/completed',
|
|
|
|
desc: '完成阶段性事项',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/stat',
|
|
|
|
desc: '待办事项列表',
|
|
|
|
});
|
|
|
|
api[1].list[11].list.push({
|
|
|
|
order: '7',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/export',
|
|
|
|
desc: '任务导出',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'TaskController',
|
|
|
|
order: '13',
|
|
|
|
link: '待办事项_[todo#task]',
|
|
|
|
desc: '待办事项 [Todo#Task]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/list',
|
|
|
|
desc: '任务列表',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/info',
|
|
|
|
desc: '任务详情',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/count',
|
|
|
|
desc: '任务数量',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/stat',
|
|
|
|
desc: '统计',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/add',
|
|
|
|
desc: '新增任务',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/upd',
|
|
|
|
desc: '修改任务',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '7',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/waiting',
|
|
|
|
desc: '事项移动到待办',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '8',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/processing',
|
|
|
|
desc: '事项移动到进行中',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '9',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/completed',
|
|
|
|
desc: '事项移动到完成',
|
|
|
|
});
|
|
|
|
api[1].list[12].list.push({
|
|
|
|
order: '10',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/todo/task/del',
|
|
|
|
desc: '删除事项',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'NoteController',
|
|
|
|
order: '14',
|
|
|
|
link: '便签_[note]',
|
|
|
|
desc: '便签 [Note]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[13].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/note/list',
|
|
|
|
desc: '全部列表',
|
|
|
|
});
|
|
|
|
api[1].list[13].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/note/add',
|
|
|
|
desc: '保存',
|
|
|
|
});
|
|
|
|
api[1].list[13].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/note/del',
|
|
|
|
desc: '删除',
|
|
|
|
});
|
|
|
|
api[1].list[13].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/note/top',
|
|
|
|
desc: '置顶/取消置顶',
|
|
|
|
});
|
|
|
|
api[1].list.push({
|
|
|
|
alias: 'WebController',
|
|
|
|
order: '15',
|
|
|
|
link: '网站收藏_[web]',
|
|
|
|
desc: '网站收藏 [Web]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[1].list[14].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/web/list',
|
2023-10-10 16:51:46 +08:00
|
|
|
desc: '网站列表 [OP]',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api[1].list[14].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/web/save',
|
|
|
|
desc: '保存',
|
|
|
|
});
|
|
|
|
api[1].list[14].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/web/del',
|
|
|
|
desc: '删除',
|
|
|
|
});
|
|
|
|
api.push({
|
|
|
|
name: '三方接口',
|
|
|
|
order: '3',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[2].list.push({
|
|
|
|
alias: 'WeatherController',
|
|
|
|
order: '1',
|
|
|
|
link: '和风天气',
|
|
|
|
desc: '和风天气',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[2].list[0].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/weather',
|
|
|
|
desc: '获取天气信息',
|
|
|
|
});
|
|
|
|
api[2].list.push({
|
|
|
|
alias: 'ThirdPartyScheduled',
|
|
|
|
order: '2',
|
|
|
|
link: '三方接口定时任务',
|
|
|
|
desc: '三方接口定时任务',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[2].list[1].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/thirdparty/scheduled/weather',
|
2023-10-10 16:44:11 +08:00
|
|
|
desc: '刷新天气缓存',
|
2023-10-08 22:03:41 +08:00
|
|
|
});
|
|
|
|
api.push({
|
|
|
|
name: '拓展功能',
|
|
|
|
order: '4',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[3].list.push({
|
|
|
|
alias: 'SentinelMetricController',
|
|
|
|
order: '1',
|
|
|
|
link: '流量监控【本地日志】',
|
|
|
|
desc: '流量监控【本地日志】',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '1',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/clusterNode',
|
|
|
|
desc: '资源列表',
|
|
|
|
});
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '2',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/resources',
|
|
|
|
desc: '一天内被请求的资源列表',
|
|
|
|
});
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '3',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/metric',
|
|
|
|
desc: '资源的监控信息',
|
|
|
|
});
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '4',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/metric/line',
|
|
|
|
desc: '资源折线图',
|
|
|
|
});
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '5',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/metric/app',
|
|
|
|
desc: '集群过去24小时的总体信息',
|
|
|
|
});
|
|
|
|
api[3].list[0].list.push({
|
|
|
|
order: '6',
|
|
|
|
deprecated: 'false',
|
|
|
|
url: 'http://127.0.0.1:9999/sentinel/cnode',
|
|
|
|
desc: '资源的秒级, 分钟级指标信息',
|
|
|
|
});
|
|
|
|
api.push({
|
|
|
|
name: '错误码列表',
|
|
|
|
order: '5',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api.push({
|
|
|
|
name: '数据字典',
|
|
|
|
order: '5',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[5].list.push({
|
|
|
|
alias: '登录方式 [GrantTypeEnum]',
|
|
|
|
order: '1',
|
|
|
|
link: '登录方式_[granttypeenum]',
|
|
|
|
desc: '登录方式 [GrantTypeEnum]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[5].list.push({
|
|
|
|
alias: '是否,真假字典 [YesNo]',
|
|
|
|
order: '2',
|
|
|
|
link: '是否,真假字典_[yesno]',
|
|
|
|
desc: '是否,真假字典 [YesNo]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[5].list.push({
|
|
|
|
alias: '用户类型 [UserTypeEnum]',
|
|
|
|
order: '3',
|
|
|
|
link: '用户类型_[usertypeenum]',
|
|
|
|
desc: '用户类型 [UserTypeEnum]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[5].list.push({
|
|
|
|
alias: '文档类型 [DocTypeEnum]',
|
|
|
|
order: '4',
|
|
|
|
link: '文档类型_[doctypeenum]',
|
|
|
|
desc: '文档类型 [DocTypeEnum]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
api[5].list.push({
|
|
|
|
alias: '文件夹类型 [FolderTypeEnum]',
|
|
|
|
order: '5',
|
|
|
|
link: '文件夹类型_[foldertypeenum]',
|
|
|
|
desc: '文件夹类型 [FolderTypeEnum]',
|
|
|
|
list: []
|
|
|
|
})
|
|
|
|
document.onkeydown = keyDownSearch;
|
|
|
|
function keyDownSearch(e) {
|
|
|
|
const theEvent = e;
|
|
|
|
const code = theEvent.keyCode || theEvent.which || theEvent.charCode;
|
|
|
|
if (code === 13) {
|
|
|
|
const search = document.getElementById('search');
|
|
|
|
const searchValue = search.value.toLocaleLowerCase();
|
|
|
|
|
|
|
|
let searchGroup = [];
|
|
|
|
for (let i = 0; i < api.length; i++) {
|
|
|
|
|
|
|
|
let apiGroup = api[i];
|
|
|
|
|
|
|
|
let searchArr = [];
|
|
|
|
for (let i = 0; i < apiGroup.list.length; i++) {
|
|
|
|
let apiData = apiGroup.list[i];
|
|
|
|
const desc = apiData.desc;
|
|
|
|
if (desc.toLocaleLowerCase().indexOf(searchValue) > -1) {
|
|
|
|
searchArr.push({
|
|
|
|
order: apiData.order,
|
|
|
|
desc: apiData.desc,
|
|
|
|
link: apiData.link,
|
|
|
|
list: apiData.list
|
|
|
|
});
|
|
|
|
} else {
|
|
|
|
let methodList = apiData.list || [];
|
|
|
|
let methodListTemp = [];
|
|
|
|
for (let j = 0; j < methodList.length; j++) {
|
|
|
|
const methodData = methodList[j];
|
|
|
|
const methodDesc = methodData.desc;
|
|
|
|
if (methodDesc.toLocaleLowerCase().indexOf(searchValue) > -1) {
|
|
|
|
methodListTemp.push(methodData);
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (methodListTemp.length > 0) {
|
|
|
|
const data = {
|
|
|
|
order: apiData.order,
|
|
|
|
desc: apiData.desc,
|
|
|
|
link: apiData.link,
|
|
|
|
list: methodListTemp
|
|
|
|
};
|
|
|
|
searchArr.push(data);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (apiGroup.name.toLocaleLowerCase().indexOf(searchValue) > -1) {
|
|
|
|
searchGroup.push({
|
|
|
|
name: apiGroup.name,
|
|
|
|
order: apiGroup.order,
|
|
|
|
list: searchArr
|
|
|
|
});
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
if (searchArr.length === 0) {
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
searchGroup.push({
|
|
|
|
name: apiGroup.name,
|
|
|
|
order: apiGroup.order,
|
|
|
|
list: searchArr
|
|
|
|
});
|
|
|
|
}
|
|
|
|
let html;
|
|
|
|
if (searchValue === '') {
|
|
|
|
const liClass = "";
|
|
|
|
const display = "display: none";
|
|
|
|
html = buildAccordion(api,liClass,display);
|
|
|
|
document.getElementById('accordion').innerHTML = html;
|
|
|
|
} else {
|
|
|
|
const liClass = "open";
|
|
|
|
const display = "display: block";
|
|
|
|
html = buildAccordion(searchGroup,liClass,display);
|
|
|
|
document.getElementById('accordion').innerHTML = html;
|
|
|
|
}
|
|
|
|
const Accordion = function (el, multiple) {
|
|
|
|
this.el = el || {};
|
|
|
|
this.multiple = multiple || false;
|
|
|
|
const links = this.el.find('.dd');
|
|
|
|
links.on('click', {el: this.el, multiple: this.multiple}, this.dropdown);
|
|
|
|
};
|
|
|
|
Accordion.prototype.dropdown = function (e) {
|
|
|
|
const $el = e.data.el;
|
|
|
|
let $this = $(this), $next = $this.next();
|
|
|
|
$next.slideToggle();
|
|
|
|
$this.parent().toggleClass('open');
|
|
|
|
if (!e.data.multiple) {
|
|
|
|
$el.find('.submenu').not($next).slideUp("20").parent().removeClass('open');
|
|
|
|
}
|
|
|
|
};
|
|
|
|
new Accordion($('#accordion'), false);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function buildAccordion(apiGroups, liClass, display) {
|
|
|
|
let html = "";
|
|
|
|
if (apiGroups.length > 0) {
|
|
|
|
if (apiDocListSize === 1) {
|
|
|
|
let apiData = apiGroups[0].list;
|
|
|
|
let order = apiGroups[0].order;
|
|
|
|
for (let j = 0; j < apiData.length; j++) {
|
|
|
|
html += '<li class="'+liClass+'">';
|
|
|
|
html += '<a class="dd" href="#_'+order+'_'+apiData[j].order+'_' + apiData[j].link + '">' + apiData[j].order + '. ' + apiData[j].desc + '</a>';
|
|
|
|
html += '<ul class="sectlevel2" style="'+display+'">';
|
|
|
|
let doc = apiData[j].list;
|
|
|
|
for (let m = 0; m < doc.length; m++) {
|
|
|
|
let spanString;
|
|
|
|
if (doc[m].deprecated === 'true') {
|
|
|
|
spanString='<span class="line-through">';
|
|
|
|
} else {
|
|
|
|
spanString='<span>';
|
|
|
|
}
|
|
|
|
html += '<li><a href="#_'+order+'_' + apiData[j].order + '_' + doc[m].order + '_' + doc[m].desc + '">' + apiData[j].order + '.' + doc[m].order + '. ' + spanString + doc[m].desc + '<span></a> </li>';
|
|
|
|
}
|
|
|
|
html += '</ul>';
|
|
|
|
html += '</li>';
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
for (let i = 0; i < apiGroups.length; i++) {
|
|
|
|
let apiGroup = apiGroups[i];
|
|
|
|
html += '<li class="'+liClass+'">';
|
|
|
|
html += '<a class="dd" href="#_'+apiGroup.order+'_' + apiGroup.name + '">' + apiGroup.order + '. ' + apiGroup.name + '</a>';
|
|
|
|
html += '<ul class="sectlevel1">';
|
|
|
|
|
|
|
|
let apiData = apiGroup.list;
|
|
|
|
for (let j = 0; j < apiData.length; j++) {
|
|
|
|
html += '<li class="'+liClass+'">';
|
|
|
|
html += '<a class="dd" href="#_'+apiGroup.order+'_'+ apiData[j].order + '_'+ apiData[j].link + '">' +apiGroup.order+'.'+ apiData[j].order + '. ' + apiData[j].desc + '</a>';
|
|
|
|
html += '<ul class="sectlevel2" style="'+display+'">';
|
|
|
|
let doc = apiData[j].list;
|
|
|
|
for (let m = 0; m < doc.length; m++) {
|
|
|
|
let spanString;
|
|
|
|
if (doc[m].deprecated === 'true') {
|
|
|
|
spanString='<span class="line-through">';
|
|
|
|
} else {
|
|
|
|
spanString='<span>';
|
|
|
|
}
|
|
|
|
html += '<li><a href="#_'+apiGroup.order+'_' + apiData[j].order + '_' + doc[m].order + '_' + doc[m].desc + '">'+apiGroup.order+'.' + apiData[j].order + '.' + doc[m].order + '. ' + spanString + doc[m].desc + '<span></a> </li>';
|
|
|
|
}
|
|
|
|
html += '</ul>';
|
|
|
|
html += '</li>';
|
|
|
|
}
|
|
|
|
|
|
|
|
html += '</ul>';
|
|
|
|
html += '</li>';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return html;
|
|
|
|
}
|