bruce-models 7.1.118 → 7.1.119
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 +36 -7
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +36 -7
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/change-set/change-set.js +35 -6
- package/dist/lib/change-set/change-set.js.map +1 -1
- package/dist/types/bruce-models.d.ts +1 -1
- package/dist/types/change-set/change-set.d.ts +24 -4
- package/package.json +1 -1
package/dist/bruce-models.umd.js
CHANGED
|
@@ -8795,6 +8795,7 @@
|
|
|
8795
8795
|
EConcept["ENTITY_TYPE"] = "ET";
|
|
8796
8796
|
EConcept["ENTITY_LOD"] = "EL";
|
|
8797
8797
|
EConcept["ENTITY_RELATION"] = "ER";
|
|
8798
|
+
EConcept["ASSEMBLY"] = "A";
|
|
8798
8799
|
})(EConcept = ChangeSet.EConcept || (ChangeSet.EConcept = {}));
|
|
8799
8800
|
/**
|
|
8800
8801
|
* Updates existing or creates new Change Set record.
|
|
@@ -8831,11 +8832,18 @@
|
|
|
8831
8832
|
*/
|
|
8832
8833
|
function Get(params) {
|
|
8833
8834
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8834
|
-
let { id, expandCount, api, req: reqParams } = params;
|
|
8835
|
+
let { id, expandCount, expandCountByConcept, api, req: reqParams } = params;
|
|
8835
8836
|
if (!api) {
|
|
8836
8837
|
api = exports.ENVIRONMENT.Api().GetBruceApi();
|
|
8837
8838
|
}
|
|
8838
|
-
const
|
|
8839
|
+
const expand = [];
|
|
8840
|
+
if (expandCount) {
|
|
8841
|
+
expand.push("Count");
|
|
8842
|
+
}
|
|
8843
|
+
if (expandCountByConcept) {
|
|
8844
|
+
expand.push("CountByConcept");
|
|
8845
|
+
}
|
|
8846
|
+
const query = expand.length ? `?Expand=${expand.join(",")}` : "";
|
|
8839
8847
|
return yield api.GET(`v3/change/${id}${query}`, exports.Api.PrepReqParams(reqParams));
|
|
8840
8848
|
});
|
|
8841
8849
|
}
|
|
@@ -8894,13 +8902,10 @@
|
|
|
8894
8902
|
ChangeSet.Reject = Reject;
|
|
8895
8903
|
/**
|
|
8896
8904
|
* Gets the paged list of Change Items for the specified Change Set.
|
|
8897
|
-
* Optionally filter by Concept (E, ET, EL, ER) and/or EntityID.
|
|
8898
|
-
* TotalCount is returned when PageIndex is 0 (the default).
|
|
8899
|
-
* Pass -1 for both pageSize and pageIndex to get only TotalCount.
|
|
8900
8905
|
*/
|
|
8901
8906
|
function GetItems(params) {
|
|
8902
8907
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8903
|
-
let { id, api, req: reqParams, pageSize, pageIndex, concept, entityId } = params;
|
|
8908
|
+
let { id, api, req: reqParams, pageSize, pageIndex, concept, action, entityId } = params;
|
|
8904
8909
|
if (!api) {
|
|
8905
8910
|
api = exports.ENVIRONMENT.Api().GetBruceApi();
|
|
8906
8911
|
}
|
|
@@ -8914,6 +8919,9 @@
|
|
|
8914
8919
|
if (concept != null) {
|
|
8915
8920
|
urlParams.append("Concept", concept);
|
|
8916
8921
|
}
|
|
8922
|
+
if (action != null) {
|
|
8923
|
+
urlParams.append("Action", action);
|
|
8924
|
+
}
|
|
8917
8925
|
if (entityId != null) {
|
|
8918
8926
|
urlParams.append("EntityID", entityId);
|
|
8919
8927
|
}
|
|
@@ -8922,6 +8930,27 @@
|
|
|
8922
8930
|
});
|
|
8923
8931
|
}
|
|
8924
8932
|
ChangeSet.GetItems = GetItems;
|
|
8933
|
+
/**
|
|
8934
|
+
* Locates the first Change Item naming an Entity, so a paged list can turn to the page holding it.
|
|
8935
|
+
*/
|
|
8936
|
+
function GetItemsIndexOf(params) {
|
|
8937
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
8938
|
+
let { id, entityId, concept, action, api, req: reqParams } = params;
|
|
8939
|
+
if (!api) {
|
|
8940
|
+
api = exports.ENVIRONMENT.Api().GetBruceApi();
|
|
8941
|
+
}
|
|
8942
|
+
const urlParams = new URLSearchParams();
|
|
8943
|
+
urlParams.append("IndexOf", entityId);
|
|
8944
|
+
if (concept != null) {
|
|
8945
|
+
urlParams.append("Concept", concept);
|
|
8946
|
+
}
|
|
8947
|
+
if (action != null) {
|
|
8948
|
+
urlParams.append("Action", action);
|
|
8949
|
+
}
|
|
8950
|
+
return api.GET(`v3/change/${id}/items?${urlParams.toString()}`, exports.Api.PrepReqParams(reqParams));
|
|
8951
|
+
});
|
|
8952
|
+
}
|
|
8953
|
+
ChangeSet.GetItemsIndexOf = GetItemsIndexOf;
|
|
8925
8954
|
/**
|
|
8926
8955
|
* Updates existing or creates new Change Item within the specified Change Set.
|
|
8927
8956
|
* To create a new item omit changeItem.ID or set it to 0.
|
|
@@ -24968,7 +24997,7 @@
|
|
|
24968
24997
|
}
|
|
24969
24998
|
|
|
24970
24999
|
// This is updated with the package.json version on build.
|
|
24971
|
-
const VERSION = "7.1.
|
|
25000
|
+
const VERSION = "7.1.119";
|
|
24972
25001
|
|
|
24973
25002
|
exports.VERSION = VERSION;
|
|
24974
25003
|
exports.AbstractApi = AbstractApi;
|