@egova/egova-api 1.0.84 → 1.0.85
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/dist/demo.html +10 -0
- package/dist/index.common.js +62629 -0
- package/dist/index.css +1 -0
- package/dist/index.umd.js +62639 -0
- package/dist/index.umd.min.js +35 -0
- package/dist/static/fonts/fontello.068ca2b3.ttf +0 -0
- package/dist/static/fonts/fontello.8d4a4e6f.woff2 +0 -0
- package/dist/static/fonts/fontello.a782baa8.woff +0 -0
- package/dist/static/fonts/fontello.e73a0647.eot +0 -0
- package/dist/static/fonts/iconfont.74c043ae.eot +0 -0
- package/dist/static/fonts/iconfont.8c6d5bbb.ttf +0 -0
- package/dist/static/img/card.0eeeaea2.png +0 -0
- package/dist/static/img/fontello.9354499c.svg +72 -0
- package/dist/static/img/iconfont.26f82952.svg +83 -0
- package/dist/types/src/common/index.d.ts +2 -0
- package/dist/types/src/common/object-factory.d.ts +29 -0
- package/dist/types/src/common/utils/index.d.ts +1 -0
- package/dist/types/src/common/utils/tree-data.d.ts +3 -0
- package/dist/types/src/components/code-editor/index.d.ts +8 -0
- package/dist/types/src/components/common-tree/index.d.ts +52 -0
- package/dist/types/src/components/tips-form-label/index.d.ts +6 -0
- package/dist/types/src/decorator.d.ts +17 -0
- package/dist/types/src/decorators/autowired.d.ts +1 -0
- package/dist/types/src/decorators/receivable.d.ts +9 -0
- package/dist/types/src/decorators/service-handler.d.ts +11 -0
- package/dist/types/src/index.d.ts +7 -0
- package/dist/types/src/models/common/index.d.ts +6 -0
- package/dist/types/src/models/common/page-path.d.ts +5 -0
- package/dist/types/src/models/common/paging.d.ts +5 -0
- package/dist/types/src/models/common/query-model.d.ts +8 -0
- package/dist/types/src/models/common/sorts.d.ts +5 -0
- package/dist/types/src/models/common/user-info.d.ts +13 -0
- package/dist/types/src/models/index.d.ts +1 -0
- package/dist/types/src/services/base-service.d.ts +37 -0
- package/dist/types/src/services/common-service.d.ts +8 -0
- package/dist/types/src/services/index.d.ts +3 -0
- package/dist/types/src/settings/index.d.ts +5 -0
- package/dist/types/src/views/project-combine/api-project/api-project-detail/api/index.d.ts +16 -0
- package/dist/types/src/views/project-combine/api-project/api-project-detail/catalog/index.d.ts +6 -0
- package/dist/types/src/views/project-combine/api-project/api-project-detail/ddcat/index.d.ts +6 -0
- package/dist/types/src/views/project-combine/api-project/api-project-detail/index.d.ts +10 -0
- package/dist/types/src/views/project-combine/api-project/api-project-list/index.d.ts +60 -0
- package/dist/types/src/views/project-combine/api-project/index.d.ts +70 -0
- package/dist/types/src/views/project-combine/api-project/service.d.ts +6 -0
- package/dist/types/src/views/project-combine/combine-model/base-editor/index.d.ts +8 -0
- package/dist/types/src/views/project-combine/combine-model/index.d.ts +59 -0
- package/dist/types/src/views/project-combine/combine-model/request-parameter-list/index.d.ts +35 -0
- package/dist/types/src/views/project-combine/combine-model/response-parameter-list/index.d.ts +4 -0
- package/dist/types/src/views/project-combine/combine-model/test-run-modal/index.d.ts +19 -0
- package/dist/types/src/views/project-combine/data-model/data-model-doc/index.d.ts +13 -0
- package/dist/types/src/views/project-combine/data-model/data-model-list/index.d.ts +60 -0
- package/dist/types/src/views/project-combine/data-model/index.d.ts +60 -0
- package/dist/types/src/views/project-combine/data-model/service.d.ts +5 -0
- package/dist/types/src/views/project-combine/index.d.ts +34 -0
- package/dist/types/src/views/project-combine/service.d.ts +12 -0
- package/dist/types/src/views/project-combine/tree/add-node-modal/index.d.ts +16 -0
- package/dist/types/src/views/project-combine/tree/index.d.ts +32 -0
- package/dist/types/src/views/project-combine/tree/node/index.d.ts +11 -0
- package/dist/types/src/views/project-combine/tree/service.d.ts +5 -0
- package/dist/types/src/views/project-comment/index.d.ts +15 -0
- package/dist/types/src/views/project-comment/item/index.d.ts +10 -0
- package/dist/types/src/views/project-comment/service.d.ts +5 -0
- package/dist/types/src/views/project-detail/after-execution-script/index.d.ts +7 -0
- package/dist/types/src/views/project-detail/after-execution-transfer/index.d.ts +27 -0
- package/dist/types/src/views/project-detail/base-editor-setting.d.ts +7 -0
- package/dist/types/src/views/project-detail/current-variable-modal/index.d.ts +5 -0
- package/dist/types/src/views/project-detail/global-variable-modal/index.d.ts +15 -0
- package/dist/types/src/views/project-detail/group-select/index.d.ts +14 -0
- package/dist/types/src/views/project-detail/headers-setting/index.d.ts +10 -0
- package/dist/types/src/views/project-detail/index.d.ts +30 -0
- package/dist/types/src/views/project-detail/interface-settings/index.d.ts +25 -0
- package/dist/types/src/views/project-detail/interface-settings/model.d.ts +43 -0
- package/dist/types/src/views/project-detail/params-setting/index.d.ts +34 -0
- package/dist/types/src/views/project-detail/pre-execution-setting/index.d.ts +16 -0
- package/dist/types/src/views/project-detail/response/index.d.ts +36 -0
- package/dist/types/src/views/project-detail/security-setting/index.d.ts +18 -0
- package/dist/types/src/views/project-detail/service.d.ts +15 -0
- package/dist/types/src/views/project-detail/tree/index.d.ts +53 -0
- package/dist/types/src/views/project-detail/tree-node/index.d.ts +9 -0
- package/dist/types/src/views/project-list/add-project-modal/index.d.ts +6 -0
- package/dist/types/src/views/project-list/card/index.d.ts +9 -0
- package/dist/types/src/views/project-list/confirm/index.d.ts +10 -0
- package/dist/types/src/views/project-list/index.d.ts +30 -0
- package/dist/types/src/views/project-list/service.d.ts +7 -0
- package/package.json +2 -2
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
export declare class InterfaceModel {
|
|
2
|
+
info: any;
|
|
3
|
+
json: string;
|
|
4
|
+
queryParams: Array<any>;
|
|
5
|
+
formParams: Array<any>;
|
|
6
|
+
requestHeaders: Array<any>;
|
|
7
|
+
preScripts: Array<PreScript>;
|
|
8
|
+
postScripts: Array<PostScript>;
|
|
9
|
+
eventScripts: Array<any>;
|
|
10
|
+
convertConfig: ConvertConfig;
|
|
11
|
+
fieldMappings: Array<FieldMapping>;
|
|
12
|
+
authentication: Authentication;
|
|
13
|
+
}
|
|
14
|
+
export declare class Authentication {
|
|
15
|
+
type: string;
|
|
16
|
+
content: string;
|
|
17
|
+
location: string;
|
|
18
|
+
locationKey: string;
|
|
19
|
+
}
|
|
20
|
+
export declare class ConvertConfig {
|
|
21
|
+
convertRoot: string;
|
|
22
|
+
successCodePath: string;
|
|
23
|
+
successCode: string;
|
|
24
|
+
}
|
|
25
|
+
export declare class FieldMapping {
|
|
26
|
+
id: string;
|
|
27
|
+
paramPath: string;
|
|
28
|
+
originalParamPath: string;
|
|
29
|
+
name: string;
|
|
30
|
+
valueType: string;
|
|
31
|
+
checked: boolean;
|
|
32
|
+
}
|
|
33
|
+
export declare class PreScript {
|
|
34
|
+
id: string;
|
|
35
|
+
projectId: string;
|
|
36
|
+
apiId: string;
|
|
37
|
+
eventType: string;
|
|
38
|
+
type: string;
|
|
39
|
+
content: string;
|
|
40
|
+
}
|
|
41
|
+
export declare class PostScript extends PreScript {
|
|
42
|
+
eventType: string;
|
|
43
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import BaseEditorSetting from "../base-editor-setting";
|
|
2
|
+
import { InterfaceModel } from "../interface-settings/model";
|
|
3
|
+
import ApiService from "../service";
|
|
4
|
+
import "./index.scss";
|
|
5
|
+
export default class ParamsSetting extends BaseEditorSetting {
|
|
6
|
+
interfaceModel: InterfaceModel;
|
|
7
|
+
service: ApiService;
|
|
8
|
+
value: Array<string>;
|
|
9
|
+
paramColumns: Array<any>;
|
|
10
|
+
queryDataList: Array<any>;
|
|
11
|
+
requestBodyTypeList: Array<any>;
|
|
12
|
+
typeMap: any;
|
|
13
|
+
getExpand(value: string): boolean;
|
|
14
|
+
onDelete(paramList: Array<any>, index: number): void;
|
|
15
|
+
onUp(paramList: Array<any>, index: number): void;
|
|
16
|
+
onDown(paramList: Array<any>, index: number): void;
|
|
17
|
+
onTop(paramList: Array<any>, index: number): void;
|
|
18
|
+
onBottom(paramList: Array<any>, index: number): void;
|
|
19
|
+
onDeleteBodyParam(paramList: Array<any>, id: string): void;
|
|
20
|
+
onUpBodyParam(paramList: Array<any>, id?: string): void;
|
|
21
|
+
onDownBodyParam(paramList: Array<any>, id?: string): void;
|
|
22
|
+
onTopBodyParam(paramList: Array<any>, id?: string): void;
|
|
23
|
+
onBottomBodyParam(paramList: Array<any>, id?: string): void;
|
|
24
|
+
onChangeDisabled(value: boolean, item: any): void;
|
|
25
|
+
init(): void;
|
|
26
|
+
get bodyDataList(): any[];
|
|
27
|
+
onAddRequestParam(): void;
|
|
28
|
+
onAddBodyParam(): void;
|
|
29
|
+
get bodyType(): string;
|
|
30
|
+
set bodyType(value: string);
|
|
31
|
+
get isFormData(): boolean;
|
|
32
|
+
onBeautify(): void;
|
|
33
|
+
mounted(): Promise<void>;
|
|
34
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import BaseEditorSetting from "../base-editor-setting";
|
|
2
|
+
import { InterfaceModel, PreScript } from "../interface-settings/model";
|
|
3
|
+
import "./index.scss";
|
|
4
|
+
import ApiService from "../service";
|
|
5
|
+
export default class PreExecutionSetting extends BaseEditorSetting {
|
|
6
|
+
interfaceModel: InterfaceModel;
|
|
7
|
+
service: ApiService;
|
|
8
|
+
scriptData: any;
|
|
9
|
+
model: PreScript;
|
|
10
|
+
key: "postScripts" | "preScripts";
|
|
11
|
+
mounted(): void;
|
|
12
|
+
getScript(): Promise<void>;
|
|
13
|
+
onClickItem(item: any): void;
|
|
14
|
+
get script(): string;
|
|
15
|
+
set script(value: string);
|
|
16
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import BaseEditorSetting from "../base-editor-setting";
|
|
2
|
+
import "./index.scss";
|
|
3
|
+
export declare class Response {
|
|
4
|
+
code?: number;
|
|
5
|
+
time?: number;
|
|
6
|
+
size?: number;
|
|
7
|
+
content: string;
|
|
8
|
+
originalContent: string;
|
|
9
|
+
requestHeaders: any;
|
|
10
|
+
responseHeaders: any;
|
|
11
|
+
cookies: any;
|
|
12
|
+
errorMessage: string;
|
|
13
|
+
output: string;
|
|
14
|
+
}
|
|
15
|
+
export default class ResponsePanel extends BaseEditorSetting {
|
|
16
|
+
responseSettingTypeList: Array<any>;
|
|
17
|
+
lang: "json" | "xml";
|
|
18
|
+
contentType: "content" | "originalContent";
|
|
19
|
+
response: Response;
|
|
20
|
+
headerColumns: Array<any>;
|
|
21
|
+
active: any;
|
|
22
|
+
onClickResponseSettingTpye(type: any): void;
|
|
23
|
+
get content(): string;
|
|
24
|
+
get output(): string;
|
|
25
|
+
get responseHeaders(): {
|
|
26
|
+
key: string;
|
|
27
|
+
value: any;
|
|
28
|
+
}[];
|
|
29
|
+
get requestHeaders(): {
|
|
30
|
+
key: string;
|
|
31
|
+
value: any;
|
|
32
|
+
}[];
|
|
33
|
+
get cookies(): any;
|
|
34
|
+
onChangeLang(lang: "json" | "xml"): void;
|
|
35
|
+
init(): void;
|
|
36
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Component } from "@egova/flagwind-web";
|
|
2
|
+
import { InterfaceModel } from "../interface-settings/model";
|
|
3
|
+
import ApiService from "../service";
|
|
4
|
+
import "./index.scss";
|
|
5
|
+
export default class SecuritySetting extends Component {
|
|
6
|
+
interfaceModel: InterfaceModel;
|
|
7
|
+
service: ApiService;
|
|
8
|
+
securityTypeList: Array<any>;
|
|
9
|
+
tokenLocationTypeList: Array<any>;
|
|
10
|
+
grantTypeList: Array<any>;
|
|
11
|
+
model: any;
|
|
12
|
+
mounted(): void;
|
|
13
|
+
getSecurityTypeList(): Promise<void>;
|
|
14
|
+
getTokenLocationTypeList(): Promise<void>;
|
|
15
|
+
getGrantTypeList(): Promise<void>;
|
|
16
|
+
modelChange(): void;
|
|
17
|
+
onClear(): void;
|
|
18
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { CommonService } from "@/services";
|
|
2
|
+
import { InterfaceModel } from "./interface-settings/model";
|
|
3
|
+
export default class ApiService extends CommonService {
|
|
4
|
+
getApiTree(projectId: string): Promise<any>;
|
|
5
|
+
deleteApi(id: string): Promise<any>;
|
|
6
|
+
saveApi(api: any): Promise<any>;
|
|
7
|
+
copyApi(id: string, name: string, projectId: string, categoryId: string): Promise<any>;
|
|
8
|
+
apiInfo(id: string): Promise<any>;
|
|
9
|
+
run(apiId: string, apiInfo: InterfaceModel): Promise<any>;
|
|
10
|
+
saveApiInfo(apiInfo: InterfaceModel): Promise<any>;
|
|
11
|
+
parseResponse2Fields(originalJson: string, convertRoot?: string, collapse?: boolean): Promise<any>;
|
|
12
|
+
preScript(): Promise<any>;
|
|
13
|
+
postScript(): Promise<any>;
|
|
14
|
+
projectInfo(id: string): Promise<any>;
|
|
15
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { Component } from "@egova/flagwind-web";
|
|
2
|
+
import ApiService from "../service";
|
|
3
|
+
import "./index.scss";
|
|
4
|
+
export default class ProjectTree extends Component {
|
|
5
|
+
projectId: string;
|
|
6
|
+
service: ApiService;
|
|
7
|
+
data: Array<any>;
|
|
8
|
+
groupTree: Array<any>;
|
|
9
|
+
parent: any;
|
|
10
|
+
renderData: Array<any>;
|
|
11
|
+
keyword: string;
|
|
12
|
+
type: string;
|
|
13
|
+
typeList: Array<any>;
|
|
14
|
+
showInterfaceModal: boolean;
|
|
15
|
+
showGroupModal: boolean;
|
|
16
|
+
interfaceModel: any;
|
|
17
|
+
showCopyModal: boolean;
|
|
18
|
+
copyName: string;
|
|
19
|
+
group: any;
|
|
20
|
+
renderContent(h: Function, { root, node, data }: {
|
|
21
|
+
root: Array<any>;
|
|
22
|
+
node: any;
|
|
23
|
+
data: any;
|
|
24
|
+
}): void;
|
|
25
|
+
onCheckInterface(data: any): void;
|
|
26
|
+
onEditInterface(data: any): void;
|
|
27
|
+
onDeleteInterface(data: any): Promise<void>;
|
|
28
|
+
onCopyInterface(data: any): void;
|
|
29
|
+
onCopy(): Promise<void>;
|
|
30
|
+
onCopyCancel(): void;
|
|
31
|
+
onAddInterface(group: any): void;
|
|
32
|
+
onSaveInterface(): Promise<void>;
|
|
33
|
+
onDeleteGroup(group: any): Promise<void>;
|
|
34
|
+
onEditGroup(group: any): void;
|
|
35
|
+
onAddGroup(): void;
|
|
36
|
+
/**
|
|
37
|
+
* 输入关键字对数据进行过滤
|
|
38
|
+
*/
|
|
39
|
+
onFilter(): void;
|
|
40
|
+
/**
|
|
41
|
+
* 判断一个节点是否是与关键字匹配的叶子节点,或者是包含符合条件的叶子节点的祖先节点
|
|
42
|
+
* @param node
|
|
43
|
+
*/
|
|
44
|
+
match(node: any): boolean;
|
|
45
|
+
/**
|
|
46
|
+
* 处理渲染数据,只保留与关键字匹配的叶子节点和其祖先节点
|
|
47
|
+
* @param data
|
|
48
|
+
*/
|
|
49
|
+
filterData(data: Array<any>): any[];
|
|
50
|
+
onSelectParent(group: any): void;
|
|
51
|
+
onSaveGroup(): Promise<void>;
|
|
52
|
+
init(): Promise<void>;
|
|
53
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { View } from "@egova/flagwind-web";
|
|
2
|
+
import "./index.scss";
|
|
3
|
+
import ProjectService from "./service";
|
|
4
|
+
export default class ProjectList extends View {
|
|
5
|
+
type: "list" | "card";
|
|
6
|
+
condition: any;
|
|
7
|
+
dataList: Array<any>;
|
|
8
|
+
showAddModal: boolean;
|
|
9
|
+
loading: boolean;
|
|
10
|
+
columns: Array<any>;
|
|
11
|
+
service: ProjectService;
|
|
12
|
+
current: any;
|
|
13
|
+
get uploadAction(): string;
|
|
14
|
+
onCheckType(type: "list" | "card"): void;
|
|
15
|
+
onAdd(): void;
|
|
16
|
+
onDelete(row: any): Promise<void>;
|
|
17
|
+
onDetail(data: any): void;
|
|
18
|
+
onEdit(data: any): void;
|
|
19
|
+
onExport(data: any): Promise<void>;
|
|
20
|
+
onComment(): void;
|
|
21
|
+
onQuery(): Promise<void>;
|
|
22
|
+
mounted(): void;
|
|
23
|
+
onSave(): Promise<void>;
|
|
24
|
+
get headers(): {
|
|
25
|
+
Authorization: string;
|
|
26
|
+
};
|
|
27
|
+
onSuccess(res: any, file: File): void;
|
|
28
|
+
onBeforeUpload(file: any): boolean;
|
|
29
|
+
onFormatError(file: any): void;
|
|
30
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { CommonService } from "@/services";
|
|
2
|
+
export default class ProjectService extends CommonService {
|
|
3
|
+
getProjectList(condition?: any): Promise<any>;
|
|
4
|
+
saveProject(project: any): Promise<any>;
|
|
5
|
+
deleteProject(id: string): Promise<any>;
|
|
6
|
+
exportProject(data: any): Promise<any>;
|
|
7
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@egova/egova-api",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.85",
|
|
4
4
|
"description": "api",
|
|
5
5
|
"author": "egova",
|
|
6
6
|
"publishConfig": {
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"last 2 versions",
|
|
81
81
|
"not ie <= 8"
|
|
82
82
|
],
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "975b2f2ffd1627b3e12ecd1130b48ef7064e5d20"
|
|
84
84
|
}
|