@fecommunity/reactpress-toolkit 1.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/demos/simple.ts +65 -0
- package/dist/api/Admin.d.ts +14 -0
- package/dist/api/Admin.js +32 -0
- package/dist/api/All.d.ts +14 -0
- package/dist/api/All.js +32 -0
- package/dist/api/Archives.d.ts +14 -0
- package/dist/api/Archives.js +32 -0
- package/dist/api/Article.d.ts +108 -0
- package/dist/api/Article.js +177 -0
- package/dist/api/Auth.d.ts +27 -0
- package/dist/api/Auth.js +56 -0
- package/dist/api/Book.d.ts +15 -0
- package/dist/api/Book.js +33 -0
- package/dist/api/Category.d.ts +44 -0
- package/dist/api/Category.js +81 -0
- package/dist/api/Chapter.d.ts +15 -0
- package/dist/api/Chapter.js +33 -0
- package/dist/api/Comment.d.ts +52 -0
- package/dist/api/Comment.js +93 -0
- package/dist/api/File.d.ts +36 -0
- package/dist/api/File.js +69 -0
- package/dist/api/Get.d.ts +14 -0
- package/dist/api/Get.js +32 -0
- package/dist/api/Github.d.ts +14 -0
- package/dist/api/Github.js +32 -0
- package/dist/api/Host.d.ts +14 -0
- package/dist/api/Host.js +32 -0
- package/dist/api/Id.d.ts +284 -0
- package/dist/api/Id.js +422 -0
- package/dist/api/Knowledge.d.ts +68 -0
- package/dist/api/Knowledge.js +118 -0
- package/dist/api/Login.d.ts +14 -0
- package/dist/api/Login.js +32 -0
- package/dist/api/Page.d.ts +52 -0
- package/dist/api/Page.js +93 -0
- package/dist/api/Password.d.ts +15 -0
- package/dist/api/Password.js +33 -0
- package/dist/api/Recommend.d.ts +14 -0
- package/dist/api/Recommend.js +32 -0
- package/dist/api/Register.d.ts +15 -0
- package/dist/api/Register.js +33 -0
- package/dist/api/Search.d.ts +27 -0
- package/dist/api/Search.js +56 -0
- package/dist/api/Setting.d.ts +20 -0
- package/dist/api/Setting.js +45 -0
- package/dist/api/Smtp.d.ts +28 -0
- package/dist/api/Smtp.js +57 -0
- package/dist/api/Tag.d.ts +52 -0
- package/dist/api/Tag.js +93 -0
- package/dist/api/Update.d.ts +15 -0
- package/dist/api/Update.js +33 -0
- package/dist/api/Upload.d.ts +15 -0
- package/dist/api/Upload.js +33 -0
- package/dist/api/Url.d.ts +14 -0
- package/dist/api/Url.js +32 -0
- package/dist/api/User.d.ts +36 -0
- package/dist/api/User.js +72 -0
- package/dist/api/View.d.ts +44 -0
- package/dist/api/View.js +81 -0
- package/dist/api/api-instance.d.ts +39 -0
- package/dist/api/api-instance.js +46 -0
- package/dist/api/http-client.d.ts +41 -0
- package/dist/api/http-client.js +94 -0
- package/dist/api/httpClient.d.ts +41 -0
- package/dist/api/httpClient.js +94 -0
- package/dist/api/index.d.ts +18 -0
- package/dist/api/index.js +43 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.js +46 -0
- package/dist/types/data-contracts.d.ts +177 -0
- package/dist/types/data-contracts.js +12 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.js +19 -0
- package/dist/utils/common.d.ts +23 -0
- package/dist/utils/common.js +78 -0
- package/dist/utils/http.d.ts +3 -0
- package/dist/utils/http.js +47 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +20 -0
- package/package.json +19 -0
- package/scripts/generate-api-types.js +571 -0
- package/scripts/generate-swagger.js +47 -0
- package/scripts/organize-api.js +136 -0
- package/src/api/Article.ts +186 -0
- package/src/api/Auth.ts +54 -0
- package/src/api/Category.ts +82 -0
- package/src/api/Comment.ts +95 -0
- package/src/api/File.ts +69 -0
- package/src/api/Knowledge.ts +122 -0
- package/src/api/Page.ts +95 -0
- package/src/api/Search.ts +54 -0
- package/src/api/Setting.ts +43 -0
- package/src/api/Smtp.ts +56 -0
- package/src/api/Tag.ts +95 -0
- package/src/api/User.ts +72 -0
- package/src/api/View.ts +82 -0
- package/src/api/api-instance.ts +69 -0
- package/src/api/httpClient.ts +140 -0
- package/src/api/index.ts +25 -0
- package/src/index.ts +18 -0
- package/src/types/data-contracts.ts +198 -0
- package/src/types/index.ts +4 -0
- package/src/utils/common.ts +108 -0
- package/src/utils/http.ts +52 -0
- package/src/utils/index.ts +5 -0
- package/test-final.js +56 -0
- package/test-import.js +34 -0
- package/tsconfig.json +20 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { ICategory } from '../types/data-contracts';
|
|
2
|
+
import { HttpClient, RequestParams } from './httpClient';
|
|
3
|
+
export declare class Category<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
|
|
4
|
+
/**
|
|
5
|
+
* No description
|
|
6
|
+
*
|
|
7
|
+
* @tags Category
|
|
8
|
+
* @name create
|
|
9
|
+
* @request POST:/category
|
|
10
|
+
*/
|
|
11
|
+
create: (params?: RequestParams) => Promise<import("axios").AxiosResponse<ICategory[], any, {}>>;
|
|
12
|
+
/**
|
|
13
|
+
* No description
|
|
14
|
+
*
|
|
15
|
+
* @tags Category
|
|
16
|
+
* @name findAll
|
|
17
|
+
* @request GET:/category
|
|
18
|
+
*/
|
|
19
|
+
findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
20
|
+
/**
|
|
21
|
+
* No description
|
|
22
|
+
*
|
|
23
|
+
* @tags Category
|
|
24
|
+
* @name findById
|
|
25
|
+
* @request GET:/category/{id}
|
|
26
|
+
*/
|
|
27
|
+
findById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
28
|
+
/**
|
|
29
|
+
* No description
|
|
30
|
+
*
|
|
31
|
+
* @tags Category
|
|
32
|
+
* @name updateById
|
|
33
|
+
* @request PATCH:/category/{id}
|
|
34
|
+
*/
|
|
35
|
+
updateById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
36
|
+
/**
|
|
37
|
+
* No description
|
|
38
|
+
*
|
|
39
|
+
* @tags Category
|
|
40
|
+
* @name deleteById
|
|
41
|
+
* @request DELETE:/category/{id}
|
|
42
|
+
*/
|
|
43
|
+
deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
44
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Category = void 0;
|
|
14
|
+
const httpClient_1 = require("./httpClient");
|
|
15
|
+
class Category extends httpClient_1.HttpClient {
|
|
16
|
+
constructor() {
|
|
17
|
+
super(...arguments);
|
|
18
|
+
/**
|
|
19
|
+
* No description
|
|
20
|
+
*
|
|
21
|
+
* @tags Category
|
|
22
|
+
* @name create
|
|
23
|
+
* @request POST:/category
|
|
24
|
+
*/
|
|
25
|
+
this.create = (params = {}) => this.request({
|
|
26
|
+
path: `/category`,
|
|
27
|
+
method: 'POST',
|
|
28
|
+
format: 'json',
|
|
29
|
+
...params,
|
|
30
|
+
});
|
|
31
|
+
/**
|
|
32
|
+
* No description
|
|
33
|
+
*
|
|
34
|
+
* @tags Category
|
|
35
|
+
* @name findAll
|
|
36
|
+
* @request GET:/category
|
|
37
|
+
*/
|
|
38
|
+
this.findAll = (params = {}) => this.request({
|
|
39
|
+
path: `/category`,
|
|
40
|
+
method: 'GET',
|
|
41
|
+
...params,
|
|
42
|
+
});
|
|
43
|
+
/**
|
|
44
|
+
* No description
|
|
45
|
+
*
|
|
46
|
+
* @tags Category
|
|
47
|
+
* @name findById
|
|
48
|
+
* @request GET:/category/{id}
|
|
49
|
+
*/
|
|
50
|
+
this.findById = (id, params = {}) => this.request({
|
|
51
|
+
path: `/category/${id}`,
|
|
52
|
+
method: 'GET',
|
|
53
|
+
...params,
|
|
54
|
+
});
|
|
55
|
+
/**
|
|
56
|
+
* No description
|
|
57
|
+
*
|
|
58
|
+
* @tags Category
|
|
59
|
+
* @name updateById
|
|
60
|
+
* @request PATCH:/category/{id}
|
|
61
|
+
*/
|
|
62
|
+
this.updateById = (id, params = {}) => this.request({
|
|
63
|
+
path: `/category/${id}`,
|
|
64
|
+
method: 'PATCH',
|
|
65
|
+
...params,
|
|
66
|
+
});
|
|
67
|
+
/**
|
|
68
|
+
* No description
|
|
69
|
+
*
|
|
70
|
+
* @tags Category
|
|
71
|
+
* @name deleteById
|
|
72
|
+
* @request DELETE:/category/{id}
|
|
73
|
+
*/
|
|
74
|
+
this.deleteById = (id, params = {}) => this.request({
|
|
75
|
+
path: `/category/${id}`,
|
|
76
|
+
method: 'DELETE',
|
|
77
|
+
...params,
|
|
78
|
+
});
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
exports.Category = Category;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { IKnowledge } from '../types/data-contracts';
|
|
2
|
+
import { HttpClient, RequestParams } from './http-client';
|
|
3
|
+
export declare class Chapter<SecurityDataType = unknown> {
|
|
4
|
+
http: HttpClient<SecurityDataType>;
|
|
5
|
+
constructor(http: HttpClient<SecurityDataType>);
|
|
6
|
+
/**
|
|
7
|
+
* No description
|
|
8
|
+
*
|
|
9
|
+
* @tags Knowledge
|
|
10
|
+
* @name KnowledgeControllerCreateChapter
|
|
11
|
+
* @request POST:/Knowledge/chapter
|
|
12
|
+
* @response `200` `(IKnowledge)[]` 创建知识章节
|
|
13
|
+
*/
|
|
14
|
+
knowledgeControllerCreateChapter: (params?: RequestParams) => Promise<import("axios").AxiosResponse<IKnowledge[], any, {}>>;
|
|
15
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Chapter = void 0;
|
|
14
|
+
class Chapter {
|
|
15
|
+
constructor(http) {
|
|
16
|
+
/**
|
|
17
|
+
* No description
|
|
18
|
+
*
|
|
19
|
+
* @tags Knowledge
|
|
20
|
+
* @name KnowledgeControllerCreateChapter
|
|
21
|
+
* @request POST:/Knowledge/chapter
|
|
22
|
+
* @response `200` `(IKnowledge)[]` 创建知识章节
|
|
23
|
+
*/
|
|
24
|
+
this.knowledgeControllerCreateChapter = (params = {}) => this.http.request({
|
|
25
|
+
path: `/Knowledge/chapter`,
|
|
26
|
+
method: 'POST',
|
|
27
|
+
format: 'json',
|
|
28
|
+
...params,
|
|
29
|
+
});
|
|
30
|
+
this.http = http;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.Chapter = Chapter;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { IComment } from '../types/data-contracts';
|
|
2
|
+
import { HttpClient, RequestParams } from './httpClient';
|
|
3
|
+
export declare class Comment<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
|
|
4
|
+
/**
|
|
5
|
+
* No description
|
|
6
|
+
*
|
|
7
|
+
* @tags Comment
|
|
8
|
+
* @name create
|
|
9
|
+
* @request POST:/comment
|
|
10
|
+
*/
|
|
11
|
+
create: (params?: RequestParams) => Promise<import("axios").AxiosResponse<IComment[], any, {}>>;
|
|
12
|
+
/**
|
|
13
|
+
* No description
|
|
14
|
+
*
|
|
15
|
+
* @tags Comment
|
|
16
|
+
* @name findAll
|
|
17
|
+
* @request GET:/comment
|
|
18
|
+
*/
|
|
19
|
+
findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
20
|
+
/**
|
|
21
|
+
* No description
|
|
22
|
+
*
|
|
23
|
+
* @tags Comment
|
|
24
|
+
* @name findById
|
|
25
|
+
* @request GET:/comment/{id}
|
|
26
|
+
*/
|
|
27
|
+
findById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
28
|
+
/**
|
|
29
|
+
* No description
|
|
30
|
+
*
|
|
31
|
+
* @tags Comment
|
|
32
|
+
* @name updateById
|
|
33
|
+
* @request PATCH:/comment/{id}
|
|
34
|
+
*/
|
|
35
|
+
updateById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
36
|
+
/**
|
|
37
|
+
* No description
|
|
38
|
+
*
|
|
39
|
+
* @tags Comment
|
|
40
|
+
* @name deleteById
|
|
41
|
+
* @request DELETE:/comment/{id}
|
|
42
|
+
*/
|
|
43
|
+
deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
44
|
+
/**
|
|
45
|
+
* No description
|
|
46
|
+
*
|
|
47
|
+
* @tags Comment
|
|
48
|
+
* @name CommentControllerGetArticleComments
|
|
49
|
+
* @request GET:/comment/host/{hostId}
|
|
50
|
+
*/
|
|
51
|
+
commentControllerGetArticleComments: (hostId: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
52
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Comment = void 0;
|
|
14
|
+
const httpClient_1 = require("./httpClient");
|
|
15
|
+
class Comment extends httpClient_1.HttpClient {
|
|
16
|
+
constructor() {
|
|
17
|
+
super(...arguments);
|
|
18
|
+
/**
|
|
19
|
+
* No description
|
|
20
|
+
*
|
|
21
|
+
* @tags Comment
|
|
22
|
+
* @name create
|
|
23
|
+
* @request POST:/comment
|
|
24
|
+
*/
|
|
25
|
+
this.create = (params = {}) => this.request({
|
|
26
|
+
path: `/comment`,
|
|
27
|
+
method: 'POST',
|
|
28
|
+
format: 'json',
|
|
29
|
+
...params,
|
|
30
|
+
});
|
|
31
|
+
/**
|
|
32
|
+
* No description
|
|
33
|
+
*
|
|
34
|
+
* @tags Comment
|
|
35
|
+
* @name findAll
|
|
36
|
+
* @request GET:/comment
|
|
37
|
+
*/
|
|
38
|
+
this.findAll = (params = {}) => this.request({
|
|
39
|
+
path: `/comment`,
|
|
40
|
+
method: 'GET',
|
|
41
|
+
...params,
|
|
42
|
+
});
|
|
43
|
+
/**
|
|
44
|
+
* No description
|
|
45
|
+
*
|
|
46
|
+
* @tags Comment
|
|
47
|
+
* @name findById
|
|
48
|
+
* @request GET:/comment/{id}
|
|
49
|
+
*/
|
|
50
|
+
this.findById = (id, params = {}) => this.request({
|
|
51
|
+
path: `/comment/${id}`,
|
|
52
|
+
method: 'GET',
|
|
53
|
+
...params,
|
|
54
|
+
});
|
|
55
|
+
/**
|
|
56
|
+
* No description
|
|
57
|
+
*
|
|
58
|
+
* @tags Comment
|
|
59
|
+
* @name updateById
|
|
60
|
+
* @request PATCH:/comment/{id}
|
|
61
|
+
*/
|
|
62
|
+
this.updateById = (id, params = {}) => this.request({
|
|
63
|
+
path: `/comment/${id}`,
|
|
64
|
+
method: 'PATCH',
|
|
65
|
+
...params,
|
|
66
|
+
});
|
|
67
|
+
/**
|
|
68
|
+
* No description
|
|
69
|
+
*
|
|
70
|
+
* @tags Comment
|
|
71
|
+
* @name deleteById
|
|
72
|
+
* @request DELETE:/comment/{id}
|
|
73
|
+
*/
|
|
74
|
+
this.deleteById = (id, params = {}) => this.request({
|
|
75
|
+
path: `/comment/${id}`,
|
|
76
|
+
method: 'DELETE',
|
|
77
|
+
...params,
|
|
78
|
+
});
|
|
79
|
+
/**
|
|
80
|
+
* No description
|
|
81
|
+
*
|
|
82
|
+
* @tags Comment
|
|
83
|
+
* @name CommentControllerGetArticleComments
|
|
84
|
+
* @request GET:/comment/host/{hostId}
|
|
85
|
+
*/
|
|
86
|
+
this.commentControllerGetArticleComments = (hostId, params = {}) => this.request({
|
|
87
|
+
path: `/comment/host/${hostId}`,
|
|
88
|
+
method: 'GET',
|
|
89
|
+
...params,
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
exports.Comment = Comment;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { IFile } from '../types/data-contracts';
|
|
2
|
+
import { HttpClient, RequestParams } from './httpClient';
|
|
3
|
+
export declare class File<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
|
|
4
|
+
/**
|
|
5
|
+
* No description
|
|
6
|
+
*
|
|
7
|
+
* @tags File
|
|
8
|
+
* @name FileControllerUploadFile
|
|
9
|
+
* @request POST:/file/upload
|
|
10
|
+
*/
|
|
11
|
+
fileControllerUploadFile: (params?: RequestParams) => Promise<import("axios").AxiosResponse<IFile[], any, {}>>;
|
|
12
|
+
/**
|
|
13
|
+
* No description
|
|
14
|
+
*
|
|
15
|
+
* @tags File
|
|
16
|
+
* @name findAll
|
|
17
|
+
* @request GET:/file
|
|
18
|
+
*/
|
|
19
|
+
findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
20
|
+
/**
|
|
21
|
+
* No description
|
|
22
|
+
*
|
|
23
|
+
* @tags File
|
|
24
|
+
* @name findById
|
|
25
|
+
* @request GET:/file/{id}
|
|
26
|
+
*/
|
|
27
|
+
findById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
28
|
+
/**
|
|
29
|
+
* No description
|
|
30
|
+
*
|
|
31
|
+
* @tags File
|
|
32
|
+
* @name deleteById
|
|
33
|
+
* @request DELETE:/file/{id}
|
|
34
|
+
*/
|
|
35
|
+
deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
36
|
+
}
|
package/dist/api/File.js
ADDED
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.File = void 0;
|
|
14
|
+
const httpClient_1 = require("./httpClient");
|
|
15
|
+
class File extends httpClient_1.HttpClient {
|
|
16
|
+
constructor() {
|
|
17
|
+
super(...arguments);
|
|
18
|
+
/**
|
|
19
|
+
* No description
|
|
20
|
+
*
|
|
21
|
+
* @tags File
|
|
22
|
+
* @name FileControllerUploadFile
|
|
23
|
+
* @request POST:/file/upload
|
|
24
|
+
*/
|
|
25
|
+
this.fileControllerUploadFile = (params = {}) => this.request({
|
|
26
|
+
path: `/file/upload`,
|
|
27
|
+
method: 'POST',
|
|
28
|
+
format: 'json',
|
|
29
|
+
...params,
|
|
30
|
+
});
|
|
31
|
+
/**
|
|
32
|
+
* No description
|
|
33
|
+
*
|
|
34
|
+
* @tags File
|
|
35
|
+
* @name findAll
|
|
36
|
+
* @request GET:/file
|
|
37
|
+
*/
|
|
38
|
+
this.findAll = (params = {}) => this.request({
|
|
39
|
+
path: `/file`,
|
|
40
|
+
method: 'GET',
|
|
41
|
+
...params,
|
|
42
|
+
});
|
|
43
|
+
/**
|
|
44
|
+
* No description
|
|
45
|
+
*
|
|
46
|
+
* @tags File
|
|
47
|
+
* @name findById
|
|
48
|
+
* @request GET:/file/{id}
|
|
49
|
+
*/
|
|
50
|
+
this.findById = (id, params = {}) => this.request({
|
|
51
|
+
path: `/file/${id}`,
|
|
52
|
+
method: 'GET',
|
|
53
|
+
...params,
|
|
54
|
+
});
|
|
55
|
+
/**
|
|
56
|
+
* No description
|
|
57
|
+
*
|
|
58
|
+
* @tags File
|
|
59
|
+
* @name deleteById
|
|
60
|
+
* @request DELETE:/file/{id}
|
|
61
|
+
*/
|
|
62
|
+
this.deleteById = (id, params = {}) => this.request({
|
|
63
|
+
path: `/file/${id}`,
|
|
64
|
+
method: 'DELETE',
|
|
65
|
+
...params,
|
|
66
|
+
});
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
exports.File = File;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HttpClient, RequestParams } from './http-client';
|
|
2
|
+
export declare class Get<SecurityDataType = unknown> {
|
|
3
|
+
http: HttpClient<SecurityDataType>;
|
|
4
|
+
constructor(http: HttpClient<SecurityDataType>);
|
|
5
|
+
/**
|
|
6
|
+
* No description
|
|
7
|
+
*
|
|
8
|
+
* @tags Setting
|
|
9
|
+
* @name SettingControllerFindAll
|
|
10
|
+
* @request POST:/setting/get
|
|
11
|
+
* @response `200` `void`
|
|
12
|
+
*/
|
|
13
|
+
settingControllerFindAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
14
|
+
}
|
package/dist/api/Get.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Get = void 0;
|
|
14
|
+
class Get {
|
|
15
|
+
constructor(http) {
|
|
16
|
+
/**
|
|
17
|
+
* No description
|
|
18
|
+
*
|
|
19
|
+
* @tags Setting
|
|
20
|
+
* @name SettingControllerFindAll
|
|
21
|
+
* @request POST:/setting/get
|
|
22
|
+
* @response `200` `void`
|
|
23
|
+
*/
|
|
24
|
+
this.settingControllerFindAll = (params = {}) => this.http.request({
|
|
25
|
+
path: `/setting/get`,
|
|
26
|
+
method: 'POST',
|
|
27
|
+
...params,
|
|
28
|
+
});
|
|
29
|
+
this.http = http;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
exports.Get = Get;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HttpClient, RequestParams } from './http-client';
|
|
2
|
+
export declare class Github<SecurityDataType = unknown> {
|
|
3
|
+
http: HttpClient<SecurityDataType>;
|
|
4
|
+
constructor(http: HttpClient<SecurityDataType>);
|
|
5
|
+
/**
|
|
6
|
+
* No description
|
|
7
|
+
*
|
|
8
|
+
* @tags Auth
|
|
9
|
+
* @name AuthControllerLoginWithGithub
|
|
10
|
+
* @request POST:/auth/github
|
|
11
|
+
* @response `201` `void`
|
|
12
|
+
*/
|
|
13
|
+
authControllerLoginWithGithub: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Github = void 0;
|
|
14
|
+
class Github {
|
|
15
|
+
constructor(http) {
|
|
16
|
+
/**
|
|
17
|
+
* No description
|
|
18
|
+
*
|
|
19
|
+
* @tags Auth
|
|
20
|
+
* @name AuthControllerLoginWithGithub
|
|
21
|
+
* @request POST:/auth/github
|
|
22
|
+
* @response `201` `void`
|
|
23
|
+
*/
|
|
24
|
+
this.authControllerLoginWithGithub = (params = {}) => this.http.request({
|
|
25
|
+
path: `/auth/github`,
|
|
26
|
+
method: 'POST',
|
|
27
|
+
...params,
|
|
28
|
+
});
|
|
29
|
+
this.http = http;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
exports.Github = Github;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { HttpClient, RequestParams } from './http-client';
|
|
2
|
+
export declare class Host<SecurityDataType = unknown> {
|
|
3
|
+
http: HttpClient<SecurityDataType>;
|
|
4
|
+
constructor(http: HttpClient<SecurityDataType>);
|
|
5
|
+
/**
|
|
6
|
+
* No description
|
|
7
|
+
*
|
|
8
|
+
* @tags Comment
|
|
9
|
+
* @name CommentControllerGetArticleComments
|
|
10
|
+
* @request GET:/comment/host/{hostId}
|
|
11
|
+
* @response `200` `void`
|
|
12
|
+
*/
|
|
13
|
+
commentControllerGetArticleComments: (hostId: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
14
|
+
}
|
package/dist/api/Host.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/*
|
|
5
|
+
* ---------------------------------------------------------------
|
|
6
|
+
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ##
|
|
7
|
+
* ## ##
|
|
8
|
+
* ## AUTHOR: acacode ##
|
|
9
|
+
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ##
|
|
10
|
+
* ---------------------------------------------------------------
|
|
11
|
+
*/
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.Host = void 0;
|
|
14
|
+
class Host {
|
|
15
|
+
constructor(http) {
|
|
16
|
+
/**
|
|
17
|
+
* No description
|
|
18
|
+
*
|
|
19
|
+
* @tags Comment
|
|
20
|
+
* @name CommentControllerGetArticleComments
|
|
21
|
+
* @request GET:/comment/host/{hostId}
|
|
22
|
+
* @response `200` `void`
|
|
23
|
+
*/
|
|
24
|
+
this.commentControllerGetArticleComments = (hostId, params = {}) => this.http.request({
|
|
25
|
+
path: `/comment/host/${hostId}`,
|
|
26
|
+
method: 'GET',
|
|
27
|
+
...params,
|
|
28
|
+
});
|
|
29
|
+
this.http = http;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
exports.Host = Host;
|