@easyquery/core 7.2.5-beta01 → 7.2.5-rc01
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/easyquery.core.cjs.js +6165 -0
- package/dist/easyquery.core.esm.js +6126 -0
- package/dist/{lib → types}/common/eq_services.d.ts +16 -12
- package/dist/{lib → types}/dm/data_model.d.ts +3 -23
- package/dist/{lib → types}/dm/operator.d.ts +2 -2
- package/dist/{lib → types}/main/context.d.ts +17 -2
- package/dist/types/main/context_resolver.d.ts +3 -0
- package/dist/types/main/init.d.ts +1 -0
- package/dist/{lib → types}/public_api.d.ts +2 -0
- package/dist/{lib → types}/query/query.d.ts +19 -8
- package/package.json +13 -37
- package/dist/bundles/easyquery.core.js +0 -9584
- package/dist/bundles/easyquery.core.js.map +0 -1
- package/dist/bundles/easyquery.core.min.js +0 -2
- package/dist/bundles/easyquery.core.min.js.map +0 -1
- package/dist/lib/common/eq_services.js +0 -160
- package/dist/lib/common/eq_services.js.map +0 -1
- package/dist/lib/common/query_param.js +0 -2
- package/dist/lib/common/query_param.js.map +0 -1
- package/dist/lib/common/tree.js +0 -58
- package/dist/lib/common/tree.js.map +0 -1
- package/dist/lib/data/eq_aggr_container.js +0 -109
- package/dist/lib/data/eq_aggr_container.js.map +0 -1
- package/dist/lib/data/eq_data_loader.js +0 -50
- package/dist/lib/data/eq_data_loader.js.map +0 -1
- package/dist/lib/data/google_data_converter.js +0 -174
- package/dist/lib/data/google_data_converter.js.map +0 -1
- package/dist/lib/dm/aggr_function.js +0 -43
- package/dist/lib/dm/aggr_function.js.map +0 -1
- package/dist/lib/dm/data_model.js +0 -935
- package/dist/lib/dm/data_model.js.map +0 -1
- package/dist/lib/dm/dto/af_data.js +0 -2
- package/dist/lib/dm/dto/af_data.js.map +0 -1
- package/dist/lib/dm/dto/dm_data.js +0 -2
- package/dist/lib/dm/dto/dm_data.js.map +0 -1
- package/dist/lib/dm/dto/entity_data.js +0 -2
- package/dist/lib/dm/dto/entity_data.js.map +0 -1
- package/dist/lib/dm/dto/operator_data.js +0 -2
- package/dist/lib/dm/dto/operator_data.js.map +0 -1
- package/dist/lib/dm/dto/ve_data.js +0 -2
- package/dist/lib/dm/dto/ve_data.js.map +0 -1
- package/dist/lib/dm/entity.js +0 -91
- package/dist/lib/dm/entity.js.map +0 -1
- package/dist/lib/dm/link.js +0 -2
- package/dist/lib/dm/link.js.map +0 -1
- package/dist/lib/dm/operator.js +0 -94
- package/dist/lib/dm/operator.js.map +0 -1
- package/dist/lib/dm/value_editor.js +0 -44
- package/dist/lib/dm/value_editor.js.map +0 -1
- package/dist/lib/eqs/eqs_data_fetcher.js +0 -37
- package/dist/lib/eqs/eqs_data_fetcher.js.map +0 -1
- package/dist/lib/eqs/eqs_exporter.js +0 -60
- package/dist/lib/eqs/eqs_exporter.js.map +0 -1
- package/dist/lib/eqs/eqs_model_loader.js +0 -43
- package/dist/lib/eqs/eqs_model_loader.js.map +0 -1
- package/dist/lib/eqs/eqs_query_file_loader.js +0 -55
- package/dist/lib/eqs/eqs_query_file_loader.js.map +0 -1
- package/dist/lib/eqs/eqs_query_synchronizer.js +0 -24
- package/dist/lib/eqs/eqs_query_synchronizer.js.map +0 -1
- package/dist/lib/eqs/eqs_value_list_resolver.js +0 -29
- package/dist/lib/eqs/eqs_value_list_resolver.js.map +0 -1
- package/dist/lib/export/exporter.js +0 -7
- package/dist/lib/export/exporter.js.map +0 -1
- package/dist/lib/i18n/text_resources.js +0 -27
- package/dist/lib/i18n/text_resources.js.map +0 -1
- package/dist/lib/main/action.js +0 -6
- package/dist/lib/main/action.js.map +0 -1
- package/dist/lib/main/context.js +0 -1492
- package/dist/lib/main/context.js.map +0 -1
- package/dist/lib/main/context_options.js +0 -2
- package/dist/lib/main/context_options.js.map +0 -1
- package/dist/lib/main/data_fetcher.js +0 -2
- package/dist/lib/main/data_fetcher.js.map +0 -1
- package/dist/lib/main/eq_actions.js +0 -16
- package/dist/lib/main/eq_actions.js.map +0 -1
- package/dist/lib/main/list_cache.js +0 -2
- package/dist/lib/main/list_cache.js.map +0 -1
- package/dist/lib/main/model_loader.js +0 -33
- package/dist/lib/main/model_loader.js.map +0 -1
- package/dist/lib/main/model_storage.js +0 -18
- package/dist/lib/main/model_storage.js.map +0 -1
- package/dist/lib/main/query_file_loader.js +0 -2
- package/dist/lib/main/query_file_loader.js.map +0 -1
- package/dist/lib/main/query_storage.js +0 -125
- package/dist/lib/main/query_storage.js.map +0 -1
- package/dist/lib/main/query_synchronizer.js +0 -2
- package/dist/lib/main/query_synchronizer.js.map +0 -1
- package/dist/lib/main/value_list_resolver.js +0 -2
- package/dist/lib/main/value_list_resolver.js.map +0 -1
- package/dist/lib/main/widget.js +0 -102
- package/dist/lib/main/widget.js.map +0 -1
- package/dist/lib/public_api.js +0 -60
- package/dist/lib/public_api.js.map +0 -1
- package/dist/lib/query/condition.js +0 -332
- package/dist/lib/query/condition.js.map +0 -1
- package/dist/lib/query/descriptors.js +0 -2
- package/dist/lib/query/descriptors.js.map +0 -1
- package/dist/lib/query/dto/condition_data.js +0 -2
- package/dist/lib/query/dto/condition_data.js.map +0 -1
- package/dist/lib/query/dto/expression_data.js +0 -2
- package/dist/lib/query/dto/expression_data.js.map +0 -1
- package/dist/lib/query/dto/query_column_data.js +0 -2
- package/dist/lib/query/dto/query_column_data.js.map +0 -1
- package/dist/lib/query/dto/query_data.js +0 -2
- package/dist/lib/query/dto/query_data.js.map +0 -1
- package/dist/lib/query/expression.js +0 -203
- package/dist/lib/query/expression.js.map +0 -1
- package/dist/lib/query/query.js +0 -1503
- package/dist/lib/query/query.js.map +0 -1
- package/dist/lib/query/query_column.js +0 -205
- package/dist/lib/query/query_column.js.map +0 -1
- package/dist/lib/query/query_events.js +0 -20
- package/dist/lib/query/query_events.js.map +0 -1
- package/dist/lib/types/cond_part.js +0 -8
- package/dist/lib/types/cond_part.js.map +0 -1
- package/dist/lib/types/cond_tag.js +0 -14
- package/dist/lib/types/cond_tag.js.map +0 -1
- package/dist/lib/types/data_kind.js +0 -17
- package/dist/lib/types/data_kind.js.map +0 -1
- package/dist/lib/types/eq_editor_tag.js +0 -21
- package/dist/lib/types/eq_editor_tag.js.map +0 -1
- package/dist/lib/types/expr_tag.js +0 -21
- package/dist/lib/types/expr_tag.js.map +0 -1
- package/dist/lib/types/link_type.js +0 -19
- package/dist/lib/types/link_type.js.map +0 -1
- package/dist/lib/types/widget_group.js +0 -19
- package/dist/lib/types/widget_group.js.map +0 -1
- package/dist/lib/utils/constants.js +0 -51
- package/dist/lib/utils/constants.js.map +0 -1
- package/dist/lib/utils/format_parser.js +0 -88
- package/dist/lib/utils/format_parser.js.map +0 -1
- package/dist/lib/utils/utils.js +0 -103
- package/dist/lib/utils/utils.js.map +0 -1
- package/dist/lib/utils/version_info.js +0 -13
- package/dist/lib/utils/version_info.js.map +0 -1
- package/tsconfig.json +0 -22
- package/webpack.config.js +0 -51
- /package/dist/{lib → types}/common/query_param.d.ts +0 -0
- /package/dist/{lib → types}/common/tree.d.ts +0 -0
- /package/dist/{lib → types}/data/eq_aggr_container.d.ts +0 -0
- /package/dist/{lib → types}/data/eq_data_loader.d.ts +0 -0
- /package/dist/{lib → types}/data/google_data_converter.d.ts +0 -0
- /package/dist/{lib → types}/dm/aggr_function.d.ts +0 -0
- /package/dist/{lib → types}/dm/dto/af_data.d.ts +0 -0
- /package/dist/{lib → types}/dm/dto/dm_data.d.ts +0 -0
- /package/dist/{lib → types}/dm/dto/entity_data.d.ts +0 -0
- /package/dist/{lib → types}/dm/dto/operator_data.d.ts +0 -0
- /package/dist/{lib → types}/dm/dto/ve_data.d.ts +0 -0
- /package/dist/{lib → types}/dm/entity.d.ts +0 -0
- /package/dist/{lib → types}/dm/link.d.ts +0 -0
- /package/dist/{lib → types}/dm/value_editor.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_data_fetcher.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_exporter.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_model_loader.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_query_file_loader.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_query_synchronizer.d.ts +0 -0
- /package/dist/{lib → types}/eqs/eqs_value_list_resolver.d.ts +0 -0
- /package/dist/{lib → types}/export/exporter.d.ts +0 -0
- /package/dist/{lib → types}/i18n/text_resources.d.ts +0 -0
- /package/dist/{lib → types}/main/action.d.ts +0 -0
- /package/dist/{lib → types}/main/context_options.d.ts +0 -0
- /package/dist/{lib → types}/main/data_fetcher.d.ts +0 -0
- /package/dist/{lib → types}/main/eq_actions.d.ts +0 -0
- /package/dist/{lib → types}/main/list_cache.d.ts +0 -0
- /package/dist/{lib → types}/main/model_loader.d.ts +0 -0
- /package/dist/{lib → types}/main/model_storage.d.ts +0 -0
- /package/dist/{lib → types}/main/query_file_loader.d.ts +0 -0
- /package/dist/{lib → types}/main/query_storage.d.ts +0 -0
- /package/dist/{lib → types}/main/query_synchronizer.d.ts +0 -0
- /package/dist/{lib → types}/main/value_list_resolver.d.ts +0 -0
- /package/dist/{lib → types}/main/widget.d.ts +0 -0
- /package/dist/{lib → types}/query/condition.d.ts +0 -0
- /package/dist/{lib → types}/query/descriptors.d.ts +0 -0
- /package/dist/{lib → types}/query/dto/condition_data.d.ts +0 -0
- /package/dist/{lib → types}/query/dto/expression_data.d.ts +0 -0
- /package/dist/{lib → types}/query/dto/query_column_data.d.ts +0 -0
- /package/dist/{lib → types}/query/dto/query_data.d.ts +0 -0
- /package/dist/{lib → types}/query/expression.d.ts +0 -0
- /package/dist/{lib → types}/query/query_column.d.ts +0 -0
- /package/dist/{lib → types}/query/query_events.d.ts +0 -0
- /package/dist/{lib → types}/types/cond_part.d.ts +0 -0
- /package/dist/{lib → types}/types/cond_tag.d.ts +0 -0
- /package/dist/{lib → types}/types/data_kind.d.ts +0 -0
- /package/dist/{lib → types}/types/eq_editor_tag.d.ts +0 -0
- /package/dist/{lib → types}/types/expr_tag.d.ts +0 -0
- /package/dist/{lib → types}/types/link_type.d.ts +0 -0
- /package/dist/{lib → types}/types/widget_group.d.ts +0 -0
- /package/dist/{lib → types}/utils/constants.d.ts +0 -0
- /package/dist/{lib → types}/utils/format_parser.d.ts +0 -0
- /package/dist/{lib → types}/utils/utils.d.ts +0 -0
- /package/dist/{lib → types}/utils/version_info.d.ts +0 -0
|
@@ -10,7 +10,8 @@ import { DataFetcher } from '../main/data_fetcher';
|
|
|
10
10
|
import { EqValueListResolver } from '../main/value_list_resolver';
|
|
11
11
|
import { QueryFileLoader } from '../main/query_file_loader';
|
|
12
12
|
export declare class EqServiceProvider {
|
|
13
|
-
|
|
13
|
+
private static _instance;
|
|
14
|
+
static getInstance(): EqServiceProvider;
|
|
14
15
|
private httpClient;
|
|
15
16
|
private queryResolver;
|
|
16
17
|
private modelResolver;
|
|
@@ -30,19 +31,19 @@ export declare class EqServiceProvider {
|
|
|
30
31
|
private vlrResolver;
|
|
31
32
|
private queryFileLoaderResolver;
|
|
32
33
|
private aggrCalculatoResolver;
|
|
33
|
-
constructor(
|
|
34
|
+
constructor();
|
|
34
35
|
reset(): void;
|
|
35
36
|
getHttpClient(): HttpClient;
|
|
36
|
-
createDataModel(): DataModel;
|
|
37
|
-
createQuery(): Query;
|
|
38
|
-
getModelLoader(): EqModelLoader;
|
|
39
|
-
getModelStorage(): DataModelStorage;
|
|
40
|
-
getQueryStorage(): QueryStorage;
|
|
41
|
-
getQuerySynchronizer(): QuerySynchronizer;
|
|
42
|
-
getDataFetcher(): DataFetcher;
|
|
43
|
-
getValueListResolver(): EqValueListResolver;
|
|
44
|
-
getQueryFileLoader(): QueryFileLoader;
|
|
45
|
-
getAggregatesCalculator(): AggregatesCalculator;
|
|
37
|
+
createDataModel(context: EqContext): DataModel;
|
|
38
|
+
createQuery(context: EqContext): Query;
|
|
39
|
+
getModelLoader(context: EqContext): EqModelLoader;
|
|
40
|
+
getModelStorage(context: EqContext): DataModelStorage;
|
|
41
|
+
getQueryStorage(context: EqContext): QueryStorage;
|
|
42
|
+
getQuerySynchronizer(context: EqContext): QuerySynchronizer;
|
|
43
|
+
getDataFetcher(context: EqContext): DataFetcher;
|
|
44
|
+
getValueListResolver(context: EqContext): EqValueListResolver;
|
|
45
|
+
getQueryFileLoader(context: EqContext): QueryFileLoader;
|
|
46
|
+
getAggregatesCalculator(context: EqContext): AggregatesCalculator;
|
|
46
47
|
registerDataModelResolver(resolver: (context: EqContext) => DataModel): void;
|
|
47
48
|
registerQueryResolver(resolver: (context: EqContext) => Query): void;
|
|
48
49
|
registerModelLoaderResolver(resolver: (context: EqContext) => EqModelLoader): void;
|
|
@@ -53,4 +54,7 @@ export declare class EqServiceProvider {
|
|
|
53
54
|
registerValueListResolver(resolver: (context: EqContext) => EqValueListResolver): void;
|
|
54
55
|
registerQueryFileLoaderResolver(resolver: (context: EqContext) => QueryFileLoader): void;
|
|
55
56
|
registerAggregatesCalculator(resolver: (context: EqContext) => AggregatesCalculator): void;
|
|
57
|
+
private services;
|
|
58
|
+
registerService<T>(serviceId: string, serviceResolver: () => T): void;
|
|
59
|
+
getService<T>(serviceId: string): T | undefined;
|
|
56
60
|
}
|
|
@@ -5,9 +5,7 @@ import { Entity, EntityAttr } from './entity';
|
|
|
5
5
|
import { EqValueEditor } from './value_editor';
|
|
6
6
|
import { Link } from './link';
|
|
7
7
|
import { DataKind } from '../types/data_kind';
|
|
8
|
-
import { Query } from '../query/query';
|
|
9
8
|
import { ModelPlainData } from './dto/dm_data';
|
|
10
|
-
import { Tree } from '../common/tree';
|
|
11
9
|
/**
|
|
12
10
|
* Operator descriptor.
|
|
13
11
|
*/
|
|
@@ -83,11 +81,6 @@ export declare class DataModel extends MetaData {
|
|
|
83
81
|
* @returns An instance of EqValueEditor class
|
|
84
82
|
*/
|
|
85
83
|
createValueEditor(): ValueEditor;
|
|
86
|
-
/**
|
|
87
|
-
* Creates query.
|
|
88
|
-
* @returns The Query.
|
|
89
|
-
*/
|
|
90
|
-
createQuery(): Query;
|
|
91
84
|
/**
|
|
92
85
|
* Gets root entity of the data model.
|
|
93
86
|
* @returns The root entity.
|
|
@@ -153,20 +146,7 @@ export declare class DataModel extends MetaData {
|
|
|
153
146
|
* @return The array of operator ids.
|
|
154
147
|
*/
|
|
155
148
|
getOperatorIdsByDataType(type: DataType): string[];
|
|
156
|
-
/**
|
|
157
|
-
* Builds entities tree used in query.
|
|
158
|
-
* @param query The query.
|
|
159
|
-
*/
|
|
160
|
-
buildQueryPath(query: Query): Tree<Entity>;
|
|
161
|
-
private createTreeNodeFromEntity;
|
|
162
|
-
/**
|
|
163
|
-
* Get Entities used in query.
|
|
164
|
-
* @param query The query.
|
|
165
|
-
*/
|
|
166
|
-
getEntitiesInQuery(query: Query): Entity[];
|
|
167
149
|
findAggrFunctionById(funcId: string): AggrFunction | null;
|
|
168
|
-
private fillEntitiesByCondtionGroup;
|
|
169
|
-
private addEntityByExpression;
|
|
170
150
|
/**
|
|
171
151
|
* Finds link between two entities.
|
|
172
152
|
* @param entityFrom The entity `from`.
|
|
@@ -316,9 +296,9 @@ export declare class DataModel extends MetaData {
|
|
|
316
296
|
*/
|
|
317
297
|
getTimeMacroValue(macroExpr: string): Date | null;
|
|
318
298
|
/**
|
|
319
|
-
* Gets time or
|
|
320
|
-
* @param
|
|
321
|
-
* @returns The time or macro
|
|
299
|
+
* Gets a time value by macor or the macro itself.
|
|
300
|
+
* @param time The macro or time value.
|
|
301
|
+
* @returns The time value or a macro that represents a particular time.
|
|
322
302
|
*/
|
|
323
303
|
getTimeOrMacroValue(time: string): string | Date;
|
|
324
304
|
getAllDateMacros(): string[];
|
|
@@ -69,12 +69,12 @@ export declare class Operand {
|
|
|
69
69
|
/**
|
|
70
70
|
* Loads operand from its JSON representation object.
|
|
71
71
|
* @param model The Data Model.
|
|
72
|
-
* @param
|
|
72
|
+
* @param operand A plain JS object that represents the operand.
|
|
73
73
|
*/
|
|
74
74
|
loadFromData(model: DataModel, operand: OperandData): void;
|
|
75
75
|
/**
|
|
76
76
|
* Copies operand from other operand.
|
|
77
|
-
* @param
|
|
77
|
+
* @param src The source operand.
|
|
78
78
|
*/
|
|
79
79
|
copyFrom(src: Operand): void;
|
|
80
80
|
}
|
|
@@ -62,6 +62,21 @@ export declare class EqContext {
|
|
|
62
62
|
private afterGroupFetch?;
|
|
63
63
|
constructor();
|
|
64
64
|
getServices(): EqServiceProvider;
|
|
65
|
+
/**
|
|
66
|
+
* Activates `Enterprise` functionality of the library. Works only with @easyquery/enterprise packag and a proper license key.
|
|
67
|
+
* @param keyOrInitCallback The license key or a callback wich is called after
|
|
68
|
+
* loading the license key from the back-end.
|
|
69
|
+
* If the callback function is called useEnterprise will try to get the license key from {base}/lck endpoint
|
|
70
|
+
*
|
|
71
|
+
* @example
|
|
72
|
+
* context.useEnterprise('license key');
|
|
73
|
+
* //or
|
|
74
|
+
* context.useEnterprise(() => {
|
|
75
|
+
* //further logic
|
|
76
|
+
* view.init(options);
|
|
77
|
+
* });
|
|
78
|
+
*/
|
|
79
|
+
useEnterprise(this: EqContext, keyOrInitCallback: string | (() => void)): void;
|
|
65
80
|
registerExporter(format: string, resolver: EqExporterResolver): void;
|
|
66
81
|
registerServerExporter(format: string, responseType: XMLHttpRequestResponseType): void;
|
|
67
82
|
getExporter(format: string): EqExporter | null;
|
|
@@ -70,7 +85,7 @@ export declare class EqContext {
|
|
|
70
85
|
private endpointVarsRegex;
|
|
71
86
|
resolveEndpoint(endpointKey: EqEndpointKey, options?: any): string;
|
|
72
87
|
setEndpoint(key: EqEndpointKey, value: string): void;
|
|
73
|
-
|
|
88
|
+
setEndpointIfNotExist(key: EqEndpointKey, value: string): void;
|
|
74
89
|
private setDefaultEndpoints;
|
|
75
90
|
private elasticPaging;
|
|
76
91
|
initStart(): void;
|
|
@@ -171,7 +186,7 @@ export declare class EqContext {
|
|
|
171
186
|
* Throws the error passed in the function parameter.
|
|
172
187
|
* If onError event handler is defined - we call that method.
|
|
173
188
|
* Otherwise - just place the error message to the browser console.
|
|
174
|
-
* @param error
|
|
189
|
+
* @param status an instance of ActionStatus inteface that represents the action on which the error occurred
|
|
175
190
|
*/
|
|
176
191
|
throwError(status: ActionStatus): void;
|
|
177
192
|
/**
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import './main/init';
|
|
1
2
|
export * from './utils/utils';
|
|
2
3
|
export * from './utils/constants';
|
|
3
4
|
export * from './export/exporter';
|
|
@@ -28,6 +29,7 @@ export * from './main/model_loader';
|
|
|
28
29
|
export * from './main/model_storage';
|
|
29
30
|
export * from './main/query_storage';
|
|
30
31
|
export * from './main/context';
|
|
32
|
+
export * from './main/context_resolver';
|
|
31
33
|
export * from './main/list_cache';
|
|
32
34
|
export * from './main/context_options';
|
|
33
35
|
export * from './main/widget';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { EventEmitter, EqEvent, AggregationColumnStore, AggregationSettings } from '@easydata/core';
|
|
2
2
|
import { DataModel } from '../dm/data_model';
|
|
3
3
|
import { Operator } from '../dm/operator';
|
|
4
|
-
import { EntityAttr } from '../dm/entity';
|
|
4
|
+
import { Entity, EntityAttr } from '../dm/entity';
|
|
5
5
|
import { QueryColumn, SortDirection } from './query_column';
|
|
6
6
|
import { Condition } from './condition';
|
|
7
7
|
import { ExprTag } from '../types/expr_tag';
|
|
@@ -9,6 +9,7 @@ import { CondTag } from '../types/cond_tag';
|
|
|
9
9
|
import { QueryData } from './dto/query_data';
|
|
10
10
|
import { ModelPlainData } from '../dm/dto/dm_data';
|
|
11
11
|
import { EqContext } from '../main/context';
|
|
12
|
+
import { Tree } from '../common/tree';
|
|
12
13
|
import { ColumnDescriptor, SimpleConditionDescriptor, ConditionGroupDescriptor } from './descriptors';
|
|
13
14
|
import { QueryChangeEventParams, QueryChangeAction } from './query_events';
|
|
14
15
|
/**
|
|
@@ -104,7 +105,7 @@ export declare class Query implements AggregationColumnStore {
|
|
|
104
105
|
isEx(): boolean;
|
|
105
106
|
/**
|
|
106
107
|
* Resets the query: clears all its conditions and columns, regenerate the ID and sets the default name.
|
|
107
|
-
* @param
|
|
108
|
+
* @param clearQuery Indicates whether we need to clear the content of the query on reset (default: true)
|
|
108
109
|
*/
|
|
109
110
|
reset(clearQuery?: boolean): void;
|
|
110
111
|
hasEnabledAggrColumns(): boolean;
|
|
@@ -125,8 +126,8 @@ export declare class Query implements AggregationColumnStore {
|
|
|
125
126
|
private validateConditionGroup;
|
|
126
127
|
/**
|
|
127
128
|
* Sets data to the query.
|
|
128
|
-
* @param data
|
|
129
|
-
* @param
|
|
129
|
+
* @param data A plain JS object that represents the query or a JSON string
|
|
130
|
+
* @param options An instance of LoadQueryFromDataOptions interface that can contain different loading options
|
|
130
131
|
*/
|
|
131
132
|
loadFromDataOrJson(data: QueryData | string, options?: LoadQueryFromDataOptions): void;
|
|
132
133
|
/**
|
|
@@ -224,8 +225,7 @@ export declare class Query implements AggregationColumnStore {
|
|
|
224
225
|
*/
|
|
225
226
|
setId(id: string): void;
|
|
226
227
|
/**
|
|
227
|
-
* Regenerates
|
|
228
|
-
* @param id New Query ID.
|
|
228
|
+
* Regenerates the query ID.
|
|
229
229
|
*/
|
|
230
230
|
regenerateId(): void;
|
|
231
231
|
/**
|
|
@@ -284,12 +284,12 @@ export declare class Query implements AggregationColumnStore {
|
|
|
284
284
|
getColumnById(id: string): QueryColumn;
|
|
285
285
|
/**
|
|
286
286
|
* Adds a new column with specified parameters
|
|
287
|
-
* @param
|
|
287
|
+
* @param descriptor The descriptor of the new column. Can contain different parameters like:
|
|
288
288
|
* `attribute` - a reference to a EntityAttr object,
|
|
289
289
|
* `attributeId` - an ID of the entity attribute we need (if we don't indicate `attribute`),
|
|
290
290
|
* `index`, sorting`, 'sortIndex` and other
|
|
291
291
|
*
|
|
292
|
-
* @param
|
|
292
|
+
* @param silent Indicates if we should raise a queryChanged event. If true - the operation will be performed silently, so no event is raised.
|
|
293
293
|
* @retruns The column.
|
|
294
294
|
* @example
|
|
295
295
|
* query.addColumn({
|
|
@@ -415,4 +415,15 @@ export declare class Query implements AggregationColumnStore {
|
|
|
415
415
|
* Retruns conditions text
|
|
416
416
|
*/
|
|
417
417
|
getConditionsTextAsHtml(): string;
|
|
418
|
+
/**
|
|
419
|
+
* Gets an array of all entities used in the query.
|
|
420
|
+
*/
|
|
421
|
+
getEntitiesInQuery(): Entity[];
|
|
422
|
+
private fillEntitiesByCondtionGroup;
|
|
423
|
+
private addEntityByExpression;
|
|
424
|
+
/**
|
|
425
|
+
* Builds and returns the path (actually the tree) between the entities used in the query.
|
|
426
|
+
*/
|
|
427
|
+
buildQueryPath(): Tree<Entity>;
|
|
428
|
+
private createTreeNodeFromEntity;
|
|
418
429
|
}
|
package/package.json
CHANGED
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@easyquery/core",
|
|
3
|
-
"version": "7.2.5-
|
|
3
|
+
"version": "7.2.5-rc01",
|
|
4
4
|
"description": "EasyQuery.JS Community core modules",
|
|
5
|
-
"types": "./dist/
|
|
6
|
-
"main": "./dist/
|
|
7
|
-
"module": "./dist/
|
|
5
|
+
"types": "./dist/types/public_api.d.ts",
|
|
6
|
+
"main": "./dist/easyquery.core.cjs.js",
|
|
7
|
+
"module": "./dist/easyquery.core.esm.js",
|
|
8
8
|
"scripts": {
|
|
9
|
-
"
|
|
10
|
-
"build": "
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"test": "npm run clean-test && tsc -p tsconfig-test.json && jasmine JASMINE_CONFIG_PATH=jasmine.json",
|
|
15
|
-
"clean-test": "rimraf ./test/dist"
|
|
9
|
+
"clear": "shx rm -rf dist/* docs/*",
|
|
10
|
+
"build": "npm run clear && rollup -c",
|
|
11
|
+
"watch": "npm run clear && rollup -c -w",
|
|
12
|
+
"docs": "typedoc src/public_api.ts --out ./docs",
|
|
13
|
+
"test": "jest"
|
|
16
14
|
},
|
|
17
15
|
"author": "Korzh.com",
|
|
18
16
|
"homepage": "https://korzh.com/easyquery/javascript",
|
|
@@ -30,32 +28,10 @@
|
|
|
30
28
|
],
|
|
31
29
|
"bugs": "https://korzh.com/support",
|
|
32
30
|
"license": "LGPL-3.0",
|
|
31
|
+
"files": [
|
|
32
|
+
"dist"
|
|
33
|
+
],
|
|
33
34
|
"peerDependencies": {
|
|
34
|
-
"@easydata/core": "^1.4.
|
|
35
|
-
},
|
|
36
|
-
"devDependencies": {
|
|
37
|
-
"@olton/typedoc-webpack-plugin": "^0.1.0",
|
|
38
|
-
"@types/jasmine": "^4.3.2",
|
|
39
|
-
"@types/node": "20.2.5",
|
|
40
|
-
"es6-promise": "^4.2.8",
|
|
41
|
-
"jasmine": "^5.0.0",
|
|
42
|
-
"jasmine-ts-console-reporter": "^3.1.1",
|
|
43
|
-
"jsdom": "^22.1.0",
|
|
44
|
-
"nodemon": "2.0.22",
|
|
45
|
-
"rimraf": "5.0.1",
|
|
46
|
-
"terser-webpack-plugin": "^5.3.9",
|
|
47
|
-
"ts-loader": "^9.4.3",
|
|
48
|
-
"typedoc": "^0.24.7",
|
|
49
|
-
"typescript": "5.0.*",
|
|
50
|
-
"webpack": "^5.84.1",
|
|
51
|
-
"webpack-cli": "^5.1.1"
|
|
52
|
-
},
|
|
53
|
-
"nodemonConfig": {
|
|
54
|
-
"watch": [
|
|
55
|
-
"src"
|
|
56
|
-
],
|
|
57
|
-
"delay": "1000",
|
|
58
|
-
"ext": "ts,js",
|
|
59
|
-
"exec": "tsc"
|
|
35
|
+
"@easydata/core": "^1.4.21"
|
|
60
36
|
}
|
|
61
37
|
}
|