@easyquery/core 7.4.1-rc03 → 7.4.1-rc04

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/LICENSE.md CHANGED
@@ -1,163 +1,163 @@
1
- GNU Lesser General Public License
2
- =================================
3
-
4
- _Version 3, 29 June 2007_
5
- _Copyright © 2007 Free Software Foundation, Inc. &lt;<http://fsf.org/>&gt;_
6
-
7
- Everyone is permitted to copy and distribute verbatim copies
8
- of this license document, but changing it is not allowed.
9
-
10
-
11
- This version of the GNU Lesser General Public License incorporates
12
- the terms and conditions of version 3 of the GNU General Public
13
- License, supplemented by the additional permissions listed below.
14
-
15
- ### 0. Additional Definitions
16
-
17
- As used herein, “this License” refers to version 3 of the GNU Lesser
18
- General Public License, and the “GNU GPL” refers to version 3 of the GNU
19
- General Public License.
20
-
21
- “The Library” refers to a covered work governed by this License,
22
- other than an Application or a Combined Work as defined below.
23
-
24
- An “Application” is any work that makes use of an interface provided
25
- by the Library, but which is not otherwise based on the Library.
26
- Defining a subclass of a class defined by the Library is deemed a mode
27
- of using an interface provided by the Library.
28
-
29
- A “Combined Work” is a work produced by combining or linking an
30
- Application with the Library. The particular version of the Library
31
- with which the Combined Work was made is also called the “Linked
32
- Version”.
33
-
34
- The “Minimal Corresponding Source” for a Combined Work means the
35
- Corresponding Source for the Combined Work, excluding any source code
36
- for portions of the Combined Work that, considered in isolation, are
37
- based on the Application, and not on the Linked Version.
38
-
39
- The “Corresponding Application Code” for a Combined Work means the
40
- object code and/or source code for the Application, including any data
41
- and utility programs needed for reproducing the Combined Work from the
42
- Application, but excluding the System Libraries of the Combined Work.
43
-
44
- ### 1. Exception to Section 3 of the GNU GPL
45
-
46
- You may convey a covered work under sections 3 and 4 of this License
47
- without being bound by section 3 of the GNU GPL.
48
-
49
- ### 2. Conveying Modified Versions
50
-
51
- If you modify a copy of the Library, and, in your modifications, a
52
- facility refers to a function or data to be supplied by an Application
53
- that uses the facility (other than as an argument passed when the
54
- facility is invoked), then you may convey a copy of the modified
55
- version:
56
-
57
- * **a)** under this License, provided that you make a good faith effort to
58
- ensure that, in the event an Application does not supply the
59
- function or data, the facility still operates, and performs
60
- whatever part of its purpose remains meaningful, or
61
-
62
- * **b)** under the GNU GPL, with none of the additional permissions of
63
- this License applicable to that copy.
64
-
65
- ### 3. Object Code Incorporating Material from Library Header Files
66
-
67
- The object code form of an Application may incorporate material from
68
- a header file that is part of the Library. You may convey such object
69
- code under terms of your choice, provided that, if the incorporated
70
- material is not limited to numerical parameters, data structure
71
- layouts and accessors, or small macros, inline functions and templates
72
- (ten or fewer lines in length), you do both of the following:
73
-
74
- * **a)** Give prominent notice with each copy of the object code that the
75
- Library is used in it and that the Library and its use are
76
- covered by this License.
77
- * **b)** Accompany the object code with a copy of the GNU GPL and this license
78
- document.
79
-
80
- ### 4. Combined Works
81
-
82
- You may convey a Combined Work under terms of your choice that,
83
- taken together, effectively do not restrict modification of the
84
- portions of the Library contained in the Combined Work and reverse
85
- engineering for debugging such modifications, if you also do each of
86
- the following:
87
-
88
- * **a)** Give prominent notice with each copy of the Combined Work that
89
- the Library is used in it and that the Library and its use are
90
- covered by this License.
91
-
92
- * **b)** Accompany the Combined Work with a copy of the GNU GPL and this license
93
- document.
94
-
95
- * **c)** For a Combined Work that displays copyright notices during
96
- execution, include the copyright notice for the Library among
97
- these notices, as well as a reference directing the user to the
98
- copies of the GNU GPL and this license document.
99
-
100
- * **d)** Do one of the following:
101
- - **0)** Convey the Minimal Corresponding Source under the terms of this
102
- License, and the Corresponding Application Code in a form
103
- suitable for, and under terms that permit, the user to
104
- recombine or relink the Application with a modified version of
105
- the Linked Version to produce a modified Combined Work, in the
106
- manner specified by section 6 of the GNU GPL for conveying
107
- Corresponding Source.
108
- - **1)** Use a suitable shared library mechanism for linking with the
109
- Library. A suitable mechanism is one that **(a)** uses at run time
110
- a copy of the Library already present on the user's computer
111
- system, and **(b)** will operate properly with a modified version
112
- of the Library that is interface-compatible with the Linked
113
- Version.
114
-
115
- * **e)** Provide Installation Information, but only if you would otherwise
116
- be required to provide such information under section 6 of the
117
- GNU GPL, and only to the extent that such information is
118
- necessary to install and execute a modified version of the
119
- Combined Work produced by recombining or relinking the
120
- Application with a modified version of the Linked Version. (If
121
- you use option **4d0**, the Installation Information must accompany
122
- the Minimal Corresponding Source and Corresponding Application
123
- Code. If you use option **4d1**, you must provide the Installation
124
- Information in the manner specified by section 6 of the GNU GPL
125
- for conveying Corresponding Source.)
126
-
127
- ### 5. Combined Libraries
128
-
129
- You may place library facilities that are a work based on the
130
- Library side by side in a single library together with other library
131
- facilities that are not Applications and are not covered by this
132
- License, and convey such a combined library under terms of your
133
- choice, if you do both of the following:
134
-
135
- * **a)** Accompany the combined library with a copy of the same work based
136
- on the Library, uncombined with any other library facilities,
137
- conveyed under the terms of this License.
138
- * **b)** Give prominent notice with the combined library that part of it
139
- is a work based on the Library, and explaining where to find the
140
- accompanying uncombined form of the same work.
141
-
142
- ### 6. Revised Versions of the GNU Lesser General Public License
143
-
144
- The Free Software Foundation may publish revised and/or new versions
145
- of the GNU Lesser General Public License from time to time. Such new
146
- versions will be similar in spirit to the present version, but may
147
- differ in detail to address new problems or concerns.
148
-
149
- Each version is given a distinguishing version number. If the
150
- Library as you received it specifies that a certain numbered version
151
- of the GNU Lesser General Public License “or any later version”
152
- applies to it, you have the option of following the terms and
153
- conditions either of that published version or of any later version
154
- published by the Free Software Foundation. If the Library as you
155
- received it does not specify a version number of the GNU Lesser
156
- General Public License, you may choose any version of the GNU Lesser
157
- General Public License ever published by the Free Software Foundation.
158
-
159
- If the Library as you received it specifies that a proxy can decide
160
- whether future versions of the GNU Lesser General Public License shall
161
- apply, that proxy's public statement of acceptance of any version is
162
- permanent authorization for you to choose that version for the
1
+ GNU Lesser General Public License
2
+ =================================
3
+
4
+ _Version 3, 29 June 2007_
5
+ _Copyright © 2007 Free Software Foundation, Inc. &lt;<http://fsf.org/>&gt;_
6
+
7
+ Everyone is permitted to copy and distribute verbatim copies
8
+ of this license document, but changing it is not allowed.
9
+
10
+
11
+ This version of the GNU Lesser General Public License incorporates
12
+ the terms and conditions of version 3 of the GNU General Public
13
+ License, supplemented by the additional permissions listed below.
14
+
15
+ ### 0. Additional Definitions
16
+
17
+ As used herein, “this License” refers to version 3 of the GNU Lesser
18
+ General Public License, and the “GNU GPL” refers to version 3 of the GNU
19
+ General Public License.
20
+
21
+ “The Library” refers to a covered work governed by this License,
22
+ other than an Application or a Combined Work as defined below.
23
+
24
+ An “Application” is any work that makes use of an interface provided
25
+ by the Library, but which is not otherwise based on the Library.
26
+ Defining a subclass of a class defined by the Library is deemed a mode
27
+ of using an interface provided by the Library.
28
+
29
+ A “Combined Work” is a work produced by combining or linking an
30
+ Application with the Library. The particular version of the Library
31
+ with which the Combined Work was made is also called the “Linked
32
+ Version”.
33
+
34
+ The “Minimal Corresponding Source” for a Combined Work means the
35
+ Corresponding Source for the Combined Work, excluding any source code
36
+ for portions of the Combined Work that, considered in isolation, are
37
+ based on the Application, and not on the Linked Version.
38
+
39
+ The “Corresponding Application Code” for a Combined Work means the
40
+ object code and/or source code for the Application, including any data
41
+ and utility programs needed for reproducing the Combined Work from the
42
+ Application, but excluding the System Libraries of the Combined Work.
43
+
44
+ ### 1. Exception to Section 3 of the GNU GPL
45
+
46
+ You may convey a covered work under sections 3 and 4 of this License
47
+ without being bound by section 3 of the GNU GPL.
48
+
49
+ ### 2. Conveying Modified Versions
50
+
51
+ If you modify a copy of the Library, and, in your modifications, a
52
+ facility refers to a function or data to be supplied by an Application
53
+ that uses the facility (other than as an argument passed when the
54
+ facility is invoked), then you may convey a copy of the modified
55
+ version:
56
+
57
+ * **a)** under this License, provided that you make a good faith effort to
58
+ ensure that, in the event an Application does not supply the
59
+ function or data, the facility still operates, and performs
60
+ whatever part of its purpose remains meaningful, or
61
+
62
+ * **b)** under the GNU GPL, with none of the additional permissions of
63
+ this License applicable to that copy.
64
+
65
+ ### 3. Object Code Incorporating Material from Library Header Files
66
+
67
+ The object code form of an Application may incorporate material from
68
+ a header file that is part of the Library. You may convey such object
69
+ code under terms of your choice, provided that, if the incorporated
70
+ material is not limited to numerical parameters, data structure
71
+ layouts and accessors, or small macros, inline functions and templates
72
+ (ten or fewer lines in length), you do both of the following:
73
+
74
+ * **a)** Give prominent notice with each copy of the object code that the
75
+ Library is used in it and that the Library and its use are
76
+ covered by this License.
77
+ * **b)** Accompany the object code with a copy of the GNU GPL and this license
78
+ document.
79
+
80
+ ### 4. Combined Works
81
+
82
+ You may convey a Combined Work under terms of your choice that,
83
+ taken together, effectively do not restrict modification of the
84
+ portions of the Library contained in the Combined Work and reverse
85
+ engineering for debugging such modifications, if you also do each of
86
+ the following:
87
+
88
+ * **a)** Give prominent notice with each copy of the Combined Work that
89
+ the Library is used in it and that the Library and its use are
90
+ covered by this License.
91
+
92
+ * **b)** Accompany the Combined Work with a copy of the GNU GPL and this license
93
+ document.
94
+
95
+ * **c)** For a Combined Work that displays copyright notices during
96
+ execution, include the copyright notice for the Library among
97
+ these notices, as well as a reference directing the user to the
98
+ copies of the GNU GPL and this license document.
99
+
100
+ * **d)** Do one of the following:
101
+ - **0)** Convey the Minimal Corresponding Source under the terms of this
102
+ License, and the Corresponding Application Code in a form
103
+ suitable for, and under terms that permit, the user to
104
+ recombine or relink the Application with a modified version of
105
+ the Linked Version to produce a modified Combined Work, in the
106
+ manner specified by section 6 of the GNU GPL for conveying
107
+ Corresponding Source.
108
+ - **1)** Use a suitable shared library mechanism for linking with the
109
+ Library. A suitable mechanism is one that **(a)** uses at run time
110
+ a copy of the Library already present on the user's computer
111
+ system, and **(b)** will operate properly with a modified version
112
+ of the Library that is interface-compatible with the Linked
113
+ Version.
114
+
115
+ * **e)** Provide Installation Information, but only if you would otherwise
116
+ be required to provide such information under section 6 of the
117
+ GNU GPL, and only to the extent that such information is
118
+ necessary to install and execute a modified version of the
119
+ Combined Work produced by recombining or relinking the
120
+ Application with a modified version of the Linked Version. (If
121
+ you use option **4d0**, the Installation Information must accompany
122
+ the Minimal Corresponding Source and Corresponding Application
123
+ Code. If you use option **4d1**, you must provide the Installation
124
+ Information in the manner specified by section 6 of the GNU GPL
125
+ for conveying Corresponding Source.)
126
+
127
+ ### 5. Combined Libraries
128
+
129
+ You may place library facilities that are a work based on the
130
+ Library side by side in a single library together with other library
131
+ facilities that are not Applications and are not covered by this
132
+ License, and convey such a combined library under terms of your
133
+ choice, if you do both of the following:
134
+
135
+ * **a)** Accompany the combined library with a copy of the same work based
136
+ on the Library, uncombined with any other library facilities,
137
+ conveyed under the terms of this License.
138
+ * **b)** Give prominent notice with the combined library that part of it
139
+ is a work based on the Library, and explaining where to find the
140
+ accompanying uncombined form of the same work.
141
+
142
+ ### 6. Revised Versions of the GNU Lesser General Public License
143
+
144
+ The Free Software Foundation may publish revised and/or new versions
145
+ of the GNU Lesser General Public License from time to time. Such new
146
+ versions will be similar in spirit to the present version, but may
147
+ differ in detail to address new problems or concerns.
148
+
149
+ Each version is given a distinguishing version number. If the
150
+ Library as you received it specifies that a certain numbered version
151
+ of the GNU Lesser General Public License “or any later version”
152
+ applies to it, you have the option of following the terms and
153
+ conditions either of that published version or of any later version
154
+ published by the Free Software Foundation. If the Library as you
155
+ received it does not specify a version number of the GNU Lesser
156
+ General Public License, you may choose any version of the GNU Lesser
157
+ General Public License ever published by the Free Software Foundation.
158
+
159
+ If the Library as you received it specifies that a proxy can decide
160
+ whether future versions of the GNU Lesser General Public License shall
161
+ apply, that proxy's public statement of acceptance of any version is
162
+ permanent authorization for you to choose that version for the
163
163
  Library.
