smartbi-toolkit 1.1.4 → 1.2.0
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/README.md +59 -12
- package/dist/common-Cnq1SoER.d.ts +25 -0
- package/dist/console-BJttltN4.js +93 -0
- package/dist/index.d.ts +23 -14
- package/dist/index.js +97 -127
- package/dist/{methods → service}/AnalysisReportService.d.ts +18 -14
- package/dist/service/AnalysisReportService.js +138 -0
- package/dist/service/BusinessThemeService.d.ts +11 -0
- package/dist/service/BusinessThemeService.js +20 -0
- package/dist/{methods → service}/BusinessViewService.d.ts +18 -14
- package/dist/service/BusinessViewService.js +146 -0
- package/dist/{methods → service}/CatalogService.d.ts +26 -22
- package/dist/service/CatalogService.js +300 -0
- package/dist/{methods → service}/ClientCombinedReportService.d.ts +14 -10
- package/dist/service/ClientCombinedReportService.js +96 -0
- package/dist/{methods → service}/ClientInsightService.d.ts +17 -13
- package/dist/service/ClientInsightService.js +123 -0
- package/dist/{methods → service}/ClientReportService.d.ts +27 -23
- package/dist/service/ClientReportService.js +244 -0
- package/dist/service/CombinedReportService.d.ts +11 -0
- package/dist/service/CombinedReportService.js +14 -0
- package/dist/{methods → service}/DataSourceService.d.ts +26 -22
- package/dist/service/DataSourceService.js +306 -0
- package/dist/service/GraphicReportService.d.ts +11 -0
- package/dist/service/GraphicReportService.js +14 -0
- package/dist/service/InsightReport.d.ts +75 -0
- package/dist/service/InsightReport.js +118 -0
- package/dist/{methods → service}/MetadataService.d.ts +10 -6
- package/dist/service/MetadataService.js +60 -0
- package/dist/service/OfficeReport.d.ts +53 -0
- package/dist/service/OfficeReport.js +74 -0
- package/dist/{methods → service}/OfficeReportService.d.ts +10 -6
- package/dist/service/OfficeReportService.js +56 -0
- package/dist/service/OltpMetadataService.d.ts +23 -0
- package/dist/service/OltpMetadataService.js +30 -0
- package/dist/service/ParameterService.d.ts +15 -0
- package/dist/service/ParameterService.js +22 -0
- package/dist/service/PoolService.d.ts +14 -0
- package/dist/service/PoolService.js +21 -0
- package/dist/{methods → service}/PortalService.d.ts +14 -10
- package/dist/service/PortalService.js +106 -0
- package/dist/{methods → service}/Report.d.ts +31 -27
- package/dist/service/Report.js +275 -0
- package/dist/service/SSReport.d.ts +90 -0
- package/dist/service/SSReport.js +127 -0
- package/dist/service/ScheduleTaskService.d.ts +15 -0
- package/dist/service/ScheduleTaskService.js +22 -0
- package/dist/service/SimpleReportService.d.ts +15 -0
- package/dist/service/SimpleReportService.js +22 -0
- package/dist/service/SpreadSheetReportService.d.ts +47 -0
- package/dist/service/SpreadSheetReportService.js +65 -0
- package/dist/service/SystemConfigService.d.ts +21 -0
- package/dist/service/SystemConfigService.js +28 -0
- package/dist/service/TimeConsuming.d.ts +10 -0
- package/dist/service/TimeConsuming.js +13 -0
- package/dist/service/TimeConsumingService.d.ts +8 -0
- package/dist/service/TimeConsumingService.js +13 -0
- package/dist/{methods → service}/UserManagerService.d.ts +40 -36
- package/dist/service/UserManagerService.js +365 -0
- package/dist/types-DOYMZhxT.d.ts +409 -0
- package/dist/vite-plugin/vite-plugin-smartbi.d.ts +21 -0
- package/dist/vite-plugin/vite-plugin-smartbi.js +54 -0
- package/dist/vite-plugin/vite-plugin-smartbix.d.ts +17 -0
- package/dist/vite-plugin/vite-plugin-smartbix.js +101 -0
- package/package.json +59 -141
- package/dist/methods/AnalysisReportService.js +0 -126
- package/dist/methods/BusinessThemeService.d.ts +0 -8
- package/dist/methods/BusinessThemeService.js +0 -11
- package/dist/methods/BusinessViewService.js +0 -120
- package/dist/methods/CatalogService.js +0 -230
- package/dist/methods/ClientCombinedReportService.js +0 -82
- package/dist/methods/ClientInsightService.js +0 -107
- package/dist/methods/ClientReportService.js +0 -206
- package/dist/methods/CombinedReportService.d.ts +0 -7
- package/dist/methods/CombinedReportService.js +0 -10
- package/dist/methods/DataSourceService.js +0 -220
- package/dist/methods/GraphicReportService.d.ts +0 -7
- package/dist/methods/GraphicReportService.js +0 -10
- package/dist/methods/InsightReport.d.ts +0 -71
- package/dist/methods/InsightReport.js +0 -98
- package/dist/methods/MetadataService.js +0 -47
- package/dist/methods/OfficeReport.d.ts +0 -49
- package/dist/methods/OfficeReport.js +0 -65
- package/dist/methods/OfficeReportService.js +0 -46
- package/dist/methods/OltpMetadataService.d.ts +0 -19
- package/dist/methods/OltpMetadataService.js +0 -25
- package/dist/methods/ParameterService.d.ts +0 -12
- package/dist/methods/ParameterService.js +0 -18
- package/dist/methods/PoolService.d.ts +0 -11
- package/dist/methods/PoolService.js +0 -17
- package/dist/methods/PortalService.js +0 -89
- package/dist/methods/Report.js +0 -230
- package/dist/methods/SSReport.d.ts +0 -86
- package/dist/methods/SSReport.js +0 -114
- package/dist/methods/ScheduleTaskService.d.ts +0 -12
- package/dist/methods/ScheduleTaskService.js +0 -18
- package/dist/methods/SimpleReportService.d.ts +0 -12
- package/dist/methods/SimpleReportService.js +0 -18
- package/dist/methods/SpreadSheetReportService.d.ts +0 -43
- package/dist/methods/SpreadSheetReportService.js +0 -55
- package/dist/methods/SystemConfigService.d.ts +0 -17
- package/dist/methods/SystemConfigService.js +0 -23
- package/dist/methods/TimeConsuming.d.ts +0 -6
- package/dist/methods/TimeConsuming.js +0 -9
- package/dist/methods/TimeConsumingService.d.ts +0 -5
- package/dist/methods/TimeConsumingService.js +0 -9
- package/dist/methods/UserManagerService.js +0 -312
- package/dist/types.d.ts +0 -412
- package/dist/types.js +0 -61
- package/dist/vite-plugin-smartbi/index.d.ts +0 -36
- package/dist/vite-plugin-smartbi/index.js +0 -107
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/OfficeReport.ts
|
|
4
|
+
/**
|
|
5
|
+
* 打开Word分析报告
|
|
6
|
+
* @param id Word分析报告id
|
|
7
|
+
* @returns 无返回值
|
|
8
|
+
*/
|
|
9
|
+
const openOfficeReport = (id) => {
|
|
10
|
+
return smartbi("OfficeReport", "open", [id]);
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* 关闭Word分析报告
|
|
14
|
+
* @returns 无返回值
|
|
15
|
+
*/
|
|
16
|
+
const closeOfficeReport = () => {
|
|
17
|
+
return smartbi("OfficeReport", "close", []);
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* 获取Word分析报告参数列表
|
|
21
|
+
* @returns 返回参数列表
|
|
22
|
+
*/
|
|
23
|
+
const getOfficeReportParamList = () => {
|
|
24
|
+
return smartbi("OfficeReport", "getParamList", []);
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* 根据参数ID获取参数备选值
|
|
28
|
+
* @param paramId 参数ID
|
|
29
|
+
* @returns 返回参数备选值列表
|
|
30
|
+
*/
|
|
31
|
+
const getOfficeReportParamStandbyValue = (paramId) => {
|
|
32
|
+
return smartbi("OfficeReport", "getParamStandbyValue", [paramId]);
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* 根据参数ID获取参数默认值
|
|
36
|
+
* @param pid 参数ID
|
|
37
|
+
* @returns 返回参数默认值
|
|
38
|
+
*/
|
|
39
|
+
const getOfficeReportParamDefaultValueByPID = (pid) => {
|
|
40
|
+
return smartbi("OfficeReport", "getParamDefaultValueByPID", [pid]);
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* 设置参数值
|
|
44
|
+
* @param id 参数ID
|
|
45
|
+
* @param value 参数真实值
|
|
46
|
+
* @param displayValue 参数显示值
|
|
47
|
+
* @returns 无返回值
|
|
48
|
+
*/
|
|
49
|
+
const setOfficeReportParamValue = (id, value, displayValue) => {
|
|
50
|
+
return smartbi("OfficeReport", "setParamValue", [
|
|
51
|
+
id,
|
|
52
|
+
value,
|
|
53
|
+
displayValue
|
|
54
|
+
]);
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* 导出Word分析报告
|
|
58
|
+
* @param type 导出类型
|
|
59
|
+
* @param os 输出流
|
|
60
|
+
* @returns 无返回值
|
|
61
|
+
*/
|
|
62
|
+
const exportOfficeReport = (type, os) => {
|
|
63
|
+
return smartbi("OfficeReport", "doExport", [type, os]);
|
|
64
|
+
};
|
|
65
|
+
/**
|
|
66
|
+
* 获取执行状态
|
|
67
|
+
* @returns 返回执行状态信息
|
|
68
|
+
*/
|
|
69
|
+
const getOfficeReportExecutingState = () => {
|
|
70
|
+
return smartbi("OfficeReport", "getExecutingState", []);
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
//#endregion
|
|
74
|
+
export { closeOfficeReport, exportOfficeReport, getOfficeReportExecutingState, getOfficeReportParamDefaultValueByPID, getOfficeReportParamList, getOfficeReportParamStandbyValue, openOfficeReport, setOfficeReportParamValue };
|
|
@@ -1,30 +1,32 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { D as NameValuePair } from "../types-DOYMZhxT.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/OfficeReportService.d.ts
|
|
2
4
|
/**
|
|
3
5
|
* 打开报表
|
|
4
6
|
* @param reportId 报表ID
|
|
5
7
|
* @returns 返回报表的JSON对象
|
|
6
8
|
*/
|
|
7
|
-
|
|
9
|
+
declare const openReport: (reportId: string) => Promise<any>;
|
|
8
10
|
/**
|
|
9
11
|
* 关闭报表
|
|
10
12
|
* @param clientId 客户端ID
|
|
11
13
|
* @returns 无返回值
|
|
12
14
|
*/
|
|
13
|
-
|
|
15
|
+
declare const closeReport: (clientId: string) => Promise<void>;
|
|
14
16
|
/**
|
|
15
17
|
* 获取参数备选值
|
|
16
18
|
* @param panelId 参数面板会话ID
|
|
17
19
|
* @param paramId 参数ID
|
|
18
20
|
* @returns 返回参数备选值列表
|
|
19
21
|
*/
|
|
20
|
-
|
|
22
|
+
declare const getParamStandbyValue: (panelId: string, paramId: string) => Promise<NameValuePair[]>;
|
|
21
23
|
/**
|
|
22
24
|
* 根据参数ID获取参数默认值
|
|
23
25
|
* @param panelId 参数面板会话ID
|
|
24
26
|
* @param paramId 参数ID
|
|
25
27
|
* @returns 返回参数默认值的JSON数组
|
|
26
28
|
*/
|
|
27
|
-
|
|
29
|
+
declare const getParamDefaultValueByPID: (panelId: string, paramId: string) => Promise<any[]>;
|
|
28
30
|
/**
|
|
29
31
|
* 设置参数值
|
|
30
32
|
* @param panelId 参数面板ID
|
|
@@ -33,4 +35,6 @@ export declare const getParamDefaultValueByPID: (panelId: string, paramId: strin
|
|
|
33
35
|
* @param displayValue 参数显示值
|
|
34
36
|
* @returns 返回是否设置成功的布尔值
|
|
35
37
|
*/
|
|
36
|
-
|
|
38
|
+
declare const setParamValue: (panelId: string, paramId: string, value: string, displayValue: string) => Promise<boolean>;
|
|
39
|
+
//#endregion
|
|
40
|
+
export { closeReport, getParamDefaultValueByPID, getParamStandbyValue, openReport, setParamValue };
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/OfficeReportService.ts
|
|
4
|
+
/**
|
|
5
|
+
* 打开报表
|
|
6
|
+
* @param reportId 报表ID
|
|
7
|
+
* @returns 返回报表的JSON对象
|
|
8
|
+
*/
|
|
9
|
+
const openReport = (reportId) => {
|
|
10
|
+
return smartbi("OfficeReportService", "openReport", [reportId]);
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* 关闭报表
|
|
14
|
+
* @param clientId 客户端ID
|
|
15
|
+
* @returns 无返回值
|
|
16
|
+
*/
|
|
17
|
+
const closeReport = (clientId) => {
|
|
18
|
+
return smartbi("OfficeReportService", "closeReport", [clientId]);
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* 获取参数备选值
|
|
22
|
+
* @param panelId 参数面板会话ID
|
|
23
|
+
* @param paramId 参数ID
|
|
24
|
+
* @returns 返回参数备选值列表
|
|
25
|
+
*/
|
|
26
|
+
const getParamStandbyValue = (panelId, paramId) => {
|
|
27
|
+
return smartbi("OfficeReportService", "getParamStandbyValue", [panelId, paramId]);
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* 根据参数ID获取参数默认值
|
|
31
|
+
* @param panelId 参数面板会话ID
|
|
32
|
+
* @param paramId 参数ID
|
|
33
|
+
* @returns 返回参数默认值的JSON数组
|
|
34
|
+
*/
|
|
35
|
+
const getParamDefaultValueByPID = (panelId, paramId) => {
|
|
36
|
+
return smartbi("OfficeReportService", "getParamDefaultValueByPID", [panelId, paramId]);
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* 设置参数值
|
|
40
|
+
* @param panelId 参数面板ID
|
|
41
|
+
* @param paramId 参数ID
|
|
42
|
+
* @param value 参数真实值
|
|
43
|
+
* @param displayValue 参数显示值
|
|
44
|
+
* @returns 返回是否设置成功的布尔值
|
|
45
|
+
*/
|
|
46
|
+
const setParamValue = (panelId, paramId, value, displayValue) => {
|
|
47
|
+
return smartbi("OfficeReportService", "setParamValue", [
|
|
48
|
+
panelId,
|
|
49
|
+
paramId,
|
|
50
|
+
value,
|
|
51
|
+
displayValue
|
|
52
|
+
]);
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
//#endregion
|
|
56
|
+
export { closeReport, getParamDefaultValueByPID, getParamStandbyValue, openReport, setParamValue };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { W as TableField, a as CalcField, d as DataSource } from "../types-DOYMZhxT.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/OltpMetadataService.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* 获取计算字段对象的基本信息
|
|
6
|
+
* @param calcFieldById 计算字段ID
|
|
7
|
+
* @returns 返回计算字段对象
|
|
8
|
+
*/
|
|
9
|
+
declare const getCalcFieldById: (calcFieldById: string) => Promise<CalcField>;
|
|
10
|
+
/**
|
|
11
|
+
* 获取指定的数据源的详细信息
|
|
12
|
+
* @param dataSourceID 数据源连接的ID值
|
|
13
|
+
* @returns 返回数据源对象
|
|
14
|
+
*/
|
|
15
|
+
declare const getOltpDataSource: (dataSourceID: string) => Promise<DataSource>;
|
|
16
|
+
/**
|
|
17
|
+
* 获取指定的表的字段的详细信息,包括:数据类型、字段长度
|
|
18
|
+
* @param fieldId 表的字段
|
|
19
|
+
* @returns 返回表的字段的详细信息
|
|
20
|
+
*/
|
|
21
|
+
declare const getFieldAttribute: (fieldId: string) => Promise<TableField>;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { getCalcFieldById, getFieldAttribute, getOltpDataSource };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/OltpMetadataService.ts
|
|
4
|
+
/**
|
|
5
|
+
* 获取计算字段对象的基本信息
|
|
6
|
+
* @param calcFieldById 计算字段ID
|
|
7
|
+
* @returns 返回计算字段对象
|
|
8
|
+
*/
|
|
9
|
+
const getCalcFieldById = (calcFieldById) => {
|
|
10
|
+
return smartbi("OltpMetadataService", "getCalcFieldById", [calcFieldById]);
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* 获取指定的数据源的详细信息
|
|
14
|
+
* @param dataSourceID 数据源连接的ID值
|
|
15
|
+
* @returns 返回数据源对象
|
|
16
|
+
*/
|
|
17
|
+
const getOltpDataSource = (dataSourceID) => {
|
|
18
|
+
return smartbi("OltpMetadataService", "getDataSource", [dataSourceID]);
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* 获取指定的表的字段的详细信息,包括:数据类型、字段长度
|
|
22
|
+
* @param fieldId 表的字段
|
|
23
|
+
* @returns 返回表的字段的详细信息
|
|
24
|
+
*/
|
|
25
|
+
const getFieldAttribute = (fieldId) => {
|
|
26
|
+
return smartbi("OltpMetadataService", "getFieldAttribute", [fieldId]);
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
//#endregion
|
|
30
|
+
export { getCalcFieldById, getFieldAttribute, getOltpDataSource };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
//#region src/service/ParameterService.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* 根据参数ID获取参数默认值SQL语句
|
|
4
|
+
* @param paramId 参数ID
|
|
5
|
+
* @returns 返回SQL语句
|
|
6
|
+
*/
|
|
7
|
+
declare const getParameterDefaultSQLById: (paramId: string) => Promise<string>;
|
|
8
|
+
/**
|
|
9
|
+
* 根据参数ID获取参数备选值SQL语句
|
|
10
|
+
* @param paramId 参数ID
|
|
11
|
+
* @returns 返回SQL语句
|
|
12
|
+
*/
|
|
13
|
+
declare const getParameterStandbySQLById: (paramId: string) => Promise<string>;
|
|
14
|
+
//#endregion
|
|
15
|
+
export { getParameterDefaultSQLById, getParameterStandbySQLById };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/ParameterService.ts
|
|
4
|
+
/**
|
|
5
|
+
* 根据参数ID获取参数默认值SQL语句
|
|
6
|
+
* @param paramId 参数ID
|
|
7
|
+
* @returns 返回SQL语句
|
|
8
|
+
*/
|
|
9
|
+
const getParameterDefaultSQLById = (paramId) => {
|
|
10
|
+
return smartbi("ParameterService", "getParameterDefaultSQLById", [paramId]);
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* 根据参数ID获取参数备选值SQL语句
|
|
14
|
+
* @param paramId 参数ID
|
|
15
|
+
* @returns 返回SQL语句
|
|
16
|
+
*/
|
|
17
|
+
const getParameterStandbySQLById = (paramId) => {
|
|
18
|
+
return smartbi("ParameterService", "getParameterStandbySQLById", [paramId]);
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
//#endregion
|
|
22
|
+
export { getParameterDefaultSQLById, getParameterStandbySQLById };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
//#region src/service/PoolService.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* 清除所有连接池
|
|
4
|
+
* @returns 无返回值
|
|
5
|
+
*/
|
|
6
|
+
declare const clearAllPools: () => Promise<void>;
|
|
7
|
+
/**
|
|
8
|
+
* 根据连接池名称清除连接池
|
|
9
|
+
* @param poolName 连接池名称
|
|
10
|
+
* @returns 无返回值
|
|
11
|
+
*/
|
|
12
|
+
declare const clearPoolByName: (poolName: string) => Promise<void>;
|
|
13
|
+
//#endregion
|
|
14
|
+
export { clearAllPools, clearPoolByName };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/PoolService.ts
|
|
4
|
+
/**
|
|
5
|
+
* 清除所有连接池
|
|
6
|
+
* @returns 无返回值
|
|
7
|
+
*/
|
|
8
|
+
const clearAllPools = () => {
|
|
9
|
+
return smartbi("PoolService", "clearAllPools", []);
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* 根据连接池名称清除连接池
|
|
13
|
+
* @param poolName 连接池名称
|
|
14
|
+
* @returns 无返回值
|
|
15
|
+
*/
|
|
16
|
+
const clearPoolByName = (poolName) => {
|
|
17
|
+
return smartbi("PoolService", "clearPoolByName", [poolName]);
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
//#endregion
|
|
21
|
+
export { clearAllPools, clearPoolByName };
|
|
@@ -1,23 +1,25 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { D as NameValuePair, j as Parameter } from "../types-DOYMZhxT.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/PortalService.d.ts
|
|
2
4
|
/**
|
|
3
5
|
* 打开整个页面
|
|
4
6
|
* @param pageId 页面ID
|
|
5
7
|
* @returns 返回客户端ID
|
|
6
8
|
*/
|
|
7
|
-
|
|
9
|
+
declare const openEntirePage: (pageId: string) => Promise<string>;
|
|
8
10
|
/**
|
|
9
11
|
* 执行页面中所有的查询
|
|
10
12
|
* @param clientId 客户端ID
|
|
11
13
|
* @param portletType 组件类型
|
|
12
14
|
* @returns 无返回值
|
|
13
15
|
*/
|
|
14
|
-
|
|
16
|
+
declare const excuteAllQueryInPage: (clientId: string, portletType: string[]) => Promise<void>;
|
|
15
17
|
/**
|
|
16
18
|
* 关闭整个页面
|
|
17
19
|
* @param clientId 客户端ID
|
|
18
20
|
* @returns 无返回值
|
|
19
21
|
*/
|
|
20
|
-
|
|
22
|
+
declare const closeEntirePage: (clientId: string) => Promise<void>;
|
|
21
23
|
/**
|
|
22
24
|
* 导出页面
|
|
23
25
|
* @param clientId 客户端ID
|
|
@@ -27,21 +29,21 @@ export declare const closeEntirePage: (clientId: string) => Promise<void>;
|
|
|
27
29
|
* @param postData 可选参数 - 参数
|
|
28
30
|
* @returns 无返回值
|
|
29
31
|
*/
|
|
30
|
-
|
|
32
|
+
declare const doExport: (clientId: string, exportType: string, pageWidth: number, os: any, postData?: string) => Promise<void>;
|
|
31
33
|
/**
|
|
32
34
|
* 根据参数ID获取参数默认值
|
|
33
35
|
* @param clientId 客户端ID
|
|
34
36
|
* @param paramId 参数ID
|
|
35
37
|
* @returns 返回参数默认值
|
|
36
38
|
*/
|
|
37
|
-
|
|
39
|
+
declare const getParamDefaultValue: (clientId: string, paramId: string) => Promise<string>;
|
|
38
40
|
/**
|
|
39
41
|
* 根据参数ID获取参数默认值列表
|
|
40
42
|
* @param clientId 客户端ID
|
|
41
43
|
* @param paramId 参数ID
|
|
42
44
|
* @returns 返回参数默认值列表
|
|
43
45
|
*/
|
|
44
|
-
|
|
46
|
+
declare const getParamDefaultValues: (clientId: string, paramId: string) => Promise<string[]>;
|
|
45
47
|
/**
|
|
46
48
|
* 设置参数值
|
|
47
49
|
* @param clientId 客户端ID
|
|
@@ -50,17 +52,19 @@ export declare const getParamDefaultValues: (clientId: string, paramId: string)
|
|
|
50
52
|
* @param paramDisplayValue 参数显示值
|
|
51
53
|
* @returns 无返回值
|
|
52
54
|
*/
|
|
53
|
-
|
|
55
|
+
declare const setParamValue: (clientId: string, paramId: string, paramValue: string, paramDisplayValue: string) => Promise<void>;
|
|
54
56
|
/**
|
|
55
57
|
* 获取页面的参数列表
|
|
56
58
|
* @param pageId 页面ID
|
|
57
59
|
* @returns 返回参数列表
|
|
58
60
|
*/
|
|
59
|
-
|
|
61
|
+
declare const getParameters: (pageId: string) => Promise<Parameter[]>;
|
|
60
62
|
/**
|
|
61
63
|
* 获取参数备选值
|
|
62
64
|
* @param clientId 客户端ID
|
|
63
65
|
* @param paramId 参数ID
|
|
64
66
|
* @returns 返回参数标准值
|
|
65
67
|
*/
|
|
66
|
-
|
|
68
|
+
declare const getParamStandbyValue: (clientId: string, paramId: string) => Promise<NameValuePair[]>;
|
|
69
|
+
//#endregion
|
|
70
|
+
export { closeEntirePage, doExport, excuteAllQueryInPage, getParamDefaultValue, getParamDefaultValues, getParamStandbyValue, getParameters, openEntirePage, setParamValue };
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { smartbi } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/service/PortalService.ts
|
|
4
|
+
/**
|
|
5
|
+
* 打开整个页面
|
|
6
|
+
* @param pageId 页面ID
|
|
7
|
+
* @returns 返回客户端ID
|
|
8
|
+
*/
|
|
9
|
+
const openEntirePage = (pageId) => {
|
|
10
|
+
return smartbi("PortalService", "openEntirePage", [pageId]);
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* 执行页面中所有的查询
|
|
14
|
+
* @param clientId 客户端ID
|
|
15
|
+
* @param portletType 组件类型
|
|
16
|
+
* @returns 无返回值
|
|
17
|
+
*/
|
|
18
|
+
const excuteAllQueryInPage = (clientId, portletType) => {
|
|
19
|
+
return smartbi("PortalService", "excuteAllQueryInPage", [clientId, portletType.toString()]);
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* 关闭整个页面
|
|
23
|
+
* @param clientId 客户端ID
|
|
24
|
+
* @returns 无返回值
|
|
25
|
+
*/
|
|
26
|
+
const closeEntirePage = (clientId) => {
|
|
27
|
+
return smartbi("PortalService", "closeEntirePage", [clientId]);
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* 导出页面
|
|
31
|
+
* @param clientId 客户端ID
|
|
32
|
+
* @param exportType 导出类型
|
|
33
|
+
* @param pageWidth 页面大小
|
|
34
|
+
* @param os 输出流
|
|
35
|
+
* @param postData 可选参数 - 参数
|
|
36
|
+
* @returns 无返回值
|
|
37
|
+
*/
|
|
38
|
+
const doExport = (clientId, exportType, pageWidth, os, postData) => {
|
|
39
|
+
if (postData !== void 0) return smartbi("PortalService", "doExport", [
|
|
40
|
+
clientId,
|
|
41
|
+
exportType,
|
|
42
|
+
pageWidth,
|
|
43
|
+
os,
|
|
44
|
+
postData
|
|
45
|
+
]);
|
|
46
|
+
else return smartbi("PortalService", "doExport", [
|
|
47
|
+
clientId,
|
|
48
|
+
exportType,
|
|
49
|
+
pageWidth,
|
|
50
|
+
os
|
|
51
|
+
]);
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* 根据参数ID获取参数默认值
|
|
55
|
+
* @param clientId 客户端ID
|
|
56
|
+
* @param paramId 参数ID
|
|
57
|
+
* @returns 返回参数默认值
|
|
58
|
+
*/
|
|
59
|
+
const getParamDefaultValue = (clientId, paramId) => {
|
|
60
|
+
return smartbi("PortalService", "getParamDefaultValue", [clientId, paramId]);
|
|
61
|
+
};
|
|
62
|
+
/**
|
|
63
|
+
* 根据参数ID获取参数默认值列表
|
|
64
|
+
* @param clientId 客户端ID
|
|
65
|
+
* @param paramId 参数ID
|
|
66
|
+
* @returns 返回参数默认值列表
|
|
67
|
+
*/
|
|
68
|
+
const getParamDefaultValues = (clientId, paramId) => {
|
|
69
|
+
return smartbi("PortalService", "getParamDefaultValues", [clientId, paramId]);
|
|
70
|
+
};
|
|
71
|
+
/**
|
|
72
|
+
* 设置参数值
|
|
73
|
+
* @param clientId 客户端ID
|
|
74
|
+
* @param paramId 参数ID
|
|
75
|
+
* @param paramValue 参数值
|
|
76
|
+
* @param paramDisplayValue 参数显示值
|
|
77
|
+
* @returns 无返回值
|
|
78
|
+
*/
|
|
79
|
+
const setParamValue = (clientId, paramId, paramValue, paramDisplayValue) => {
|
|
80
|
+
return smartbi("PortalService", "setParamValue", [
|
|
81
|
+
clientId,
|
|
82
|
+
paramId,
|
|
83
|
+
paramValue,
|
|
84
|
+
paramDisplayValue
|
|
85
|
+
]);
|
|
86
|
+
};
|
|
87
|
+
/**
|
|
88
|
+
* 获取页面的参数列表
|
|
89
|
+
* @param pageId 页面ID
|
|
90
|
+
* @returns 返回参数列表
|
|
91
|
+
*/
|
|
92
|
+
const getParameters = (pageId) => {
|
|
93
|
+
return smartbi("PortalService", "getParameters", [pageId]);
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* 获取参数备选值
|
|
97
|
+
* @param clientId 客户端ID
|
|
98
|
+
* @param paramId 参数ID
|
|
99
|
+
* @returns 返回参数标准值
|
|
100
|
+
*/
|
|
101
|
+
const getParamStandbyValue = (clientId, paramId) => {
|
|
102
|
+
return smartbi("PortalService", "getParamStandbyValue", [clientId, paramId]);
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
//#endregion
|
|
106
|
+
export { closeEntirePage, doExport, excuteAllQueryInPage, getParamDefaultValue, getParamDefaultValues, getParamStandbyValue, getParameters, openEntirePage, setParamValue };
|