bruce-models 2.9.6 → 2.9.8
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 +62 -62
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +62 -62
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/api/abstract-api.js +24 -28
- package/dist/lib/api/abstract-api.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/entity/entity.js +3 -1
- package/dist/lib/entity/entity.js.map +1 -1
- package/dist/lib/entity/getters/entity-filter-getter.js +2 -0
- package/dist/lib/entity/getters/entity-filter-getter.js.map +1 -1
- package/dist/lib/plugin/plugin.js +32 -32
- package/dist/types/api/abstract-api.d.ts +3 -3
- package/dist/types/bruce-models.d.ts +1 -1
- package/dist/types/entity/entity.d.ts +1 -0
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -265,36 +265,32 @@ class AbstractApi {
|
|
|
265
265
|
}
|
|
266
266
|
}
|
|
267
267
|
GetCacheItem(key, reqParams) {
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
return this.Cache.Get(key);
|
|
277
|
-
});
|
|
268
|
+
let noCache = reqParams === null || reqParams === void 0 ? void 0 : reqParams.noCache;
|
|
269
|
+
if (noCache == null) {
|
|
270
|
+
noCache = Api.DEFAULT_NO_CACHE;
|
|
271
|
+
}
|
|
272
|
+
if (noCache) {
|
|
273
|
+
return null;
|
|
274
|
+
}
|
|
275
|
+
return this.Cache.Get(key);
|
|
278
276
|
}
|
|
279
277
|
SetCacheItem(params) {
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
persistence: "memory"
|
|
297
|
-
});
|
|
278
|
+
let { key, value, duration, req } = params;
|
|
279
|
+
let noCache = req === null || req === void 0 ? void 0 : req.noCache;
|
|
280
|
+
if (noCache == null) {
|
|
281
|
+
noCache = Api.DEFAULT_NO_CACHE;
|
|
282
|
+
}
|
|
283
|
+
if (noCache) {
|
|
284
|
+
return;
|
|
285
|
+
}
|
|
286
|
+
if (isNaN(duration)) {
|
|
287
|
+
duration = Api.DEFAULT_CACHE_DURATION;
|
|
288
|
+
}
|
|
289
|
+
this.Cache.Set({
|
|
290
|
+
id: key,
|
|
291
|
+
data: value,
|
|
292
|
+
duration,
|
|
293
|
+
persistence: "memory"
|
|
298
294
|
});
|
|
299
295
|
}
|
|
300
296
|
GetSessionId() {
|
|
@@ -2318,6 +2314,7 @@ var Entity;
|
|
|
2318
2314
|
}
|
|
2319
2315
|
Entity.CalculateName = CalculateName;
|
|
2320
2316
|
function GetList(params) {
|
|
2317
|
+
var _a;
|
|
2321
2318
|
return __awaiter(this, void 0, void 0, function* () {
|
|
2322
2319
|
let { api, filter, req: reqParams, viaCdn, viaCdnCacheToken } = params;
|
|
2323
2320
|
if (!api) {
|
|
@@ -2328,8 +2325,9 @@ var Entity;
|
|
|
2328
2325
|
requestFilter = Object.assign({}, filter.entityTypeConditions);
|
|
2329
2326
|
}
|
|
2330
2327
|
if (filter.layerIds != null && filter.layerIds.length > 0) {
|
|
2328
|
+
const operator = (_a = filter.layerIdsOperator) !== null && _a !== void 0 ? _a : "equals";
|
|
2331
2329
|
requestFilter["Bruce.Layer.ID"] = {
|
|
2332
|
-
|
|
2330
|
+
[operator]: filter.layerIds
|
|
2333
2331
|
};
|
|
2334
2332
|
}
|
|
2335
2333
|
if (filter.bounds) {
|
|
@@ -5141,6 +5139,8 @@ var EntityFilterGetter;
|
|
|
5141
5139
|
pageIndex: curCell.FetchPageIndex,
|
|
5142
5140
|
entityTypeId: this.typeId,
|
|
5143
5141
|
layerIds: this.tagIds,
|
|
5142
|
+
// Any tag specified will be allowed.
|
|
5143
|
+
layerIdsOperator: "in",
|
|
5144
5144
|
bounds: curCell.GetBounds(),
|
|
5145
5145
|
sortOrder: Api.ESortOrder.Asc,
|
|
5146
5146
|
entityTypeConditions: this.attrFilter
|
|
@@ -8936,40 +8936,40 @@ var Plugin;
|
|
|
8936
8936
|
window[paramsId] = pluginParams ? pluginParams : {};
|
|
8937
8937
|
const disposeId = ObjectUtils.UId();
|
|
8938
8938
|
const elementId = ObjectUtils.UId();
|
|
8939
|
-
let script = `
|
|
8940
|
-
function run() {
|
|
8941
|
-
${fileContent}
|
|
8942
|
-
|
|
8943
|
-
const paramsId = "${paramsId}";
|
|
8944
|
-
const containerId = "${containerId}";
|
|
8945
|
-
let container;
|
|
8946
|
-
if (containerId) {
|
|
8947
|
-
container = document.getElementById("${containerId}");
|
|
8948
|
-
}
|
|
8949
|
-
|
|
8950
|
-
let pluginHTML = null;
|
|
8951
|
-
if (container) {
|
|
8952
|
-
pluginHTML = document.createElement("div");
|
|
8953
|
-
pluginHTML.id = "${elementId}";
|
|
8954
|
-
container.appendChild(pluginHTML);
|
|
8955
|
-
}
|
|
8956
|
-
|
|
8957
|
-
{TEMPLATE_CODE}
|
|
8958
|
-
const params = window["${paramsId}"];
|
|
8959
|
-
|
|
8960
|
-
window["${disposeId}"] = Run({
|
|
8961
|
-
element: pluginHTML,
|
|
8962
|
-
container: container,
|
|
8963
|
-
pluginParams: params
|
|
8964
|
-
});
|
|
8965
|
-
}
|
|
8966
|
-
run();
|
|
8939
|
+
let script = `
|
|
8940
|
+
function run() {
|
|
8941
|
+
${fileContent}
|
|
8942
|
+
|
|
8943
|
+
const paramsId = "${paramsId}";
|
|
8944
|
+
const containerId = "${containerId}";
|
|
8945
|
+
let container;
|
|
8946
|
+
if (containerId) {
|
|
8947
|
+
container = document.getElementById("${containerId}");
|
|
8948
|
+
}
|
|
8949
|
+
|
|
8950
|
+
let pluginHTML = null;
|
|
8951
|
+
if (container) {
|
|
8952
|
+
pluginHTML = document.createElement("div");
|
|
8953
|
+
pluginHTML.id = "${elementId}";
|
|
8954
|
+
container.appendChild(pluginHTML);
|
|
8955
|
+
}
|
|
8956
|
+
|
|
8957
|
+
{TEMPLATE_CODE}
|
|
8958
|
+
const params = window["${paramsId}"];
|
|
8959
|
+
|
|
8960
|
+
window["${disposeId}"] = Run({
|
|
8961
|
+
element: pluginHTML,
|
|
8962
|
+
container: container,
|
|
8963
|
+
pluginParams: params
|
|
8964
|
+
});
|
|
8965
|
+
}
|
|
8966
|
+
run();
|
|
8967
8967
|
`;
|
|
8968
8968
|
if (script.includes("var template")) {
|
|
8969
|
-
script = script.replace("{TEMPLATE_CODE}", `
|
|
8970
|
-
if (pluginHTML && template) {
|
|
8971
|
-
pluginHTML.innerHTML = template;
|
|
8972
|
-
}
|
|
8969
|
+
script = script.replace("{TEMPLATE_CODE}", `
|
|
8970
|
+
if (pluginHTML && template) {
|
|
8971
|
+
pluginHTML.innerHTML = template;
|
|
8972
|
+
}
|
|
8973
8973
|
`);
|
|
8974
8974
|
}
|
|
8975
8975
|
else {
|
|
@@ -9108,7 +9108,7 @@ var DataSource;
|
|
|
9108
9108
|
DataSource.GetList = GetList;
|
|
9109
9109
|
})(DataSource || (DataSource = {}));
|
|
9110
9110
|
|
|
9111
|
-
const VERSION = "2.9.
|
|
9111
|
+
const VERSION = "2.9.8";
|
|
9112
9112
|
|
|
9113
9113
|
export { VERSION, AnnDocument, CustomForm, AbstractApi, Api, BruceApi, CamApi, IdmApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityType, Entity, EntityGlobe, EntityFilterGetter, BatchedDataGetter, EntityCoords, EntityTypeVisualSettings, EntityAttribute, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, Account, AccountInvite, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, ImportCad, ImportCsv, ImportJson, ImportKml, ImportedFile, Markup, Uploader, Plugin, ENVIRONMENT, DataSource };
|
|
9114
9114
|
//# sourceMappingURL=bruce-models.es5.js.map
|