@refinitiv-ui/efx-grid 6.0.102 → 6.0.104

Sign up to get free protection for your applications and to get access to all the features.
@@ -12012,7 +12012,6 @@ let DataCache = function () {
12012
12012
 
12013
12013
  _t._rows = {};
12014
12014
  _t._subs = {};
12015
- _t._staticFields = {};
12016
12015
  _t._onInsert = _t._onInsert.bind(_t);
12017
12016
  _t._onUpdate = _t._onUpdate.bind(_t);
12018
12017
  _t._onDelete = _t._onDelete.bind(_t);
@@ -12448,64 +12447,34 @@ DataCache.prototype.cloneRowData = function (rid) {
12448
12447
  return values;
12449
12448
  };
12450
12449
 
12451
- /**
12452
- * Deprecated. Built-in Data Service is deprecated due to the lack of flexibility.
12450
+ /** Deprecated. Built-in Data Service is deprecated due to the lack of flexibility.
12453
12451
  * @public
12454
- * @param {Array.<string>} fields
12452
+ * @ignore
12455
12453
  * @suppress {checkTypes}
12456
12454
  */
12457
- DataCache.prototype.addStaticFields = function (fields) {
12458
- if (!Array.isArray(fields)) {
12459
- return;
12460
- }
12461
-
12462
- for (let i in fields) {
12463
- if (!this._staticFields[fields[i]]) {
12464
- this._staticFields[fields[i]] = 1;
12465
- } else {
12466
- this._staticFields[fields[i]]++;
12467
- }
12468
- }
12469
- };
12455
+ DataCache.prototype.addStaticFields = function () {};
12470
12456
 
12471
12457
  /**
12472
12458
  * Deprecated. Built-in Data Service is deprecated due to the lack of flexibility.
12473
12459
  * @public
12474
- * @param {Array.<string>} fields
12460
+ * @ignore
12475
12461
  * @suppress {checkTypes}
12476
12462
  */
12477
- DataCache.prototype.removeStaticFields = function (fields) {
12478
- if (!Array.isArray(fields)) {
12479
- return;
12480
- }
12481
-
12482
- for (let i in fields) {
12483
- if (this._staticFields[fields[i]]) {
12484
- this._staticFields[fields[i]]--;
12485
-
12486
- if (this._staticFields[fields[i]] === 0) {
12487
- delete this._staticFields[fields[i]];
12488
- }
12489
- }
12490
- }
12491
- };
12463
+ DataCache.prototype.removeStaticFields = function () {};
12492
12464
 
12493
12465
  /**
12494
12466
  * Deprecated. Built-in Data Service is deprecated due to the lack of flexibility.
12495
12467
  * @public
12468
+ * @ignore
12496
12469
  */
12497
- DataCache.prototype.resetStaticFields = function () {
12498
- this._staticFields = {};
12499
- };
12470
+ DataCache.prototype.resetStaticFields = function () {};
12500
12471
 
12501
12472
  /**
12502
12473
  * Deprecated. Built-in Data Service is deprecated due to the lack of flexibility.
12503
12474
  * @public
12504
- * @return {Object.<string, number>}
12475
+ * @ignore
12505
12476
  */
12506
- DataCache.prototype.getStaticFields = function () {
12507
- return this._staticFields;
12508
- };
12477
+ DataCache.prototype.getStaticFields = function () {};
12509
12478
 
12510
12479
  /**
12511
12480
  * Construct a JSON object that is compatible with console.table()
@@ -12772,29 +12741,15 @@ DataCache.prototype._onQ2DataChanged = function (e) {
12772
12741
  */
12773
12742
  DataCache.prototype._onQ2SubAdded = function (e) {
12774
12743
  let subs = e["subs"];
12775
- let duplicateSubIds = e["duplicateSubIds"];
12776
12744
  let len = subs.length;
12777
12745
 
12778
12746
  for (let i = 0; i < len; ++i) {
12779
12747
  let sub = subs[i];
12780
- let ric = sub["ric"];
12781
12748
 
12782
12749
  // chain subId fires twice, one with "_ci_" and one without "_ci_"
12783
12750
  // the subId with "_ci_" should be ignore
12784
- if(sub["id"].indexOf("_ci_") >= 0){
12785
- continue;
12786
- }
12787
-
12788
- this.addSubscription(sub, ric);
12789
-
12790
- if (duplicateSubIds) { // There will be no network request for duplicate subs, and hence we need to update the data from our cache
12791
- let dupSubId = duplicateSubIds[i];
12792
-
12793
- if (dupSubId) {
12794
- window.setTimeout(
12795
- this._onDuplicateRic.bind(this, sub["id"], this.getRowData(dupSubId + ric)),
12796
- 10);
12797
- }
12751
+ if(sub["id"].indexOf("_ci_") < 0){
12752
+ this.addSubscription(sub, sub["ric"]);
12798
12753
  }
12799
12754
  }
12800
12755
  };
@@ -12812,48 +12767,8 @@ DataCache.prototype._onQ2SubRemoved = function (e) {
12812
12767
 
12813
12768
  // chain subId fires twice, one with "_ci_" and one without "_ci_"
12814
12769
  // the subId with "_ci_" should be ignore
12815
- if(sub["id"].indexOf("_ci_") >= 0){
12816
- continue;
12817
- }
12818
-
12819
- this.removeSubscription(sub);
12820
- }
12821
- };
12822
-
12823
- /**
12824
- * @private
12825
- * @param {string} subId
12826
- * @param {Object.<string, *>} dupData
12827
- */
12828
- DataCache.prototype._onDuplicateRic = function (subId, dupData) {
12829
- let sub = this._subs[subId];
12830
-
12831
- if (!sub) {
12832
- return;
12833
- }
12834
-
12835
- sub = sub["s"]; // Quotes2' subscription
12836
-
12837
- let ric = sub["ric"];
12838
- let dupSubId = /** @type{string} */(dupData["SUB_ID"]);
12839
- let values = this._cloneRowData(dupData, ric, subId);
12840
-
12841
- if (!values) {
12842
- return;
12843
- }
12844
-
12845
- this._onInsert(sub, ric, values);
12846
-
12847
- let children = sub["children"];
12848
-
12849
- if (children) {
12850
- let childCount = children.length;
12851
-
12852
- for (let i = 0; i < childCount; ++i) {
12853
- ric = children[i];
12854
- values = this._cloneRowData(dupSubId, ric, subId);
12855
-
12856
- this._onInsert(sub, ric, values);
12770
+ if(sub["id"].indexOf("_ci_") < 0){
12771
+ this.removeSubscription(sub);
12857
12772
  }
12858
12773
  }
12859
12774
  };
@@ -12894,38 +12809,6 @@ DataCache.prototype._onDelete = function (sub, ric, values/*, rowN*/) {
12894
12809
  this.setRowData(sub["id"] + ric, null, {"subscription": sub, "ric": ric});
12895
12810
  };
12896
12811
 
12897
- /**
12898
- * @private
12899
- * @param {string|Object.<string, *>} obj
12900
- * @param {string} ric
12901
- * @param {string} newSubId
12902
- * @return {Object}
12903
- */
12904
- DataCache.prototype._cloneRowData = function (obj, ric, newSubId) {
12905
- let subId = (typeof obj === "string") ? obj : obj["SUB_ID"];
12906
- let fields = this._rows[subId + ric];
12907
-
12908
- if (!fields) { // The specified row has been removed
12909
- if (typeof obj === "object") {
12910
- fields = obj;
12911
- } else {
12912
- return null;
12913
- }
12914
- }
12915
-
12916
- let values = {};
12917
-
12918
- for (let key in fields) {
12919
- if (this._staticFields[key] == null) { // Static field must not be cloned
12920
- values[key] = fields[key];
12921
- }
12922
- }
12923
-
12924
- values["SUB_ID"] = newSubId;
12925
-
12926
- return values;
12927
- };
12928
-
12929
12812
  /** @protected
12930
12813
  * @ignore
12931
12814
  * @type {!Object.<string, Object>}
@@ -12944,12 +12827,6 @@ DataCache.prototype._subs;
12944
12827
  */
12945
12828
  DataCache.prototype._quotes2 = null;
12946
12829
 
12947
- /**
12948
- * @private
12949
- * @type {Object.<string, number>}
12950
- */
12951
- DataCache.prototype._staticFields = null;
12952
-
12953
12830
  /** @protected
12954
12831
  * @ignore
12955
12832
  * @type {boolean}
@@ -25785,7 +25662,7 @@ Core_Core.prototype._hasPendingRowChange = false;
25785
25662
  * @return {string}
25786
25663
  */
25787
25664
  Core_Core.getVersion = function () {
25788
- return "5.1.105";
25665
+ return "5.1.106";
25789
25666
  };
25790
25667
  /** {@link ElementWrapper#dispose}
25791
25668
  * @override