bruce-models 7.1.127 → 7.1.128
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 +40 -10
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +40 -10
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/user/user.js +39 -9
- package/dist/lib/user/user.js.map +1 -1
- package/dist/types/bruce-models.d.ts +1 -1
- package/dist/types/user/user.d.ts +8 -2
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -24000,9 +24000,10 @@ var User;
|
|
|
24000
24000
|
* @param accountId
|
|
24001
24001
|
* @param exclusive
|
|
24002
24002
|
* @param search
|
|
24003
|
+
* @param expand
|
|
24003
24004
|
* @returns
|
|
24004
24005
|
*/
|
|
24005
|
-
function GetListCacheKey(sessionId, accountId, exclusive, search) {
|
|
24006
|
+
function GetListCacheKey(sessionId, accountId, exclusive, search, expand) {
|
|
24006
24007
|
if (!exclusive) {
|
|
24007
24008
|
exclusive = false;
|
|
24008
24009
|
}
|
|
@@ -24015,7 +24016,10 @@ var User;
|
|
|
24015
24016
|
if (!accountId) {
|
|
24016
24017
|
accountId = "";
|
|
24017
24018
|
}
|
|
24018
|
-
|
|
24019
|
+
if (!expand) {
|
|
24020
|
+
expand = "";
|
|
24021
|
+
}
|
|
24022
|
+
return Api.ECacheKey.User + Api.ECacheKey.Account + Api.ECacheKey.Id + accountId + Api.ECacheKey.Id + exclusive + Api.ECacheKey.Id + search + Api.ECacheKey.Session + Api.ECacheKey.Id + sessionId + Api.ECacheKey.Id + expand;
|
|
24019
24023
|
}
|
|
24020
24024
|
LoginUser.GetListCacheKey = GetListCacheKey;
|
|
24021
24025
|
/**
|
|
@@ -24042,15 +24046,16 @@ var User;
|
|
|
24042
24046
|
*/
|
|
24043
24047
|
function GetList(params) {
|
|
24044
24048
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24045
|
-
let { api, accountId, exclusive, req: reqParams, search } = params;
|
|
24049
|
+
let { api, accountId, exclusive, req: reqParams, search, expandLastAccess } = params;
|
|
24046
24050
|
if (!api) {
|
|
24047
24051
|
api = ENVIRONMENT.Api().GetGuardianApi();
|
|
24048
24052
|
}
|
|
24049
24053
|
if (!exclusive) {
|
|
24050
24054
|
exclusive = false;
|
|
24051
24055
|
}
|
|
24056
|
+
const expand = GetListExpand(expandLastAccess);
|
|
24052
24057
|
const sessionId = api.GetSessionId();
|
|
24053
|
-
const cacheKey = GetListCacheKey(sessionId, accountId, exclusive, search);
|
|
24058
|
+
const cacheKey = GetListCacheKey(sessionId, accountId, exclusive, search, expand);
|
|
24054
24059
|
const cache = exclusive ? null : api.GetCacheItem(cacheKey, reqParams);
|
|
24055
24060
|
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
24056
24061
|
return cache.data;
|
|
@@ -24067,6 +24072,9 @@ var User;
|
|
|
24067
24072
|
if (exclusive) {
|
|
24068
24073
|
urlParams.append("allExcludingClientAccount", "true");
|
|
24069
24074
|
}
|
|
24075
|
+
if (expand) {
|
|
24076
|
+
urlParams.append("Expand", expand);
|
|
24077
|
+
}
|
|
24070
24078
|
const data = yield api.GET(`v3/users?${urlParams.toString()}`, reqParams);
|
|
24071
24079
|
res({
|
|
24072
24080
|
users: data.Items
|
|
@@ -24242,16 +24250,20 @@ var User;
|
|
|
24242
24250
|
* }
|
|
24243
24251
|
* @param sessionId
|
|
24244
24252
|
* @param accountId
|
|
24253
|
+
* @param expand
|
|
24245
24254
|
* @returns
|
|
24246
24255
|
*/
|
|
24247
|
-
function GetListCacheKey(sessionId, accountId) {
|
|
24256
|
+
function GetListCacheKey(sessionId, accountId, expand) {
|
|
24248
24257
|
if (!sessionId) {
|
|
24249
24258
|
sessionId = "anonymous";
|
|
24250
24259
|
}
|
|
24251
24260
|
if (!accountId) {
|
|
24252
24261
|
accountId = "";
|
|
24253
24262
|
}
|
|
24254
|
-
|
|
24263
|
+
if (!expand) {
|
|
24264
|
+
expand = "";
|
|
24265
|
+
}
|
|
24266
|
+
return Api.ECacheKey.AccessToken + Api.ECacheKey.Account + Api.ECacheKey.Id + accountId + Api.ECacheKey.Session + Api.ECacheKey.Id + sessionId + Api.ECacheKey.Id + expand;
|
|
24255
24267
|
}
|
|
24256
24268
|
AccessToken.GetListCacheKey = GetListCacheKey;
|
|
24257
24269
|
/**
|
|
@@ -24261,18 +24273,26 @@ var User;
|
|
|
24261
24273
|
*/
|
|
24262
24274
|
function GetList(params) {
|
|
24263
24275
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24264
|
-
let { api, accountId, req: reqParams } = params;
|
|
24276
|
+
let { api, accountId, expandLastAccess, req: reqParams } = params;
|
|
24277
|
+
if (!accountId) {
|
|
24278
|
+
throw ("Account ID is required.");
|
|
24279
|
+
}
|
|
24265
24280
|
if (!api) {
|
|
24266
24281
|
api = ENVIRONMENT.Api().GetGuardianApi();
|
|
24267
24282
|
}
|
|
24268
|
-
const
|
|
24283
|
+
const expand = GetListExpand(expandLastAccess);
|
|
24284
|
+
const cacheKey = GetListCacheKey(api.GetSessionId(), accountId, expand);
|
|
24269
24285
|
const cache = api.GetCacheItem(cacheKey, reqParams);
|
|
24270
24286
|
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
24271
24287
|
return cache.data;
|
|
24272
24288
|
}
|
|
24273
24289
|
const req = new Promise((res, rej) => __awaiter(this, void 0, void 0, function* () {
|
|
24274
24290
|
try {
|
|
24275
|
-
|
|
24291
|
+
let url = `v3/account/${accountId}/accessTokens`;
|
|
24292
|
+
if (expand) {
|
|
24293
|
+
url += "?Expand=" + expand;
|
|
24294
|
+
}
|
|
24295
|
+
const data = yield api.GET(url, reqParams);
|
|
24276
24296
|
res({
|
|
24277
24297
|
users: data.Items
|
|
24278
24298
|
});
|
|
@@ -24335,6 +24355,16 @@ var User;
|
|
|
24335
24355
|
}
|
|
24336
24356
|
AccessToken.Create = Create;
|
|
24337
24357
|
})(AccessToken = User$$1.AccessToken || (User$$1.AccessToken = {}));
|
|
24358
|
+
/**
|
|
24359
|
+
* Builds the Expand value for a user list, or undefined to leave Guardian's default.
|
|
24360
|
+
* An explicit Expand replaces the default permission expansion, so it is asked for again.
|
|
24361
|
+
*/
|
|
24362
|
+
function GetListExpand(expandLastAccess) {
|
|
24363
|
+
if (!expandLastAccess) {
|
|
24364
|
+
return undefined;
|
|
24365
|
+
}
|
|
24366
|
+
return "permission,lastAccess";
|
|
24367
|
+
}
|
|
24338
24368
|
/**
|
|
24339
24369
|
* Updates the password for a user by supplying the existing and new password.
|
|
24340
24370
|
* @param params
|
|
@@ -25869,7 +25899,7 @@ function getFirstWrappedArray(data, wrapperKeys) {
|
|
|
25869
25899
|
}
|
|
25870
25900
|
|
|
25871
25901
|
// This is updated with the package.json version on build.
|
|
25872
|
-
const VERSION = "7.1.
|
|
25902
|
+
const VERSION = "7.1.128";
|
|
25873
25903
|
|
|
25874
25904
|
export { VERSION, Account, AccountAudit, AccountConcept, AccountFeatures, AccountInvite, AccountLimits, AccountTemplate, AccountType, AnnDocument, AbstractApi, Api, ApiGetters, BruceApi, GlobalApi, GuardianApi, Assembly, Calculator, ChangeSet, ClientFile, ClientFileFolder, 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, NavigatorChatClient, NAVIGATOR_CHAT_RPC_METHOD_CHAT_EVENT, NAVIGATOR_CHAT_RPC_METHOD_SERVER_READY, NAVIGATOR_CHAT_RPC_METHOD_SERVER_READY_ACK, NAVIGATOR_CHAT_RPC_METHOD_TOOLS_CALL, NAVIGATOR_CHAT_RPC_METHOD_TOOL_RESPONSE, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NAVIGATOR_CHAT_EVENT_PRESENTATION_PLAN_APPLIED, NAVIGATOR_CHAT_LEGACY_EVENT_SESSION_CLEARED, NAVIGATOR_CHAT_STEP_TRACKING_UPDATE, NAVIGATOR_CHAT_STEP_JOB_COMPLETE, NAVIGATOR_CHAT_STEP_QUEUED_INPUT, NAVIGATOR_CHAT_STEP_LLM_CONTEXT, NAVIGATOR_CHAT_TRACKING_KIND_PRESENTATION_PLAN, NAVIGATOR_CHAT_CANCELLED_JOB_STATUSES, isNavigatorChatClientEventType, isNavigatorChatCancelledJobStatus, buildNavigatorChatEventMessage, parseNavigatorChatServerMessage, 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 };
|
|
25875
25905
|
//# sourceMappingURL=bruce-models.es5.js.map
|