bruce-models 7.1.33 → 7.1.35
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/bruce-models.es5.js +121 -7
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +116 -6
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/ann-document/ann-document.js +11 -5
- package/dist/lib/ann-document/ann-document.js.map +1 -1
- package/dist/lib/bruce-models.js +2 -1
- package/dist/lib/bruce-models.js.map +1 -1
- package/dist/lib/data-transform/data-transform.js +120 -0
- package/dist/lib/data-transform/data-transform.js.map +1 -0
- package/dist/lib/entity/entity-attribute.js +2 -0
- package/dist/lib/entity/entity-attribute.js.map +1 -1
- package/dist/types/ann-document/ann-document.d.ts +2 -1
- package/dist/types/bruce-models.d.ts +2 -1
- package/dist/types/data-transform/data-transform.d.ts +133 -0
- package/dist/types/entity/entity-attribute.d.ts +2 -1
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -2294,14 +2294,14 @@ var AnnDocument;
|
|
|
2294
2294
|
*/
|
|
2295
2295
|
function GetList(params) {
|
|
2296
2296
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2297
|
-
let { api, docType: type, req: reqParams, entityId, expandSettings, pageIndex, pageSize } = params;
|
|
2297
|
+
let { search, api, docType: type, req: reqParams, entityId, expandSettings, pageIndex, pageSize } = params;
|
|
2298
2298
|
if (!api) {
|
|
2299
2299
|
api = ENVIRONMENT.Api().GetBruceApi();
|
|
2300
2300
|
}
|
|
2301
2301
|
if (!type) {
|
|
2302
2302
|
type = "";
|
|
2303
2303
|
}
|
|
2304
|
-
const cache = api.GetCacheItem(GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize), reqParams);
|
|
2304
|
+
const cache = api.GetCacheItem(GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize, search), reqParams);
|
|
2305
2305
|
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
2306
2306
|
return cache.data;
|
|
2307
2307
|
}
|
|
@@ -2321,6 +2321,9 @@ var AnnDocument;
|
|
|
2321
2321
|
urlParams.append("PageIndex", String(pageIndex || 0));
|
|
2322
2322
|
urlParams.append("PageSize", String(pageSize || 0));
|
|
2323
2323
|
}
|
|
2324
|
+
if (search) {
|
|
2325
|
+
urlParams.append("search", search);
|
|
2326
|
+
}
|
|
2324
2327
|
const url = "documentViews" + `?${urlParams.toString()}`;
|
|
2325
2328
|
const data = yield api.GET(url, Api.PrepReqParams(reqParams));
|
|
2326
2329
|
res({
|
|
@@ -2332,7 +2335,7 @@ var AnnDocument;
|
|
|
2332
2335
|
}
|
|
2333
2336
|
}));
|
|
2334
2337
|
api.SetCacheItem({
|
|
2335
|
-
key: GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize),
|
|
2338
|
+
key: GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize, search),
|
|
2336
2339
|
value: req,
|
|
2337
2340
|
req: reqParams
|
|
2338
2341
|
});
|
|
@@ -2387,20 +2390,23 @@ var AnnDocument;
|
|
|
2387
2390
|
* @param pageSize
|
|
2388
2391
|
* @returns
|
|
2389
2392
|
*/
|
|
2390
|
-
function GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize) {
|
|
2393
|
+
function GetListCacheKey(type, entityId, expandSettings, pageIndex, pageSize, search) {
|
|
2391
2394
|
if (!expandSettings) {
|
|
2392
2395
|
expandSettings = false;
|
|
2393
2396
|
}
|
|
2394
2397
|
if (!entityId) {
|
|
2395
2398
|
entityId = "";
|
|
2396
2399
|
}
|
|
2400
|
+
if (!search) {
|
|
2401
|
+
search = "";
|
|
2402
|
+
}
|
|
2397
2403
|
if (!pageIndex) {
|
|
2398
2404
|
pageIndex = 0;
|
|
2399
2405
|
}
|
|
2400
2406
|
if (!pageSize) {
|
|
2401
2407
|
pageSize = 0;
|
|
2402
2408
|
}
|
|
2403
|
-
return Api.ECacheKey.AnnDocument + type + entityId + expandSettings + pageIndex + "_" + pageSize;
|
|
2409
|
+
return Api.ECacheKey.AnnDocument + type + entityId + expandSettings + pageIndex + "_" + pageSize + "_" + search;
|
|
2404
2410
|
}
|
|
2405
2411
|
AnnDocument.GetListCacheKey = GetListCacheKey;
|
|
2406
2412
|
})(AnnDocument || (AnnDocument = {}));
|
|
@@ -3205,6 +3211,8 @@ var EntityAttribute;
|
|
|
3205
3211
|
EType["Url"] = "Url";
|
|
3206
3212
|
// Serial number that increments for each new entity/missing-attr-value.
|
|
3207
3213
|
EType["Serial"] = "Serial";
|
|
3214
|
+
// Number ID or string hotspot-key lookup.
|
|
3215
|
+
EType["DocumentView"] = "DocumentView";
|
|
3208
3216
|
})(EType = EntityAttribute.EType || (EntityAttribute.EType = {}));
|
|
3209
3217
|
/**
|
|
3210
3218
|
* Describes url open behavior.
|
|
@@ -15939,6 +15947,112 @@ var DataLab;
|
|
|
15939
15947
|
DataLab.Run = Run;
|
|
15940
15948
|
})(DataLab || (DataLab = {}));
|
|
15941
15949
|
|
|
15950
|
+
/**
|
|
15951
|
+
* Describes the "Data Transform" concept within Nextspace.
|
|
15952
|
+
*/
|
|
15953
|
+
var DataTransform;
|
|
15954
|
+
(function (DataTransform) {
|
|
15955
|
+
/**
|
|
15956
|
+
* Supported Logic Flow diagram item types.
|
|
15957
|
+
*/
|
|
15958
|
+
let ELogicFlowDiagramItemType;
|
|
15959
|
+
(function (ELogicFlowDiagramItemType) {
|
|
15960
|
+
ELogicFlowDiagramItemType["InputValue"] = "input-value";
|
|
15961
|
+
ELogicFlowDiagramItemType["OutputValue"] = "output-value";
|
|
15962
|
+
ELogicFlowDiagramItemType["If"] = "if";
|
|
15963
|
+
ELogicFlowDiagramItemType["Formula"] = "formula";
|
|
15964
|
+
ELogicFlowDiagramItemType["Switch"] = "switch";
|
|
15965
|
+
})(ELogicFlowDiagramItemType = DataTransform.ELogicFlowDiagramItemType || (DataTransform.ELogicFlowDiagramItemType = {}));
|
|
15966
|
+
/**
|
|
15967
|
+
* Supported Logic Flow connection point types.
|
|
15968
|
+
*/
|
|
15969
|
+
let ELogicFlowConnectionPointType;
|
|
15970
|
+
(function (ELogicFlowConnectionPointType) {
|
|
15971
|
+
ELogicFlowConnectionPointType["Input"] = "input";
|
|
15972
|
+
ELogicFlowConnectionPointType["Output"] = "output";
|
|
15973
|
+
})(ELogicFlowConnectionPointType = DataTransform.ELogicFlowConnectionPointType || (DataTransform.ELogicFlowConnectionPointType = {}));
|
|
15974
|
+
/**
|
|
15975
|
+
* Supported Logic Flow connection end roles.
|
|
15976
|
+
*/
|
|
15977
|
+
let ELogicFlowConnectionEndRole;
|
|
15978
|
+
(function (ELogicFlowConnectionEndRole) {
|
|
15979
|
+
ELogicFlowConnectionEndRole["From"] = "from";
|
|
15980
|
+
ELogicFlowConnectionEndRole["To"] = "to";
|
|
15981
|
+
})(ELogicFlowConnectionEndRole = DataTransform.ELogicFlowConnectionEndRole || (DataTransform.ELogicFlowConnectionEndRole = {}));
|
|
15982
|
+
/**
|
|
15983
|
+
* Requests a suggested Logic Flow diagram from a natural-language prompt.
|
|
15984
|
+
* Route: POST v1/entityType/{entityType_id}/DataTransform/SuggestLogicFlowDiagram
|
|
15985
|
+
*/
|
|
15986
|
+
function SuggestLogicFlowDiagramByPrompt(params) {
|
|
15987
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15988
|
+
let { api, entityTypeId, prompt, model, maxNodes, dataTransformId, dataTransform, dataTransformContext, sourceDataSchema, destinationDataSchema, inputAttributes, outputAttributes, req: reqParams } = params;
|
|
15989
|
+
if (!entityTypeId) {
|
|
15990
|
+
throw ("Entity Type ID is required.");
|
|
15991
|
+
}
|
|
15992
|
+
prompt = prompt === null || prompt === void 0 ? void 0 : prompt.trim();
|
|
15993
|
+
if (!prompt) {
|
|
15994
|
+
throw ("Prompt is required.");
|
|
15995
|
+
}
|
|
15996
|
+
if (!api) {
|
|
15997
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
15998
|
+
}
|
|
15999
|
+
const body = {
|
|
16000
|
+
Prompt: prompt
|
|
16001
|
+
};
|
|
16002
|
+
if (model) {
|
|
16003
|
+
body.Model = model;
|
|
16004
|
+
}
|
|
16005
|
+
if (typeof maxNodes == "number" && !isNaN(maxNodes)) {
|
|
16006
|
+
body.MaxNodes = maxNodes;
|
|
16007
|
+
}
|
|
16008
|
+
if (typeof dataTransformId == "number" && dataTransformId > 0) {
|
|
16009
|
+
body["DataTransform.ID"] = dataTransformId;
|
|
16010
|
+
}
|
|
16011
|
+
if (dataTransform != null) {
|
|
16012
|
+
body.DataTransform = dataTransform;
|
|
16013
|
+
}
|
|
16014
|
+
if (dataTransformContext != null) {
|
|
16015
|
+
body.DataTransformContext = dataTransformContext;
|
|
16016
|
+
}
|
|
16017
|
+
if (sourceDataSchema != null) {
|
|
16018
|
+
body.SourceDataSchema = sourceDataSchema;
|
|
16019
|
+
}
|
|
16020
|
+
if (destinationDataSchema != null) {
|
|
16021
|
+
body.DestinationDataSchema = destinationDataSchema;
|
|
16022
|
+
}
|
|
16023
|
+
if (inputAttributes === null || inputAttributes === void 0 ? void 0 : inputAttributes.length) {
|
|
16024
|
+
body.InputAttributes = inputAttributes;
|
|
16025
|
+
}
|
|
16026
|
+
if (outputAttributes === null || outputAttributes === void 0 ? void 0 : outputAttributes.length) {
|
|
16027
|
+
body.OutputAttributes = outputAttributes;
|
|
16028
|
+
}
|
|
16029
|
+
const route = `v1/entityType/${Api.Encode(entityTypeId)}/DataTransform/SuggestLogicFlowDiagram`;
|
|
16030
|
+
const response = yield api.POST(route, body, Api.PrepReqParams(reqParams));
|
|
16031
|
+
let diagram = (response === null || response === void 0 ? void 0 : response.diagram)
|
|
16032
|
+
|| (response === null || response === void 0 ? void 0 : response.Diagram)
|
|
16033
|
+
|| (response === null || response === void 0 ? void 0 : response.LogicFlowDiagram)
|
|
16034
|
+
|| (response === null || response === void 0 ? void 0 : response.result)
|
|
16035
|
+
|| (response === null || response === void 0 ? void 0 : response.Result)
|
|
16036
|
+
|| response;
|
|
16037
|
+
if (typeof diagram == "string") {
|
|
16038
|
+
try {
|
|
16039
|
+
diagram = JSON.parse(diagram);
|
|
16040
|
+
}
|
|
16041
|
+
catch (e) {
|
|
16042
|
+
// Keep original shape if parse fails.
|
|
16043
|
+
}
|
|
16044
|
+
}
|
|
16045
|
+
if (!diagram || typeof diagram != "object") {
|
|
16046
|
+
throw ("No Logic Flow Diagram was returned by the suggestion API.");
|
|
16047
|
+
}
|
|
16048
|
+
return {
|
|
16049
|
+
diagram: diagram
|
|
16050
|
+
};
|
|
16051
|
+
});
|
|
16052
|
+
}
|
|
16053
|
+
DataTransform.SuggestLogicFlowDiagramByPrompt = SuggestLogicFlowDiagramByPrompt;
|
|
16054
|
+
})(DataTransform || (DataTransform = {}));
|
|
16055
|
+
|
|
15942
16056
|
var DataLabGroup;
|
|
15943
16057
|
(function (DataLabGroup) {
|
|
15944
16058
|
/**
|
|
@@ -18111,7 +18225,7 @@ var ChangeSet;
|
|
|
18111
18225
|
})(ChangeSet || (ChangeSet = {}));
|
|
18112
18226
|
|
|
18113
18227
|
// This is updated with the package.json version on build.
|
|
18114
|
-
const VERSION = "7.1.
|
|
18228
|
+
const VERSION = "7.1.35";
|
|
18115
18229
|
|
|
18116
|
-
export { VERSION, Assembly, AnnDocument, CustomForm, AbstractApi, Api, BruceApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, GeoJson, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityTypeTrigger, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, DashboardView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18230
|
+
export { VERSION, Assembly, AnnDocument, CustomForm, AbstractApi, Api, BruceApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, GeoJson, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityTypeTrigger, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, DashboardView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataTransform, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18117
18231
|
//# sourceMappingURL=bruce-models.es5.js.map
|