bruce-models 7.1.108 → 7.1.109
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 +154 -9
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +149 -8
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/api/api.js +1 -0
- package/dist/lib/api/api.js.map +1 -1
- package/dist/lib/bruce-models.js +2 -1
- package/dist/lib/bruce-models.js.map +1 -1
- package/dist/lib/entity/entity-type-source.js +123 -0
- package/dist/lib/entity/entity-type-source.js.map +1 -0
- package/dist/lib/markup/markup.js +11 -0
- package/dist/lib/markup/markup.js.map +1 -1
- package/dist/lib/workflow/workflow-schedule.js +31 -7
- package/dist/lib/workflow/workflow-schedule.js.map +1 -1
- package/dist/types/api/api.d.ts +1 -0
- package/dist/types/bruce-models.d.ts +2 -1
- package/dist/types/entity/entity-type-source.d.ts +93 -0
- package/dist/types/markup/markup.d.ts +8 -0
- package/dist/types/workflow/workflow-schedule.d.ts +14 -5
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -40,6 +40,7 @@ var Api;
|
|
|
40
40
|
ECacheKey["Entity"] = "entity";
|
|
41
41
|
ECacheKey["EntityType"] = "entitytype";
|
|
42
42
|
ECacheKey["EntityTypeRelation"] = "entitytyperelation";
|
|
43
|
+
ECacheKey["EntityTypeSource"] = "entitytypesource";
|
|
43
44
|
ECacheKey["Ontology"] = "ontology";
|
|
44
45
|
ECacheKey["EntityTypeTrigger"] = "entitytypetrigger";
|
|
45
46
|
ECacheKey["DataFeed"] = "datafeed";
|
|
@@ -17237,6 +17238,115 @@ var EntityTypeRelation;
|
|
|
17237
17238
|
}
|
|
17238
17239
|
})(EntityTypeRelation || (EntityTypeRelation = {}));
|
|
17239
17240
|
|
|
17241
|
+
/**
|
|
17242
|
+
* Describes the "Entity Type Source" concept within Nextspace.
|
|
17243
|
+
*/
|
|
17244
|
+
var EntityTypeSource;
|
|
17245
|
+
(function (EntityTypeSource) {
|
|
17246
|
+
let EKind;
|
|
17247
|
+
(function (EKind) {
|
|
17248
|
+
// Deprecated. Behaves as Entity.
|
|
17249
|
+
EKind["Unset"] = "UNSET";
|
|
17250
|
+
// Creates or updates Entities matching the key in the Data Mapping.
|
|
17251
|
+
EKind["Entity"] = "ENTITY";
|
|
17252
|
+
// Overlays attributes onto Entities that already exist.
|
|
17253
|
+
EKind["Attribute"] = "ATTRIBUTE";
|
|
17254
|
+
// On demand only. The Entity's Outline carries a URL to fetch its rows.
|
|
17255
|
+
EKind["Reference"] = "REFERENCE";
|
|
17256
|
+
})(EKind = EntityTypeSource.EKind || (EntityTypeSource.EKind = {}));
|
|
17257
|
+
/**
|
|
17258
|
+
* Gets a single Entity Type Source record, including its Data Mapping.
|
|
17259
|
+
*/
|
|
17260
|
+
function Get(params) {
|
|
17261
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
17262
|
+
let { api, entityTypeId, entityTypeSourceId, req } = params;
|
|
17263
|
+
if (!entityTypeId) {
|
|
17264
|
+
throw ("Entity Type ID is required.");
|
|
17265
|
+
}
|
|
17266
|
+
if (!entityTypeSourceId) {
|
|
17267
|
+
throw ("Entity Type Source ID is required.");
|
|
17268
|
+
}
|
|
17269
|
+
if (!api) {
|
|
17270
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
17271
|
+
}
|
|
17272
|
+
const key = GetCacheKey(entityTypeId, entityTypeSourceId);
|
|
17273
|
+
const cache = api.GetCacheItem(key, req);
|
|
17274
|
+
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
17275
|
+
return cache.data;
|
|
17276
|
+
}
|
|
17277
|
+
const prom = new Promise((res, rej) => __awaiter(this, void 0, void 0, function* () {
|
|
17278
|
+
try {
|
|
17279
|
+
const data = yield api.GET(`entityType/${entityTypeId}/source/${entityTypeSourceId}`, Api.PrepReqParams(req));
|
|
17280
|
+
res({
|
|
17281
|
+
source: data
|
|
17282
|
+
});
|
|
17283
|
+
}
|
|
17284
|
+
catch (e) {
|
|
17285
|
+
rej(e);
|
|
17286
|
+
}
|
|
17287
|
+
}));
|
|
17288
|
+
api.SetCacheItem({
|
|
17289
|
+
key,
|
|
17290
|
+
value: prom,
|
|
17291
|
+
req
|
|
17292
|
+
});
|
|
17293
|
+
return prom;
|
|
17294
|
+
});
|
|
17295
|
+
}
|
|
17296
|
+
EntityTypeSource.Get = Get;
|
|
17297
|
+
/**
|
|
17298
|
+
* Gets the Entity Type Source records feeding the specified Entity Type.
|
|
17299
|
+
*/
|
|
17300
|
+
function GetList(params) {
|
|
17301
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
17302
|
+
let { api, entityTypeId, req } = params;
|
|
17303
|
+
if (!entityTypeId) {
|
|
17304
|
+
throw ("Entity Type ID is required.");
|
|
17305
|
+
}
|
|
17306
|
+
if (!api) {
|
|
17307
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
17308
|
+
}
|
|
17309
|
+
const key = GetListCacheKey(entityTypeId);
|
|
17310
|
+
const cache = api.GetCacheItem(key, req);
|
|
17311
|
+
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
17312
|
+
return cache.data;
|
|
17313
|
+
}
|
|
17314
|
+
const prom = new Promise((res, rej) => __awaiter(this, void 0, void 0, function* () {
|
|
17315
|
+
try {
|
|
17316
|
+
const data = yield api.GET(`entityType/${entityTypeId}/sources`, Api.PrepReqParams(req));
|
|
17317
|
+
res({
|
|
17318
|
+
sources: Array.isArray(data === null || data === void 0 ? void 0 : data.Items) ? data.Items : []
|
|
17319
|
+
});
|
|
17320
|
+
}
|
|
17321
|
+
catch (e) {
|
|
17322
|
+
rej(e);
|
|
17323
|
+
}
|
|
17324
|
+
}));
|
|
17325
|
+
api.SetCacheItem({
|
|
17326
|
+
key,
|
|
17327
|
+
value: prom,
|
|
17328
|
+
req
|
|
17329
|
+
});
|
|
17330
|
+
return prom;
|
|
17331
|
+
});
|
|
17332
|
+
}
|
|
17333
|
+
EntityTypeSource.GetList = GetList;
|
|
17334
|
+
/**
|
|
17335
|
+
* Returns cache identifier for an Entity Type Source record.
|
|
17336
|
+
*/
|
|
17337
|
+
function GetCacheKey(entityTypeId, entityTypeSourceId) {
|
|
17338
|
+
return Api.ECacheKey.EntityTypeSource + Api.ECacheKey.Id + entityTypeId + Api.ECacheKey.Id + entityTypeSourceId;
|
|
17339
|
+
}
|
|
17340
|
+
EntityTypeSource.GetCacheKey = GetCacheKey;
|
|
17341
|
+
/**
|
|
17342
|
+
* Returns cache identifier for the list of Entity Type Source records for an Entity Type.
|
|
17343
|
+
*/
|
|
17344
|
+
function GetListCacheKey(entityTypeId) {
|
|
17345
|
+
return Api.ECacheKey.EntityTypeSource + Api.ECacheKey.Id + entityTypeId;
|
|
17346
|
+
}
|
|
17347
|
+
EntityTypeSource.GetListCacheKey = GetListCacheKey;
|
|
17348
|
+
})(EntityTypeSource || (EntityTypeSource = {}));
|
|
17349
|
+
|
|
17240
17350
|
/**
|
|
17241
17351
|
* Describes the "BruceEntityTypeTrigger" concept within Nextspace.
|
|
17242
17352
|
* These records define trigger rules that are scoped to an Entity Type.
|
|
@@ -18643,6 +18753,17 @@ var Markup;
|
|
|
18643
18753
|
EAnchorDivSide["BottomRight"] = "BottomRight";
|
|
18644
18754
|
EAnchorDivSide["TopRight"] = "TopRight";
|
|
18645
18755
|
})(EAnchorDivSide = Div.EAnchorDivSide || (Div.EAnchorDivSide = {}));
|
|
18756
|
+
/**
|
|
18757
|
+
* Whether a div's height is authored or taken from what is in it.
|
|
18758
|
+
*/
|
|
18759
|
+
let ECellSizing;
|
|
18760
|
+
(function (ECellSizing) {
|
|
18761
|
+
// The stored height is the height. Content that does not fit is clipped.
|
|
18762
|
+
ECellSizing["Fixed"] = "FIXED";
|
|
18763
|
+
// The content decides the height, with the stored height as a floor.
|
|
18764
|
+
// The stored height is kept up to date from what was actually laid out.
|
|
18765
|
+
ECellSizing["Auto"] = "AUTO";
|
|
18766
|
+
})(ECellSizing = Div.ECellSizing || (Div.ECellSizing = {}));
|
|
18646
18767
|
// Describes expected content of a row cell.
|
|
18647
18768
|
let EItemType;
|
|
18648
18769
|
(function (EItemType) {
|
|
@@ -24390,14 +24511,15 @@ var WorkflowSchedule;
|
|
|
24390
24511
|
if (!api) {
|
|
24391
24512
|
api = ENVIRONMENT.Api().GetBruceApi();
|
|
24392
24513
|
}
|
|
24393
|
-
const
|
|
24514
|
+
const url = BuildListUrl(params);
|
|
24515
|
+
const key = GetListCacheKey(params);
|
|
24394
24516
|
const cache = api.GetCacheItem(key, req);
|
|
24395
24517
|
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
24396
24518
|
return cache.data;
|
|
24397
24519
|
}
|
|
24398
24520
|
const request = new Promise((res, rej) => __awaiter(this, void 0, void 0, function* () {
|
|
24399
24521
|
try {
|
|
24400
|
-
const data = yield api.GET(
|
|
24522
|
+
const data = yield api.GET(url, Api.PrepReqParams(req));
|
|
24401
24523
|
res({ workflowSchedules: ParseListResponse(data) });
|
|
24402
24524
|
}
|
|
24403
24525
|
catch (e) {
|
|
@@ -24421,7 +24543,7 @@ var WorkflowSchedule;
|
|
|
24421
24543
|
const id = workflowSchedule.ID && workflowSchedule.ID > 0 ? workflowSchedule.ID : 0;
|
|
24422
24544
|
const data = yield api.POST(`workflow/schedule/${id}`, workflowSchedule, Api.PrepReqParams(req));
|
|
24423
24545
|
const parsed = ParseResponse(data);
|
|
24424
|
-
api.Cache.
|
|
24546
|
+
api.Cache.RemoveByStartsWith(Api.ECacheKey.WorkflowSchedule);
|
|
24425
24547
|
if (id > 0) {
|
|
24426
24548
|
api.Cache.Remove(GetCacheKey(id));
|
|
24427
24549
|
}
|
|
@@ -24443,12 +24565,20 @@ var WorkflowSchedule;
|
|
|
24443
24565
|
api = ENVIRONMENT.Api().GetBruceApi();
|
|
24444
24566
|
}
|
|
24445
24567
|
yield api.DELETE(`workflow/schedule/${workflowScheduleId}`, Api.PrepReqParams(req));
|
|
24446
|
-
api.Cache.
|
|
24447
|
-
api.Cache.Remove(GetListCacheKey());
|
|
24568
|
+
api.Cache.RemoveByStartsWith(Api.ECacheKey.WorkflowSchedule);
|
|
24448
24569
|
api.Cache.RemoveByStartsWith(Api.ECacheKey.WorkflowItem);
|
|
24449
24570
|
});
|
|
24450
24571
|
}
|
|
24451
24572
|
WorkflowSchedule.Delete = Delete;
|
|
24573
|
+
function BuildListUrl(params) {
|
|
24574
|
+
var _a, _b, _c, _d;
|
|
24575
|
+
const q = new URLSearchParams();
|
|
24576
|
+
appendParam$1(q, "Entity.InternalID", (_b = (_a = params === null || params === void 0 ? void 0 : params.entityInternalId) !== null && _a !== void 0 ? _a : params === null || params === void 0 ? void 0 : params["Entity.InternalID"]) !== null && _b !== void 0 ? _b : params === null || params === void 0 ? void 0 : params.EntityInternalID);
|
|
24577
|
+
appendParam$1(q, "Entity.ID", (_d = (_c = params === null || params === void 0 ? void 0 : params.entityId) !== null && _c !== void 0 ? _c : params === null || params === void 0 ? void 0 : params["Entity.ID"]) !== null && _d !== void 0 ? _d : params === null || params === void 0 ? void 0 : params.EntityID);
|
|
24578
|
+
const qs = q.toString();
|
|
24579
|
+
return qs ? `workflow/schedules?${qs}` : "workflow/schedules";
|
|
24580
|
+
}
|
|
24581
|
+
WorkflowSchedule.BuildListUrl = BuildListUrl;
|
|
24452
24582
|
function ParseResponse(response) {
|
|
24453
24583
|
var _a, _b, _c, _d;
|
|
24454
24584
|
const parsed = parseObject$6(response);
|
|
@@ -24477,11 +24607,26 @@ var WorkflowSchedule;
|
|
|
24477
24607
|
return `${Api.ECacheKey.WorkflowSchedule}${Api.ECacheKey.Id}${id}`;
|
|
24478
24608
|
}
|
|
24479
24609
|
WorkflowSchedule.GetCacheKey = GetCacheKey;
|
|
24480
|
-
function GetListCacheKey() {
|
|
24481
|
-
|
|
24610
|
+
function GetListCacheKey(params) {
|
|
24611
|
+
const url = BuildListUrl(params);
|
|
24612
|
+
return url === "workflow/schedules"
|
|
24613
|
+
? Api.ECacheKey.WorkflowSchedule
|
|
24614
|
+
: `${Api.ECacheKey.WorkflowSchedule}${Api.ECacheKey.ListId}${url}`;
|
|
24482
24615
|
}
|
|
24483
24616
|
WorkflowSchedule.GetListCacheKey = GetListCacheKey;
|
|
24484
24617
|
})(WorkflowSchedule || (WorkflowSchedule = {}));
|
|
24618
|
+
function appendParam$1(q, key, value) {
|
|
24619
|
+
if (value == null || value === "") {
|
|
24620
|
+
return;
|
|
24621
|
+
}
|
|
24622
|
+
if (Array.isArray(value)) {
|
|
24623
|
+
if (value.length) {
|
|
24624
|
+
q.append(key, value.join(","));
|
|
24625
|
+
}
|
|
24626
|
+
return;
|
|
24627
|
+
}
|
|
24628
|
+
q.append(key, String(value));
|
|
24629
|
+
}
|
|
24485
24630
|
function parseObject$6(data) {
|
|
24486
24631
|
if (data == null || data == undefined) {
|
|
24487
24632
|
return null;
|
|
@@ -24811,7 +24956,7 @@ function getFirstWrappedArray(data, wrapperKeys) {
|
|
|
24811
24956
|
}
|
|
24812
24957
|
|
|
24813
24958
|
// This is updated with the package.json version on build.
|
|
24814
|
-
const VERSION = "7.1.
|
|
24959
|
+
const VERSION = "7.1.109";
|
|
24815
24960
|
|
|
24816
|
-
export { VERSION, Account, AccountAudit, AccountConcept, AccountFeatures, AccountInvite, AccountLimits, AccountTemplate, AccountType, AnnDocument, AbstractApi, Api, ApiGetters, BruceApi, GlobalApi, GuardianApi, Assembly, Calculator, ChangeSet, ClientFile, ClientFileValueMap, Bounds, BruceEvent, BruceVariable, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, RequestLane, GeoJson, Geometry, LRUCache, UTC, CustomForm, DashboardView, DataFeed, DataLab, DataLabGroup, DataSource, DataTransform, Comment, Entity, EntityAttachment, EntityAttachmentType, EntityAttribute, EntityComment, EntityCoords, EntityHistoricData, EntityLink, EntityLod, EntityLodCategory, EntityRelation, EntityRelationType, EntitySource, EntityTableView, EntityTag, EntityType, EntityTypeRelation, EntityTypeTrigger, Ontology, OntologyDocument, ENVIRONMENT, ExportBrz, ExportCsv, ExportNsx, ExportUsd, Hexbin, ImportAssembly, ImportCad, ImportCsv, ImportGeoJson, ImportJson, ImportKml, ImportLcc, ImportTif, ImportedFile, Uploader, Markup, UIMarkup, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, Plugin, PluginAiTool, ProgramKey, MenuItem, ProjectView, ProjectViewBookmark, ProjectViewBookmarkGroup, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewLegacyTile, ProjectViewTile, ZoomControl, Scenario, HostingLocation, MessageBroker, PendingAction, RecordChangeFeed, Style, Tileset, Tracking, Permission, Session, User, UserGroup, UserMfaMethod, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, WorkflowItem, WorkflowSchedule, WorkflowType, WorkflowItemType };
|
|
24961
|
+
export { VERSION, Account, AccountAudit, AccountConcept, AccountFeatures, AccountInvite, AccountLimits, AccountTemplate, AccountType, AnnDocument, AbstractApi, Api, ApiGetters, BruceApi, GlobalApi, GuardianApi, Assembly, Calculator, ChangeSet, ClientFile, ClientFileValueMap, Bounds, BruceEvent, BruceVariable, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, RequestLane, GeoJson, Geometry, LRUCache, UTC, CustomForm, DashboardView, DataFeed, DataLab, DataLabGroup, DataSource, DataTransform, Comment, Entity, EntityAttachment, EntityAttachmentType, EntityAttribute, EntityComment, EntityCoords, EntityHistoricData, EntityLink, EntityLod, EntityLodCategory, EntityRelation, EntityRelationType, EntitySource, EntityTableView, EntityTag, EntityType, EntityTypeRelation, EntityTypeSource, EntityTypeTrigger, Ontology, OntologyDocument, ENVIRONMENT, ExportBrz, ExportCsv, ExportNsx, ExportUsd, Hexbin, ImportAssembly, ImportCad, ImportCsv, ImportGeoJson, ImportJson, ImportKml, ImportLcc, ImportTif, ImportedFile, Uploader, Markup, UIMarkup, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, Plugin, PluginAiTool, ProgramKey, MenuItem, ProjectView, ProjectViewBookmark, ProjectViewBookmarkGroup, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewLegacyTile, ProjectViewTile, ZoomControl, Scenario, HostingLocation, MessageBroker, PendingAction, RecordChangeFeed, Style, Tileset, Tracking, Permission, Session, User, UserGroup, UserMfaMethod, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, WorkflowItem, WorkflowSchedule, WorkflowType, WorkflowItemType };
|
|
24817
24962
|
//# sourceMappingURL=bruce-models.es5.js.map
|