smartbi-toolkit 1.1.2 → 1.1.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 (62) hide show
  1. package/README.md +5 -0
  2. package/dist/index.d.ts +30 -0
  3. package/dist/index.js +141 -0
  4. package/dist/methods/AnalysisReportService.d.ts +93 -0
  5. package/dist/methods/AnalysisReportService.js +126 -0
  6. package/dist/methods/BusinessThemeService.d.ts +8 -0
  7. package/dist/methods/BusinessThemeService.js +11 -0
  8. package/dist/methods/BusinessViewService.d.ts +94 -0
  9. package/dist/methods/BusinessViewService.js +120 -0
  10. package/dist/methods/CatalogService.d.ts +188 -0
  11. package/dist/methods/CatalogService.js +230 -0
  12. package/dist/methods/ClientCombinedReportService.d.ts +63 -0
  13. package/dist/methods/ClientCombinedReportService.js +82 -0
  14. package/dist/methods/ClientInsightService.d.ts +83 -0
  15. package/dist/methods/ClientInsightService.js +107 -0
  16. package/dist/methods/ClientReportService.d.ts +162 -0
  17. package/dist/methods/ClientReportService.js +206 -0
  18. package/dist/methods/CombinedReportService.d.ts +7 -0
  19. package/dist/methods/CombinedReportService.js +10 -0
  20. package/dist/methods/DataSourceService.d.ts +178 -0
  21. package/dist/methods/DataSourceService.js +220 -0
  22. package/dist/methods/GraphicReportService.d.ts +7 -0
  23. package/dist/methods/GraphicReportService.js +10 -0
  24. package/dist/methods/InsightReport.d.ts +71 -0
  25. package/dist/methods/InsightReport.js +98 -0
  26. package/dist/methods/MetadataService.d.ts +37 -0
  27. package/dist/methods/MetadataService.js +47 -0
  28. package/dist/methods/OfficeReport.d.ts +49 -0
  29. package/dist/methods/OfficeReport.js +65 -0
  30. package/dist/methods/OfficeReportService.d.ts +36 -0
  31. package/dist/methods/OfficeReportService.js +46 -0
  32. package/dist/methods/OltpMetadataService.d.ts +19 -0
  33. package/dist/methods/OltpMetadataService.js +25 -0
  34. package/dist/methods/ParameterService.d.ts +12 -0
  35. package/dist/methods/ParameterService.js +18 -0
  36. package/dist/methods/PoolService.d.ts +11 -0
  37. package/dist/methods/PoolService.js +17 -0
  38. package/dist/methods/PortalService.d.ts +66 -0
  39. package/dist/methods/PortalService.js +89 -0
  40. package/dist/methods/Report.d.ts +178 -0
  41. package/dist/methods/Report.js +230 -0
  42. package/dist/methods/SSReport.d.ts +86 -0
  43. package/dist/methods/SSReport.js +114 -0
  44. package/dist/methods/ScheduleTaskService.d.ts +12 -0
  45. package/dist/methods/ScheduleTaskService.js +18 -0
  46. package/dist/methods/SimpleReportService.d.ts +12 -0
  47. package/dist/methods/SimpleReportService.js +18 -0
  48. package/dist/methods/SpreadSheetReportService.d.ts +43 -0
  49. package/dist/methods/SpreadSheetReportService.js +55 -0
  50. package/dist/methods/SystemConfigService.d.ts +17 -0
  51. package/dist/methods/SystemConfigService.js +23 -0
  52. package/dist/methods/TimeConsuming.d.ts +6 -0
  53. package/dist/methods/TimeConsuming.js +9 -0
  54. package/dist/methods/TimeConsumingService.d.ts +5 -0
  55. package/dist/methods/TimeConsumingService.js +9 -0
  56. package/dist/methods/UserManagerService.d.ts +236 -0
  57. package/dist/methods/UserManagerService.js +312 -0
  58. package/dist/types.d.ts +412 -0
  59. package/dist/types.js +61 -0
  60. package/dist/vite-plugin-smartbi/index.d.ts +36 -0
  61. package/dist/vite-plugin-smartbi/index.js +107 -0
  62. package/package.json +1 -1
