@memberjunction/global 2.112.0 → 2.113.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/dist/Core.d.ts +0 -29
- package/dist/Core.d.ts.map +0 -1
- package/dist/Core.js +0 -58
- package/dist/Core.js.map +0 -1
- package/dist/generic/QueryCache.d.ts +0 -85
- package/dist/generic/QueryCache.d.ts.map +0 -1
- package/dist/generic/QueryCache.js +0 -198
- package/dist/generic/QueryCache.js.map +0 -1
- package/dist/generic/QueryCacheConfig.d.ts +0 -72
- package/dist/generic/QueryCacheConfig.d.ts.map +0 -1
- package/dist/generic/QueryCacheConfig.js +0 -3
- package/dist/generic/QueryCacheConfig.js.map +0 -1
- package/dist/generic/applicationInfo.d.ts +0 -138
- package/dist/generic/applicationInfo.d.ts.map +0 -1
- package/dist/generic/applicationInfo.js +0 -177
- package/dist/generic/applicationInfo.js.map +0 -1
- package/dist/generic/authEvaluator.d.ts +0 -25
- package/dist/generic/authEvaluator.d.ts.map +0 -1
- package/dist/generic/authEvaluator.js +0 -49
- package/dist/generic/authEvaluator.js.map +0 -1
- package/dist/generic/authTypes.d.ts +0 -193
- package/dist/generic/authTypes.d.ts.map +0 -1
- package/dist/generic/authTypes.js +0 -19
- package/dist/generic/authTypes.js.map +0 -1
- package/dist/generic/baseEngine.d.ts +0 -260
- package/dist/generic/baseEngine.d.ts.map +0 -1
- package/dist/generic/baseEngine.js +0 -510
- package/dist/generic/baseEngine.js.map +0 -1
- package/dist/generic/baseEntity.d.ts +0 -691
- package/dist/generic/baseEntity.d.ts.map +0 -1
- package/dist/generic/baseEntity.js +0 -1688
- package/dist/generic/baseEntity.js.map +0 -1
- package/dist/generic/baseInfo.d.ts +0 -24
- package/dist/generic/baseInfo.d.ts.map +0 -1
- package/dist/generic/baseInfo.js +0 -53
- package/dist/generic/baseInfo.js.map +0 -1
- package/dist/generic/compositeKey.d.ts +0 -206
- package/dist/generic/compositeKey.d.ts.map +0 -1
- package/dist/generic/compositeKey.js +0 -412
- package/dist/generic/compositeKey.js.map +0 -1
- package/dist/generic/databaseProviderBase.d.ts +0 -46
- package/dist/generic/databaseProviderBase.d.ts.map +0 -1
- package/dist/generic/databaseProviderBase.js +0 -14
- package/dist/generic/databaseProviderBase.js.map +0 -1
- package/dist/generic/entityInfo.d.ts +0 -983
- package/dist/generic/entityInfo.d.ts.map +0 -1
- package/dist/generic/entityInfo.js +0 -1401
- package/dist/generic/entityInfo.js.map +0 -1
- package/dist/generic/explorerNavigationItem.d.ts +0 -20
- package/dist/generic/explorerNavigationItem.d.ts.map +0 -1
- package/dist/generic/explorerNavigationItem.js +0 -29
- package/dist/generic/explorerNavigationItem.js.map +0 -1
- package/dist/generic/interfaces.d.ts +0 -610
- package/dist/generic/interfaces.d.ts.map +0 -1
- package/dist/generic/interfaces.js +0 -211
- package/dist/generic/interfaces.js.map +0 -1
- package/dist/generic/libraryInfo.d.ts +0 -40
- package/dist/generic/libraryInfo.d.ts.map +0 -1
- package/dist/generic/libraryInfo.js +0 -56
- package/dist/generic/libraryInfo.js.map +0 -1
- package/dist/generic/logging.d.ts +0 -179
- package/dist/generic/logging.d.ts.map +0 -1
- package/dist/generic/logging.js +0 -382
- package/dist/generic/logging.js.map +0 -1
- package/dist/generic/metadata.d.ts +0 -305
- package/dist/generic/metadata.d.ts.map +0 -1
- package/dist/generic/metadata.js +0 -454
- package/dist/generic/metadata.js.map +0 -1
- package/dist/generic/metadataUtil.d.ts +0 -8
- package/dist/generic/metadataUtil.d.ts.map +0 -1
- package/dist/generic/metadataUtil.js +0 -36
- package/dist/generic/metadataUtil.js.map +0 -1
- package/dist/generic/providerBase.d.ts +0 -546
- package/dist/generic/providerBase.d.ts.map +0 -1
- package/dist/generic/providerBase.js +0 -999
- package/dist/generic/providerBase.js.map +0 -1
- package/dist/generic/queryInfo.d.ts +0 -460
- package/dist/generic/queryInfo.d.ts.map +0 -1
- package/dist/generic/queryInfo.js +0 -633
- package/dist/generic/queryInfo.js.map +0 -1
- package/dist/generic/querySQLFilters.d.ts +0 -54
- package/dist/generic/querySQLFilters.d.ts.map +0 -1
- package/dist/generic/querySQLFilters.js +0 -84
- package/dist/generic/querySQLFilters.js.map +0 -1
- package/dist/generic/runQuery.d.ts +0 -96
- package/dist/generic/runQuery.d.ts.map +0 -1
- package/dist/generic/runQuery.js +0 -66
- package/dist/generic/runQuery.js.map +0 -1
- package/dist/generic/runQuerySQLFilterImplementations.d.ts +0 -51
- package/dist/generic/runQuerySQLFilterImplementations.d.ts.map +0 -1
- package/dist/generic/runQuerySQLFilterImplementations.js +0 -238
- package/dist/generic/runQuerySQLFilterImplementations.js.map +0 -1
- package/dist/generic/runReport.d.ts +0 -25
- package/dist/generic/runReport.d.ts.map +0 -1
- package/dist/generic/runReport.js +0 -42
- package/dist/generic/runReport.js.map +0 -1
- package/dist/generic/securityInfo.d.ts +0 -355
- package/dist/generic/securityInfo.d.ts.map +0 -1
- package/dist/generic/securityInfo.js +0 -425
- package/dist/generic/securityInfo.js.map +0 -1
- package/dist/generic/transactionGroup.d.ts +0 -184
- package/dist/generic/transactionGroup.d.ts.map +0 -1
- package/dist/generic/transactionGroup.js +0 -357
- package/dist/generic/transactionGroup.js.map +0 -1
- package/dist/generic/util.d.ts +0 -81
- package/dist/generic/util.d.ts.map +0 -1
- package/dist/generic/util.js +0 -301
- package/dist/generic/util.js.map +0 -1
- package/dist/views/runView.d.ts +0 -150
- package/dist/views/runView.d.ts.map +0 -1
- package/dist/views/runView.js +0 -100
- package/dist/views/runView.js.map +0 -1
- package/dist/views/viewInfo.d.ts +0 -121
- package/dist/views/viewInfo.d.ts.map +0 -1
- package/dist/views/viewInfo.js +0 -182
- package/dist/views/viewInfo.js.map +0 -1
|
@@ -1,633 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.QueryParameterInfo = exports.QueryEntityInfo = exports.QueryPermissionInfo = exports.QueryFieldInfo = exports.QueryCategoryInfo = exports.QueryInfo = void 0;
|
|
4
|
-
const baseInfo_1 = require("./baseInfo");
|
|
5
|
-
const metadata_1 = require("./metadata");
|
|
6
|
-
/**
|
|
7
|
-
* Catalog of stored queries. This is useful for any arbitrary query that is known to be performant and correct and can be reused.
|
|
8
|
-
* Queries can be viewed/run by a user, used programatically via RunQuery, and also used by AI systems for improved reliability
|
|
9
|
-
* instead of dynamically generated SQL. Queries can also improve security since they store the SQL instead of using dynamic SQL.
|
|
10
|
-
*/
|
|
11
|
-
class QueryInfo extends baseInfo_1.BaseInfo {
|
|
12
|
-
/**
|
|
13
|
-
* Gets the full hierarchical path of this query's category (e.g., "/MJ/AI/Agents/").
|
|
14
|
-
* This provides a unique filepath-like identifier for the category hierarchy.
|
|
15
|
-
* Returns empty string if the query is not categorized.
|
|
16
|
-
* @returns {string} The category path with leading and trailing slashes
|
|
17
|
-
*/
|
|
18
|
-
get CategoryPath() {
|
|
19
|
-
if (this._categoryPath === null) {
|
|
20
|
-
this._categoryPath = this.buildCategoryPath();
|
|
21
|
-
}
|
|
22
|
-
return this._categoryPath;
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* Gets the cache configuration for this query.
|
|
26
|
-
* If the query has no explicit cache config but category inheritance is enabled,
|
|
27
|
-
* walks up the category tree to find inherited cache settings.
|
|
28
|
-
* @returns {QueryCacheConfig | null} The cache configuration or null if caching is disabled
|
|
29
|
-
*/
|
|
30
|
-
get CacheConfig() {
|
|
31
|
-
// If we already built the config, return it
|
|
32
|
-
if (this._cacheConfig !== null) {
|
|
33
|
-
return this._cacheConfig;
|
|
34
|
-
}
|
|
35
|
-
// If caching is explicitly enabled on this query
|
|
36
|
-
if (this.CacheEnabled) {
|
|
37
|
-
this._cacheConfig = {
|
|
38
|
-
enabled: true,
|
|
39
|
-
ttlMinutes: this.CacheTTLMinutes || 60, // Default to 60 minutes
|
|
40
|
-
maxCacheSize: this.CacheMaxSize || undefined,
|
|
41
|
-
cacheKey: 'exact'
|
|
42
|
-
};
|
|
43
|
-
return this._cacheConfig;
|
|
44
|
-
}
|
|
45
|
-
// Check for inherited cache config from category
|
|
46
|
-
if (this.CategoryInfo) {
|
|
47
|
-
const inheritedConfig = this.getInheritedCacheConfig();
|
|
48
|
-
if (inheritedConfig) {
|
|
49
|
-
this._cacheConfig = inheritedConfig;
|
|
50
|
-
return this._cacheConfig;
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
// No caching configured
|
|
54
|
-
this._cacheConfig = { enabled: false, ttlMinutes: 0 };
|
|
55
|
-
return this._cacheConfig;
|
|
56
|
-
}
|
|
57
|
-
/**
|
|
58
|
-
* Walks up the category hierarchy to find inherited cache configuration.
|
|
59
|
-
* @returns {QueryCacheConfig | null} The inherited cache config or null if none found
|
|
60
|
-
*/
|
|
61
|
-
getInheritedCacheConfig() {
|
|
62
|
-
let category = this.CategoryInfo;
|
|
63
|
-
while (category) {
|
|
64
|
-
if (category.DefaultCacheEnabled && category.CacheInheritanceEnabled) {
|
|
65
|
-
return {
|
|
66
|
-
enabled: true,
|
|
67
|
-
ttlMinutes: category.DefaultCacheTTLMinutes || 60,
|
|
68
|
-
maxCacheSize: category.DefaultCacheMaxSize || undefined,
|
|
69
|
-
cacheKey: 'exact',
|
|
70
|
-
inheritFromCategory: true
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
category = category.ParentCategoryInfo;
|
|
74
|
-
}
|
|
75
|
-
return null;
|
|
76
|
-
}
|
|
77
|
-
/**
|
|
78
|
-
* Gets the field metadata for this query, including display names, data types, and formatting rules.
|
|
79
|
-
* @returns {QueryFieldInfo[]} Array of field metadata for the query
|
|
80
|
-
*/
|
|
81
|
-
get Fields() {
|
|
82
|
-
if (this._fields === null) {
|
|
83
|
-
this._fields = metadata_1.Metadata.Provider.QueryFields.filter(f => f.QueryID === this.ID);
|
|
84
|
-
}
|
|
85
|
-
return this._fields;
|
|
86
|
-
}
|
|
87
|
-
/**
|
|
88
|
-
* Gets the permissions that control access to this query, defining which users and roles can run it.
|
|
89
|
-
* @returns {QueryPermissionInfo[]} Array of permission settings for the query
|
|
90
|
-
*/
|
|
91
|
-
get Permissions() {
|
|
92
|
-
return metadata_1.Metadata.Provider.QueryPermissions.filter(p => p.QueryID === this.ID);
|
|
93
|
-
}
|
|
94
|
-
/**
|
|
95
|
-
* Gets the parameter definitions for this parameterized query if it uses Nunjucks templates.
|
|
96
|
-
* Parameters include validation filters and metadata for type-safe query execution.
|
|
97
|
-
* @returns {QueryParameterInfo[]} Array of parameter definitions for the query
|
|
98
|
-
*/
|
|
99
|
-
get Parameters() {
|
|
100
|
-
if (this._parameters === null) {
|
|
101
|
-
this._parameters = metadata_1.Metadata.Provider.QueryParameters.filter(p => p.QueryID === this.ID);
|
|
102
|
-
}
|
|
103
|
-
return this._parameters;
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* Gets the entities that are involved in this query, tracking which MemberJunction entities are referenced.
|
|
107
|
-
* @returns {QueryEntityInfo[]} Array of entities used by the query
|
|
108
|
-
*/
|
|
109
|
-
get Entities() {
|
|
110
|
-
if (this._entities === null) {
|
|
111
|
-
this._entities = metadata_1.Metadata.Provider.QueryEntities.filter(e => e.QueryID === this.ID);
|
|
112
|
-
}
|
|
113
|
-
return this._entities;
|
|
114
|
-
}
|
|
115
|
-
constructor(initData = null) {
|
|
116
|
-
super();
|
|
117
|
-
/**
|
|
118
|
-
* Unique identifier for the query record
|
|
119
|
-
*/
|
|
120
|
-
this.ID = null;
|
|
121
|
-
/**
|
|
122
|
-
* Name of the query for display and reference
|
|
123
|
-
*/
|
|
124
|
-
this.Name = null;
|
|
125
|
-
/**
|
|
126
|
-
* Detailed description of what the query does and what data it returns
|
|
127
|
-
*/
|
|
128
|
-
this.Description = null;
|
|
129
|
-
/**
|
|
130
|
-
* Foreign key reference to the Query Categories entity
|
|
131
|
-
*/
|
|
132
|
-
this.CategoryID = null;
|
|
133
|
-
/**
|
|
134
|
-
* The actual SQL query text to execute, may include Nunjucks template parameters
|
|
135
|
-
*/
|
|
136
|
-
this.SQL = null;
|
|
137
|
-
/**
|
|
138
|
-
* The original SQL before any optimization or modification, kept for reference and comparison
|
|
139
|
-
*/
|
|
140
|
-
this.OriginalSQL = null;
|
|
141
|
-
/**
|
|
142
|
-
* User feedback on query accuracy, performance, or suggested improvements
|
|
143
|
-
*/
|
|
144
|
-
this.Feedback = null;
|
|
145
|
-
/**
|
|
146
|
-
* Current status of the query in the approval workflow
|
|
147
|
-
*/
|
|
148
|
-
this.Status = null;
|
|
149
|
-
/**
|
|
150
|
-
* Value indicating the quality of the query, higher values mean better quality
|
|
151
|
-
*/
|
|
152
|
-
this.QualityRank = null;
|
|
153
|
-
/**
|
|
154
|
-
* Automatically set to true when the SQL column contains Nunjucks template markers like {{paramName}}
|
|
155
|
-
*/
|
|
156
|
-
this.UsesTemplate = false;
|
|
157
|
-
/**
|
|
158
|
-
* When true, all executions of this query will be logged to the Audit Log system for tracking and compliance
|
|
159
|
-
*/
|
|
160
|
-
this.AuditQueryRuns = false;
|
|
161
|
-
/**
|
|
162
|
-
* When true, query results will be cached in memory with TTL expiration
|
|
163
|
-
*/
|
|
164
|
-
this.CacheEnabled = false;
|
|
165
|
-
/**
|
|
166
|
-
* Time-to-live in minutes for cached query results. NULL uses default TTL.
|
|
167
|
-
*/
|
|
168
|
-
this.CacheTTLMinutes = null;
|
|
169
|
-
/**
|
|
170
|
-
* Maximum number of cached result sets for this query. NULL uses default size limit.
|
|
171
|
-
*/
|
|
172
|
-
this.CacheMaxSize = null;
|
|
173
|
-
/**
|
|
174
|
-
* Date and time when this query record was created
|
|
175
|
-
*/
|
|
176
|
-
this.__mj_CreatedAt = null;
|
|
177
|
-
/**
|
|
178
|
-
* Date and time when this query record was last updated
|
|
179
|
-
*/
|
|
180
|
-
this.__mj_UpdatedAt = null;
|
|
181
|
-
/**
|
|
182
|
-
* Optional JSON-serialized embedding vector for the query, used for similarity search and query analysis
|
|
183
|
-
*/
|
|
184
|
-
this.EmbeddingVector = null;
|
|
185
|
-
/**
|
|
186
|
-
* The AI Model ID used to generate the embedding vector for this query. Required for vector similarity comparisons.
|
|
187
|
-
*/
|
|
188
|
-
this.EmbeddingModelID = null;
|
|
189
|
-
// virtual fields - returned by the database VIEW
|
|
190
|
-
/**
|
|
191
|
-
* Category name from the related Query Categories entity
|
|
192
|
-
*/
|
|
193
|
-
this.Category = null;
|
|
194
|
-
/**
|
|
195
|
-
* The AI Model name used to generate the embedding vector
|
|
196
|
-
*/
|
|
197
|
-
this.EmbeddingModel = null;
|
|
198
|
-
this._categoryPath = null;
|
|
199
|
-
this._cacheConfig = null;
|
|
200
|
-
this._fields = null;
|
|
201
|
-
this._parameters = null;
|
|
202
|
-
this._entities = null;
|
|
203
|
-
if (initData) {
|
|
204
|
-
this.copyInitData(initData);
|
|
205
|
-
// do some special handling to create class instances instead of just data objects
|
|
206
|
-
// copy the Entity Field Values
|
|
207
|
-
const f = initData.Fields || initData._Fields;
|
|
208
|
-
if (f) {
|
|
209
|
-
this._fields = []; // only set to blank array on constructor if we have fields provided, otherwise leave blank because we can later lazy load in the Fields() accessor getter method!
|
|
210
|
-
for (let j = 0; j < f.length; j++) {
|
|
211
|
-
this._fields.push(new QueryFieldInfo(f));
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
}
|
|
215
|
-
}
|
|
216
|
-
/**
|
|
217
|
-
* Gets the category information for this query, supporting hierarchical organization.
|
|
218
|
-
* @returns {QueryCategoryInfo} The category this query belongs to, or undefined if not categorized
|
|
219
|
-
*/
|
|
220
|
-
get CategoryInfo() {
|
|
221
|
-
return metadata_1.Metadata.Provider.QueryCategories.find(c => c.ID === this.CategoryID);
|
|
222
|
-
}
|
|
223
|
-
/**
|
|
224
|
-
* Builds the hierarchical category path by walking up the parent chain.
|
|
225
|
-
* @returns {string} The category path (e.g., "/MJ/AI/Agents/") or empty string if uncategorized
|
|
226
|
-
*/
|
|
227
|
-
buildCategoryPath() {
|
|
228
|
-
if (!this.CategoryID)
|
|
229
|
-
return '';
|
|
230
|
-
const pathSegments = [];
|
|
231
|
-
let currentCategory = this.CategoryInfo;
|
|
232
|
-
// Walk up the hierarchy to build the path
|
|
233
|
-
while (currentCategory) {
|
|
234
|
-
pathSegments.unshift(currentCategory.Name);
|
|
235
|
-
currentCategory = currentCategory.ParentCategoryInfo;
|
|
236
|
-
}
|
|
237
|
-
return pathSegments.length > 0 ? `/${pathSegments.join('/')}/` : '';
|
|
238
|
-
}
|
|
239
|
-
/**
|
|
240
|
-
* Checks if a user has permission to run this query based on their roles.
|
|
241
|
-
* A user can run a query if:
|
|
242
|
-
* 1. The query has no permissions defined (open to all)
|
|
243
|
-
* 2. The user has at least one role that is granted permission
|
|
244
|
-
*
|
|
245
|
-
* @param user The user to check permissions for
|
|
246
|
-
* @returns true if the user has permission to run the query
|
|
247
|
-
*/
|
|
248
|
-
UserHasRunPermissions(user) {
|
|
249
|
-
const permissions = this.Permissions;
|
|
250
|
-
// If no permissions are defined, the query is open to all
|
|
251
|
-
if (!permissions || permissions.length === 0) {
|
|
252
|
-
return true;
|
|
253
|
-
}
|
|
254
|
-
// Check if user has any of the required roles
|
|
255
|
-
if (user && user.UserRoles) {
|
|
256
|
-
for (const userRole of user.UserRoles) {
|
|
257
|
-
if (permissions.some(p => p.Role.trim().toLowerCase() === userRole.Role.trim().toLowerCase())) {
|
|
258
|
-
return true;
|
|
259
|
-
}
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
return false;
|
|
263
|
-
}
|
|
264
|
-
/**
|
|
265
|
-
* Checks if a user can run this query, considering both permissions and query status.
|
|
266
|
-
* A query can be run if:
|
|
267
|
-
* 1. The user has permission to run it (via UserHasRunPermissions)
|
|
268
|
-
* 2. The query status is 'Approved'
|
|
269
|
-
*
|
|
270
|
-
* @param user The user to check
|
|
271
|
-
* @returns true if the user can run the query right now
|
|
272
|
-
*/
|
|
273
|
-
UserCanRun(user) {
|
|
274
|
-
// First check permissions
|
|
275
|
-
if (!this.UserHasRunPermissions(user)) {
|
|
276
|
-
return false;
|
|
277
|
-
}
|
|
278
|
-
// Then check status - only approved queries can be run
|
|
279
|
-
return this.Status === 'Approved';
|
|
280
|
-
}
|
|
281
|
-
}
|
|
282
|
-
exports.QueryInfo = QueryInfo;
|
|
283
|
-
/**
|
|
284
|
-
* Organizes saved queries into categories for discovery and management, supporting folder-like organization of queries.
|
|
285
|
-
*/
|
|
286
|
-
class QueryCategoryInfo extends baseInfo_1.BaseInfo {
|
|
287
|
-
constructor(initData = null) {
|
|
288
|
-
super();
|
|
289
|
-
/**
|
|
290
|
-
* Unique identifier for the query category
|
|
291
|
-
*/
|
|
292
|
-
this.ID = null;
|
|
293
|
-
/**
|
|
294
|
-
* Name of the category for organizing queries
|
|
295
|
-
*/
|
|
296
|
-
this.Name = null;
|
|
297
|
-
/**
|
|
298
|
-
* Foreign key to parent category for hierarchical organization
|
|
299
|
-
*/
|
|
300
|
-
this.ParentID = null;
|
|
301
|
-
/**
|
|
302
|
-
* Description of what types of queries belong in this category
|
|
303
|
-
*/
|
|
304
|
-
this.Description = null;
|
|
305
|
-
/**
|
|
306
|
-
* Default cache setting for queries in this category
|
|
307
|
-
*/
|
|
308
|
-
this.DefaultCacheEnabled = false;
|
|
309
|
-
/**
|
|
310
|
-
* Default TTL in minutes for cached results of queries in this category
|
|
311
|
-
*/
|
|
312
|
-
this.DefaultCacheTTLMinutes = null;
|
|
313
|
-
/**
|
|
314
|
-
* Default maximum cache size for queries in this category
|
|
315
|
-
*/
|
|
316
|
-
this.DefaultCacheMaxSize = null;
|
|
317
|
-
/**
|
|
318
|
-
* When true, queries without cache config will inherit from this category
|
|
319
|
-
*/
|
|
320
|
-
this.CacheInheritanceEnabled = true;
|
|
321
|
-
/**
|
|
322
|
-
* Date and time when this category was created
|
|
323
|
-
*/
|
|
324
|
-
this.__mj_CreatedAt = null;
|
|
325
|
-
/**
|
|
326
|
-
* Date and time when this category was last updated
|
|
327
|
-
*/
|
|
328
|
-
this.__mj_UpdatedAt = null;
|
|
329
|
-
// virtual fields - returned by the database VIEW
|
|
330
|
-
/**
|
|
331
|
-
* Parent category name from the related category
|
|
332
|
-
*/
|
|
333
|
-
this.Parent = null;
|
|
334
|
-
if (initData) {
|
|
335
|
-
this.copyInitData(initData);
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
/**
|
|
339
|
-
* Gets the parent category information for hierarchical category organization.
|
|
340
|
-
* @returns {QueryCategoryInfo} The parent category, or undefined if this is a top-level category
|
|
341
|
-
*/
|
|
342
|
-
get ParentCategoryInfo() {
|
|
343
|
-
return metadata_1.Metadata.Provider.QueryCategories.find(c => c.ID === this.ParentID);
|
|
344
|
-
}
|
|
345
|
-
/**
|
|
346
|
-
* Gets all queries that belong to this category.
|
|
347
|
-
* @returns {QueryInfo[]} Array of queries in this category
|
|
348
|
-
*/
|
|
349
|
-
get Queries() {
|
|
350
|
-
return metadata_1.Metadata.Provider.Queries.filter(q => q.CategoryID === this.ID);
|
|
351
|
-
}
|
|
352
|
-
}
|
|
353
|
-
exports.QueryCategoryInfo = QueryCategoryInfo;
|
|
354
|
-
/**
|
|
355
|
-
* Stores field-level metadata for queries including display names, data types, and formatting rules for result presentation.
|
|
356
|
-
*/
|
|
357
|
-
class QueryFieldInfo extends baseInfo_1.BaseInfo {
|
|
358
|
-
constructor(initData = null) {
|
|
359
|
-
super();
|
|
360
|
-
/**
|
|
361
|
-
* Name of the field as it appears in query results
|
|
362
|
-
*/
|
|
363
|
-
this.Name = null;
|
|
364
|
-
/**
|
|
365
|
-
* Foreign key to the parent query
|
|
366
|
-
*/
|
|
367
|
-
this.QueryID = null;
|
|
368
|
-
/**
|
|
369
|
-
* Description of what this field represents
|
|
370
|
-
*/
|
|
371
|
-
this.Description = null;
|
|
372
|
-
/**
|
|
373
|
-
* Display order of this field in query results
|
|
374
|
-
*/
|
|
375
|
-
this.Sequence = null;
|
|
376
|
-
/**
|
|
377
|
-
* The base type, not including parameters, in SQL. For example this field would be nvarchar or decimal, and wouldn't include type parameters. The SQLFullType field provides that information.
|
|
378
|
-
*/
|
|
379
|
-
this.SQLBaseType = null;
|
|
380
|
-
/**
|
|
381
|
-
* The full SQL type for the field, for example datetime or nvarchar(10) etc.
|
|
382
|
-
*/
|
|
383
|
-
this.SQLFullType = null;
|
|
384
|
-
/**
|
|
385
|
-
* Foreign key to the source entity this field comes from
|
|
386
|
-
*/
|
|
387
|
-
this.SourceEntityID = null;
|
|
388
|
-
/**
|
|
389
|
-
* Name of the field in the source entity
|
|
390
|
-
*/
|
|
391
|
-
this.SourceFieldName = null;
|
|
392
|
-
/**
|
|
393
|
-
* Whether this field is computed rather than directly selected from a table
|
|
394
|
-
*/
|
|
395
|
-
this.IsComputed = null;
|
|
396
|
-
/**
|
|
397
|
-
* Explanation of how this computed field is calculated
|
|
398
|
-
*/
|
|
399
|
-
this.ComputationDescription = null;
|
|
400
|
-
/**
|
|
401
|
-
* Whether this field represents a summary/aggregate value
|
|
402
|
-
*/
|
|
403
|
-
this.IsSummary = null;
|
|
404
|
-
/**
|
|
405
|
-
* Description of the summary calculation
|
|
406
|
-
*/
|
|
407
|
-
this.SummaryDescription = null;
|
|
408
|
-
/**
|
|
409
|
-
* Date and time when this field was created
|
|
410
|
-
*/
|
|
411
|
-
this.__mj_CreatedAt = null;
|
|
412
|
-
/**
|
|
413
|
-
* Date and time when this field was last updated
|
|
414
|
-
*/
|
|
415
|
-
this.__mj_UpdatedAt = null;
|
|
416
|
-
/**
|
|
417
|
-
* How this field was detected: AI (automatic) or Manual (user-specified)
|
|
418
|
-
*/
|
|
419
|
-
this.DetectionMethod = 'Manual';
|
|
420
|
-
/**
|
|
421
|
-
* Confidence score (0.00-1.00) when AI detection was used for this field
|
|
422
|
-
*/
|
|
423
|
-
this.AutoDetectConfidenceScore = null;
|
|
424
|
-
// virtual fields - returned by the database VIEW
|
|
425
|
-
/**
|
|
426
|
-
* Source entity name if field is from an entity
|
|
427
|
-
*/
|
|
428
|
-
this.SourceEntity = null;
|
|
429
|
-
if (initData) {
|
|
430
|
-
this.copyInitData(initData);
|
|
431
|
-
}
|
|
432
|
-
}
|
|
433
|
-
/**
|
|
434
|
-
* Gets the entity information for the source entity this field comes from.
|
|
435
|
-
* @returns {EntityInfo} The source entity metadata, or undefined if not linked to an entity
|
|
436
|
-
*/
|
|
437
|
-
get SourceEntityInfo() {
|
|
438
|
-
return metadata_1.Metadata.Provider.Entities.find(e => e.ID === this.SourceEntityID);
|
|
439
|
-
}
|
|
440
|
-
/**
|
|
441
|
-
* Gets the query information this field belongs to.
|
|
442
|
-
* @returns {QueryInfo} The parent query metadata
|
|
443
|
-
*/
|
|
444
|
-
get QueryInfo() {
|
|
445
|
-
return metadata_1.Metadata.Provider.Queries.find(q => q.ID === this.ID);
|
|
446
|
-
}
|
|
447
|
-
}
|
|
448
|
-
exports.QueryFieldInfo = QueryFieldInfo;
|
|
449
|
-
/**
|
|
450
|
-
* Controls access to queries by defining which users and roles can run specific queries.
|
|
451
|
-
*/
|
|
452
|
-
class QueryPermissionInfo extends baseInfo_1.BaseInfo {
|
|
453
|
-
constructor(initData = null) {
|
|
454
|
-
super();
|
|
455
|
-
/**
|
|
456
|
-
* Foreign key to the query this permission applies to
|
|
457
|
-
*/
|
|
458
|
-
this.QueryID = null;
|
|
459
|
-
/**
|
|
460
|
-
*
|
|
461
|
-
*/
|
|
462
|
-
this.RoleID = null;
|
|
463
|
-
// virtual fields - returned by the database VIEW
|
|
464
|
-
/**
|
|
465
|
-
* Name of the role that has permission to run this query
|
|
466
|
-
*/
|
|
467
|
-
this.Role = null;
|
|
468
|
-
/**
|
|
469
|
-
* Query name from the related query
|
|
470
|
-
*/
|
|
471
|
-
this.Query = null;
|
|
472
|
-
if (initData) {
|
|
473
|
-
this.copyInitData(initData);
|
|
474
|
-
}
|
|
475
|
-
}
|
|
476
|
-
/**
|
|
477
|
-
* Gets the query information this permission applies to.
|
|
478
|
-
* @returns {QueryInfo} The query metadata this permission controls
|
|
479
|
-
*/
|
|
480
|
-
get QueryInfo() {
|
|
481
|
-
return metadata_1.Metadata.Provider.Queries.find(q => q.ID === this.QueryID);
|
|
482
|
-
}
|
|
483
|
-
}
|
|
484
|
-
exports.QueryPermissionInfo = QueryPermissionInfo;
|
|
485
|
-
/**
|
|
486
|
-
* Tracks which entities are involved in a given query. The Queries table stores SQL and descriptions for stored queries
|
|
487
|
-
* that can be executed and serve as examples for AI.
|
|
488
|
-
*/
|
|
489
|
-
class QueryEntityInfo extends baseInfo_1.BaseInfo {
|
|
490
|
-
constructor(initData = null) {
|
|
491
|
-
super();
|
|
492
|
-
/**
|
|
493
|
-
* References the ID of the query in the Queries table
|
|
494
|
-
*/
|
|
495
|
-
this.QueryID = null;
|
|
496
|
-
/**
|
|
497
|
-
* References the ID of the entity in the Entities table
|
|
498
|
-
*/
|
|
499
|
-
this.EntityID = null;
|
|
500
|
-
/**
|
|
501
|
-
* How this entity association was detected: AI (automatic) or Manual (user-specified)
|
|
502
|
-
*/
|
|
503
|
-
this.DetectionMethod = 'Manual';
|
|
504
|
-
/**
|
|
505
|
-
* Confidence score (0.00-1.00) when AI detection was used
|
|
506
|
-
*/
|
|
507
|
-
this.AutoDetectConfidenceScore = null;
|
|
508
|
-
/**
|
|
509
|
-
* Date and time when this association was created
|
|
510
|
-
*/
|
|
511
|
-
this.__mj_CreatedAt = null;
|
|
512
|
-
/**
|
|
513
|
-
* Date and time when this association was last updated
|
|
514
|
-
*/
|
|
515
|
-
this.__mj_UpdatedAt = null;
|
|
516
|
-
// virtual fields - returned by the database VIEW
|
|
517
|
-
/**
|
|
518
|
-
* Query name from the related query
|
|
519
|
-
*/
|
|
520
|
-
this.Query = null;
|
|
521
|
-
/**
|
|
522
|
-
* Entity name from the related entity
|
|
523
|
-
*/
|
|
524
|
-
this.Entity = null;
|
|
525
|
-
if (initData) {
|
|
526
|
-
this.copyInitData(initData);
|
|
527
|
-
}
|
|
528
|
-
}
|
|
529
|
-
/**
|
|
530
|
-
* Gets the query information this entity relationship belongs to.
|
|
531
|
-
* @returns {QueryInfo} The parent query metadata
|
|
532
|
-
*/
|
|
533
|
-
get QueryInfo() {
|
|
534
|
-
return metadata_1.Metadata.Provider.Queries.find(q => q.ID === this.QueryID);
|
|
535
|
-
}
|
|
536
|
-
/**
|
|
537
|
-
* Gets the entity information for the entity involved in this query.
|
|
538
|
-
* @returns {EntityInfo} The entity metadata
|
|
539
|
-
*/
|
|
540
|
-
get EntityInfo() {
|
|
541
|
-
return metadata_1.Metadata.Provider.Entities.find(e => e.ID === this.EntityID);
|
|
542
|
-
}
|
|
543
|
-
}
|
|
544
|
-
exports.QueryEntityInfo = QueryEntityInfo;
|
|
545
|
-
/**
|
|
546
|
-
* Stores parameter definitions for parameterized queries that use Nunjucks templates. Each parameter represents a dynamic value
|
|
547
|
-
* that can be passed when executing the query. Parameters are automatically extracted from the query template by the QueryEntityServer
|
|
548
|
-
* using LLM analysis, or can be manually defined. The combination of parameter metadata and validation filters creates a
|
|
549
|
-
* self-documenting, type-safe query execution system.
|
|
550
|
-
*/
|
|
551
|
-
class QueryParameterInfo extends baseInfo_1.BaseInfo {
|
|
552
|
-
constructor(initData = null) {
|
|
553
|
-
super();
|
|
554
|
-
/**
|
|
555
|
-
* Foreign key to the query this parameter belongs to
|
|
556
|
-
*/
|
|
557
|
-
this.QueryID = null;
|
|
558
|
-
/**
|
|
559
|
-
* The name of the parameter as it appears in the Nunjucks template (e.g., {{parameterName}})
|
|
560
|
-
*/
|
|
561
|
-
this.Name = null;
|
|
562
|
-
/**
|
|
563
|
-
* Data type of the parameter for validation and type casting
|
|
564
|
-
*/
|
|
565
|
-
this.Type = null;
|
|
566
|
-
/**
|
|
567
|
-
* Whether this parameter must be provided when executing the query
|
|
568
|
-
*/
|
|
569
|
-
this.IsRequired = false;
|
|
570
|
-
/**
|
|
571
|
-
* Default value to use when parameter is not provided
|
|
572
|
-
*/
|
|
573
|
-
this.DefaultValue = null;
|
|
574
|
-
/**
|
|
575
|
-
* Human-readable description of what this parameter is for
|
|
576
|
-
*/
|
|
577
|
-
this.Description = null;
|
|
578
|
-
/**
|
|
579
|
-
* Example value demonstrating the proper format for this parameter
|
|
580
|
-
*/
|
|
581
|
-
this.SampleValue = null;
|
|
582
|
-
/**
|
|
583
|
-
* JSON array of Nunjucks filter definitions for value transformation
|
|
584
|
-
*/
|
|
585
|
-
this.ValidationFilters = null;
|
|
586
|
-
/**
|
|
587
|
-
* How this parameter was detected: AI (automatic) or Manual (user-specified)
|
|
588
|
-
*/
|
|
589
|
-
this.DetectionMethod = 'Manual';
|
|
590
|
-
/**
|
|
591
|
-
* Confidence score (0.00-1.00) when AI detection was used
|
|
592
|
-
*/
|
|
593
|
-
this.AutoDetectConfidenceScore = null;
|
|
594
|
-
/**
|
|
595
|
-
* Date and time when this parameter was created
|
|
596
|
-
*/
|
|
597
|
-
this.__mj_CreatedAt = null;
|
|
598
|
-
/**
|
|
599
|
-
* Date and time when this parameter was last updated
|
|
600
|
-
*/
|
|
601
|
-
this.__mj_UpdatedAt = null;
|
|
602
|
-
// virtual field from view
|
|
603
|
-
/**
|
|
604
|
-
* Query name from the related query
|
|
605
|
-
*/
|
|
606
|
-
this.Query = null;
|
|
607
|
-
if (initData) {
|
|
608
|
-
this.copyInitData(initData);
|
|
609
|
-
}
|
|
610
|
-
}
|
|
611
|
-
/**
|
|
612
|
-
* Gets the query information this parameter belongs to.
|
|
613
|
-
* @returns {QueryInfo} The parent query metadata
|
|
614
|
-
*/
|
|
615
|
-
get QueryInfo() {
|
|
616
|
-
return metadata_1.Metadata.Provider.Queries.find(q => q.ID === this.QueryID);
|
|
617
|
-
}
|
|
618
|
-
/**
|
|
619
|
-
* Gets the parsed validation filters for this parameter.
|
|
620
|
-
* Parses the JSON string of filter definitions into an array of filter objects.
|
|
621
|
-
* @returns {any[]} Array of parsed filter definitions, or empty array if parsing fails
|
|
622
|
-
*/
|
|
623
|
-
get ParsedFilters() {
|
|
624
|
-
try {
|
|
625
|
-
return this.ValidationFilters ? JSON.parse(this.ValidationFilters) : [];
|
|
626
|
-
}
|
|
627
|
-
catch {
|
|
628
|
-
return [];
|
|
629
|
-
}
|
|
630
|
-
}
|
|
631
|
-
}
|
|
632
|
-
exports.QueryParameterInfo = QueryParameterInfo;
|
|
633
|
-
//# sourceMappingURL=queryInfo.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"queryInfo.js","sourceRoot":"","sources":["../../src/generic/queryInfo.ts"],"names":[],"mappings":";;;AAAA,yCAAsC;AAEtC,yCAAsC;AAItC;;;;GAIG;AACH,MAAa,SAAU,SAAQ,mBAAQ;IAqFnC;;;;;OAKG;IACH,IAAI,YAAY;QACZ,IAAI,IAAI,CAAC,aAAa,KAAK,IAAI,EAAE,CAAC;YAC9B,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,iBAAiB,EAAE,CAAC;QAClD,CAAC;QACD,OAAO,IAAI,CAAC,aAAa,CAAC;IAC9B,CAAC;IAGD;;;;;OAKG;IACH,IAAI,WAAW;QACX,4CAA4C;QAC5C,IAAI,IAAI,CAAC,YAAY,KAAK,IAAI,EAAE,CAAC;YAC7B,OAAO,IAAI,CAAC,YAAY,CAAC;QAC7B,CAAC;QAED,iDAAiD;QACjD,IAAI,IAAI,CAAC,YAAY,EAAE,CAAC;YACpB,IAAI,CAAC,YAAY,GAAG;gBAChB,OAAO,EAAE,IAAI;gBACb,UAAU,EAAE,IAAI,CAAC,eAAe,IAAI,EAAE,EAAE,wBAAwB;gBAChE,YAAY,EAAE,IAAI,CAAC,YAAY,IAAI,SAAS;gBAC5C,QAAQ,EAAE,OAAO;aACpB,CAAC;YACF,OAAO,IAAI,CAAC,YAAY,CAAC;QAC7B,CAAC;QAED,iDAAiD;QACjD,IAAI,IAAI,CAAC,YAAY,EAAE,CAAC;YACpB,MAAM,eAAe,GAAG,IAAI,CAAC,uBAAuB,EAAE,CAAC;YACvD,IAAI,eAAe,EAAE,CAAC;gBAClB,IAAI,CAAC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