@fecommunity/reactpress-toolkit 1.0.0-beta.2 → 1.0.0-beta.4

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.
Files changed (150) hide show
  1. package/README.md +222 -25
  2. package/dist/api/Article.d.ts +43 -28
  3. package/dist/api/Article.js +42 -31
  4. package/dist/api/Auth.d.ts +12 -7
  5. package/dist/api/Auth.js +12 -10
  6. package/dist/api/Category.d.ts +19 -12
  7. package/dist/api/Category.js +18 -15
  8. package/dist/api/Comment.d.ts +22 -14
  9. package/dist/api/Comment.js +21 -17
  10. package/dist/api/File.d.ts +16 -10
  11. package/dist/api/File.js +15 -13
  12. package/dist/{HttpClient.d.ts → api/HttpClient.d.ts} +2 -2
  13. package/dist/{HttpClient.js → api/HttpClient.js} +4 -2
  14. package/dist/api/Knowledge.d.ts +28 -18
  15. package/dist/api/Knowledge.js +27 -22
  16. package/dist/api/Page.d.ts +22 -14
  17. package/dist/api/Page.js +21 -17
  18. package/dist/api/Search.d.ts +12 -7
  19. package/dist/api/Search.js +12 -10
  20. package/dist/api/Setting.d.ts +10 -6
  21. package/dist/api/Setting.js +9 -9
  22. package/dist/api/Smtp.d.ts +13 -8
  23. package/dist/api/Smtp.js +12 -11
  24. package/dist/api/Tag.d.ts +22 -14
  25. package/dist/api/Tag.js +21 -17
  26. package/dist/api/User.d.ts +17 -10
  27. package/dist/api/User.js +16 -16
  28. package/dist/api/View.d.ts +19 -12
  29. package/dist/api/View.js +18 -15
  30. package/dist/api/index.d.ts +13 -18
  31. package/dist/api/index.js +28 -40
  32. package/dist/api/instance.d.ts +47 -0
  33. package/dist/api/instance.js +71 -0
  34. package/dist/config/env.d.ts +1 -0
  35. package/dist/config/env.js +89 -0
  36. package/dist/config/global.d.ts +34 -0
  37. package/dist/config/global.js +382 -0
  38. package/dist/config/i18n.d.ts +4 -0
  39. package/dist/config/i18n.js +43 -0
  40. package/dist/config/index.d.ts +15 -0
  41. package/dist/config/index.js +25 -0
  42. package/dist/index.d.ts +11 -5
  43. package/dist/index.js +18 -25
  44. package/dist/locales/en.json +97 -0
  45. package/dist/locales/zh.json +97 -0
  46. package/dist/types/index.d.ts +245 -1
  47. package/dist/types/index.js +10 -17
  48. package/dist/utils/index.d.ts +33 -2
  49. package/dist/utils/index.js +57 -18
  50. package/package.json +20 -5
  51. package/dist/Article.d.ts +0 -121
  52. package/dist/Article.js +0 -189
  53. package/dist/Auth.d.ts +0 -30
  54. package/dist/Auth.js +0 -59
  55. package/dist/Category.d.ts +0 -49
  56. package/dist/Category.js +0 -85
  57. package/dist/Comment.d.ts +0 -58
  58. package/dist/Comment.js +0 -98
  59. package/dist/File.d.ts +0 -40
  60. package/dist/File.js +0 -72
  61. package/dist/Knowledge.d.ts +0 -76
  62. package/dist/Knowledge.js +0 -124
  63. package/dist/Page.d.ts +0 -58
  64. package/dist/Page.js +0 -98
  65. package/dist/Search.d.ts +0 -30
  66. package/dist/Search.js +0 -59
  67. package/dist/Setting.d.ts +0 -22
  68. package/dist/Setting.js +0 -46
  69. package/dist/Smtp.d.ts +0 -31
  70. package/dist/Smtp.js +0 -59
  71. package/dist/Tag.d.ts +0 -58
  72. package/dist/Tag.js +0 -98
  73. package/dist/User.d.ts +0 -41
  74. package/dist/User.js +0 -73
  75. package/dist/View.d.ts +0 -49
  76. package/dist/View.js +0 -85
  77. package/dist/api/Admin.d.ts +0 -14
  78. package/dist/api/Admin.js +0 -32
  79. package/dist/api/All.d.ts +0 -14
  80. package/dist/api/All.js +0 -32
  81. package/dist/api/ApiInstance.d.ts +0 -39
  82. package/dist/api/ApiInstance.js +0 -46
  83. package/dist/api/Archives.d.ts +0 -14
  84. package/dist/api/Archives.js +0 -32
  85. package/dist/api/ArticleRoute.d.ts +0 -201
  86. package/dist/api/ArticleRoute.js +0 -12
  87. package/dist/api/AuthRoute.d.ts +0 -44
  88. package/dist/api/AuthRoute.js +0 -12
  89. package/dist/api/Book.d.ts +0 -15
  90. package/dist/api/Book.js +0 -33
  91. package/dist/api/CategoryRoute.d.ts +0 -79
  92. package/dist/api/CategoryRoute.js +0 -12
  93. package/dist/api/Chapter.d.ts +0 -15
  94. package/dist/api/Chapter.js +0 -33
  95. package/dist/api/CommentRoute.d.ts +0 -95
  96. package/dist/api/CommentRoute.js +0 -12
  97. package/dist/api/FileRoute.d.ts +0 -63
  98. package/dist/api/FileRoute.js +0 -12
  99. package/dist/api/Get.d.ts +0 -14
  100. package/dist/api/Get.js +0 -32
  101. package/dist/api/Github.d.ts +0 -14
  102. package/dist/api/Github.js +0 -32
  103. package/dist/api/Host.d.ts +0 -14
  104. package/dist/api/Host.js +0 -32
  105. package/dist/api/Id.d.ts +0 -284
  106. package/dist/api/Id.js +0 -422
  107. package/dist/api/KnowledgeRoute.d.ts +0 -125
  108. package/dist/api/KnowledgeRoute.js +0 -12
  109. package/dist/api/Login.d.ts +0 -14
  110. package/dist/api/Login.js +0 -32
  111. package/dist/api/PageRoute.d.ts +0 -95
  112. package/dist/api/PageRoute.js +0 -12
  113. package/dist/api/Password.d.ts +0 -15
  114. package/dist/api/Password.js +0 -33
  115. package/dist/api/Recommend.d.ts +0 -14
  116. package/dist/api/Recommend.js +0 -32
  117. package/dist/api/Register.d.ts +0 -15
  118. package/dist/api/Register.js +0 -33
  119. package/dist/api/SearchRoute.d.ts +0 -46
  120. package/dist/api/SearchRoute.js +0 -12
  121. package/dist/api/SettingRoute.d.ts +0 -31
  122. package/dist/api/SettingRoute.js +0 -12
  123. package/dist/api/SmtpRoute.d.ts +0 -47
  124. package/dist/api/SmtpRoute.js +0 -12
  125. package/dist/api/TagRoute.d.ts +0 -95
  126. package/dist/api/TagRoute.js +0 -12
  127. package/dist/api/Update.d.ts +0 -15
  128. package/dist/api/Update.js +0 -33
  129. package/dist/api/Upload.d.ts +0 -15
  130. package/dist/api/Upload.js +0 -33
  131. package/dist/api/Url.d.ts +0 -14
  132. package/dist/api/Url.js +0 -32
  133. package/dist/api/UserRoute.d.ts +0 -60
  134. package/dist/api/UserRoute.js +0 -12
  135. package/dist/api/ViewRoute.d.ts +0 -77
  136. package/dist/api/ViewRoute.js +0 -12
  137. package/dist/api/api-instance.d.ts +0 -39
  138. package/dist/api/api-instance.js +0 -46
  139. package/dist/api/http-client.d.ts +0 -41
  140. package/dist/api/http-client.js +0 -94
  141. package/dist/api/httpClient.d.ts +0 -42
  142. package/dist/api/httpClient.js +0 -95
  143. package/dist/data-contracts.d.ts +0 -245
  144. package/dist/data-contracts.js +0 -12
  145. package/dist/types/data-contracts.d.ts +0 -177
  146. package/dist/types/data-contracts.js +0 -12
  147. package/dist/utils/common.d.ts +0 -21
  148. package/dist/utils/common.js +0 -52
  149. package/dist/utils/http.d.ts +0 -3
  150. package/dist/utils/http.js +0 -45
