bruce-models 7.1.32 → 7.1.34
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 +194 -2
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +185 -1
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +3 -1
- package/dist/lib/bruce-models.js.map +1 -1
- package/dist/lib/dashboard/dashboard-view.js +100 -0
- package/dist/lib/dashboard/dashboard-view.js.map +1 -0
- package/dist/lib/data-transform/data-transform.js +120 -0
- package/dist/lib/data-transform/data-transform.js.map +1 -0
- package/dist/types/bruce-models.d.ts +3 -1
- package/dist/types/dashboard/dashboard-view.d.ts +53 -0
- package/dist/types/data-transform/data-transform.d.ts +133 -0
- package/package.json +1 -1
package/dist/bruce-models.es5.js
CHANGED
|
@@ -9171,6 +9171,92 @@ var EntityTableView;
|
|
|
9171
9171
|
EntityTableView.Delete = Delete;
|
|
9172
9172
|
})(EntityTableView || (EntityTableView = {}));
|
|
9173
9173
|
|
|
9174
|
+
/**
|
|
9175
|
+
* Represents a Dashboard View record.
|
|
9176
|
+
*/
|
|
9177
|
+
var DashboardView;
|
|
9178
|
+
(function (DashboardView) {
|
|
9179
|
+
/**
|
|
9180
|
+
* Returns a record matching the given viewId.
|
|
9181
|
+
* @param params
|
|
9182
|
+
*/
|
|
9183
|
+
function Get(params) {
|
|
9184
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
9185
|
+
let { viewId, api, req } = params;
|
|
9186
|
+
if (!api) {
|
|
9187
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
9188
|
+
}
|
|
9189
|
+
req = Api.PrepReqParams(req);
|
|
9190
|
+
const res = yield api.GET(`ui.dashboardview/${viewId}`, req);
|
|
9191
|
+
return {
|
|
9192
|
+
view: res
|
|
9193
|
+
};
|
|
9194
|
+
});
|
|
9195
|
+
}
|
|
9196
|
+
DashboardView.Get = Get;
|
|
9197
|
+
/**
|
|
9198
|
+
* Returns the list of all available Dashboard Views.
|
|
9199
|
+
* @param params
|
|
9200
|
+
*/
|
|
9201
|
+
function GetList(params) {
|
|
9202
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
9203
|
+
if (!params) {
|
|
9204
|
+
params = {};
|
|
9205
|
+
}
|
|
9206
|
+
let { api, req } = params;
|
|
9207
|
+
if (!api) {
|
|
9208
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
9209
|
+
}
|
|
9210
|
+
req = Api.PrepReqParams(req);
|
|
9211
|
+
const res = yield api.GET("ui.dashboardviews", req);
|
|
9212
|
+
let items = res === null || res === void 0 ? void 0 : res.Items;
|
|
9213
|
+
if (!items) {
|
|
9214
|
+
items = [];
|
|
9215
|
+
}
|
|
9216
|
+
return {
|
|
9217
|
+
views: items
|
|
9218
|
+
};
|
|
9219
|
+
});
|
|
9220
|
+
}
|
|
9221
|
+
DashboardView.GetList = GetList;
|
|
9222
|
+
/**
|
|
9223
|
+
* Creates or updates a Dashboard View record.
|
|
9224
|
+
*/
|
|
9225
|
+
function Update(params) {
|
|
9226
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
9227
|
+
let { view, api, req } = params;
|
|
9228
|
+
if (!api) {
|
|
9229
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
9230
|
+
}
|
|
9231
|
+
req = Api.PrepReqParams(req);
|
|
9232
|
+
let viewId = view.ID;
|
|
9233
|
+
if (!viewId) {
|
|
9234
|
+
viewId = 0;
|
|
9235
|
+
}
|
|
9236
|
+
const res = yield api.POST(`ui.dashboardview/${viewId}`, view, req);
|
|
9237
|
+
return {
|
|
9238
|
+
view: res
|
|
9239
|
+
};
|
|
9240
|
+
});
|
|
9241
|
+
}
|
|
9242
|
+
DashboardView.Update = Update;
|
|
9243
|
+
/**
|
|
9244
|
+
* Deletes a Dashboard View record.
|
|
9245
|
+
* @param params
|
|
9246
|
+
*/
|
|
9247
|
+
function Delete(params) {
|
|
9248
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
9249
|
+
let { viewId, api, req } = params;
|
|
9250
|
+
if (!api) {
|
|
9251
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
9252
|
+
}
|
|
9253
|
+
req = Api.PrepReqParams(req);
|
|
9254
|
+
return yield api.DELETE(`ui.dashboardview/${viewId}`, req);
|
|
9255
|
+
});
|
|
9256
|
+
}
|
|
9257
|
+
DashboardView.Delete = Delete;
|
|
9258
|
+
})(DashboardView || (DashboardView = {}));
|
|
9259
|
+
|
|
9174
9260
|
/**
|
|
9175
9261
|
* Describes the "Style" concept within Nextspace.
|
|
9176
9262
|
* A legacy way of referring to styles is "entity display settings".
|
|
@@ -15853,6 +15939,112 @@ var DataLab;
|
|
|
15853
15939
|
DataLab.Run = Run;
|
|
15854
15940
|
})(DataLab || (DataLab = {}));
|
|
15855
15941
|
|
|
15942
|
+
/**
|
|
15943
|
+
* Describes the "Data Transform" concept within Nextspace.
|
|
15944
|
+
*/
|
|
15945
|
+
var DataTransform;
|
|
15946
|
+
(function (DataTransform) {
|
|
15947
|
+
/**
|
|
15948
|
+
* Supported Logic Flow diagram item types.
|
|
15949
|
+
*/
|
|
15950
|
+
let ELogicFlowDiagramItemType;
|
|
15951
|
+
(function (ELogicFlowDiagramItemType) {
|
|
15952
|
+
ELogicFlowDiagramItemType["InputValue"] = "input-value";
|
|
15953
|
+
ELogicFlowDiagramItemType["OutputValue"] = "output-value";
|
|
15954
|
+
ELogicFlowDiagramItemType["If"] = "if";
|
|
15955
|
+
ELogicFlowDiagramItemType["Formula"] = "formula";
|
|
15956
|
+
ELogicFlowDiagramItemType["Switch"] = "switch";
|
|
15957
|
+
})(ELogicFlowDiagramItemType = DataTransform.ELogicFlowDiagramItemType || (DataTransform.ELogicFlowDiagramItemType = {}));
|
|
15958
|
+
/**
|
|
15959
|
+
* Supported Logic Flow connection point types.
|
|
15960
|
+
*/
|
|
15961
|
+
let ELogicFlowConnectionPointType;
|
|
15962
|
+
(function (ELogicFlowConnectionPointType) {
|
|
15963
|
+
ELogicFlowConnectionPointType["Input"] = "input";
|
|
15964
|
+
ELogicFlowConnectionPointType["Output"] = "output";
|
|
15965
|
+
})(ELogicFlowConnectionPointType = DataTransform.ELogicFlowConnectionPointType || (DataTransform.ELogicFlowConnectionPointType = {}));
|
|
15966
|
+
/**
|
|
15967
|
+
* Supported Logic Flow connection end roles.
|
|
15968
|
+
*/
|
|
15969
|
+
let ELogicFlowConnectionEndRole;
|
|
15970
|
+
(function (ELogicFlowConnectionEndRole) {
|
|
15971
|
+
ELogicFlowConnectionEndRole["From"] = "from";
|
|
15972
|
+
ELogicFlowConnectionEndRole["To"] = "to";
|
|
15973
|
+
})(ELogicFlowConnectionEndRole = DataTransform.ELogicFlowConnectionEndRole || (DataTransform.ELogicFlowConnectionEndRole = {}));
|
|
15974
|
+
/**
|
|
15975
|
+
* Requests a suggested Logic Flow diagram from a natural-language prompt.
|
|
15976
|
+
* Route: POST v1/entityType/{entityType_id}/DataTransform/SuggestLogicFlowDiagram
|
|
15977
|
+
*/
|
|
15978
|
+
function SuggestLogicFlowDiagramByPrompt(params) {
|
|
15979
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15980
|
+
let { api, entityTypeId, prompt, model, maxNodes, dataTransformId, dataTransform, dataTransformContext, sourceDataSchema, destinationDataSchema, inputAttributes, outputAttributes, req: reqParams } = params;
|
|
15981
|
+
if (!entityTypeId) {
|
|
15982
|
+
throw ("Entity Type ID is required.");
|
|
15983
|
+
}
|
|
15984
|
+
prompt = prompt === null || prompt === void 0 ? void 0 : prompt.trim();
|
|
15985
|
+
if (!prompt) {
|
|
15986
|
+
throw ("Prompt is required.");
|
|
15987
|
+
}
|
|
15988
|
+
if (!api) {
|
|
15989
|
+
api = ENVIRONMENT.Api().GetBruceApi();
|
|
15990
|
+
}
|
|
15991
|
+
const body = {
|
|
15992
|
+
Prompt: prompt
|
|
15993
|
+
};
|
|
15994
|
+
if (model) {
|
|
15995
|
+
body.Model = model;
|
|
15996
|
+
}
|
|
15997
|
+
if (typeof maxNodes == "number" && !isNaN(maxNodes)) {
|
|
15998
|
+
body.MaxNodes = maxNodes;
|
|
15999
|
+
}
|
|
16000
|
+
if (typeof dataTransformId == "number" && dataTransformId > 0) {
|
|
16001
|
+
body["DataTransform.ID"] = dataTransformId;
|
|
16002
|
+
}
|
|
16003
|
+
if (dataTransform != null) {
|
|
16004
|
+
body.DataTransform = dataTransform;
|
|
16005
|
+
}
|
|
16006
|
+
if (dataTransformContext != null) {
|
|
16007
|
+
body.DataTransformContext = dataTransformContext;
|
|
16008
|
+
}
|
|
16009
|
+
if (sourceDataSchema != null) {
|
|
16010
|
+
body.SourceDataSchema = sourceDataSchema;
|
|
16011
|
+
}
|
|
16012
|
+
if (destinationDataSchema != null) {
|
|
16013
|
+
body.DestinationDataSchema = destinationDataSchema;
|
|
16014
|
+
}
|
|
16015
|
+
if (inputAttributes === null || inputAttributes === void 0 ? void 0 : inputAttributes.length) {
|
|
16016
|
+
body.InputAttributes = inputAttributes;
|
|
16017
|
+
}
|
|
16018
|
+
if (outputAttributes === null || outputAttributes === void 0 ? void 0 : outputAttributes.length) {
|
|
16019
|
+
body.OutputAttributes = outputAttributes;
|
|
16020
|
+
}
|
|
16021
|
+
const route = `v1/entityType/${Api.Encode(entityTypeId)}/DataTransform/SuggestLogicFlowDiagram`;
|
|
16022
|
+
const response = yield api.POST(route, body, Api.PrepReqParams(reqParams));
|
|
16023
|
+
let diagram = (response === null || response === void 0 ? void 0 : response.diagram)
|
|
16024
|
+
|| (response === null || response === void 0 ? void 0 : response.Diagram)
|
|
16025
|
+
|| (response === null || response === void 0 ? void 0 : response.LogicFlowDiagram)
|
|
16026
|
+
|| (response === null || response === void 0 ? void 0 : response.result)
|
|
16027
|
+
|| (response === null || response === void 0 ? void 0 : response.Result)
|
|
16028
|
+
|| response;
|
|
16029
|
+
if (typeof diagram == "string") {
|
|
16030
|
+
try {
|
|
16031
|
+
diagram = JSON.parse(diagram);
|
|
16032
|
+
}
|
|
16033
|
+
catch (e) {
|
|
16034
|
+
// Keep original shape if parse fails.
|
|
16035
|
+
}
|
|
16036
|
+
}
|
|
16037
|
+
if (!diagram || typeof diagram != "object") {
|
|
16038
|
+
throw ("No Logic Flow Diagram was returned by the suggestion API.");
|
|
16039
|
+
}
|
|
16040
|
+
return {
|
|
16041
|
+
diagram: diagram
|
|
16042
|
+
};
|
|
16043
|
+
});
|
|
16044
|
+
}
|
|
16045
|
+
DataTransform.SuggestLogicFlowDiagramByPrompt = SuggestLogicFlowDiagramByPrompt;
|
|
16046
|
+
})(DataTransform || (DataTransform = {}));
|
|
16047
|
+
|
|
15856
16048
|
var DataLabGroup;
|
|
15857
16049
|
(function (DataLabGroup) {
|
|
15858
16050
|
/**
|
|
@@ -18025,7 +18217,7 @@ var ChangeSet;
|
|
|
18025
18217
|
})(ChangeSet || (ChangeSet = {}));
|
|
18026
18218
|
|
|
18027
18219
|
// This is updated with the package.json version on build.
|
|
18028
|
-
const VERSION = "7.1.
|
|
18220
|
+
const VERSION = "7.1.34";
|
|
18029
18221
|
|
|
18030
|
-
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, EntityTypeTrigger, 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, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18222
|
+
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, EntityTypeTrigger, EntityType, Entity, EntityCoords, EntityAttribute, EntityHistoricData, EntityTableView, DashboardView, Comment, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, ProjectViewLegacy, ProjectViewLegacyBookmark, ProjectViewBookmarkGroup, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, UserMfaMethod, Account, AccountInvite, AccountFeatures, AccountLimits, AccountTemplate, AccountType, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, DataTransform, DataLabGroup, DataFeed, ImportAssembly, ImportCad, ImportCsv, ImportJson, ImportGeoJson, ImportKml, ImportLcc, ImportedFile, ExportBrz, ExportUsd, Markup, Uploader, Plugin, ENVIRONMENT, DataSource, Scenario, Tracking, NAVIGATOR_CHAT_EVENT_ENTITY_HIGHLIGHT_APPLIED, NAVIGATOR_CHAT_EVENT_SCENE_CONTEXT_PREFETCHED, NavigatorChatClient, NavigatorMcpWebSocketClient, ChangeSet };
|
|
18031
18223
|
//# sourceMappingURL=bruce-models.es5.js.map
|