2022-05-23 05:05:59 +00:00
|
|
|
|
"use strict";
|
|
|
|
|
exports.__esModule = true;
|
|
|
|
|
exports.WikiApiDefinition = void 0;
|
|
|
|
|
exports.WikiApiDefinition = {
|
|
|
|
|
/**
|
|
|
|
|
* 获取用户所有知识库(创建的、参与的)
|
|
|
|
|
*/
|
|
|
|
|
getAllWikis: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'list/all',
|
|
|
|
|
client: function () { return '/wiki/list/all'; }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取用户创建的知识库
|
|
|
|
|
*/
|
|
|
|
|
getOwnWikis: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'list/own',
|
|
|
|
|
client: function () { return '/wiki/list/own'; }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取用户参与的知识库
|
|
|
|
|
*/
|
|
|
|
|
getJoinWikis: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'list/join',
|
|
|
|
|
client: function () { return '/wiki/list/join'; }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 新建知识库
|
|
|
|
|
*/
|
|
|
|
|
add: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'post',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'add',
|
|
|
|
|
client: function () { return '/wiki/add'; }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库首页文档
|
|
|
|
|
*/
|
|
|
|
|
getHomeDocumentById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'homedoc/:id',
|
|
|
|
|
client: function (id) { return "/wiki/homedoc/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库目录
|
|
|
|
|
*/
|
|
|
|
|
getTocsById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'tocs/:id',
|
|
|
|
|
client: function (id) { return "/wiki/tocs/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 更新知识库目录
|
|
|
|
|
*/
|
|
|
|
|
updateTocsById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'patch',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'tocs/:id/update',
|
|
|
|
|
client: function (id) { return "/wiki/tocs/".concat(id, "/update"); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库所有文档
|
|
|
|
|
*/
|
|
|
|
|
getDocumentsById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'documents/:id',
|
|
|
|
|
client: function (id) { return "/wiki/documents/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库详情
|
|
|
|
|
*/
|
|
|
|
|
getDetailById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'detail/:id',
|
|
|
|
|
client: function (id) { return "/wiki/detail/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 更新知识库
|
|
|
|
|
*/
|
|
|
|
|
updateById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'patch',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'update/:id',
|
|
|
|
|
client: function (id) { return "/wiki/update/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 删除知识库
|
|
|
|
|
*/
|
|
|
|
|
deleteById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'delete',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'delet/:id',
|
|
|
|
|
client: function (id) { return "/wiki/delet/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库成员
|
|
|
|
|
*/
|
|
|
|
|
getMemberById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'member/:id',
|
|
|
|
|
client: function (id) { return "/wiki/member/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 添加知识库成员
|
|
|
|
|
*/
|
|
|
|
|
addMemberById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'post',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'member/:id/add',
|
|
|
|
|
client: function (id) { return "/wiki/member/".concat(id, "/add"); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 更新知识库成员
|
|
|
|
|
*/
|
|
|
|
|
updateMemberById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'patch',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'member/:id/update',
|
|
|
|
|
client: function (id) { return "/wiki/member/".concat(id, "/update"); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 删除知识库成员
|
|
|
|
|
*/
|
|
|
|
|
deleteMemberById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'delete',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'member/:id/delete',
|
|
|
|
|
client: function (id) { return "/wiki/member/".concat(id, "/delete"); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 分享知识库
|
|
|
|
|
*/
|
|
|
|
|
shareById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'post',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: 'share/:id',
|
|
|
|
|
client: function (id) { return "/wiki/share/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取公开知识库首页文档
|
|
|
|
|
*/
|
|
|
|
|
getPublicHomeDocumentById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: '/public/homedoc/:id',
|
|
|
|
|
client: function (id) { return "/wiki/public/homedoc/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取公开知识库目录
|
|
|
|
|
*/
|
|
|
|
|
getPublicTocsById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: '/public/tocs/:id',
|
|
|
|
|
client: function (id) { return "/wiki/public/tocs/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取知识库详情
|
|
|
|
|
*/
|
|
|
|
|
getPublicDetailById: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: '/public/detail/:id',
|
|
|
|
|
client: function (id) { return "/wiki/public/detail/".concat(id); }
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 获取所有公开知识库
|
|
|
|
|
*/
|
|
|
|
|
getPublicWikis: {
|
2022-05-23 08:20:56 +00:00
|
|
|
|
method: 'get',
|
2022-05-23 05:05:59 +00:00
|
|
|
|
server: '/public/wikis',
|
2022-05-23 08:20:56 +00:00
|
|
|
|
client: function () { return "/wiki/public/wikis"; }
|
2022-05-23 05:05:59 +00:00
|
|
|
|
}
|
|
|
|
|
};
|