backendless 6.6.1 → 6.6.3

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/backendless.d.ts CHANGED
@@ -6,7 +6,6 @@ declare module Backendless {
6
6
  type JSONValue = string | number | boolean | { [x: string]: JSONValue } | Array<JSONValue>
7
7
 
8
8
  let debugMode: boolean;
9
- let useTableClassesFromGlobalScope: boolean;
10
9
  let serverURL: string;
11
10
  let appId: string;
12
11
  let apiKey: string;
@@ -39,7 +38,6 @@ declare module Backendless {
39
38
  domain?: string;
40
39
  debugMode?: boolean;
41
40
  XMLHttpRequest?: XMLHttpRequest;
42
- useTableClassesFromGlobalScope?: boolean;
43
41
  }
44
42
 
45
43
  /**
@@ -1,6 +1,6 @@
1
1
  /*
2
2
  * ********************************************************************************************************************
3
- * Backendless SDK for JavaScript. Version: 6.6.1
3
+ * Backendless SDK for JavaScript. Version: 6.6.3
4
4
  *
5
5
  * Copyright 2012-2023 BACKENDLESS.COM. All Rights Reserved.
6
6
  *
@@ -16927,46 +16927,49 @@ var DataStore = /*#__PURE__*/function () {
16927
16927
  key: "getObjectCount",
16928
16928
  value: function () {
16929
16929
  var _getObjectCount = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee10(condition) {
16930
- var distinct;
16930
+ var distinct, groupBy;
16931
16931
  return _regenerator["default"].wrap(function _callee10$(_context10) {
16932
16932
  while (1) {
16933
16933
  switch (_context10.prev = _context10.next) {
16934
16934
  case 0:
16935
16935
  distinct = undefined;
16936
+ groupBy = undefined;
16936
16937
 
16937
16938
  if (!condition) {
16938
- _context10.next = 9;
16939
+ _context10.next = 11;
16939
16940
  break;
16940
16941
  }
16941
16942
 
16942
16943
  if (!(condition instanceof _dataQueryBuilder["default"])) {
16943
- _context10.next = 7;
16944
+ _context10.next = 9;
16944
16945
  break;
16945
16946
  }
16946
16947
 
16947
16948
  distinct = condition.getDistinct() || undefined;
16949
+ groupBy = condition.getGroupBy() || undefined;
16948
16950
  condition = condition.getWhereClause() || undefined;
16949
- _context10.next = 9;
16951
+ _context10.next = 11;
16950
16952
  break;
16951
16953
 
16952
- case 7:
16954
+ case 9:
16953
16955
  if (!(typeof condition !== 'string')) {
16954
- _context10.next = 9;
16956
+ _context10.next = 11;
16955
16957
  break;
16956
16958
  }
16957
16959
 
16958
16960
  throw new Error('Condition must be a string or an instance of DataQueryBuilder.');
16959
16961
 
16960
- case 9:
16962
+ case 11:
16961
16963
  return _context10.abrupt("return", this.app.request.post({
16962
16964
  url: this.app.urls.dataTableCount(this.className),
16963
16965
  data: {
16964
16966
  where: condition,
16965
- distinct: distinct
16967
+ distinct: distinct,
16968
+ groupBy: groupBy
16966
16969
  }
16967
16970
  }));
16968
16971
 
16969
- case 10:
16972
+ case 12:
16970
16973
  case "end":
16971
16974
  return _context10.stop();
16972
16975
  }
@@ -17436,13 +17439,6 @@ var convertToClientRecords = function () {
17436
17439
  delete source[prop].__subID;
17437
17440
  } else {
17438
17441
  var Model = context.classToTableMap[source[prop].___class];
17439
-
17440
- if (!Model && context.app.useTableClassesFromGlobalScope && _utils["default"].globalScope[source[prop].___class]) {
17441
- // eslint-disable-next-line no-console
17442
- console.warn('Resolving DataTable classes from the global scope is deprecated ' + 'and it won\'t be supported in the nearest future. ' + 'Instead, you should register your DataTable classes ' + 'using the following method Backendless.Data.mapTableToClass');
17443
- Model = _utils["default"].globalScope[source[prop].___class];
17444
- }
17445
-
17446
17442
  target[prop] = Model ? new Model() : {};
17447
17443
 
17448
17444
  if (__subID && !context.subIds[__subID]) {
@@ -20265,10 +20261,7 @@ var DEFAULT_PROPS = {
20265
20261
  apiURI: '/api',
20266
20262
  debugMode: false,
20267
20263
  standalone: false,
20268
- XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined,
20269
- //TODO: this is a temporary to disable getting DataTable classes from the global scope
20270
- //TODO: it will be removed in the nearest future
20271
- useTableClassesFromGlobalScope: true
20264
+ XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined
20272
20265
  };
20273
20266
  var STATELESS_PROPS = ['appId', 'apiKey', 'domain'];
20274
20267
  var root = (typeof self === "undefined" ? "undefined" : (0, _typeof2["default"])(self)) === 'object' && self.self === self && self || (typeof global === "undefined" ? "undefined" : (0, _typeof2["default"])(global)) === 'object' && global.global === global && global;
@@ -20514,15 +20507,6 @@ var Backendless = /*#__PURE__*/function () {
20514
20507
  },
20515
20508
  set: function set(appPath) {
20516
20509
  throw new Error("Setting '".concat(appPath, "' value to Backendless.appPath directly is not possible, ") + 'instead you must use Backendless.initApp(APP_ID, API_KEY) for setup the value');
20517
- } ///--------useTableClassesFromGlobalScope-------///
20518
-
20519
- }, {
20520
- key: "useTableClassesFromGlobalScope",
20521
- get: function get() {
20522
- return this.__useTableClassesFromGlobalScope;
20523
- },
20524
- set: function set(useTableClassesFromGlobalScope) {
20525
- this.__useTableClassesFromGlobalScope = !!useTableClassesFromGlobalScope;
20526
20510
  } ///--------debugMode-------///
20527
20511
 
20528
20512
  }, {