@quickbi/bi-types 3.0.41-beta.9 → 3.0.41
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/cjs/chart-config.d.ts +378 -0
- package/cjs/component-type.d.ts +488 -0
- package/cjs/cross-table.d.ts +151 -0
- package/cjs/cube/cube-blend.d.ts +22 -0
- package/cjs/cube/cube-links.d.ts +35 -0
- package/cjs/cube/cube-model.d.ts +611 -0
- package/cjs/cube/data-source.d.ts +179 -0
- package/cjs/cube/index.d.ts +9 -0
- package/cjs/cube/table-schema.d.ts +43 -0
- package/cjs/data-panel/base.d.ts +159 -0
- package/cjs/data-panel/data-config.d.ts +236 -0
- package/cjs/data-panel/data-schema-item.d.ts +734 -0
- package/cjs/data-panel/data-schema.d.ts +101 -0
- package/cjs/data-panel/index.d.ts +9 -0
- package/cjs/etl.d.ts +76 -0
- package/cjs/index.d.ts +29 -0
- package/cjs/index.js +88 -61
- package/cjs/open/common/event-types.d.ts +22 -0
- package/cjs/open/common/misc.d.ts +11 -0
- package/cjs/open/common/page-types.d.ts +19 -0
- package/cjs/open/common/tools.d.ts +23 -0
- package/cjs/open/components/component-lifecycle.d.ts +36 -0
- package/cjs/open/components/component-meta.d.ts +27 -0
- package/cjs/open/components/component-props.d.ts +148 -0
- package/cjs/open/components/data-schema.d.ts +53 -0
- package/cjs/open/components/style-schema.d.ts +161 -0
- package/cjs/open/embed/core.d.ts +65 -0
- package/cjs/open/events/event-props.d.ts +33 -0
- package/cjs/open/events/event-schema.d.ts +12 -0
- package/cjs/open/menus/menu-props.d.ts +178 -0
- package/cjs/open/menus/menu-schema.d.ts +35 -0
- package/cjs/router/route-key.d.ts +406 -0
- package/cjs/router/route-tree.d.ts +15 -0
- package/cjs/standard-model.d.ts +497 -0
- package/esm/chart-config.d.ts +378 -0
- package/esm/component-type.d.ts +488 -0
- package/esm/cross-table.d.ts +151 -0
- package/esm/cube/cube-blend.d.ts +22 -0
- package/esm/cube/cube-links.d.ts +35 -0
- package/esm/cube/cube-model.d.ts +611 -0
- package/esm/cube/data-source.d.ts +179 -0
- package/esm/cube/index.d.ts +9 -0
- package/esm/cube/table-schema.d.ts +43 -0
- package/esm/data-panel/base.d.ts +159 -0
- package/esm/data-panel/data-config.d.ts +236 -0
- package/esm/data-panel/data-schema-item.d.ts +734 -0
- package/esm/data-panel/data-schema.d.ts +101 -0
- package/esm/data-panel/index.d.ts +9 -0
- package/esm/etl.d.ts +76 -0
- package/esm/index.d.ts +29 -0
- package/esm/index.mjs +88 -61
- package/esm/open/common/event-types.d.ts +22 -0
- package/esm/open/common/misc.d.ts +11 -0
- package/esm/open/common/page-types.d.ts +19 -0
- package/esm/open/common/tools.d.ts +23 -0
- package/esm/open/components/component-lifecycle.d.ts +36 -0
- package/esm/open/components/component-meta.d.ts +27 -0
- package/esm/open/components/component-props.d.ts +148 -0
- package/esm/open/components/data-schema.d.ts +53 -0
- package/esm/open/components/style-schema.d.ts +161 -0
- package/esm/open/embed/core.d.ts +65 -0
- package/esm/open/events/event-props.d.ts +33 -0
- package/esm/open/events/event-schema.d.ts +12 -0
- package/esm/open/menus/menu-props.d.ts +178 -0
- package/esm/open/menus/menu-schema.d.ts +35 -0
- package/esm/router/route-key.d.ts +406 -0
- package/esm/router/route-tree.d.ts +15 -0
- package/esm/standard-model.d.ts +497 -0
- package/package.json +2 -4
|
@@ -0,0 +1,611 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author 无愚
|
|
3
|
+
* @description 数据集接口模型
|
|
4
|
+
*/
|
|
5
|
+
import type { DsCreateOriginEnum, DsType, DataLoadMode } from './data-source';
|
|
6
|
+
export declare enum CustomAreaType {
|
|
7
|
+
/** 自定义地理信息 */
|
|
8
|
+
CUSTOM_AREA = "CUSTOM_AREA",
|
|
9
|
+
/** 自定义geojson */
|
|
10
|
+
CUSTOM_GEOJSON = "CUSTOM_GEOJSON",
|
|
11
|
+
/** 自定义层级 */
|
|
12
|
+
CUSTOM_TREE = "CUSTOM_TREE",
|
|
13
|
+
/** 自定义图片 */
|
|
14
|
+
CUSTOM_PICTURE = "CUSTOM_PICTURE"
|
|
15
|
+
}
|
|
16
|
+
/** 自定义图片底图信息 */
|
|
17
|
+
export declare enum PictureCoordinateType {
|
|
18
|
+
/** 纵坐标 */
|
|
19
|
+
HORIZONTAL = "CUSTOM_PICTURE_HORIZONTAL",
|
|
20
|
+
/** 横坐标 */
|
|
21
|
+
VERTICAL = "CUSTOM_PICTURE_VERTICAL"
|
|
22
|
+
}
|
|
23
|
+
/** 自定义地理信息 */
|
|
24
|
+
export interface ExtraInfo {
|
|
25
|
+
/** 自定义层级Id */
|
|
26
|
+
customGeoLevel?: number;
|
|
27
|
+
/** 自定义图片类型 */
|
|
28
|
+
pictureCoordinateType?: PictureCoordinateType;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* 关联字段
|
|
32
|
+
* 数据混合blend和数据集物理表关联physical均使用该字段
|
|
33
|
+
*/
|
|
34
|
+
export type JoinKey = {
|
|
35
|
+
/** 源表字段(blend模式为数据集字段id,physical模式为物理字段名) */
|
|
36
|
+
sourceKey: string;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated
|
|
39
|
+
* 源表关联物理字段类型(QBI目前没在用,保留)
|
|
40
|
+
*/
|
|
41
|
+
sourceType?: string;
|
|
42
|
+
/** 目标表字段(blend模式为数据集字段id,physical模式为物理字段名) */
|
|
43
|
+
targetKey: string;
|
|
44
|
+
/**
|
|
45
|
+
* @deprecated
|
|
46
|
+
* 标表关联物理字段类型(QBI目前没在用,保留)
|
|
47
|
+
*/
|
|
48
|
+
targetType?: string;
|
|
49
|
+
/**
|
|
50
|
+
* @deprecated
|
|
51
|
+
* 条件(目前QBI只支持这个equal-to)
|
|
52
|
+
*/
|
|
53
|
+
condition: JoinCondition;
|
|
54
|
+
/**
|
|
55
|
+
* 目前仅physical模式使用
|
|
56
|
+
*/
|
|
57
|
+
targetCalculateMember?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* 目前仅physical模式使用
|
|
60
|
+
*/
|
|
61
|
+
sourceCalculateMember?: boolean;
|
|
62
|
+
};
|
|
63
|
+
/** 表模型 */
|
|
64
|
+
export interface PhysicalTable {
|
|
65
|
+
/** 唯一标识 */
|
|
66
|
+
uniqueId: string;
|
|
67
|
+
/** 表展示名称 */
|
|
68
|
+
caption?: string;
|
|
69
|
+
/** 表id */
|
|
70
|
+
tableName: string;
|
|
71
|
+
/** 物理表所属数据源ID */
|
|
72
|
+
datasourceId: string;
|
|
73
|
+
/** 是否为事实表(中心表标识) */
|
|
74
|
+
factTable: boolean;
|
|
75
|
+
dsType: DsType;
|
|
76
|
+
}
|
|
77
|
+
/** 表模型 */
|
|
78
|
+
export interface VirtualTable {
|
|
79
|
+
/** 唯一标识 */
|
|
80
|
+
uniqueId: string;
|
|
81
|
+
/** 表展示名称 */
|
|
82
|
+
caption: string;
|
|
83
|
+
/** 表名 */
|
|
84
|
+
tableName: string;
|
|
85
|
+
/** 物理表所属数据源ID */
|
|
86
|
+
datasourceId: string;
|
|
87
|
+
/** 是否为事实表(中心表标识) */
|
|
88
|
+
factTable: boolean;
|
|
89
|
+
dsType: DsType;
|
|
90
|
+
sqlId: string;
|
|
91
|
+
sql: string;
|
|
92
|
+
}
|
|
93
|
+
export interface Link {
|
|
94
|
+
/** 源表id(blend模式为数据集id,physical模式为物理表id) */
|
|
95
|
+
source: string;
|
|
96
|
+
/** 关联表id(blend模式为数据集id,physical模式为物理表id) */
|
|
97
|
+
target: string;
|
|
98
|
+
/** 关联类型 */
|
|
99
|
+
joinType: TableJoinType;
|
|
100
|
+
/**
|
|
101
|
+
* @deprecated
|
|
102
|
+
* 目前只有many-to-one
|
|
103
|
+
*/
|
|
104
|
+
relation?: TableRelation;
|
|
105
|
+
joinKeys: JoinKey[];
|
|
106
|
+
}
|
|
107
|
+
/** 物理表关联模型 */
|
|
108
|
+
export type PhysicalLink = Link;
|
|
109
|
+
export declare class PhysicalSchema {
|
|
110
|
+
tables: PhysicalTable[];
|
|
111
|
+
/** 自定义sql、view */
|
|
112
|
+
virtualTables: VirtualTable[];
|
|
113
|
+
/** 表关联关系 */
|
|
114
|
+
links: PhysicalLink[];
|
|
115
|
+
/** odps表是否开启全表扫描 */
|
|
116
|
+
sqlHintTypes?: string[];
|
|
117
|
+
sqlHints?: HintModal[];
|
|
118
|
+
}
|
|
119
|
+
/** 数据集层级结构/文件夹/属性的嵌套关系 */
|
|
120
|
+
export type FieldTree = AttributeNode | FolderAndHierarchyNode;
|
|
121
|
+
export type AttributeMapValue = {
|
|
122
|
+
attribute: FieldAttribute;
|
|
123
|
+
type: 'Dimension' | 'Measure';
|
|
124
|
+
};
|
|
125
|
+
/** 数据集逻辑模型 */
|
|
126
|
+
export declare class CubeSchema {
|
|
127
|
+
/** 唯一标识,无业务逻辑,不要使用 */
|
|
128
|
+
uniqueId: string;
|
|
129
|
+
/** 数据集ID */
|
|
130
|
+
cubeId: string;
|
|
131
|
+
/** 数据源ID */
|
|
132
|
+
datasourceId: string;
|
|
133
|
+
/** 数据集名称 */
|
|
134
|
+
caption: string;
|
|
135
|
+
/** 字段列表 */
|
|
136
|
+
fields: Field[];
|
|
137
|
+
/** 普通字段、层系、文件夹树形结构 */
|
|
138
|
+
fieldTree: FieldTree[];
|
|
139
|
+
/** 过滤条件 */
|
|
140
|
+
filter?: FilterAttr[];
|
|
141
|
+
/** 全局参数 */
|
|
142
|
+
params: ParamType[];
|
|
143
|
+
/** 占位符 */
|
|
144
|
+
sqlPlaceholders: ParamType[];
|
|
145
|
+
}
|
|
146
|
+
/** 数据集额外信息 */
|
|
147
|
+
export declare class SchemaExtraInfo {
|
|
148
|
+
/** 数据集所在工作空间的文件夹位置 */
|
|
149
|
+
aimDirId: string;
|
|
150
|
+
hasAuthorizedUse?: boolean;
|
|
151
|
+
/** 权限列表 */
|
|
152
|
+
permissionList?: string[];
|
|
153
|
+
/** 行级权限,列级权限字段id */
|
|
154
|
+
dataLevelAttributeIds: string[];
|
|
155
|
+
/** 无列级权限的字段 */
|
|
156
|
+
withoutColumnLevelPermissionFields: string[];
|
|
157
|
+
/** 聚合方式 */
|
|
158
|
+
aggFunctions?: string[];
|
|
159
|
+
/** 是否开启数据脱敏 */
|
|
160
|
+
isDataMaskOpen?: number;
|
|
161
|
+
/** 是否开启列级权限 1=开启 0=未开启 */
|
|
162
|
+
isOpenColumnLevelPermission?: number;
|
|
163
|
+
/** 是否开启了行级权限 1=开启 0=未开启 */
|
|
164
|
+
isOpenRowLevelPermission?: number;
|
|
165
|
+
/** 当前数据集来自的类型 */
|
|
166
|
+
dsCreateOrigin?: DsCreateOriginEnum;
|
|
167
|
+
/** 跨源模式 */
|
|
168
|
+
dataLoadMode?: DataLoadMode;
|
|
169
|
+
/** 是否为etl 生成的数据集 */
|
|
170
|
+
etlGenerateCube?: boolean;
|
|
171
|
+
/** 数据集类型 */
|
|
172
|
+
cubeType?: 'upload' | 'upload_static';
|
|
173
|
+
/** 数据集owner */
|
|
174
|
+
creatorId?: string;
|
|
175
|
+
}
|
|
176
|
+
/** 数据集模型 */
|
|
177
|
+
export declare class CubeModel {
|
|
178
|
+
/** 物理表 */
|
|
179
|
+
physicalSchema: PhysicalSchema;
|
|
180
|
+
/** 数据集逻辑模型 */
|
|
181
|
+
cubeSchema: CubeSchema;
|
|
182
|
+
/** 数据集结构版本 */
|
|
183
|
+
metaModelVersion: string;
|
|
184
|
+
/** 数据集订正版本(前端使用) */
|
|
185
|
+
userDefineVersion: string;
|
|
186
|
+
/** 数据集额外信息 */
|
|
187
|
+
schemaExtraInfo: SchemaExtraInfo;
|
|
188
|
+
}
|
|
189
|
+
/** 数据集影子模型 */
|
|
190
|
+
export type CubeShadow = CubeSchema;
|
|
191
|
+
/** 表关联类型 */
|
|
192
|
+
export declare enum TableJoinType {
|
|
193
|
+
LEFT_OUTER_JOIN = "LEFT_OUTER_JOIN",
|
|
194
|
+
INNER_JOIN = "INNER_JOIN",
|
|
195
|
+
FULL_OUTER_JOIN = "FULL_OUTER_JOIN",
|
|
196
|
+
JOIN_ERROR = "JOIN_ERROR"
|
|
197
|
+
}
|
|
198
|
+
export declare enum TableRelation {
|
|
199
|
+
MANY_TO_ONE = "many-to-one"
|
|
200
|
+
}
|
|
201
|
+
export declare enum JoinCondition {
|
|
202
|
+
EQUAL_TO = "equal-to",
|
|
203
|
+
UNEQUAL_TO = "unequal-to",
|
|
204
|
+
GREATER_THAN = "greater-than",
|
|
205
|
+
LESS_THAN = "less-than"
|
|
206
|
+
}
|
|
207
|
+
/** 字段列表定义,包含维度、度量 */
|
|
208
|
+
export interface Field {
|
|
209
|
+
/** 唯一标识 */
|
|
210
|
+
uniqueId: string;
|
|
211
|
+
/** 字段名称 */
|
|
212
|
+
caption: string;
|
|
213
|
+
type: 'Dimension' | 'Measure';
|
|
214
|
+
/** 标记数据面板上的字段、文件夹,和数据集原有的字段、文件夹区别开来 */
|
|
215
|
+
fromPanel?: boolean;
|
|
216
|
+
/** 老接口保留字段(计算字段expression中作为唯一标识使用),新数据跟uniqueId值相同 */
|
|
217
|
+
name?: string;
|
|
218
|
+
/** 引用表id */
|
|
219
|
+
table: string;
|
|
220
|
+
/** 物理字段 */
|
|
221
|
+
column: string;
|
|
222
|
+
/** 是否为衍生字段,分组字段和计算字段都为true */
|
|
223
|
+
calculateMember: boolean;
|
|
224
|
+
/** 字段描述,仅日期类型会使用 */
|
|
225
|
+
comments?: string;
|
|
226
|
+
attributes: FieldAttribute[];
|
|
227
|
+
}
|
|
228
|
+
/** 当前数据类型,如果没有进行过类型切换,则和OriginDataType一致 影响sql生成 (原colType) */
|
|
229
|
+
export declare enum DataType {
|
|
230
|
+
number = "number",
|
|
231
|
+
string = "string",
|
|
232
|
+
date = "date",
|
|
233
|
+
datetime = "datetime",
|
|
234
|
+
time = "time"
|
|
235
|
+
}
|
|
236
|
+
/** 二级数据类型:不影响sql生成,影响内存处理及前端icon展示(如:地理维度、) */
|
|
237
|
+
export declare enum SecondDataType {
|
|
238
|
+
number = "number",
|
|
239
|
+
string = "string",
|
|
240
|
+
geographic = "geographic",
|
|
241
|
+
imageUrl = "imageUrl",
|
|
242
|
+
imageFileId = "imageFileId",
|
|
243
|
+
date = "date",
|
|
244
|
+
datetime = "datetime",
|
|
245
|
+
time = "time",
|
|
246
|
+
multiValue = "multi_value"
|
|
247
|
+
}
|
|
248
|
+
/** 物理数据类型:第一次初始化时填写,后续不会修改 */
|
|
249
|
+
export type OriginDataType = DataType;
|
|
250
|
+
/** 年粒度日期类型 */
|
|
251
|
+
export declare enum CalendarTypeEnum {
|
|
252
|
+
/** 公历年 */
|
|
253
|
+
GregorianYear = "gregorian-year",
|
|
254
|
+
/** 财年 */
|
|
255
|
+
FiscalYear = "fiscal-year",
|
|
256
|
+
/** 农历年 */
|
|
257
|
+
LunarYear = "lunar-year"
|
|
258
|
+
}
|
|
259
|
+
/** 日期维度支持的粒度 */
|
|
260
|
+
export declare enum DateGranularity {
|
|
261
|
+
year = "year",
|
|
262
|
+
fiscalYear = "fiscal-year",
|
|
263
|
+
quarter = "year-quarter",
|
|
264
|
+
fiscalYearQuarter = "fiscal-year-quarter",
|
|
265
|
+
month = "year-month",
|
|
266
|
+
week = "year-week",
|
|
267
|
+
day = "year-month-day",
|
|
268
|
+
hour = "hour",
|
|
269
|
+
minute = "hour-minute",
|
|
270
|
+
second = "hour-minute-second",
|
|
271
|
+
datetime = "datetime"
|
|
272
|
+
}
|
|
273
|
+
/** 地理维度支持的粒度 */
|
|
274
|
+
export declare enum RegionGranularity {
|
|
275
|
+
/** 洲 */
|
|
276
|
+
continent = "CONTINENT",
|
|
277
|
+
/** 国家 */
|
|
278
|
+
country = "COUNTRY",
|
|
279
|
+
/** 区域 */
|
|
280
|
+
region = "REGION",
|
|
281
|
+
/** 省 */
|
|
282
|
+
province = "PROVINCE",
|
|
283
|
+
/** 市 */
|
|
284
|
+
city = "CITY",
|
|
285
|
+
/** 区 */
|
|
286
|
+
xian = "XIAN",
|
|
287
|
+
/** 街道 */
|
|
288
|
+
street = "STREET",
|
|
289
|
+
/** 经度 */
|
|
290
|
+
lng = "LNG",
|
|
291
|
+
/** 纬度 */
|
|
292
|
+
lat = "LAT",
|
|
293
|
+
/** 自定义区域 */
|
|
294
|
+
custom_region = "CUSTOM_REGION"
|
|
295
|
+
}
|
|
296
|
+
/** 多值分隔符 */
|
|
297
|
+
export declare enum MultiSeparator {
|
|
298
|
+
comma = ",",
|
|
299
|
+
semicolon = ";",
|
|
300
|
+
space = " "
|
|
301
|
+
}
|
|
302
|
+
/**
|
|
303
|
+
* 维度树结构类型
|
|
304
|
+
* Normal: 正常层级结构
|
|
305
|
+
* Date: 日期类型层级结构
|
|
306
|
+
* Linked: 关联类型文件夹
|
|
307
|
+
*/
|
|
308
|
+
export type DimensionTreeFlags = 'DimensionNormal' | 'DimensionDate' | 'DimensionLinked' | null;
|
|
309
|
+
/**
|
|
310
|
+
* 度量树结构类型
|
|
311
|
+
* Normal: 正常层级结构
|
|
312
|
+
* Linked: 关联类型文件夹
|
|
313
|
+
*/
|
|
314
|
+
export type MeasureTreeFlags = 'MeasureNormal' | 'MeasureLinked' | null;
|
|
315
|
+
/**
|
|
316
|
+
* 树节点类型
|
|
317
|
+
* folder: 文件夹
|
|
318
|
+
* hierarchy: 层级结构
|
|
319
|
+
* attribute: 普通节点
|
|
320
|
+
* dimensionGroup: 维度组
|
|
321
|
+
* measureGroup: 度量组
|
|
322
|
+
* lnglatGroup: 经纬度组
|
|
323
|
+
* */
|
|
324
|
+
export type TreeNodeTypes = 'folder' | 'hierarchy' | 'attribute' | 'dimensionGroup' | 'measureGroup' | 'lnglatGroup';
|
|
325
|
+
/** 分组字段类型 */
|
|
326
|
+
export type GroupType = 'NormalGroup' | 'ListGroup' | 'CustomizedGroup';
|
|
327
|
+
/** 数值-自定义分组类型 */
|
|
328
|
+
export type CustomizedGroup = {
|
|
329
|
+
/** 是否是默认分组字段 */
|
|
330
|
+
groupName: string;
|
|
331
|
+
defaultGroup: boolean;
|
|
332
|
+
lower: string;
|
|
333
|
+
upper: string;
|
|
334
|
+
lowerOperator: 'greaterThan' | 'greaterThanOrEqualTo';
|
|
335
|
+
upperOperator: 'lessThan' | 'lessThanOrEqualTo';
|
|
336
|
+
groupNameType: any;
|
|
337
|
+
};
|
|
338
|
+
/** 枚举-列表分组类型 */
|
|
339
|
+
export type ListGrouping = {
|
|
340
|
+
groupName: string;
|
|
341
|
+
groupElementList: string[];
|
|
342
|
+
defaultGroup: boolean;
|
|
343
|
+
};
|
|
344
|
+
/** 日期类型-自定义区间分组 */
|
|
345
|
+
export type NormalGroup = {
|
|
346
|
+
groupName: string;
|
|
347
|
+
defaultGroup: boolean;
|
|
348
|
+
lower: string;
|
|
349
|
+
upper: string;
|
|
350
|
+
lowerOperator: 'greaterThanOrEqualTo';
|
|
351
|
+
upperOperator: 'lessThanOrEqualTo';
|
|
352
|
+
};
|
|
353
|
+
/** 分组字段 */
|
|
354
|
+
export type Groups = CustomizedGroup[] | ListGrouping[] | NormalGroup[];
|
|
355
|
+
/** 空值展示配置类型 */
|
|
356
|
+
export declare enum EmptyValueType {
|
|
357
|
+
/** 空值 */
|
|
358
|
+
EmptyValue = "EmptyValue",
|
|
359
|
+
/** 空字符串 */
|
|
360
|
+
EmptyString = "EmptyString"
|
|
361
|
+
}
|
|
362
|
+
/** 空值展示配置枚举 */
|
|
363
|
+
export declare enum EmptyValueDisplayType {
|
|
364
|
+
/** 展示为'-' */
|
|
365
|
+
Hyphen = "hyphen",
|
|
366
|
+
/** 展示为{空}/{空字符串} */
|
|
367
|
+
Braces = "braces",
|
|
368
|
+
/** 展示为"null" */
|
|
369
|
+
Null = "null",
|
|
370
|
+
/** 不展示 */
|
|
371
|
+
NotDisplay = "notDisplay",
|
|
372
|
+
/** 自定义 */
|
|
373
|
+
Custom = "custom"
|
|
374
|
+
}
|
|
375
|
+
export declare class EmptyStringOrNullDisplayConfig {
|
|
376
|
+
/** 展示类型 */
|
|
377
|
+
formatType: EmptyValueDisplayType;
|
|
378
|
+
/** 自定义展示内容 */
|
|
379
|
+
customFormat: string;
|
|
380
|
+
/** 是否是自动(继承数据集) */
|
|
381
|
+
isAuto?: boolean;
|
|
382
|
+
}
|
|
383
|
+
/** 空值展示配置 */
|
|
384
|
+
export declare class EmptyValueDisplayConfig {
|
|
385
|
+
/** 空值展示配置 */
|
|
386
|
+
emptyValueConfig: EmptyStringOrNullDisplayConfig;
|
|
387
|
+
/** 空字符串展示配置 */
|
|
388
|
+
emptyStringConfig: EmptyStringOrNullDisplayConfig;
|
|
389
|
+
static getDefaultConfigForQuickReport(): EmptyValueDisplayConfig;
|
|
390
|
+
static convertAttrEmptyValueDisplayConfig(attr: FieldAttribute, isAuto?: boolean): EmptyValueDisplayConfig;
|
|
391
|
+
/** 根据fieldSettingMap中存储的配置转换成空值展示配置模型 */
|
|
392
|
+
static getConfigByFieldSettingMap(fieldSetting: any, defaultValue?: any): EmptyValueDisplayConfig;
|
|
393
|
+
}
|
|
394
|
+
/** 字段属性 */
|
|
395
|
+
export interface FieldAttribute {
|
|
396
|
+
/** 唯一标识 */
|
|
397
|
+
uniqueId: string;
|
|
398
|
+
/** 显示名称 */
|
|
399
|
+
caption: string;
|
|
400
|
+
/** 一级数据类型(分析类型):影响sql生成 */
|
|
401
|
+
dataType: DataType;
|
|
402
|
+
/** 二级数据类型:不影响sql生成,影响内存处理及前端icon展示(如:地理维度、) */
|
|
403
|
+
secondDataType: SecondDataType | null;
|
|
404
|
+
/** 原始物理数据类型 */
|
|
405
|
+
originDataType: OriginDataType | null;
|
|
406
|
+
/** 格式化格式 */
|
|
407
|
+
format: string | null;
|
|
408
|
+
/** 表数据物理存储格式(暂未使用2021-03) */
|
|
409
|
+
dataFormat: string | null;
|
|
410
|
+
/** 聚合方式 */
|
|
411
|
+
aggregator: Aggregator | null;
|
|
412
|
+
/** 是否支持做聚合, 维度=null, 普通度量/非聚合的扩展度量=true, 聚合扩展度量=false */
|
|
413
|
+
supportAggregation: boolean | null;
|
|
414
|
+
/** 自定义周的开始时间,只在周类型时间维度有效, 从 1-7 代表周一到周日 */
|
|
415
|
+
firstDayOfWeek: number | null;
|
|
416
|
+
/** 财年开始的月份 只有year和quarter粒度有 从1-12代表1月份到12月份 */
|
|
417
|
+
firstMonthOfYear?: number | null;
|
|
418
|
+
/** 年日期类型 */
|
|
419
|
+
calendarType?: CalendarTypeEnum;
|
|
420
|
+
/** 是否隐藏 */
|
|
421
|
+
isHidden: boolean;
|
|
422
|
+
/** 倍率 */
|
|
423
|
+
mult: string | null;
|
|
424
|
+
/** 维度、粒度 */
|
|
425
|
+
granularity: DateGranularity | RegionGranularity | null;
|
|
426
|
+
/** 计算字段、分组字段 */
|
|
427
|
+
expression?: Expression;
|
|
428
|
+
/** 标记数据面板上的字段、文件夹,和数据集原有的字段、文件夹区别开来 */
|
|
429
|
+
fromPanel?: boolean;
|
|
430
|
+
/** 老接口保留字段(计算字段expression中作为唯一标识使用),新数据跟uniqueId值相同 */
|
|
431
|
+
name?: string;
|
|
432
|
+
/** 字段描述 */
|
|
433
|
+
comments?: string;
|
|
434
|
+
/** 字段自定义排序设置 */
|
|
435
|
+
sortModel?: {
|
|
436
|
+
sortType: 'ASC' | 'DESC' | 'CUSTOM';
|
|
437
|
+
customOrder: string;
|
|
438
|
+
orderByList?: any;
|
|
439
|
+
};
|
|
440
|
+
/** 多值分隔符 */
|
|
441
|
+
separator?: MultiSeparator | string;
|
|
442
|
+
/** 空值展示格式类型 */
|
|
443
|
+
nullValueFormatType: EmptyValueDisplayType;
|
|
444
|
+
/** 空值自定义展示格式 */
|
|
445
|
+
nullValueCustomFormat: string;
|
|
446
|
+
/** 空字符串展示格式类型 */
|
|
447
|
+
emptyStringFormatType?: EmptyValueDisplayType;
|
|
448
|
+
/** 空字符串自定义展示格式 */
|
|
449
|
+
emptyStringCustomFormat?: string;
|
|
450
|
+
/** TODO: 将自定义区域收拢到一个字段信息中,而不是散落在 attribute */
|
|
451
|
+
/** 自定义区域id */
|
|
452
|
+
refCustomRegion?: string;
|
|
453
|
+
/** 自定义地理类型 */
|
|
454
|
+
customAreaType?: CustomAreaType;
|
|
455
|
+
/** 数据集属性额外信息 */
|
|
456
|
+
extraInfo?: ExtraInfo;
|
|
457
|
+
}
|
|
458
|
+
/** 度量类型聚合方式 */
|
|
459
|
+
export declare enum Aggregator {
|
|
460
|
+
'sum' = "sum",
|
|
461
|
+
'count' = "count",
|
|
462
|
+
'distinct-count' = "distinct-count",
|
|
463
|
+
'max' = "max",
|
|
464
|
+
'min' = "min",
|
|
465
|
+
'avg' = "avg"
|
|
466
|
+
}
|
|
467
|
+
export interface Expression {
|
|
468
|
+
type: 'dataGroup' | 'udf' | 'system';
|
|
469
|
+
value?: string;
|
|
470
|
+
/** 分组字段配置 */
|
|
471
|
+
dataGroup: {
|
|
472
|
+
/** 唯一标识 */
|
|
473
|
+
uniqueId: string;
|
|
474
|
+
/** 分组名称 */
|
|
475
|
+
caption: string;
|
|
476
|
+
/** 分组类型 */
|
|
477
|
+
groupType: GroupType;
|
|
478
|
+
refUniqueId: string;
|
|
479
|
+
/** qa中使用。qbi目前用不到 */
|
|
480
|
+
refSql?: string;
|
|
481
|
+
/** qa中使用。qbi目前用不到 */
|
|
482
|
+
refFunction?: string;
|
|
483
|
+
/** 数值类型分组字段 */
|
|
484
|
+
customizedGroups?: CustomizedGroup[];
|
|
485
|
+
/** 字符串类型分组字段 */
|
|
486
|
+
listGroupings?: ListGrouping[];
|
|
487
|
+
/** 日期类型分组字段 */
|
|
488
|
+
normalGroups?: NormalGroup[];
|
|
489
|
+
};
|
|
490
|
+
}
|
|
491
|
+
export declare class FilterAttr {
|
|
492
|
+
logicalOperator: 'and' | 'or';
|
|
493
|
+
/** 过滤值 */
|
|
494
|
+
filterElements: FilterElement[];
|
|
495
|
+
/** 嵌套过滤条件 */
|
|
496
|
+
filters: FilterAttr[];
|
|
497
|
+
beforeJoin?: boolean;
|
|
498
|
+
tableId?: string;
|
|
499
|
+
}
|
|
500
|
+
export interface FilterElement {
|
|
501
|
+
/** 过滤条件引用的字段uid */
|
|
502
|
+
resourceId: string;
|
|
503
|
+
/** 过滤条件比较运算符:> < =, 和查询控件所用保持一致 */
|
|
504
|
+
functionalOperator: string;
|
|
505
|
+
values: {
|
|
506
|
+
type?: 'absolute' | 'relative' | null;
|
|
507
|
+
value: string;
|
|
508
|
+
}[];
|
|
509
|
+
/** 前端是否隐藏掉 */
|
|
510
|
+
hidden?: boolean;
|
|
511
|
+
}
|
|
512
|
+
/** 普通字段 */
|
|
513
|
+
export interface AttributeNode {
|
|
514
|
+
/** 字段ID */
|
|
515
|
+
id: string;
|
|
516
|
+
/** 节点类型 */
|
|
517
|
+
type: TreeNodeTypes;
|
|
518
|
+
/** 标记数据面板上的字段、文件夹,和数据集原有的字段、文件夹区别开来 */
|
|
519
|
+
fromPanel?: boolean;
|
|
520
|
+
/** 节点名称,attribute类型为null */
|
|
521
|
+
name?: null;
|
|
522
|
+
caption?: string;
|
|
523
|
+
children?: (AttributeNode | FolderAndHierarchyNode)[];
|
|
524
|
+
flag: null;
|
|
525
|
+
/** 所引用的关联表的id,仅flag为DimensionLinked和MeasureLinked时存在 */
|
|
526
|
+
refUniqueId?: null;
|
|
527
|
+
}
|
|
528
|
+
/** 文件夹和层级字段 */
|
|
529
|
+
export interface FolderAndHierarchyNode {
|
|
530
|
+
/** 字段ID */
|
|
531
|
+
id?: string;
|
|
532
|
+
/** 节点类型 */
|
|
533
|
+
type: TreeNodeTypes;
|
|
534
|
+
/** 标记数据面板上的字段、文件夹,和数据集原有的字段、文件夹区别开来 */
|
|
535
|
+
fromPanel?: boolean;
|
|
536
|
+
/** 节点名称 */
|
|
537
|
+
name?: string;
|
|
538
|
+
/** 节点名称,attribute类型为null */
|
|
539
|
+
caption?: string;
|
|
540
|
+
/** 所引用的关联表的id,仅flag为DimensionLinked和MeasureLinked时存在 */
|
|
541
|
+
refUniqueId?: string;
|
|
542
|
+
children?: (AttributeNode | FolderAndHierarchyNode)[];
|
|
543
|
+
/** 文件夹和层级结构类型 */
|
|
544
|
+
flag: DimensionTreeFlags | MeasureTreeFlags;
|
|
545
|
+
}
|
|
546
|
+
/**
|
|
547
|
+
* 日期占位符的类型(单个/范围)
|
|
548
|
+
*/
|
|
549
|
+
export declare enum OriginDateType {
|
|
550
|
+
/** 单个日期 */
|
|
551
|
+
SingleDate = "singleDate",
|
|
552
|
+
/** 日期区间 */
|
|
553
|
+
DateRange = "dateRange"
|
|
554
|
+
}
|
|
555
|
+
export interface ParamType {
|
|
556
|
+
/** sql参数id */
|
|
557
|
+
uniqueId?: string;
|
|
558
|
+
/** 是否启用此参数 */
|
|
559
|
+
/** 占位符名称 */
|
|
560
|
+
name: string;
|
|
561
|
+
/** 类型 */
|
|
562
|
+
style: 'condition' | 'placeholder' | 'param';
|
|
563
|
+
/** 占位符格式化类型 */
|
|
564
|
+
type: ParamDataType;
|
|
565
|
+
table: string;
|
|
566
|
+
format: string;
|
|
567
|
+
firstDayOfWeek: number;
|
|
568
|
+
/** 是否是影子数据集的占位符 */
|
|
569
|
+
fromPanel?: boolean;
|
|
570
|
+
/** condition条件参数时,才会有该属性 */
|
|
571
|
+
conditionPlaceHolderFields?: {
|
|
572
|
+
uniqueId: string;
|
|
573
|
+
name: string;
|
|
574
|
+
column: string;
|
|
575
|
+
table: string;
|
|
576
|
+
}[];
|
|
577
|
+
/** sql 占位符的原始类型 */
|
|
578
|
+
originalType: 'dateRange';
|
|
579
|
+
/** sql 参数,占位符默认值 */
|
|
580
|
+
defaultValue?: (string | number)[];
|
|
581
|
+
/** 默认值是否全局生效,true: 生效范围与过滤器一致。false: 默认值仅在数据集生效 */
|
|
582
|
+
useInGlobal?: boolean;
|
|
583
|
+
}
|
|
584
|
+
/** 占位符参数 */
|
|
585
|
+
export declare enum ParamDataType {
|
|
586
|
+
string = "string",
|
|
587
|
+
number = "number",
|
|
588
|
+
dateRegion = "dateRegion",
|
|
589
|
+
quarterRegion = "quarterRegion",
|
|
590
|
+
monthRegion = "monthRegion",
|
|
591
|
+
weekRegion = "weekRegion",
|
|
592
|
+
yearRegion = "yearRegion",
|
|
593
|
+
ymdHmsRegion = "ymdHmsRegion"
|
|
594
|
+
}
|
|
595
|
+
/** 返回值cellset中的dimType */
|
|
596
|
+
export declare enum CellsetDimTypes {
|
|
597
|
+
StandardDimension = "StandardDimension",
|
|
598
|
+
StrDateTypeDimension = "StrDateTypeDimension",
|
|
599
|
+
StarDimension = "StarDimension",
|
|
600
|
+
GeographicDimension = "GeographicDimension",
|
|
601
|
+
/** 上面为维度字段,measureCol代表度量 */
|
|
602
|
+
measureCol = "measureCol"
|
|
603
|
+
}
|
|
604
|
+
export declare class HintModal {
|
|
605
|
+
dsType: DsType;
|
|
606
|
+
head: `set`;
|
|
607
|
+
key: string;
|
|
608
|
+
connector: `=`;
|
|
609
|
+
value: string;
|
|
610
|
+
support: boolean;
|
|
611
|
+
}
|