@@ -11,44 +11,43 @@
11
11
  */
12
12
  Object.defineProperty(exports, "__esModule", { value: true });
13
13
  exports.Knowledge = void 0;
14
- const HttpClient_1 = require("./HttpClient");
15
- class Knowledge extends HttpClient_1.HttpClient {
16
- constructor() {
17
- super(...arguments);
14
+ class Knowledge {
15
+ constructor(http) {
18
16
  /**
19
17
  * No description
20
18
  *
21
19
  * @tags Knowledge
22
- * @name createBook
20
+ * @name KnowledgeControllerCreateBook
23
21
  * @request POST:/Knowledge/book
22
+ * @response `200` `IKnowledgeControllerCreateBookData` 创建知识库
24
23
  */
25
- this.createBook = (params = {}) => this.request({
24
+ this.createBook = (params = {}) => this.http.request({
26
25
  path: `/Knowledge/book`,
27
26
  method: 'POST',
28
- format: 'json',
29
27
  ...params,
30
28
  });
31
29
  /**
32
30
  * No description
33
31
  *
34
32
  * @tags Knowledge
35
- * @name createChapter
33
+ * @name KnowledgeControllerCreateChapter
36
34
  * @request POST:/Knowledge/chapter
35
+ * @response `200` `IKnowledgeControllerCreateChapterData` 创建知识章节
37
36
  */
38
- this.createChapter = (params = {}) => this.request({
37
+ this.createChapter = (params = {}) => this.http.request({
39
38
  path: `/Knowledge/chapter`,
40
39
  method: 'POST',
41
- format: 'json',
42
40
  ...params,
43
41
  });
44
42
  /**
45
43
  * No description
46
44
  *
47
45
  * @tags Knowledge
48
- * @name deleteById
46
+ * @name KnowledgeControllerDeleteById
49
47
  * @request DELETE:/Knowledge/{id}
48
+ * @response `200` `IKnowledgeControllerDeleteByIdData`
50
49
  */
51
- this.deleteById = (id, params = {}) => this.request({
50
+ this.deleteById = (id, params = {}) => this.http.request({
52
51
  path: `/Knowledge/${id}`,
53
52
  method: 'DELETE',
54
53
  ...params,
@@ -57,10 +56,11 @@ class Knowledge extends HttpClient_1.HttpClient {
57
56
  * No description
58
57
  *
59
58
  * @tags Knowledge
60
- * @name updateById
59
+ * @name KnowledgeControllerUpdateById
61
60
  * @request PATCH:/Knowledge/{id}
61
+ * @response `200` `IKnowledgeControllerUpdateByIdData`
62
62
  */
63
- this.updateById = (id, params = {}) => this.request({
63
+ this.updateById = (id, params = {}) => this.http.request({
64
64
  path: `/Knowledge/${id}`,
65
65
  method: 'PATCH',
66
66
  ...params,
@@ -69,10 +69,11 @@ class Knowledge extends HttpClient_1.HttpClient {
69
69
  * No description
70
70
  *
71
71
  * @tags Knowledge
72
- * @name findById
72
+ * @name KnowledgeControllerFindById
73
73
  * @request GET:/Knowledge/{id}
74
+ * @response `200` `IKnowledgeControllerFindByIdData`
74
75
  */
75
- this.findById = (id, params = {}) => this.request({
76
+ this.findById = (id, params = {}) => this.http.request({
76
77
  path: `/Knowledge/${id}`,
77
78
  method: 'GET',
78
79
  ...params,
@@ -81,10 +82,11 @@ class Knowledge extends HttpClient_1.HttpClient {
81
82
  * No description
82
83
  *
83
84
  * @tags Knowledge
84
- * @name findAll
85
+ * @name KnowledgeControllerFindAll
85
86
  * @request GET:/Knowledge
87
+ * @response `200` `IKnowledgeControllerFindAllData`
86
88
  */
87
- this.findAll = (params = {}) => this.request({
89
+ this.findAll = (params = {}) => this.http.request({
88
90
  path: `/Knowledge`,
89
91
  method: 'GET',
90
92
  ...params,
@@ -93,10 +95,11 @@ class Knowledge extends HttpClient_1.HttpClient {
93
95
  * No description
94
96
  *
95
97
  * @tags Knowledge
96
- * @name updateViewsById
98
+ * @name KnowledgeControllerUpdateViewsById
97
99
  * @request POST:/Knowledge/{id}/views
100
+ * @response `200` `IKnowledgeControllerUpdateViewsByIdData`
98
101
  */
99
- this.updateViewsById = (id, params = {}) => this.request({
102
+ this.updateViewsById = (id, params = {}) => this.http.request({
100
103
  path: `/Knowledge/${id}/views`,
101
104
  method: 'POST',
102
105
  ...params,
@@ -105,14 +108,16 @@ class Knowledge extends HttpClient_1.HttpClient {
105
108
  * No description
106
109
  *
107
110
  * @tags Knowledge
108
- * @name updateLikesById
111
+ * @name KnowledgeControllerUpdateLikesById
109
112
  * @request POST:/Knowledge/{id}/likes
113
+ * @response `200` `IKnowledgeControllerUpdateLikesByIdData`
110
114
  */
111
- this.updateLikesById = (id, params = {}) => this.request({
115
+ this.updateLikesById = (id, params = {}) => this.http.request({
112
116
  path: `/Knowledge/${id}/likes`,
113
117
  method: 'POST',
114
118
  ...params,
115
119
  });
120
+ this.http = http;
116
121
  }
117
122
  }
118
123
  exports.Knowledge = Knowledge;
@@ -1,52 +1,60 @@
1
- import { IPage } from '../types/data-contracts';
1
+ import { IPageControllerCreateData } from '../types';
2
2
  import { HttpClient, RequestParams } from './HttpClient';
3
- export declare class Page<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
3
+ export declare class Page<SecurityDataType = unknown> {
4
+ http: HttpClient<SecurityDataType>;
5
+ constructor(http: HttpClient<SecurityDataType>);
4
6
  /**
5
7
  * No description
6
8
  *
7
9
  * @tags Page
8
- * @name create
10
+ * @name PageControllerCreate
9
11
  * @request POST:/page
12
+ * @response `200` `IPageControllerCreateData` 创建页面
10
13
  */
11
- create: (params?: RequestParams) => Promise<import("axios").AxiosResponse<IPage[], any, {}>>;
14
+ create: (params?: RequestParams) => Promise<IPageControllerCreateData>;
12
15
  /**
13
16
  * No description
14
17
  *
15
18
  * @tags Page
16
- * @name findAll
19
+ * @name PageControllerFindAll
17
20
  * @request GET:/page
21
+ * @response `200` `IPageControllerFindAllData`
18
22
  */
19
- findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
23
+ findAll: (params?: RequestParams) => Promise<any>;
20
24
  /**
21
25
  * No description
22
26
  *
23
27
  * @tags Page
24
- * @name findById
28
+ * @name PageControllerFindById
25
29
  * @request GET:/page/{id}
30
+ * @response `200` `IPageControllerFindByIdData`
26
31
  */
27
- findById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
32
+ findById: (id: string, params?: RequestParams) => Promise<any>;
28
33
  /**
29
34
  * No description
30
35
  *
31
36
  * @tags Page
32
- * @name updateById
37
+ * @name PageControllerUpdateById
33
38
  * @request PATCH:/page/{id}
39
+ * @response `200` `IPageControllerUpdateByIdData`
34
40
  */
35
- updateById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
41
+ updateById: (id: string, params?: RequestParams) => Promise<any>;
36
42
  /**
37
43
  * No description
38
44
  *
39
45
  * @tags Page
40
- * @name deleteById
46
+ * @name PageControllerDeleteById
41
47
  * @request DELETE:/page/{id}
48
+ * @response `200` `IPageControllerDeleteByIdData`
42
49
  */
43
- deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
50
+ deleteById: (id: string, params?: RequestParams) => Promise<any>;
44
51
  /**
45
52
  * No description
46
53
  *
47
54
  * @tags Page
48
- * @name updateViewsById
55
+ * @name PageControllerUpdateViewsById
49
56
  * @request POST:/page/{id}/views
57
+ * @response `200` `IPageControllerUpdateViewsByIdData`
50
58
  */
51
- updateViewsById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
59
+ updateViewsById: (id: string, params?: RequestParams) => Promise<any>;
52
60
  }
package/dist/api/Page.js CHANGED
@@ -11,31 +11,30 @@
11
11
  */
12
12
  Object.defineProperty(exports, "__esModule", { value: true });
13
13
  exports.Page = void 0;
14
- const HttpClient_1 = require("./HttpClient");
15
- class Page extends HttpClient_1.HttpClient {
16
- constructor() {
17
- super(...arguments);
14
+ class Page {
15
+ constructor(http) {
18
16
  /**
19
17
  * No description
20
18
  *
21
19
  * @tags Page
22
- * @name create
20
+ * @name PageControllerCreate
23
21
  * @request POST:/page
22
+ * @response `200` `IPageControllerCreateData` 创建页面
24
23
  */
25
- this.create = (params = {}) => this.request({
24
+ this.create = (params = {}) => this.http.request({
26
25
  path: `/page`,
27
26
  method: 'POST',
28
- format: 'json',
29
27
  ...params,
30
28
  });
31
29
  /**
32
30
  * No description
33
31
  *
34
32
  * @tags Page
35
- * @name findAll
33
+ * @name PageControllerFindAll
36
34
  * @request GET:/page
35
+ * @response `200` `IPageControllerFindAllData`
37
36
  */
38
- this.findAll = (params = {}) => this.request({
37
+ this.findAll = (params = {}) => this.http.request({
39
38
  path: `/page`,
40
39
  method: 'GET',
41
40
  ...params,
@@ -44,10 +43,11 @@ class Page extends HttpClient_1.HttpClient {
44
43
  * No description
45
44
  *
46
45
  * @tags Page
47
- * @name findById
46
+ * @name PageControllerFindById
48
47
  * @request GET:/page/{id}
48
+ * @response `200` `IPageControllerFindByIdData`
49
49
  */
50
- this.findById = (id, params = {}) => this.request({
50
+ this.findById = (id, params = {}) => this.http.request({
51
51
  path: `/page/${id}`,
52
52
  method: 'GET',
53
53
  ...params,
@@ -56,10 +56,11 @@ class Page extends HttpClient_1.HttpClient {
56
56
  * No description
57
57
  *
58
58
  * @tags Page
59
- * @name updateById
59
+ * @name PageControllerUpdateById
60
60
  * @request PATCH:/page/{id}
61
+ * @response `200` `IPageControllerUpdateByIdData`
61
62
  */
62
- this.updateById = (id, params = {}) => this.request({
63
+ this.updateById = (id, params = {}) => this.http.request({
63
64
  path: `/page/${id}`,
64
65
  method: 'PATCH',
65
66
  ...params,
@@ -68,10 +69,11 @@ class Page extends HttpClient_1.HttpClient {
68
69
  * No description
69
70
  *
70
71
  * @tags Page
71
- * @name deleteById
72
+ * @name PageControllerDeleteById
72
73
  * @request DELETE:/page/{id}
74
+ * @response `200` `IPageControllerDeleteByIdData`
73
75
  */
74
- this.deleteById = (id, params = {}) => this.request({
76
+ this.deleteById = (id, params = {}) => this.http.request({
75
77
  path: `/page/${id}`,
76
78
  method: 'DELETE',
77
79
  ...params,
@@ -80,14 +82,16 @@ class Page extends HttpClient_1.HttpClient {
80
82
  * No description
81
83
  *
82
84
  * @tags Page
83
- * @name updateViewsById
85
+ * @name PageControllerUpdateViewsById
84
86
  * @request POST:/page/{id}/views
87
+ * @response `200` `IPageControllerUpdateViewsByIdData`
85
88
  */
86
- this.updateViewsById = (id, params = {}) => this.request({
89
+ this.updateViewsById = (id, params = {}) => this.http.request({
87
90
  path: `/page/${id}/views`,
88
91
  method: 'POST',
89
92
  ...params,
90
93
  });
94
+ this.http = http;
91
95
  }
92
96
  }
93
97
  exports.Page = Page;
@@ -1,27 +1,32 @@
1
1
  import { HttpClient, RequestParams } from './HttpClient';
2
- export declare class Search<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
2
+ export declare class Search<SecurityDataType = unknown> {
3
+ http: HttpClient<SecurityDataType>;
4
+ constructor(http: HttpClient<SecurityDataType>);
3
5
  /**
4
6
  * No description
5
7
  *
6
8
  * @tags Search
7
- * @name searchArticle
9
+ * @name SearchControllerSearchArticle
8
10
  * @request GET:/search/article
11
+ * @response `200` `ISearchControllerSearchArticleData`
9
12
  */
10
- searchArticle: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
13
+ searchArticle: (params?: RequestParams) => Promise<any>;
11
14
  /**
12
15
  * No description
13
16
  *
14
17
  * @tags Search
15
- * @name findAll
18
+ * @name SearchControllerFindAll
16
19
  * @request GET:/search
20
+ * @response `200` `ISearchControllerFindAllData`
17
21
  */
18
- findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
22
+ findAll: (params?: RequestParams) => Promise<any>;
19
23
  /**
20
24
  * No description
21
25
  *
22
26
  * @tags Search
23
- * @name deleteById
27
+ * @name SearchControllerDeleteById
24
28
  * @request DELETE:/search/{id}
29
+ * @response `200` `ISearchControllerDeleteByIdData`
25
30
  */
26
- deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
31
+ deleteById: (id: string, params?: RequestParams) => Promise<any>;
27
32
  }
@@ -11,18 +11,17 @@
11
11
  */
12
12
  Object.defineProperty(exports, "__esModule", { value: true });
13
13
  exports.Search = void 0;
14
- const HttpClient_1 = require("./HttpClient");
15
- class Search extends HttpClient_1.HttpClient {
16
- constructor() {
17
- super(...arguments);
14
+ class Search {
15
+ constructor(http) {
18
16
  /**
19
17
  * No description
20
18
  *
21
19
  * @tags Search
22
- * @name searchArticle
20
+ * @name SearchControllerSearchArticle
23
21
  * @request GET:/search/article
22
+ * @response `200` `ISearchControllerSearchArticleData`
24
23
  */
25
- this.searchArticle = (params = {}) => this.request({
24
+ this.searchArticle = (params = {}) => this.http.request({
26
25
  path: `/search/article`,
27
26
  method: 'GET',
28
27
  ...params,
@@ -31,10 +30,11 @@ class Search extends HttpClient_1.HttpClient {
31
30
  * No description
32
31
  *
33
32
  * @tags Search
34
- * @name findAll
33
+ * @name SearchControllerFindAll
35
34
  * @request GET:/search
35
+ * @response `200` `ISearchControllerFindAllData`
36
36
  */
37
- this.findAll = (params = {}) => this.request({
37
+ this.findAll = (params = {}) => this.http.request({
38
38
  path: `/search`,
39
39
  method: 'GET',
40
40
  ...params,
@@ -43,14 +43,16 @@ class Search extends HttpClient_1.HttpClient {
43
43
  * No description
44
44
  *
45
45
  * @tags Search
46
- * @name deleteById
46
+ * @name SearchControllerDeleteById
47
47
  * @request DELETE:/search/{id}
48
+ * @response `200` `ISearchControllerDeleteByIdData`
48
49
  */
49
- this.deleteById = (id, params = {}) => this.request({
50
+ this.deleteById = (id, params = {}) => this.http.request({
50
51
  path: `/search/${id}`,
51
52
  method: 'DELETE',
52
53
  ...params,
53
54
  });
55
+ this.http = http;
54
56
  }
55
57
  }
56
58
  exports.Search = Search;
@@ -1,20 +1,24 @@
1
- import { ISetting } from '../types/data-contracts';
1
+ import { ISettingControllerUpdateData } from '../types';
2
2
  import { HttpClient, RequestParams } from './HttpClient';
3
- export declare class Setting<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
3
+ export declare class Setting<SecurityDataType = unknown> {
4
+ http: HttpClient<SecurityDataType>;
5
+ constructor(http: HttpClient<SecurityDataType>);
4
6
  /**
5
7
  * No description
6
8
  *
7
9
  * @tags Setting
8
- * @name update
10
+ * @name SettingControllerUpdate
9
11
  * @request POST:/setting
12
+ * @response `200` `ISettingControllerUpdateData` 更新设置
10
13
  */
11
- update: (params?: RequestParams) => Promise<import("axios").AxiosResponse<ISetting[], any, {}>>;
14
+ update: (params?: RequestParams) => Promise<ISettingControllerUpdateData>;
12
15
  /**
13
16
  * No description
14
17
  *
15
18
  * @tags Setting
16
- * @name findAll
19
+ * @name SettingControllerFindAll
17
20
  * @request POST:/setting/get
21
+ * @response `200` `ISettingControllerFindAllData`
18
22
  */
19
- findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
23
+ findAll: (params?: RequestParams) => Promise<any>;
20
24
  }
@@ -11,35 +11,35 @@
11
11
  */
12
12
  Object.defineProperty(exports, "__esModule", { value: true });
13
13
  exports.Setting = void 0;
14
- const HttpClient_1 = require("./HttpClient");
15
- class Setting extends HttpClient_1.HttpClient {
16
- constructor() {
17
- super(...arguments);
14
+ class Setting {
15
+ constructor(http) {
18
16
  /**
19
17
  * No description
20
18
  *
21
19
  * @tags Setting
22
- * @name update
20
+ * @name SettingControllerUpdate
23
21
  * @request POST:/setting
22
+ * @response `200` `ISettingControllerUpdateData` 更新设置
24
23
  */
25
- this.update = (params = {}) => this.request({
24
+ this.update = (params = {}) => this.http.request({
26
25
  path: `/setting`,
27
26
  method: 'POST',
28
- format: 'json',
29
27
  ...params,
30
28
  });
31
29
  /**
32
30
  * No description
33
31
  *
34
32
  * @tags Setting
35
- * @name findAll
33
+ * @name SettingControllerFindAll
36
34
  * @request POST:/setting/get
35
+ * @response `200` `ISettingControllerFindAllData`
37
36
  */
38
- this.findAll = (params = {}) => this.request({
37
+ this.findAll = (params = {}) => this.http.request({
39
38
  path: `/setting/get`,
40
39
  method: 'POST',
41
40
  ...params,
42
41
  });
42
+ this.http = http;
43
43
  }
44
44
  }
45
45
  exports.Setting = Setting;
@@ -1,28 +1,33 @@
1
- import { I_SMTP } from '../types/data-contracts';
1
+ import { ISmtpControllerCreateData } from '../types';
2
2
  import { HttpClient, RequestParams } from './HttpClient';
3
- export declare class Smtp<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
3
+ export declare class Smtp<SecurityDataType = unknown> {
4
+ http: HttpClient<SecurityDataType>;
5
+ constructor(http: HttpClient<SecurityDataType>);
4
6
  /**
5
7
  * No description
6
8
  *
7
9
  * @tags Smtp
8
- * @name create
10
+ * @name SmtpControllerCreate
9
11
  * @request POST:/smtp
12
+ * @response `200` `ISmtpControllerCreateData` 发送邮件
10
13
  */
11
- create: (params?: RequestParams) => Promise<import("axios").AxiosResponse<I_SMTP[], any, {}>>;
14
+ create: (params?: RequestParams) => Promise<ISmtpControllerCreateData>;
12
15
  /**
13
16
  * No description
14
17
  *
15
18
  * @tags Smtp
16
- * @name findAll
19
+ * @name SmtpControllerFindAll
17
20
  * @request GET:/smtp
21
+ * @response `200` `ISmtpControllerFindAllData`
18
22
  */
19
- findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
23
+ findAll: (params?: RequestParams) => Promise<any>;
20
24
  /**
21
25
  * No description
22
26
  *
23
27
  * @tags Smtp
24
- * @name deleteById
28
+ * @name SmtpControllerDeleteById
25
29
  * @request DELETE:/smtp/{id}
30
+ * @response `200` `ISmtpControllerDeleteByIdData`
26
31
  */
27
- deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
32
+ deleteById: (id: string, params?: RequestParams) => Promise<any>;
28
33
  }
package/dist/api/Smtp.js CHANGED
@@ -11,31 +11,30 @@
11
11
  */
12
12
  Object.defineProperty(exports, "__esModule", { value: true });
13
13
  exports.Smtp = void 0;
14
- const HttpClient_1 = require("./HttpClient");
15
- class Smtp extends HttpClient_1.HttpClient {
16
- constructor() {
17
- super(...arguments);
14
+ class Smtp {
15
+ constructor(http) {
18
16
  /**
19
17
  * No description
20
18
  *
21
19
  * @tags Smtp
22
- * @name create
20
+ * @name SmtpControllerCreate
23
21
  * @request POST:/smtp
22
+ * @response `200` `ISmtpControllerCreateData` 发送邮件
24
23
  */
25
- this.create = (params = {}) => this.request({
24
+ this.create = (params = {}) => this.http.request({
26
25
  path: `/smtp`,
27
26
  method: 'POST',
28
- format: 'json',
29
27
  ...params,
30
28
  });
31
29
  /**
32
30
  * No description
33
31
  *
34
32
  * @tags Smtp
35
- * @name findAll
33
+ * @name SmtpControllerFindAll
36
34
  * @request GET:/smtp
35
+ * @response `200` `ISmtpControllerFindAllData`
37
36
  */
38
- this.findAll = (params = {}) => this.request({
37
+ this.findAll = (params = {}) => this.http.request({
39
38
  path: `/smtp`,
40
39
  method: 'GET',
41
40
  ...params,
@@ -44,14 +43,16 @@ class Smtp extends HttpClient_1.HttpClient {
44
43
  * No description
45
44
  *
46
45
  * @tags Smtp
47
- * @name deleteById
46
+ * @name SmtpControllerDeleteById
48
47
  * @request DELETE:/smtp/{id}
48
+ * @response `200` `ISmtpControllerDeleteByIdData`
49
49
  */
50
- this.deleteById = (id, params = {}) => this.request({
50
+ this.deleteById = (id, params = {}) => this.http.request({
51
51
  path: `/smtp/${id}`,
52
52
  method: 'DELETE',
53
53
  ...params,
54
54
  });
55
+ this.http = http;
55
56
  }
56
57
  }
57
58
  exports.Smtp = Smtp;
package/dist/api/Tag.d.ts CHANGED
@@ -1,52 +1,60 @@
1
- import { ITag } from '../types/data-contracts';
1
+ import { ITagControllerCreateData } from '../types';
2
2
  import { HttpClient, RequestParams } from './HttpClient';
3
- export declare class Tag<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
3
+ export declare class Tag<SecurityDataType = unknown> {
4
+ http: HttpClient<SecurityDataType>;
5
+ constructor(http: HttpClient<SecurityDataType>);
4
6
  /**
5
7
  * No description
6
8
  *
7
9
  * @tags Tag
8
- * @name create
10
+ * @name TagControllerCreate
9
11
  * @request POST:/tag
12
+ * @response `200` `ITagControllerCreateData` 创建标签
10
13
  */
11
- create: (params?: RequestParams) => Promise<import("axios").AxiosResponse<ITag[], any, {}>>;
14
+ create: (params?: RequestParams) => Promise<ITagControllerCreateData>;
12
15
  /**
13
16
  * No description
14
17
  *
15
18
  * @tags Tag
16
- * @name findAll
19
+ * @name TagControllerFindAll
17
20
  * @request GET:/tag
21
+ * @response `200` `ITagControllerFindAllData`
18
22
  */
19
- findAll: (params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
23
+ findAll: (params?: RequestParams) => Promise<any>;
20
24
  /**
21
25
  * No description
22
26
  *
23
27
  * @tags Tag
24
- * @name findById
28
+ * @name TagControllerFindById
25
29
  * @request GET:/tag/{id}
30
+ * @response `200` `ITagControllerFindByIdData`
26
31
  */
27
- findById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
32
+ findById: (id: string, params?: RequestParams) => Promise<any>;
28
33
  /**
29
34
  * No description
30
35
  *
31
36
  * @tags Tag
32
- * @name updateById
37
+ * @name TagControllerUpdateById
33
38
  * @request PATCH:/tag/{id}
39
+ * @response `200` `ITagControllerUpdateByIdData`
34
40
  */
35
- updateById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
41
+ updateById: (id: string, params?: RequestParams) => Promise<any>;
36
42
  /**
37
43
  * No description
38
44
  *
39
45
  * @tags Tag
40
- * @name deleteById
46
+ * @name TagControllerDeleteById
41
47
  * @request DELETE:/tag/{id}
48
+ * @response `200` `ITagControllerDeleteByIdData`
42
49
  */
43
- deleteById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
50
+ deleteById: (id: string, params?: RequestParams) => Promise<any>;
44
51
  /**
45
52
  * No description
46
53
  *
47
54
  * @tags Tag
48
- * @name getArticleById
55
+ * @name TagControllerGetArticleById
49
56
  * @request GET:/tag/{id}/article
57
+ * @response `200` `ITagControllerGetArticleByIdData`
50
58
  */
51
- getArticleById: (id: string, params?: RequestParams) => Promise<import("axios").AxiosResponse<void, any, {}>>;
59
+ getArticleById: (id: string, params?: RequestParams) => Promise<any>;
52
60
  }