bruce-models 7.1.112 → 7.1.113
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 +75 -1
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +75 -1
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/workflow/workflow-item.js +74 -0
- package/dist/lib/workflow/workflow-item.js.map +1 -1
- package/dist/types/bruce-models.d.ts +1 -1
- package/dist/types/workflow/workflow-item.d.ts +45 -0
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -24396,6 +24396,39 @@ var WorkflowItem;
|
|
|
24396
24396
|
});
|
|
24397
24397
|
}
|
|
24398
24398
|
WorkflowItem.GetList = GetList;
|
|
24399
|
+
/**
|
|
24400
|
+
* Gets Workflow Item counts grouped by the Entity Types of their Subject Entities.
|
|
24401
|
+
* Parent Entity Type and Ontology breakdowns are returned only when expanded.
|
|
24402
|
+
*/
|
|
24403
|
+
function GetStatistics(params) {
|
|
24404
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
24405
|
+
if (!params) {
|
|
24406
|
+
params = {};
|
|
24407
|
+
}
|
|
24408
|
+
let { api, req } = params;
|
|
24409
|
+
if (!api) {
|
|
24410
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
24411
|
+
}
|
|
24412
|
+
const url = BuildStatisticsUrl(params);
|
|
24413
|
+
const key = GetStatisticsCacheKey(params);
|
|
24414
|
+
const cache = api.GetCacheItem(key, req);
|
|
24415
|
+
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
24416
|
+
return cache.data;
|
|
24417
|
+
}
|
|
24418
|
+
const request = new Promise((res, rej) => __awaiter(this, void 0, void 0, function* () {
|
|
24419
|
+
try {
|
|
24420
|
+
const data = yield api.GET(url, Api.PrepReqParams(req));
|
|
24421
|
+
res(ParseStatisticsResponse(data));
|
|
24422
|
+
}
|
|
24423
|
+
catch (e) {
|
|
24424
|
+
rej(e);
|
|
24425
|
+
}
|
|
24426
|
+
}));
|
|
24427
|
+
api.SetCacheItem({ key, value: request, req });
|
|
24428
|
+
return request;
|
|
24429
|
+
});
|
|
24430
|
+
}
|
|
24431
|
+
WorkflowItem.GetStatistics = GetStatistics;
|
|
24399
24432
|
function Create(params) {
|
|
24400
24433
|
var _a, _b, _c, _d, _e;
|
|
24401
24434
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -24478,12 +24511,32 @@ var WorkflowItem;
|
|
|
24478
24511
|
appendParam(q, "SlideID", params === null || params === void 0 ? void 0 : params.slideId);
|
|
24479
24512
|
appendParam(q, "EntityID", params === null || params === void 0 ? void 0 : params.entityId);
|
|
24480
24513
|
appendParam(q, "SubjectEntityID", params === null || params === void 0 ? void 0 : params.subjectEntityId);
|
|
24514
|
+
appendParam(q, "SubjectEntityTypeID", params === null || params === void 0 ? void 0 : params.subjectEntityTypeId);
|
|
24515
|
+
appendParam(q, "SubjectParentEntityTypeID", params === null || params === void 0 ? void 0 : params.subjectParentEntityTypeId);
|
|
24516
|
+
appendParam(q, "SubjectOntologyID", params === null || params === void 0 ? void 0 : params.subjectOntologyId);
|
|
24481
24517
|
appendParam(q, "Description", params === null || params === void 0 ? void 0 : params.description);
|
|
24482
24518
|
appendParam(q, "Search", params === null || params === void 0 ? void 0 : params.search);
|
|
24483
24519
|
const qs = q.toString();
|
|
24484
24520
|
return qs ? `workflow/itemsquery?${qs}` : "workflow/itemsquery";
|
|
24485
24521
|
}
|
|
24486
24522
|
WorkflowItem.BuildListUrl = BuildListUrl;
|
|
24523
|
+
function BuildStatisticsUrl(params) {
|
|
24524
|
+
const q = new URLSearchParams();
|
|
24525
|
+
appendParam(q, "itemtypeid", params === null || params === void 0 ? void 0 : params.itemTypeId);
|
|
24526
|
+
appendParam(q, "statusid", params === null || params === void 0 ? void 0 : params.statusId);
|
|
24527
|
+
appendParam(q, "queueid", params === null || params === void 0 ? void 0 : params.queueId);
|
|
24528
|
+
const expand = [];
|
|
24529
|
+
if (params === null || params === void 0 ? void 0 : params.expandParentEntityTypes) {
|
|
24530
|
+
expand.push("ParentEntityTypes");
|
|
24531
|
+
}
|
|
24532
|
+
if (params === null || params === void 0 ? void 0 : params.expandOntologies) {
|
|
24533
|
+
expand.push("Ontologies");
|
|
24534
|
+
}
|
|
24535
|
+
appendParam(q, "Expand", expand);
|
|
24536
|
+
const qs = q.toString();
|
|
24537
|
+
return qs ? `workflow/items/statistics?${qs}` : "workflow/items/statistics";
|
|
24538
|
+
}
|
|
24539
|
+
WorkflowItem.BuildStatisticsUrl = BuildStatisticsUrl;
|
|
24487
24540
|
function ParseResponse(response) {
|
|
24488
24541
|
var _a, _b, _c, _d;
|
|
24489
24542
|
const parsed = parseObject$5(response);
|
|
@@ -24509,6 +24562,23 @@ var WorkflowItem;
|
|
|
24509
24562
|
};
|
|
24510
24563
|
}
|
|
24511
24564
|
WorkflowItem.ParseListResponse = ParseListResponse;
|
|
24565
|
+
function ParseStatisticsResponse(response) {
|
|
24566
|
+
var _a, _b;
|
|
24567
|
+
const parsed = parseObject$5(response);
|
|
24568
|
+
const parsedResult = (_a = parseObject$5(parsed === null || parsed === void 0 ? void 0 : parsed.Result)) !== null && _a !== void 0 ? _a : parsed === null || parsed === void 0 ? void 0 : parsed.Result;
|
|
24569
|
+
const source = (_b = parsedResult !== null && parsedResult !== void 0 ? parsedResult : parsed) !== null && _b !== void 0 ? _b : {};
|
|
24570
|
+
const result = {
|
|
24571
|
+
EntityTypes: Array.isArray(source.EntityTypes) ? source.EntityTypes : []
|
|
24572
|
+
};
|
|
24573
|
+
if (Array.isArray(source.ParentEntityTypes)) {
|
|
24574
|
+
result.ParentEntityTypes = source.ParentEntityTypes;
|
|
24575
|
+
}
|
|
24576
|
+
if (Array.isArray(source.Ontologies)) {
|
|
24577
|
+
result.Ontologies = source.Ontologies;
|
|
24578
|
+
}
|
|
24579
|
+
return result;
|
|
24580
|
+
}
|
|
24581
|
+
WorkflowItem.ParseStatisticsResponse = ParseStatisticsResponse;
|
|
24512
24582
|
function GetCacheKey(id) {
|
|
24513
24583
|
return `${Api.ECacheKey.WorkflowItem}${Api.ECacheKey.Id}${id}`;
|
|
24514
24584
|
}
|
|
@@ -24517,6 +24587,10 @@ var WorkflowItem;
|
|
|
24517
24587
|
return `${Api.ECacheKey.WorkflowItem}${Api.ECacheKey.ListId}${BuildListUrl(params)}`;
|
|
24518
24588
|
}
|
|
24519
24589
|
WorkflowItem.GetListCacheKey = GetListCacheKey;
|
|
24590
|
+
function GetStatisticsCacheKey(params) {
|
|
24591
|
+
return `${Api.ECacheKey.WorkflowItem}${Api.ECacheKey.ListId}${BuildStatisticsUrl(params)}`;
|
|
24592
|
+
}
|
|
24593
|
+
WorkflowItem.GetStatisticsCacheKey = GetStatisticsCacheKey;
|
|
24520
24594
|
})(WorkflowItem || (WorkflowItem = {}));
|
|
24521
24595
|
function appendParam(q, key, value) {
|
|
24522
24596
|
if (value == null || value === "") {
|
|
@@ -25035,7 +25109,7 @@ function getFirstWrappedArray(data, wrapperKeys) {
|
|
|
25035
25109
|
}
|
|
25036
25110
|
|
|
25037
25111
|
// This is updated with the package.json version on build.
|
|
25038
|
-
const VERSION = "7.1.
|
|
25112
|
+
const VERSION = "7.1.113";
|
|
25039
25113
|
|
|
25040
25114
|
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 };
|
|
25041
25115
|
//# sourceMappingURL=bruce-models.es5.js.map
|