package/README.md CHANGED
@@ -1,35 +1,35 @@
1
- # @easyquery/core (part of EasyQuery.JS)
2
-
3
- EasyQuery library provides you with the means to add an ad-hoc reporting or advanced search functionality to your web application.
4
-
5
- It gives you a simple to use but a quite powerful user interface to build queries or filters to your data. Your end-users will get the power of SQL with the simplicity of a natural language.
6
-
7
- Take a look at [EasyQuery web-page](https://korzh.com/easyquery) for more information.
8
-
9
- This `core` package defines the basic functions and structures of EasyQuery library such as `DataModel`, `Query`, `Condition`, `Column` and other classes and interfaces.
10
-
11
- ## Usage
12
-
13
- A general overview of EasyQuery.JS, getting started instructions and tutorials can be found on [EasyQuery.JS documentation](https://korzh.com/easyquery/javascript/docs) web-site.
14
-
15
- If you plan to use it with ASP.NET (Core) backend - we suggest you proceed with a "bundle": [EasyQuery for ASP.NET (Core)](https://korzh.com/easyquery) which includes both EasyQuery.JS library and the server-side packages for .NET (Core).
16
-
17
- For other platforms, you will also need a special EasyQuery Server which can be installed on any Linux, Windows or Mac server. For more information please read [How EasyQuery works](https://korzh.com/easyquery/javascript#HDIW) section on EasyQuery.JS web page.
18
-
19
- ## Live examples
20
-
21
- You can test EasyQuery in several different scenarios on our [live demos page](https://korzh.com/demo/easyquery-asp-net-core-razor).
22
-
23
- The source code for these sample web-applications is available on [GitHub](https://github.com/easyquery/DotNetSamples).
24
-
25
- ## Documentation
26
-
27
- * [Getting started and tutorials](https://korzh.com/easyquery/javascript/docs)
28
- * [API Reference](https://korzh.com/easyquery/javascript/docs/api-reference-7x)
29
-
30
- ## License
31
-
32
- The package is distributed under LGPL-3.0 license.
33
-
34
- The server-side part (which is required to build a working solution) is licensed separately.
35
- For more information please see [EasyQuery.NET Licensing](https://korzh.com/easyquery/licensing) page.
1
+ # @easyquery/core (part of EasyQuery.JS)
2
+
3
+ EasyQuery library provides you with the means to add an ad-hoc reporting or advanced search functionality to your web application.
4
+
5
+ It gives you a simple to use but a quite powerful user interface to build queries or filters to your data. Your end-users will get the power of SQL with the simplicity of a natural language.
6
+
7
+ Take a look at [EasyQuery web-page](https://korzh.com/easyquery) for more information.
8
+
9
+ This `core` package defines the basic functions and structures of EasyQuery library such as `DataModel`, `Query`, `Condition`, `Column` and other classes and interfaces.
10
+
11
+ ## Usage
12
+
13
+ A general overview of EasyQuery.JS, getting started instructions and tutorials can be found on [EasyQuery.JS documentation](https://korzh.com/easyquery/javascript/docs) web-site.
14
+
15
+ If you plan to use it with ASP.NET (Core) backend - we suggest you proceed with a "bundle": [EasyQuery for ASP.NET (Core)](https://korzh.com/easyquery) which includes both EasyQuery.JS library and the server-side packages for .NET (Core).
16
+
17
+ For other platforms, you will also need a special EasyQuery Server which can be installed on any Linux, Windows or Mac server. For more information please read [How EasyQuery works](https://korzh.com/easyquery/javascript#HDIW) section on EasyQuery.JS web page.
18
+
19
+ ## Live examples
20
+
21
+ You can test EasyQuery in several different scenarios on our [live demos page](https://korzh.com/demo/easyquery-asp-net-core-razor).
22
+
23
+ The source code for these sample web-applications is available on [GitHub](https://github.com/easyquery/DotNetSamples).
24
+
25
+ ## Documentation
26
+
27
+ * [Getting started and tutorials](https://korzh.com/easyquery/javascript/docs)
28
+ * [API Reference](https://korzh.com/easyquery/javascript/docs/api-reference-7x)
29
+
30
+ ## License
31
+
32
+ The package is distributed under LGPL-3.0 license.
33
+
34
+ The server-side part (which is required to build a working solution) is licensed separately.
35
+ For more information please see [EasyQuery.NET Licensing](https://korzh.com/easyquery/licensing) page.
@@ -1,10 +1,10 @@
1
1
 
2
2
  /*
3
- * EasyQuery.JS Core v7.4.1-rc03
4
- * Copyright 2025 Korzh.com
3
+ * EasyQuery.JS Core v7.4.1-rc04
4
+ * Copyright 2026 Korzh.com
5
5
  * Licensed under MIT
6
6
  *
7
- * Build time: 10/19/2025 10:48:25 PM
7
+ * Build time: 1/5/2026 11:26:54 PM
8
8
  */
9
9
 
10
10
  'use strict';
@@ -213,6 +213,24 @@ exports.equtils = void 0;
213
213
  }
214
214
  }
215
215
  equtils.convertValue = convertValue;
216
+ function downloadFile(data, filename) {
217
+ const blob = new Blob([data]);
218
+ if (window.navigator['msSaveOrOpenBlob']) {
219
+ // Internet Explorer
220
+ window.navigator['msSaveOrOpenBlob'](blob, filename);
221
+ }
222
+ else {
223
+ var a = document.createElement("a");
224
+ document.body.appendChild(a);
225
+ a.style.display = "none";
226
+ a.href = window.URL.createObjectURL(blob);
227
+ a.download = filename;
228
+ a.click();
229
+ window.URL.revokeObjectURL(a.href);
230
+ document.body.removeChild(a);
231
+ }
232
+ }
233
+ equtils.downloadFile = downloadFile;
216
234
  })(exports.equtils || (exports.equtils = {}));
217
235
 
218
236
  /**
@@ -327,7 +345,7 @@ class Operator {
327
345
  this.caseIns = data.caseIns;
328
346
  this.isRange = data.isRange;
329
347
  this.displayFormat = data.fmt;
330
- this.paramCount = data.pcnt;
348
+ this.paramCount = data.pcnt || 0;
331
349
  this.expr = data.expr;
332
350
  this.appliedTypes = data.dtypes || this.appliedTypes;
333
351
  if (data.defOperand) {
@@ -499,16 +517,19 @@ class DataModel extends core.MetaData {
499
517
  * @param data The JSON representation object.
500
518
  */
501
519
  loadFromData(data) {
520
+ if (!data || !data.entroot)
521
+ throw 'Invalid data model object value';
502
522
  super.loadFromData(data);
503
523
  //Operators
504
- this.operators = new Array();
524
+ const newOperators = new Array();
505
525
  if (data.operators) {
506
526
  for (let i = 0; i < data.operators.length; i++) {
507
527
  let newOperator = new Operator();
508
528
  newOperator.loadFromData(this, data.operators[i]);
509
- this.operators.push(newOperator);
529
+ newOperators.push(newOperator);
510
530
  }
511
531
  }
532
+ this.operators = newOperators;
512
533
  //rootEntity
513
534
  this.rootEntity.loadFromData(this, data.entroot);
514
535
  //Aggr Functions
@@ -2780,7 +2801,12 @@ class Query {
2780
2801
  * @param name New name.
2781
2802
  */
2782
2803
  setName(name) {
2783
- this.name = name;
2804
+ this.name = this.validateName(name);
2805
+ }
2806
+ validateName(name) {
2807
+ let validName = name || 'query';
2808
+ //remove invalid characters
2809
+ return validName.replace(/["'<>\\]/g, '').trim();
2784
2810
  }
2785
2811
  /**
2786
2812
  * Gets description of the query.
@@ -3166,6 +3192,17 @@ class Query {
3166
3192
  createCondition(tag = exports.CondTag.Simple) {
3167
3193
  return new Condition(this, tag);
3168
3194
  }
3195
+ safeStringify(obj) {
3196
+ const seen = new WeakSet();
3197
+ return JSON.stringify(obj, function (key, value) {
3198
+ if (typeof value === "object" && value !== null) {
3199
+ if (seen.has(value))
3200
+ return "[Circular]";
3201
+ seen.add(value);
3202
+ }
3203
+ return value;
3204
+ });
3205
+ }
3169
3206
  /**
3170
3207
  * Adds a new simple condition (a predicate)
3171
3208
  * @param descriptor The descriptor which defines different parameters of the new condition
@@ -3182,11 +3219,14 @@ class Query {
3182
3219
  if (!descriptor.attribute) {
3183
3220
  descriptor.attribute = model.getAttributeById(descriptor.attributeId);
3184
3221
  if (!descriptor.attribute) {
3185
- throw new Error("Could not find this attribute: " + descriptor.attributeId);
3222
+ throw new Error("Could not find attribute: " + descriptor.attributeId);
3186
3223
  }
3187
3224
  }
3188
3225
  if (!descriptor.operator && descriptor.operatorId) {
3189
3226
  descriptor.operator = model.getOperatorById(descriptor.operatorId);
3227
+ if (!descriptor.operator) {
3228
+ throw new Error("Could not find operator: " + descriptor.operatorId);
3229
+ }
3190
3230
  }
3191
3231
  if (!descriptor.operator) {
3192
3232
  descriptor.operator = model.getDefaultOperatorForAttr(descriptor.attribute);
@@ -4184,29 +4224,15 @@ class EqServerExporter {
4184
4224
  if (exportOptions.options) {
4185
4225
  requestData.options = exportOptions.options;
4186
4226
  }
4187
- const url = this.context.resolveEndpoint('ExportResult', { modelId: modelId, format: format });
4227
+ const url = this.context.resolveEndpoint('ExportTotal', { modelId: modelId, format: format });
4188
4228
  const actionResult = http.post(url, requestData, { responseType: this.responseType });
4189
4229
  const request = actionResult.getRequest();
4190
4230
  return actionResult.then((responseData) => {
4191
- const blob = new Blob([responseData]);
4192
4231
  const dispositionHeader = request.getXMLHttpRequest().getResponseHeader("Content-Disposition");
4193
4232
  const filename = dispositionHeader
4194
4233
  ? dispositionHeader.match(/filename="?([^"]*)"?$/)[1]
4195
4234
  : 'export-data.' + format;
4196
- if (window.navigator['msSaveOrOpenBlob']) {
4197
- // Internet Explorer
4198
- window.navigator['msSaveOrOpenBlob'](blob, filename);
4199
- }
4200
- else {
4201
- var a = document.createElement("a");
4202
- document.body.appendChild(a);
4203
- a.style.display = "none";
4204
- a.href = window.URL.createObjectURL(blob);
4205
- a.download = filename;
4206
- a.click();
4207
- window.URL.revokeObjectURL(a.href);
4208
- document.body.removeChild(a);
4209
- }
4235
+ exports.equtils.downloadFile(responseData, filename);
4210
4236
  });
4211
4237
  }
4212
4238
  }
@@ -4549,7 +4575,10 @@ class EqContext {
4549
4575
  this.setEndpointIfNotExist('GetQueryList', exports.equtils.combinePath(endpointBase, 'models/{modelId}/queries'));
4550
4576
  this.setEndpointIfNotExist('FetchData', exports.equtils.combinePath(endpointBase, 'models/{modelId}/fetch'));
4551
4577
  this.setEndpointIfNotExist('GetValueList', exports.equtils.combinePath(endpointBase, 'models/{modelId}/valuelists/{listId}'));
4552
- this.setEndpointIfNotExist('ExportResult', exports.equtils.combinePath(endpointBase, 'models/{modelId}/export/{format}'));
4578
+ this.setEndpointIfNotExist('ExportTotal', exports.equtils.combinePath(endpointBase, 'models/{modelId}/export/{format}'));
4579
+ this.setEndpointIfNotExist('ExportStart', exports.equtils.combinePath(endpointBase, 'models/{modelId}/export/start/{format}'));
4580
+ this.setEndpointIfNotExist('ExportStatus', exports.equtils.combinePath(endpointBase, 'models/{modelId}/export/status/{exportId}'));
4581
+ this.setEndpointIfNotExist('ExportGetResult', exports.equtils.combinePath(endpointBase, 'models/{modelId}/export/result/{exportId}'));
4553
4582
  this.setEndpointIfNotExist('GetQueryFile', exports.equtils.combinePath(endpointBase, 'models/{modelId}/getqueryfile/{format}'));
4554
4583
  this.setEndpointIfNotExist('UploadQueryFile', exports.equtils.combinePath(endpointBase, 'models/{modelId}/uploadqueryfile'));
4555
4584
  }
@@ -5700,7 +5729,7 @@ class EqContext {
5700
5729
  });
5701
5730
  }
5702
5731
  /**
5703
- * Fetches the data for defined by this context and exports them to the specified format.
5732
+ * Fetches the data for the query defined in this context and exports them to the specified format.
5704
5733
  * @param options
5705
5734
  * The content of the `options` parameter depends on `EqExporter` implementation.
5706
5735
  * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
@@ -5767,6 +5796,118 @@ class EqContext {
5767
5796
  }
5768
5797
  }
5769
5798
  }
5799
+ /**
5800
+ * Initiates the data export process for the query defined in this context.
5801
+ * @param options
5802
+ * The content of the `options` parameter depends on `EqExporter` implementation.
5803
+ * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
5804
+ * and `success` and `error` callbacks
5805
+ * @example
5806
+ * context.exportStart({
5807
+ * format: csv
5808
+ * });
5809
+ *
5810
+ */
5811
+ exportStart(options) {
5812
+ let exportOptions = options || {};
5813
+ exportOptions.chunk = exportOptions.chunk || EmptyChunk;
5814
+ exportOptions.data = exportOptions.data || {}; //add data property for convenience
5815
+ if (this.beforeExportResult) {
5816
+ this.beforeExportResult(this, exportOptions);
5817
+ }
5818
+ const format = exportOptions.format || 'csv';
5819
+ {
5820
+ const queryId = this.getQuery().getId();
5821
+ if (this.useStoredQueryOnFetch) {
5822
+ exportOptions.queryId = queryId;
5823
+ }
5824
+ const localeSettings = core.i18n.getLocaleSettings();
5825
+ exportOptions.settings = localeSettings;
5826
+ const aggrSettings = this.query.getAggregationSettings();
5827
+ if (aggrSettings.hasAggregates()
5828
+ && (aggrSettings.hasGrandTotals() || aggrSettings.hasGroups())) {
5829
+ exportOptions.aggregates = aggrSettings.saveToData();
5830
+ }
5831
+ const query = exportOptions.query || this.getQuery();
5832
+ const modelId = query.getModel().getId();
5833
+ let requestData = {
5834
+ 'settings': exportOptions.settings,
5835
+ 'chunk': EmptyChunk
5836
+ };
5837
+ if (typeof (exportOptions.queryId) !== 'undefined') {
5838
+ requestData.queryId = exportOptions.queryId;
5839
+ }
5840
+ else {
5841
+ requestData.query = query.toJSONData();
5842
+ }
5843
+ if (exportOptions.data) {
5844
+ requestData.data = exportOptions.data;
5845
+ }
5846
+ if (exportOptions.options) {
5847
+ requestData.options = exportOptions.options;
5848
+ }
5849
+ const http = this.getServices().getHttpClient();
5850
+ const url = this.resolveEndpoint('ExportStart', { modelId: modelId, format: format });
5851
+ const actionResult = http.post(url, requestData);
5852
+ actionResult
5853
+ .then((responseData) => {
5854
+ this.fireEvent('exportStart');
5855
+ if (exportOptions.success) {
5856
+ exportOptions.success();
5857
+ }
5858
+ this.startExportStatusCheck(responseData.exportId);
5859
+ })
5860
+ .catch((error) => {
5861
+ const errorMessage = `Error on initating data export for query ${queryId}. \n${error.message}`;
5862
+ this.endProcess({
5863
+ result: exports.EqActionResult.Error,
5864
+ action: exports.EqAction.ExportResult,
5865
+ text: errorMessage,
5866
+ sourceError: error
5867
+ }, exports.WidgetGroup.Result);
5868
+ if (exportOptions.error) {
5869
+ exportOptions.error(errorMessage, 'ExportResult');
5870
+ }
5871
+ });
5872
+ }
5873
+ }
5874
+ startExportStatusCheck(exportId) {
5875
+ let interval;
5876
+ const checkStatus = () => {
5877
+ const http = this.getServices().getHttpClient();
5878
+ const url = this.resolveEndpoint('ExportStatus', { exportId: exportId });
5879
+ const actionResult = http.get(url);
5880
+ actionResult
5881
+ .then((responseData) => {
5882
+ if (responseData.status === 2) {
5883
+ clearInterval(interval);
5884
+ const url = this.resolveEndpoint('ExportGetResult', { exportId: exportId });
5885
+ const actionResult = http.get(url, { responseType: 'blob' });
5886
+ const request = actionResult.getRequest();
5887
+ return actionResult.then((downloadResponseData) => {
5888
+ const dispositionHeader = request.getXMLHttpRequest().getResponseHeader("Content-Disposition");
5889
+ const filename = dispositionHeader
5890
+ ? dispositionHeader.match(/filename="?([^"]*)"?$/)[1]
5891
+ : 'export-data';
5892
+ exports.equtils.downloadFile(downloadResponseData, filename);
5893
+ });
5894
+ }
5895
+ else if (responseData.status === 3) {
5896
+ clearInterval(interval);
5897
+ }
5898
+ })
5899
+ .catch((error) => {
5900
+ clearInterval(interval);
5901
+ const errorMessage = `Error on checking data export status for exportId ${exportId}. \n${error.message}`;
5902
+ console.error(errorMessage);
5903
+ });
5904
+ };
5905
+ interval = setInterval(() => {
5906
+ checkStatus();
5907
+ }, 3000);
5908
+ //initial check
5909
+ checkStatus();
5910
+ }
5770
5911
  limitCustomSqlColumns() {
5771
5912
  if (!this.options.allowCustomExpressions) {
5772
5913
  this.query.getColumns().forEach(col => {
@@ -1,10 +1,10 @@
1
1
 
2
2
  /*
3
- * EasyQuery.JS Core v7.4.1-rc03
4
- * Copyright 2025 Korzh.com
3
+ * EasyQuery.JS Core v7.4.1-rc04
4
+ * Copyright 2026 Korzh.com
5
5
  * Licensed under MIT
6
6
  *
7
- * Build time: 10/19/2025 10:48:25 PM
7
+ * Build time: 1/5/2026 11:26:54 PM
8
8
  */
9
9
 
10
10
  import { i18n, DataType, utils, ValueEditor, MetaEntity, MetaEntityAttr, EditorTag, MetaData, EventEmitter, AggregationSettings, HttpClient, EasyDataTable } from '@easydata/core';
@@ -212,6 +212,24 @@ var equtils;
212
212
  }
213
213
  }
214
214
  equtils.convertValue = convertValue;
215
+ function downloadFile(data, filename) {
216
+ const blob = new Blob([data]);
217
+ if (window.navigator['msSaveOrOpenBlob']) {
218
+ // Internet Explorer
219
+ window.navigator['msSaveOrOpenBlob'](blob, filename);
220
+ }
221
+ else {
222
+ var a = document.createElement("a");
223
+ document.body.appendChild(a);
224
+ a.style.display = "none";
225
+ a.href = window.URL.createObjectURL(blob);
226
+ a.download = filename;
227
+ a.click();
228
+ window.URL.revokeObjectURL(a.href);
229
+ document.body.removeChild(a);
230
+ }
231
+ }
232
+ equtils.downloadFile = downloadFile;
215
233
  })(equtils || (equtils = {}));
216
234
 
217
235
  /**
@@ -326,7 +344,7 @@ class Operator {
326
344
  this.caseIns = data.caseIns;
327
345
  this.isRange = data.isRange;
328
346
  this.displayFormat = data.fmt;
329
- this.paramCount = data.pcnt;
347
+ this.paramCount = data.pcnt || 0;
330
348
  this.expr = data.expr;
331
349
  this.appliedTypes = data.dtypes || this.appliedTypes;
332
350
  if (data.defOperand) {
@@ -498,16 +516,19 @@ class DataModel extends MetaData {
498
516
  * @param data The JSON representation object.
499
517
  */
500
518
  loadFromData(data) {
519
+ if (!data || !data.entroot)
520
+ throw 'Invalid data model object value';
501
521
  super.loadFromData(data);
502
522
  //Operators
503
- this.operators = new Array();
523
+ const newOperators = new Array();
504
524
  if (data.operators) {
505
525
  for (let i = 0; i < data.operators.length; i++) {
506
526
  let newOperator = new Operator();
507
527
  newOperator.loadFromData(this, data.operators[i]);
508
- this.operators.push(newOperator);
528
+ newOperators.push(newOperator);
509
529
  }
510
530
  }
531
+ this.operators = newOperators;
511
532
  //rootEntity
512
533
  this.rootEntity.loadFromData(this, data.entroot);
513
534
  //Aggr Functions
@@ -2779,7 +2800,12 @@ class Query {
2779
2800
  * @param name New name.
2780
2801
  */
2781
2802
  setName(name) {
2782
- this.name = name;
2803
+ this.name = this.validateName(name);
2804
+ }
2805
+ validateName(name) {
2806
+ let validName = name || 'query';
2807
+ //remove invalid characters
2808
+ return validName.replace(/["'<>\\]/g, '').trim();
2783
2809
  }
2784
2810
  /**
2785
2811
  * Gets description of the query.
@@ -3165,6 +3191,17 @@ class Query {
3165
3191
  createCondition(tag = CondTag.Simple) {
3166
3192
  return new Condition(this, tag);
3167
3193
  }
3194
+ safeStringify(obj) {
3195
+ const seen = new WeakSet();
3196
+ return JSON.stringify(obj, function (key, value) {
3197
+ if (typeof value === "object" && value !== null) {
3198
+ if (seen.has(value))
3199
+ return "[Circular]";
3200
+ seen.add(value);
3201
+ }
3202
+ return value;
3203
+ });
3204
+ }
3168
3205
  /**
3169
3206
  * Adds a new simple condition (a predicate)
3170
3207
  * @param descriptor The descriptor which defines different parameters of the new condition
@@ -3181,11 +3218,14 @@ class Query {
3181
3218
  if (!descriptor.attribute) {
3182
3219
  descriptor.attribute = model.getAttributeById(descriptor.attributeId);
3183
3220
  if (!descriptor.attribute) {
3184
- throw new Error("Could not find this attribute: " + descriptor.attributeId);
3221
+ throw new Error("Could not find attribute: " + descriptor.attributeId);
3185
3222
  }
3186
3223
  }
3187
3224
  if (!descriptor.operator && descriptor.operatorId) {
3188
3225
  descriptor.operator = model.getOperatorById(descriptor.operatorId);
3226
+ if (!descriptor.operator) {
3227
+ throw new Error("Could not find operator: " + descriptor.operatorId);
3228
+ }
3189
3229
  }
3190
3230
  if (!descriptor.operator) {
3191
3231
  descriptor.operator = model.getDefaultOperatorForAttr(descriptor.attribute);
@@ -4183,29 +4223,15 @@ class EqServerExporter {
4183
4223
  if (exportOptions.options) {
4184
4224
  requestData.options = exportOptions.options;
4185
4225
  }
4186
- const url = this.context.resolveEndpoint('ExportResult', { modelId: modelId, format: format });
4226
+ const url = this.context.resolveEndpoint('ExportTotal', { modelId: modelId, format: format });
4187
4227
  const actionResult = http.post(url, requestData, { responseType: this.responseType });
4188
4228
  const request = actionResult.getRequest();
4189
4229
  return actionResult.then((responseData) => {
4190
- const blob = new Blob([responseData]);
4191
4230
  const dispositionHeader = request.getXMLHttpRequest().getResponseHeader("Content-Disposition");
4192
4231
  const filename = dispositionHeader
4193
4232
  ? dispositionHeader.match(/filename="?([^"]*)"?$/)[1]
4194
4233
  : 'export-data.' + format;
4195
- if (window.navigator['msSaveOrOpenBlob']) {
4196
- // Internet Explorer
4197
- window.navigator['msSaveOrOpenBlob'](blob, filename);
4198
- }
4199
- else {
4200
- var a = document.createElement("a");
4201
- document.body.appendChild(a);
4202
- a.style.display = "none";
4203
- a.href = window.URL.createObjectURL(blob);
4204
- a.download = filename;
4205
- a.click();
4206
- window.URL.revokeObjectURL(a.href);
4207
- document.body.removeChild(a);
4208
- }
4234
+ equtils.downloadFile(responseData, filename);
4209
4235
  });
4210
4236
  }
4211
4237
  }
@@ -4548,7 +4574,10 @@ class EqContext {
4548
4574
  this.setEndpointIfNotExist('GetQueryList', equtils.combinePath(endpointBase, 'models/{modelId}/queries'));
4549
4575
  this.setEndpointIfNotExist('FetchData', equtils.combinePath(endpointBase, 'models/{modelId}/fetch'));
4550
4576
  this.setEndpointIfNotExist('GetValueList', equtils.combinePath(endpointBase, 'models/{modelId}/valuelists/{listId}'));
4551
- this.setEndpointIfNotExist('ExportResult', equtils.combinePath(endpointBase, 'models/{modelId}/export/{format}'));
4577
+ this.setEndpointIfNotExist('ExportTotal', equtils.combinePath(endpointBase, 'models/{modelId}/export/{format}'));
4578
+ this.setEndpointIfNotExist('ExportStart', equtils.combinePath(endpointBase, 'models/{modelId}/export/start/{format}'));
4579
+ this.setEndpointIfNotExist('ExportStatus', equtils.combinePath(endpointBase, 'models/{modelId}/export/status/{exportId}'));
4580
+ this.setEndpointIfNotExist('ExportGetResult', equtils.combinePath(endpointBase, 'models/{modelId}/export/result/{exportId}'));
4552
4581
  this.setEndpointIfNotExist('GetQueryFile', equtils.combinePath(endpointBase, 'models/{modelId}/getqueryfile/{format}'));
4553
4582
  this.setEndpointIfNotExist('UploadQueryFile', equtils.combinePath(endpointBase, 'models/{modelId}/uploadqueryfile'));
4554
4583
  }
@@ -5699,7 +5728,7 @@ class EqContext {
5699
5728
  });
5700
5729
  }
5701
5730
  /**
5702
- * Fetches the data for defined by this context and exports them to the specified format.
5731
+ * Fetches the data for the query defined in this context and exports them to the specified format.
5703
5732
  * @param options
5704
5733
  * The content of the `options` parameter depends on `EqExporter` implementation.
5705
5734
  * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
@@ -5766,6 +5795,118 @@ class EqContext {
5766
5795
  }
5767
5796
  }
5768
5797
  }
5798
+ /**
5799
+ * Initiates the data export process for the query defined in this context.
5800
+ * @param options
5801
+ * The content of the `options` parameter depends on `EqExporter` implementation.
5802
+ * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
5803
+ * and `success` and `error` callbacks
5804
+ * @example
5805
+ * context.exportStart({
5806
+ * format: csv
5807
+ * });
5808
+ *
5809
+ */
5810
+ exportStart(options) {
5811
+ let exportOptions = options || {};
5812
+ exportOptions.chunk = exportOptions.chunk || EmptyChunk;
5813
+ exportOptions.data = exportOptions.data || {}; //add data property for convenience
5814
+ if (this.beforeExportResult) {
5815
+ this.beforeExportResult(this, exportOptions);
5816
+ }
5817
+ const format = exportOptions.format || 'csv';
5818
+ {
5819
+ const queryId = this.getQuery().getId();
5820
+ if (this.useStoredQueryOnFetch) {
5821
+ exportOptions.queryId = queryId;
5822
+ }
5823
+ const localeSettings = i18n.getLocaleSettings();
5824
+ exportOptions.settings = localeSettings;
5825
+ const aggrSettings = this.query.getAggregationSettings();
5826
+ if (aggrSettings.hasAggregates()
5827
+ && (aggrSettings.hasGrandTotals() || aggrSettings.hasGroups())) {
5828
+ exportOptions.aggregates = aggrSettings.saveToData();
5829
+ }
5830
+ const query = exportOptions.query || this.getQuery();
5831
+ const modelId = query.getModel().getId();
5832
+ let requestData = {
5833
+ 'settings': exportOptions.settings,
5834
+ 'chunk': EmptyChunk
5835
+ };
5836
+ if (typeof (exportOptions.queryId) !== 'undefined') {
5837
+ requestData.queryId = exportOptions.queryId;
5838
+ }
5839
+ else {
5840
+ requestData.query = query.toJSONData();
5841
+ }
5842
+ if (exportOptions.data) {
5843
+ requestData.data = exportOptions.data;
5844
+ }
5845
+ if (exportOptions.options) {
5846
+ requestData.options = exportOptions.options;
5847
+ }
5848
+ const http = this.getServices().getHttpClient();
5849
+ const url = this.resolveEndpoint('ExportStart', { modelId: modelId, format: format });
5850
+ const actionResult = http.post(url, requestData);
5851
+ actionResult
5852
+ .then((responseData) => {
5853
+ this.fireEvent('exportStart');
5854
+ if (exportOptions.success) {
5855
+ exportOptions.success();
5856
+ }
5857
+ this.startExportStatusCheck(responseData.exportId);
5858
+ })
5859
+ .catch((error) => {
5860
+ const errorMessage = `Error on initating data export for query ${queryId}. \n${error.message}`;
5861
+ this.endProcess({
5862
+ result: EqActionResult.Error,
5863
+ action: EqAction.ExportResult,
5864
+ text: errorMessage,
5865
+ sourceError: error
5866
+ }, WidgetGroup.Result);
5867
+ if (exportOptions.error) {
5868
+ exportOptions.error(errorMessage, 'ExportResult');
5869
+ }
5870
+ });
5871
+ }
5872
+ }
5873
+ startExportStatusCheck(exportId) {
5874
+ let interval;
5875
+ const checkStatus = () => {
5876
+ const http = this.getServices().getHttpClient();
5877
+ const url = this.resolveEndpoint('ExportStatus', { exportId: exportId });
5878
+ const actionResult = http.get(url);
5879
+ actionResult
5880
+ .then((responseData) => {
5881
+ if (responseData.status === 2) {
5882
+ clearInterval(interval);
5883
+ const url = this.resolveEndpoint('ExportGetResult', { exportId: exportId });
5884
+ const actionResult = http.get(url, { responseType: 'blob' });
5885
+ const request = actionResult.getRequest();
5886
+ return actionResult.then((downloadResponseData) => {
5887
+ const dispositionHeader = request.getXMLHttpRequest().getResponseHeader("Content-Disposition");
5888
+ const filename = dispositionHeader
5889
+ ? dispositionHeader.match(/filename="?([^"]*)"?$/)[1]
5890
+ : 'export-data';
5891
+ equtils.downloadFile(downloadResponseData, filename);
5892
+ });
5893
+ }
5894
+ else if (responseData.status === 3) {
5895
+ clearInterval(interval);
5896
+ }
5897
+ })
5898
+ .catch((error) => {
5899
+ clearInterval(interval);
5900
+ const errorMessage = `Error on checking data export status for exportId ${exportId}. \n${error.message}`;
5901
+ console.error(errorMessage);
5902
+ });
5903
+ };
5904
+ interval = setInterval(() => {
5905
+ checkStatus();
5906
+ }, 3000);
5907
+ //initial check
5908
+ checkStatus();
5909
+ }
5769
5910
  limitCustomSqlColumns() {
5770
5911
  if (!this.options.allowCustomExpressions) {
5771
5912
  this.query.getColumns().forEach(col => {
@@ -272,7 +272,7 @@ export declare class EqContext {
272
272
  * Fires event.
273
273
  * @param eventType The event type.
274
274
  */
275
- fireEvent(eventType: 'ready' | 'loadModel' | 'initialModelLoad' | 'loadQuery' | 'syncQuery' | 'fetchData' | 'exportResult'): any;
275
+ fireEvent(eventType: 'ready' | 'loadModel' | 'initialModelLoad' | 'loadQuery' | 'syncQuery' | 'fetchData' | 'exportResult' | 'exportStart' | 'exportReady', data?: any): any;
276
276
  fireEvent(eventType: 'processStart' | 'processEnd', data: ActionStatus): any;
277
277
  fireEvent(eventType: 'error', data: Error): any;
278
278
  private baseEndpoint;
@@ -367,7 +367,7 @@ export declare class EqContext {
367
367
  */
368
368
  fetchDrillDownData(options: ContextFetchDataOptions): void;
369
369
  /**
370
- * Fetches the data for defined by this context and exports them to the specified format.
370
+ * Fetches the data for the query defined in this context and exports them to the specified format.
371
371
  * @param options
372
372
  * The content of the `options` parameter depends on `EqExporter` implementation.
373
373
  * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
@@ -379,12 +379,26 @@ export declare class EqContext {
379
379
  *
380
380
  */
381
381
  exportResult(options?: ContextExportResultOptions): void;
382
+ /**
383
+ * Initiates the data export process for the query defined in this context.
384
+ * @param options
385
+ * The content of the `options` parameter depends on `EqExporter` implementation.
386
+ * Usually it contains `format` property which defines the format of the exported data (e.g. `csv`),
387
+ * and `success` and `error` callbacks
388
+ * @example
389
+ * context.exportStart({
390
+ * format: csv
391
+ * });
392
+ *
393
+ */
394
+ exportStart(options?: ContextExportResultOptions): void;
395
+ protected startExportStatusCheck(exportId: string): void;
382
396
  private limitCustomSqlColumns;
383
397
  getAttributeTitle(attr: EntityAttr): string;
384
398
  getColumnTitle(attr: EntityAttr): string;
385
399
  getDefaultColumnCaption(column: QueryColumn): string;
386
400
  }
387
- type EqEndpointKey = 'GetModel' | 'GetQuery' | 'SaveQuery' | 'NewQuery' | 'RemoveQuery' | 'GetQueryList' | 'SyncQuery' | 'FetchData' | 'GetValueList' | 'ExportResult' | 'GetQueryFile' | 'UploadQueryFile';
401
+ type EqEndpointKey = 'GetModel' | 'GetQuery' | 'SaveQuery' | 'NewQuery' | 'RemoveQuery' | 'GetQueryList' | 'SyncQuery' | 'FetchData' | 'GetValueList' | 'ExportTotal' | 'ExportStart' | 'ExportStatus' | 'ExportGetResult' | 'GetQueryFile' | 'UploadQueryFile';
388
402
  export interface EqBackendInfo {
389
403
  type?: string;
390
404
  subType?: string;
@@ -238,6 +238,7 @@ export declare class Query implements AggregationColumnStore {
238
238
  * @param name New name.
239
239
  */
240
240
  setName(name: string): void;
241
+ validateName(name: string): string;
241
242
  /**
242
243
  * Gets description of the query.
243
244
  * @retruns The description.
@@ -336,6 +337,7 @@ export declare class Query implements AggregationColumnStore {
336
337
  addConditionGroup(descriptor: ConditionGroupDescriptor, addChildCondition?: boolean): Condition;
337
338
  addExtraConditionGroup(descriptor: ConditionGroupDescriptor, addChildCondition?: boolean): Condition;
338
339
  createCondition(tag?: CondTag): Condition;
340
+ private safeStringify;
339
341
  /**
340
342
  * Adds a new simple condition (a predicate)
341
343
  * @param descriptor The descriptor which defines different parameters of the new condition
@@ -1,17 +1,3 @@
1
1
  /** Represents editor tags*/
2
- export declare const EqEditorTag: {
3
- /** SqlList tag value */
4
- SqlList: string;
5
- /** SubQuery tag value */
6
- SubQuery: string;
7
- /** Bind to parent column tag value */
8
- BindToParentColumn: string;
9
- Unknown: string;
10
- Edit: string;
11
- /** SqlList tag value */
12
- DateTime: string;
13
- List: string;
14
- CustomList: string;
15
- File: string;
16
- };
2
+ export declare const EqEditorTag: any;
17
3
  export type EqEditorTag = (typeof EqEditorTag)[keyof typeof EqEditorTag];
@@ -31,4 +31,5 @@ export declare namespace equtils {
31
31
  * @param toDataType - the data type we want to get
32
32
  */
33
33
  function convertValue(value: string, fromDataType: DataType, toDataType: DataType): string;
34
+ function downloadFile(data: any, filename: string): void;
34
35
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easyquery/core",
3
- "version": "7.4.1-rc03",
3
+ "version": "7.4.1-rc04",
4
4
  "description": "EasyQuery.JS Community core modules",
5
5
  "types": "./dist/types/public_api.d.ts",
6
6
  "main": "./dist/easyquery.core.cjs.js",