@@ -0,0 +1,86 @@
1
+ import type { NameValuePair, Parameter, RunningInfo, SSReportExportType } from '../types';
2
+ /**
3
+ * 打开电子表格报表
4
+ * @param id 报表ID
5
+ * @returns 无返回值
6
+ */
7
+ export declare const openSSReport: (id: string) => Promise<void>;
8
+ /**
9
+ * 关闭电子表格报表
10
+ * @returns 无返回值
11
+ */
12
+ export declare const closeSSReport: () => Promise<void>;
13
+ /**
14
+ * 获取参数列表
15
+ * @returns 返回参数列表
16
+ */
17
+ export declare const getSSReportParamList: () => Promise<Parameter[]>;
18
+ /**
19
+ * 根据参数ID获取参数备选值
20
+ * @param paramId 参数ID
21
+ * @returns 返回参数键值对
22
+ */
23
+ export declare const getSSReportParamStandbyValue: (paramId: string) => Promise<NameValuePair[]>;
24
+ /**
25
+ * 根据参数ID获取参数默认值
26
+ * @param pid 参数ID
27
+ * @returns 返回参数默认值
28
+ */
29
+ export declare const getSSReportParamDefaultValueByPID: (pid: string) => Promise<string>;
30
+ /**
31
+ * 导出电子表格(基础版)
32
+ * @param type 导出类型
33
+ * @param os 输出流
34
+ * @returns 无返回值
35
+ */
36
+ export declare const exportSSReport: (type: SSReportExportType | string, os: any) => Promise<void>;
37
+ /**
38
+ * 导出电子表格(带参数版)
39
+ * @param type 导出格式
40
+ * @param os 输出流
41
+ * @param postData 请求参数
42
+ * @returns 无返回值
43
+ */
44
+ export declare const exportSSReportWithPostData: (type: SSReportExportType | string, os: any, postData: string) => Promise<void>;
45
+ /**
46
+ * 设置参数值
47
+ * @param id 参数ID
48
+ * @param value 值
49
+ * @param displayValue 显示值
50
+ * @returns 无返回值
51
+ */
52
+ export declare const setSSReportParamValue: (id: string, value: string, displayValue: string) => Promise<void>;
53
+ /**
54
+ * 设置导出工作单的索引
55
+ * @param exportSheetIndexes 导出工作单的索引
56
+ * @returns 无返回值
57
+ */
58
+ export declare const setSSReportExportSheetIndexes: (exportSheetIndexes: string) => Promise<void>;
59
+ /**
60
+ * 设置是否导出公式
61
+ * @param exportFormula 是否导出公式
62
+ * @returns 无返回值
63
+ */
64
+ export declare const setSSReportExportFormula: (exportFormula: boolean) => Promise<void>;
65
+ /**
66
+ * 获取执行状态
67
+ * @returns 返回执行状态
68
+ */
69
+ export declare const getSSReportExecutingState: () => Promise<RunningInfo>;
70
+ /**
71
+ * 获取操作
72
+ * @returns 返回操作
73
+ */
74
+ export declare const getSSReportOperation: () => Promise<string>;
75
+ /**
76
+ * 设置操作
77
+ * @param operation 操作
78
+ * @returns 无返回值
79
+ */
80
+ export declare const setSSReportOperation: (operation: string) => Promise<void>;
81
+ /**
82
+ * 设置筛选条件
83
+ * @param filtersRule 筛选条件json
84
+ * @returns 无返回值
85
+ */
86
+ export declare const setSSReportFiltersRule: (filtersRule: string) => Promise<void>;
@@ -0,0 +1,114 @@
1
+ import { smartbi } from "../index";
2
+ /**
3
+ * 打开电子表格报表
4
+ * @param id 报表ID
5
+ * @returns 无返回值
6
+ */
7
+ export const openSSReport = (id) => {
8
+ return smartbi('SSReport', 'open', [id]);
9
+ };
10
+ /**
11
+ * 关闭电子表格报表
12
+ * @returns 无返回值
13
+ */
14
+ export const closeSSReport = () => {
15
+ return smartbi('SSReport', 'close', []);
16
+ };
17
+ /**
18
+ * 获取参数列表
19
+ * @returns 返回参数列表
20
+ */
21
+ export const getSSReportParamList = () => {
22
+ return smartbi('SSReport', 'getParamList', []);
23
+ };
24
+ /**
25
+ * 根据参数ID获取参数备选值
26
+ * @param paramId 参数ID
27
+ * @returns 返回参数键值对
28
+ */
29
+ export const getSSReportParamStandbyValue = (paramId) => {
30
+ return smartbi('SSReport', 'getParamStandbyValue', [paramId]);
31
+ };
32
+ /**
33
+ * 根据参数ID获取参数默认值
34
+ * @param pid 参数ID
35
+ * @returns 返回参数默认值
36
+ */
37
+ export const getSSReportParamDefaultValueByPID = (pid) => {
38
+ return smartbi('SSReport', 'getParamDefaultValueByPID', [pid]);
39
+ };
40
+ /**
41
+ * 导出电子表格(基础版)
42
+ * @param type 导出类型
43
+ * @param os 输出流
44
+ * @returns 无返回值
45
+ */
46
+ export const exportSSReport = (type, os) => {
47
+ return smartbi('SSReport', 'doExport', [type, os]);
48
+ };
49
+ /**
50
+ * 导出电子表格(带参数版)
51
+ * @param type 导出格式
52
+ * @param os 输出流
53
+ * @param postData 请求参数
54
+ * @returns 无返回值
55
+ */
56
+ export const exportSSReportWithPostData = (type, os, postData) => {
57
+ return smartbi('SSReport', 'doExport', [type, os, postData]);
58
+ };
59
+ /**
60
+ * 设置参数值
61
+ * @param id 参数ID
62
+ * @param value 值
63
+ * @param displayValue 显示值
64
+ * @returns 无返回值
65
+ */
66
+ export const setSSReportParamValue = (id, value, displayValue) => {
67
+ return smartbi('SSReport', 'setParamValue', [id, value, displayValue]);
68
+ };
69
+ /**
70
+ * 设置导出工作单的索引
71
+ * @param exportSheetIndexes 导出工作单的索引
72
+ * @returns 无返回值
73
+ */
74
+ export const setSSReportExportSheetIndexes = (exportSheetIndexes) => {
75
+ return smartbi('SSReport', 'setExportSheetIndexes', [exportSheetIndexes]);
76
+ };
77
+ /**
78
+ * 设置是否导出公式
79
+ * @param exportFormula 是否导出公式
80
+ * @returns 无返回值
81
+ */
82
+ export const setSSReportExportFormula = (exportFormula) => {
83
+ return smartbi('SSReport', 'setExportFormula', [exportFormula]);
84
+ };
85
+ /**
86
+ * 获取执行状态
87
+ * @returns 返回执行状态
88
+ */
89
+ export const getSSReportExecutingState = () => {
90
+ return smartbi('SSReport', 'getExecutingState', []);
91
+ };
92
+ /**
93
+ * 获取操作
94
+ * @returns 返回操作
95
+ */
96
+ export const getSSReportOperation = () => {
97
+ return smartbi('SSReport', 'getOperation', []);
98
+ };
99
+ /**
100
+ * 设置操作
101
+ * @param operation 操作
102
+ * @returns 无返回值
103
+ */
104
+ export const setSSReportOperation = (operation) => {
105
+ return smartbi('SSReport', 'setOperation', [operation]);
106
+ };
107
+ /**
108
+ * 设置筛选条件
109
+ * @param filtersRule 筛选条件json
110
+ * @returns 无返回值
111
+ */
112
+ export const setSSReportFiltersRule = (filtersRule) => {
113
+ return smartbi('SSReport', 'setFiltersRule', [filtersRule]);
114
+ };
@@ -0,0 +1,12 @@
1
+ /**
2
+ * 执行计划任务
3
+ * @param scheduleId 计划ID
4
+ * @returns 返回执行结果的布尔值
5
+ */
6
+ export declare const executeSchedule: (scheduleId: string) => Promise<boolean>;
7
+ /**
8
+ * 执行任务
9
+ * @param taskId 任务ID
10
+ * @returns 返回执行结果的布尔值
11
+ */
12
+ export declare const executeTask: (taskId: string) => Promise<boolean>;
@@ -0,0 +1,18 @@
1
+ // 定义SmartBI计划任务服务相关的类型接口
2
+ import { smartbi } from "../index";
3
+ /**
4
+ * 执行计划任务
5
+ * @param scheduleId 计划ID
6
+ * @returns 返回执行结果的布尔值
7
+ */
8
+ export const executeSchedule = (scheduleId) => {
9
+ return smartbi('ScheduleTaskService', 'executeSchedule', [scheduleId]);
10
+ };
11
+ /**
12
+ * 执行任务
13
+ * @param taskId 任务ID
14
+ * @returns 返回执行结果的布尔值
15
+ */
16
+ export const executeTask = (taskId) => {
17
+ return smartbi('ScheduleTaskService', 'executeTask', [taskId]);
18
+ };
@@ -0,0 +1,12 @@
1
+ /**
2
+ * 创建并打开一个报表
3
+ * @param reportId 报表ID
4
+ * @returns 返回打开的报表对象
5
+ */
6
+ export declare const openReport: (reportId: string) => Promise<any>;
7
+ /**
8
+ * 打开一个报表不初始化数据库链接
9
+ * @param reportId 报表ID
10
+ * @returns 返回打开的报表对象
11
+ */
12
+ export declare const openReportWithoutInit: (reportId: string) => Promise<any>;
@@ -0,0 +1,18 @@
1
+ // 定义SmartBI简单报表服务相关的类型接口
2
+ import { smartbi } from "../index";
3
+ /**
4
+ * 创建并打开一个报表
5
+ * @param reportId 报表ID
6
+ * @returns 返回打开的报表对象
7
+ */
8
+ export const openReport = (reportId) => {
9
+ return smartbi('SimpleReportService', 'openReport', [reportId]);
10
+ };
11
+ /**
12
+ * 打开一个报表不初始化数据库链接
13
+ * @param reportId 报表ID
14
+ * @returns 返回打开的报表对象
15
+ */
16
+ export const openReportWithoutInit = (reportId) => {
17
+ return smartbi('SimpleReportService', 'openReportWithoutInit', [reportId]);
18
+ };
@@ -0,0 +1,43 @@
1
+ import type { NameValuePair } from '../types';
2
+ /**
3
+ * 打开电子表格报表
4
+ * @param reportId 报表ID
5
+ * @returns 返回客户端ID
6
+ */
7
+ export declare const openSpreadSheetReportQuery: (reportId: string) => Promise<any>;
8
+ /**
9
+ * 关闭电子表格报表
10
+ * @param clientId 客户端ID
11
+ * @returns 无返回值
12
+ */
13
+ export declare const closeSpreadSheetReportQuery: (clientId: string) => Promise<void>;
14
+ /**
15
+ * 根据参数ID获取参数默认值
16
+ * @param panelId 参数面板ID
17
+ * @param paramId 参数ID
18
+ * @returns 返回参数默认值
19
+ */
20
+ export declare const getSpreadSheetReportParamDefaultValueByPID: (panelId: string, paramId: string) => Promise<any[]>;
21
+ /**
22
+ * 获取参数备选值
23
+ * @param panelId 参数面板ID
24
+ * @param paramId 参数ID
25
+ * @returns 返回参数标准值
26
+ */
27
+ export declare const getSpreadSheetReportParamStandbyValue: (panelId: string, paramId: string) => Promise<NameValuePair[]>;
28
+ /**
29
+ * 获取报表层面的参数默认值
30
+ * @param contextId 报表上下文会话id
31
+ * @param paramId 参数id
32
+ * @returns 返回报表参数默认值
33
+ */
34
+ export declare const getSpreadSheetReportParamDefaultValueByContext: (contextId: string, paramId: string) => Promise<any[]>;
35
+ /**
36
+ * 设置参数值
37
+ * @param panelId 参数面板ID
38
+ * @param paramId 参数ID
39
+ * @param value 值
40
+ * @param displayValue 显示值
41
+ * @returns 返回是否设置成功的布尔值
42
+ */
43
+ export declare const setSpreadSheetReportParamValue: (panelId: string, paramId: string, value: string, displayValue: string) => Promise<boolean>;
@@ -0,0 +1,55 @@
1
+ import { smartbi } from "../index";
2
+ /**
3
+ * 打开电子表格报表
4
+ * @param reportId 报表ID
5
+ * @returns 返回客户端ID
6
+ */
7
+ export const openSpreadSheetReportQuery = (reportId) => {
8
+ return smartbi('SpreadSheetReportService', 'openQuery', [reportId]);
9
+ };
10
+ /**
11
+ * 关闭电子表格报表
12
+ * @param clientId 客户端ID
13
+ * @returns 无返回值
14
+ */
15
+ export const closeSpreadSheetReportQuery = (clientId) => {
16
+ return smartbi('SpreadSheetReportService', 'closeQuery', [clientId]);
17
+ };
18
+ /**
19
+ * 根据参数ID获取参数默认值
20
+ * @param panelId 参数面板ID
21
+ * @param paramId 参数ID
22
+ * @returns 返回参数默认值
23
+ */
24
+ export const getSpreadSheetReportParamDefaultValueByPID = (panelId, paramId) => {
25
+ return smartbi('SpreadSheetReportService', 'getParamDefaultValueByPID', [panelId, paramId]);
26
+ };
27
+ /**
28
+ * 获取参数备选值
29
+ * @param panelId 参数面板ID
30
+ * @param paramId 参数ID
31
+ * @returns 返回参数标准值
32
+ */
33
+ export const getSpreadSheetReportParamStandbyValue = (panelId, paramId) => {
34
+ return smartbi('SpreadSheetReportService', 'getParamStandbyValue', [panelId, paramId]);
35
+ };
36
+ /**
37
+ * 获取报表层面的参数默认值
38
+ * @param contextId 报表上下文会话id
39
+ * @param paramId 参数id
40
+ * @returns 返回报表参数默认值
41
+ */
42
+ export const getSpreadSheetReportParamDefaultValueByContext = (contextId, paramId) => {
43
+ return smartbi('SpreadSheetReportService', 'getReportParamDefaultValueByPID', [contextId, paramId]);
44
+ };
45
+ /**
46
+ * 设置参数值
47
+ * @param panelId 参数面板ID
48
+ * @param paramId 参数ID
49
+ * @param value 值
50
+ * @param displayValue 显示值
51
+ * @returns 返回是否设置成功的布尔值
52
+ */
53
+ export const setSpreadSheetReportParamValue = (panelId, paramId, value, displayValue) => {
54
+ return smartbi('SpreadSheetReportService', 'setParamValue', [panelId, paramId, value, displayValue]);
55
+ };
@@ -0,0 +1,17 @@
1
+ import type { SystemConfig } from '../types';
2
+ /**
3
+ * 获取系统设置
4
+ * @returns 返回系统设置对象列表
5
+ */
6
+ export declare const getSystemConfigs: () => Promise<SystemConfig[]>;
7
+ /**
8
+ * 根据键获取系统配置
9
+ * @param key 配置键
10
+ * @returns 返回系统配置对象
11
+ */
12
+ export declare const getSystemConfig: (key: string) => Promise<SystemConfig>;
13
+ /**
14
+ * 清空缓存
15
+ * @returns 无返回值
16
+ */
17
+ export declare const clearSystemConfigCache: () => Promise<void>;
@@ -0,0 +1,23 @@
1
+ import { smartbi } from "../index";
2
+ /**
3
+ * 获取系统设置
4
+ * @returns 返回系统设置对象列表
5
+ */
6
+ export const getSystemConfigs = () => {
7
+ return smartbi('SystemConfigService', 'getSystemConfigs', []);
8
+ };
9
+ /**
10
+ * 根据键获取系统配置
11
+ * @param key 配置键
12
+ * @returns 返回系统配置对象
13
+ */
14
+ export const getSystemConfig = (key) => {
15
+ return smartbi('SystemConfigService', 'getSystemConfig', [key]);
16
+ };
17
+ /**
18
+ * 清空缓存
19
+ * @returns 无返回值
20
+ */
21
+ export const clearSystemConfigCache = () => {
22
+ return smartbi('SystemConfigService', 'clearCache', []);
23
+ };
@@ -0,0 +1,6 @@
1
+ import type { RunningInfo } from '../types';
2
+ /**
3
+ * 获取状态信息
4
+ * @returns 返回执行状态信息
5
+ */
6
+ export declare const loadTimeConsuming: () => Promise<RunningInfo>;
@@ -0,0 +1,9 @@
1
+ // 定义SmartBI耗时分析相关的类型接口
2
+ import { smartbi } from "../index";
3
+ /**
4
+ * 获取状态信息
5
+ * @returns 返回执行状态信息
6
+ */
7
+ export const loadTimeConsuming = () => {
8
+ return smartbi('TimeConsuming', 'load', []);
9
+ };
@@ -0,0 +1,5 @@
1
+ /**
2
+ * 获取执行时间信息
3
+ * @returns 返回执行时间信息的JSON对象
4
+ */
5
+ export declare const loadRunningTimeConsuming: () => Promise<any>;
@@ -0,0 +1,9 @@
1
+ // 导入公共类型
2
+ import { smartbi } from "../index";
3
+ /**
4
+ * 获取执行时间信息
5
+ * @returns 返回执行时间信息的JSON对象
6
+ */
7
+ export const loadRunningTimeConsuming = () => {
8
+ return smartbi('TimeConsumingService', 'loadRunning', []);
9
+ };
@@ -0,0 +1,236 @@
1
+ import type { User, Role, Department, FunctionPermission, ExtensionAttribute } from '../types';
2
+ /**
3
+ * 创建用户
4
+ * @param parentGroupId 父组ID
5
+ * @param userName 用户名
6
+ * @param userAlias 用户别名
7
+ * @param desc 描述
8
+ * @param password 密码
9
+ * @param isEnabled 是否启用
10
+ * @param forceChangePassword 是否强制修改密码(可选)
11
+ * @returns 返回新创建的用户ID
12
+ */
13
+ export declare const createUser: (parentGroupId: string, userName: string, userAlias: string, desc: string, password: string, isEnabled: boolean, forceChangePassword?: boolean) => Promise<string>;
14
+ /**
15
+ * 指定ID创建用户
16
+ * @param parentGroupId 父组ID
17
+ * @param userId 用户ID
18
+ * @param userName 用户名
19
+ * @param userAlias 用户别名
20
+ * @param desc 描述
21
+ * @param password 密码
22
+ * @param isEnabled 是否启用
23
+ * @param forceChangePassword 是否强制修改密码(可选)
24
+ */
25
+ export declare const createUserById: (parentGroupId: string, userId: string, userName: string, userAlias: string, desc: string, password: string, isEnabled: boolean, forceChangePassword?: boolean) => Promise<void>;
26
+ /**
27
+ * 删除用户
28
+ * @param userId 用户ID
29
+ * @returns 返回是否删除成功的布尔值
30
+ */
31
+ export declare const deleteUser: (userId: string) => Promise<boolean>;
32
+ /**
33
+ * 通过用户ID获取用户信息
34
+ * @param id 用户ID
35
+ * @returns 返回用户信息
36
+ */
37
+ export declare const getUserById: (id: string) => Promise<User>;
38
+ /**
39
+ * 通过用户名称获取用户信息
40
+ * @param name 用户名称
41
+ * @returns 返回用户信息
42
+ */
43
+ export declare const getUserByName: (name: string) => Promise<User>;
44
+ /**
45
+ * 根据用户扩展属性获取用户信息
46
+ * @param key 属性键
47
+ * @param value 属性值
48
+ * @returns 返回用户列表
49
+ */
50
+ export declare const getUserByAttribute: (key: string, value: string) => Promise<User[]>;
51
+ /**
52
+ * 获取系统中的用户列表
53
+ * @returns 返回用户列表
54
+ */
55
+ export declare const getAllUsers: () => Promise<User[]>;
56
+ /**
57
+ * 获取当前登录用户信息
58
+ * @returns 返回当前用户信息
59
+ */
60
+ export declare const getCurrentUser: () => Promise<User>;
61
+ /**
62
+ * 修改当前用户的密码
63
+ * @param oldPassword 旧密码
64
+ * @param newPassword 新密码
65
+ */
66
+ export declare const changePassword: (oldPassword: string, newPassword: string) => Promise<void>;
67
+ /**
68
+ * 获取用户密码
69
+ * @param userName 用户名
70
+ * @returns 返回用户密码
71
+ */
72
+ export declare const getPassword: (userName: string) => Promise<string>;
73
+ /**
74
+ * 创建角色
75
+ * @param roleName 角色名称
76
+ * @param roleAlias 角色别名
77
+ * @param desc 描述
78
+ * @param groupId 组ID
79
+ * @returns 返回新创建的角色ID
80
+ */
81
+ export declare const createRole: (roleName: string, roleAlias: string, desc: string, groupId: string) => Promise<string>;
82
+ /**
83
+ * 删除角色
84
+ * @param roleId 角色ID
85
+ * @returns 返回是否删除成功的布尔值
86
+ */
87
+ export declare const deleteRole: (roleId: string) => Promise<boolean>;
88
+ /**
89
+ * 通过ID获取角色
90
+ * @param id 角色ID
91
+ * @returns 返回角色信息
92
+ */
93
+ export declare const getRoleById: (id: string) => Promise<Role>;
94
+ /**
95
+ * 通过角色名称获取角色对象
96
+ * @param name 角色名称
97
+ * @returns 返回角色信息
98
+ */
99
+ export declare const getRoleByName: (name: string) => Promise<Role>;
100
+ /**
101
+ * 获取系统中的角色列表
102
+ * @returns 返回角色列表
103
+ */
104
+ export declare const getAllRoles: () => Promise<Role[]>;
105
+ /**
106
+ * 给用户分配角色
107
+ * @param userId 用户ID
108
+ * @param roleIdList 角色ID列表
109
+ * @returns 返回是否分配成功的布尔值
110
+ */
111
+ export declare const assignRolesToUser: (userId: string, roleIdList: string[]) => Promise<boolean>;
112
+ /**
113
+ * 给角色分配用户
114
+ * @param roleId 角色ID
115
+ * @param userIdList 用户ID列表
116
+ * @returns 返回是否分配成功的布尔值
117
+ */
118
+ export declare const assignUsersToRole: (roleId: string, userIdList: string[]) => Promise<boolean>;
119
+ /**
120
+ * 创建组
121
+ * @param parentGroupId 父组ID
122
+ * @param groupName 组名称
123
+ * @param groupAlias 组别名
124
+ * @param desc 描述
125
+ * @param departmentCode 组编号
126
+ * @returns 返回新创建的组ID
127
+ */
128
+ export declare const createDepartment: (parentGroupId: string, groupName: string, groupAlias: string, desc: string, departmentCode: string) => Promise<string>;
129
+ /**
130
+ * 删除组
131
+ * @param groupId 组ID
132
+ * @returns 返回是否删除成功的布尔值
133
+ */
134
+ export declare const deleteDepartment: (groupId: string) => Promise<boolean>;
135
+ /**
136
+ * 通过ID获取组对象
137
+ * @param id 组ID
138
+ * @returns 返回组信息
139
+ */
140
+ export declare const getDepartmentById: (id: string) => Promise<Department>;
141
+ /**
142
+ * 通过组名称获取组对象
143
+ * @param name 组名称
144
+ * @returns 返回组信息
145
+ */
146
+ export declare const getDepartmentByName: (name: string) => Promise<Department>;
147
+ /**
148
+ * 通过组编号获取组对象
149
+ * @param code 组编号
150
+ * @returns 返回组信息
151
+ */
152
+ export declare const getDepartmentByCode: (code: string) => Promise<Department>;
153
+ /**
154
+ * 获取系统中的组列表
155
+ * @returns 返回组列表
156
+ */
157
+ export declare const getAllDepartments: () => Promise<Department[]>;
158
+ /**
159
+ * 获取用户的所属组
160
+ * @param userId 用户ID
161
+ * @returns 返回用户所属组列表
162
+ */
163
+ export declare const getDepartmentsOfUser: (userId: string) => Promise<Department[]>;
164
+ /**
165
+ * 修改组所拥有的用户
166
+ * @param groupId 组ID
167
+ * @param userIdList 用户ID列表
168
+ * @returns 返回是否修改成功的布尔值
169
+ */
170
+ export declare const assignUsersToGroup: (groupId: string, userIdList: string[]) => Promise<boolean>;
171
+ /**
172
+ * 修改用户的所属组
173
+ * @param userId 用户ID
174
+ * @param groupId 组ID列表
175
+ * @returns 返回是否修改成功的布尔值
176
+ */
177
+ export declare const assignDepartmentsToUser: (userId: string, groupId: string[]) => Promise<boolean>;
178
+ /**
179
+ * 添加扩展属性
180
+ * @param userId 用户ID
181
+ * @param key 属性键
182
+ * @param value 属性值
183
+ * @param longValue 长值
184
+ * @returns 返回是否添加成功的布尔值
185
+ */
186
+ export declare const addUserAttribute: (userId: string, key: string, value: string, longValue: string) => Promise<boolean>;
187
+ /**
188
+ * 获取指定的属性值
189
+ * @param userId 用户ID
190
+ * @param key 属性键
191
+ * @returns 返回扩展属性
192
+ */
193
+ export declare const getUserAttribute: (userId: string, key: string) => Promise<ExtensionAttribute>;
194
+ /**
195
+ * 获取某用户所有的属性值
196
+ * @param userId 用户ID
197
+ * @returns 返回用户所有扩展属性列表
198
+ */
199
+ export declare const getAllUserAttributes: (userId: string) => Promise<ExtensionAttribute[]>;
200
+ /**
201
+ * 创建操作权限
202
+ * @param funcId 权限ID
203
+ * @param parentFuncId 父权限ID
204
+ * @param funcName 权限名称
205
+ * @param funcAlias 权限别名
206
+ * @param funcDesc 权限描述
207
+ * @returns 返回是否创建成功的布尔值
208
+ */
209
+ export declare const createFunction: (funcId: string, parentFuncId: string, funcName: string, funcAlias: string, funcDesc: string) => Promise<boolean>;
210
+ /**
211
+ * 删除操作权限
212
+ * @param funcId 权限ID
213
+ * @returns 返回是否删除成功的布尔值
214
+ */
215
+ export declare const deleteFunction: (funcId: string) => Promise<boolean>;
216
+ /**
217
+ * 通过操作权限ID获取操作权限对象
218
+ * @param funcId 权限ID
219
+ * @returns 返回权限信息
220
+ */
221
+ export declare const getFunctionById: (funcId: string) => Promise<FunctionPermission>;
222
+ /**
223
+ * 获取所有操作权限列表
224
+ * @returns 返回权限列表
225
+ */
226
+ export declare const getAllFunctions: () => Promise<FunctionPermission[]>;
227
+ /**
228
+ * 获取License中的关键信息
229
+ * @returns 返回License信息
230
+ */
231
+ export declare const getLicenseInfo: () => Promise<any>;
232
+ /**
233
+ * 获取系统中所有License模块名称列表
234
+ * @returns 返回License模块名称列表
235
+ */
236
+ export declare const getLicenses: () => Promise<string[]>;