@hpcc-js/eclwatch 2.77.3 → 2.77.5

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/index.js CHANGED
@@ -4,8 +4,8 @@
4
4
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["@hpcc-js/eclwatch"] = {}, global["@hpcc-js/codemirror"], global["@hpcc-js/comms"], global["@hpcc-js/phosphor"], global["@hpcc-js/tree"], global["@hpcc-js/util"], global["@hpcc-js/common"], global["@hpcc-js/dgrid"], global["@hpcc-js/graph"], global["@hpcc-js/layout"], global["@hpcc-js/timeline"]));
5
5
  })(this, (function (exports, codemirror, comms, phosphor, tree, util, common, dgrid, graph, layout, timeline) {
6
6
  var PKG_NAME = "@hpcc-js/eclwatch";
7
- var PKG_VERSION = "2.77.3";
8
- var BUILD_VERSION = "2.108.3";
7
+ var PKG_VERSION = "2.77.5";
8
+ var BUILD_VERSION = "2.108.5";
9
9
 
10
10
  /******************************************************************************
11
11
  Copyright (c) Microsoft Corporation.
@@ -1078,7 +1078,7 @@
1078
1078
  return item;
1079
1079
  }
1080
1080
  var Store = /** @class */ (function () {
1081
- function Store(wuResult, schema, renderHtml, filter) {
1081
+ function Store(wuResult, schema, renderHtml, filter, onError) {
1082
1082
  if (filter === void 0) { filter = {}; }
1083
1083
  this._cache = {};
1084
1084
  this._filter = {};
@@ -1087,6 +1087,7 @@
1087
1087
  this._columns = this.schema2Columns(this.schema.root);
1088
1088
  this.rowFormatter = new dgrid.RowFormatter(this._columns, renderHtml);
1089
1089
  this._filter = filter;
1090
+ this.onError = onError;
1090
1091
  }
1091
1092
  Store.prototype.columns = function () {
1092
1093
  return this._columns;
@@ -1240,6 +1241,9 @@
1240
1241
  return formattedRow;
1241
1242
  })
1242
1243
  };
1244
+ }).catch(function (err) {
1245
+ _this.onError(err.Message || "An exception has occurred");
1246
+ return { totalLength: 0, data: [] };
1243
1247
  });
1244
1248
  this._cache[cacheKey] = retVal;
1245
1249
  return retVal;
@@ -1310,7 +1314,12 @@
1310
1314
  if (result_1) {
1311
1315
  result_1.fetchXMLSchema().then(function (schema) {
1312
1316
  var _a, _b;
1313
- _this._localStore = new Store(result_1, schema, _this.renderHtml(), _this.filter());
1317
+ _this._localStore = new Store(result_1, schema, _this.renderHtml(), _this.filter(), function (msg) {
1318
+ if (_this._dgrid) {
1319
+ _this._dgrid.noDataMessage = "<span class='dojoxGridNoData'>".concat(msg, "</span>");
1320
+ _this._dgrid.refresh();
1321
+ }
1322
+ });
1314
1323
  (_a = _this._dgrid) === null || _a === void 0 ? void 0 : _a.set("columns", _this._localStore.columns());
1315
1324
  (_b = _this._dgrid) === null || _b === void 0 ? void 0 : _b.set("collection", _this._localStore);
1316
1325
  });