bruce-models 6.5.2 → 6.5.3
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 +20 -5
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +20 -5
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/user/user.js +19 -4
- 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 +3 -1
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -12822,14 +12822,14 @@ var User;
|
|
|
12822
12822
|
*/
|
|
12823
12823
|
function Get(params) {
|
|
12824
12824
|
return __awaiter(this, void 0, void 0, function* () {
|
|
12825
|
-
let { api, userId: id, accountId, req: reqParams } = params;
|
|
12825
|
+
let { api, userId: id, accountId, req: reqParams, expand } = params;
|
|
12826
12826
|
if (!id) {
|
|
12827
|
-
|
|
12827
|
+
id = "anonymous";
|
|
12828
12828
|
}
|
|
12829
12829
|
if (!api) {
|
|
12830
12830
|
api = ENVIRONMENT.Api().GetGuardianApi();
|
|
12831
12831
|
}
|
|
12832
|
-
const cacheKey = GetCacheKey(api.GetSessionId(), id, accountId);
|
|
12832
|
+
const cacheKey = GetCacheKey(api.GetSessionId(), id, accountId, expand);
|
|
12833
12833
|
const cache = api.GetCacheItem(cacheKey, reqParams);
|
|
12834
12834
|
if (cache === null || cache === void 0 ? void 0 : cache.found) {
|
|
12835
12835
|
return cache.data;
|
|
@@ -12840,6 +12840,9 @@ var User;
|
|
|
12840
12840
|
if (accountId) {
|
|
12841
12841
|
urlParams.append("clientAccountID", accountId);
|
|
12842
12842
|
}
|
|
12843
|
+
if (expand) {
|
|
12844
|
+
urlParams.append("expand", expand);
|
|
12845
|
+
}
|
|
12843
12846
|
let url = `user/${id}`;
|
|
12844
12847
|
if (urlParams.toString().length) {
|
|
12845
12848
|
url += "?" + urlParams.toString();
|
|
@@ -13022,6 +13025,11 @@ var User;
|
|
|
13022
13025
|
if (!username) {
|
|
13023
13026
|
throw ("Username is required.");
|
|
13024
13027
|
}
|
|
13028
|
+
else if (typeof username == "string" && username.toLowerCase() === "anonymous") {
|
|
13029
|
+
return {
|
|
13030
|
+
isAvailable: false
|
|
13031
|
+
};
|
|
13032
|
+
}
|
|
13025
13033
|
if (!api) {
|
|
13026
13034
|
api = ENVIRONMENT.Api().GetGuardianApi();
|
|
13027
13035
|
}
|
|
@@ -13438,15 +13446,22 @@ var User;
|
|
|
13438
13446
|
* @param sessionId
|
|
13439
13447
|
* @param userId
|
|
13440
13448
|
* @param accountId
|
|
13449
|
+
* @param expand
|
|
13441
13450
|
* @returns
|
|
13442
13451
|
*/
|
|
13443
|
-
function GetCacheKey(sessionId, userId, accountId) {
|
|
13452
|
+
function GetCacheKey(sessionId, userId, accountId, expand) {
|
|
13444
13453
|
if (!accountId) {
|
|
13445
13454
|
accountId = "";
|
|
13446
13455
|
}
|
|
13447
13456
|
if (!sessionId) {
|
|
13448
13457
|
sessionId = "anonymous";
|
|
13449
13458
|
}
|
|
13459
|
+
if (!userId) {
|
|
13460
|
+
userId = "anonymous";
|
|
13461
|
+
}
|
|
13462
|
+
if (!expand) {
|
|
13463
|
+
expand = "";
|
|
13464
|
+
}
|
|
13450
13465
|
return Api.ECacheKey.User + Api.ECacheKey.Id + userId + Api.ECacheKey.Id + accountId + Api.ECacheKey.Session + Api.ECacheKey.Id + sessionId;
|
|
13451
13466
|
}
|
|
13452
13467
|
User$$1.GetCacheKey = GetCacheKey;
|
|
@@ -16163,7 +16178,7 @@ var Tracking;
|
|
|
16163
16178
|
})(Tracking || (Tracking = {}));
|
|
16164
16179
|
|
|
16165
16180
|
// This is updated with the package.json version on build.
|
|
16166
|
-
const VERSION = "6.5.
|
|
16181
|
+
const VERSION = "6.5.3";
|
|
16167
16182
|
|
|
16168
16183
|
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, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataLabGroup, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking };
|
|
16169
16184
|
//# sourceMappingURL=bruce-models.es5.js.map
|