backendless 6.3.10 → 6.3.13-test.1
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 +5 -3
- package/dist/backendless.js +7962 -7202
- package/dist/backendless.js.map +1 -1
- package/dist/backendless.min.js +2 -2
- package/dist/backendless.min.js.LICENSE.txt +398 -0
- package/es/data/store.js +13 -5
- package/es/index.js +13 -1
- package/es/messaging/channel/index.js +6 -0
- package/es/rso/connection.js +6 -0
- package/es/users/index.js +3 -2
- package/lib/data/store.js +13 -5
- package/lib/index.js +13 -1
- package/lib/messaging/channel/index.js +6 -0
- package/lib/rso/connection.js +6 -0
- package/lib/users/index.js +3 -2
- package/package.json +4 -5
- package/src/data/store.js +20 -7
- package/src/index.js +13 -0
- package/src/messaging/channel/index.js +6 -0
- package/src/rso/connection.js +6 -0
- package/src/users/index.js +2 -2
|
@@ -1 +1,399 @@
|
|
|
1
|
+
/*! ../helpers/regeneratorRuntime */
|
|
2
|
+
|
|
3
|
+
/*! ../transport */
|
|
4
|
+
|
|
5
|
+
/*! ./assertThisInitialized.js */
|
|
6
|
+
|
|
7
|
+
/*! ./client */
|
|
8
|
+
|
|
9
|
+
/*! ./config */
|
|
10
|
+
|
|
11
|
+
/*! ./constants */
|
|
12
|
+
|
|
13
|
+
/*! ./debug */
|
|
14
|
+
|
|
15
|
+
/*! ./getPrototypeOf.js */
|
|
16
|
+
|
|
17
|
+
/*! ./keys */
|
|
18
|
+
|
|
19
|
+
/*! ./listeners */
|
|
20
|
+
|
|
21
|
+
/*! ./manager */
|
|
22
|
+
|
|
23
|
+
/*! ./methods */
|
|
24
|
+
|
|
25
|
+
/*! ./on */
|
|
26
|
+
|
|
27
|
+
/*! ./polling */
|
|
28
|
+
|
|
29
|
+
/*! ./polling-jsonp */
|
|
30
|
+
|
|
31
|
+
/*! ./polling-xhr */
|
|
32
|
+
|
|
33
|
+
/*! ./scope-connector */
|
|
34
|
+
|
|
35
|
+
/*! ./session */
|
|
36
|
+
|
|
37
|
+
/*! ./setPrototypeOf.js */
|
|
38
|
+
|
|
39
|
+
/*! ./socket */
|
|
40
|
+
|
|
41
|
+
/*! ./subscriptions */
|
|
42
|
+
|
|
43
|
+
/*! ./superPropBase.js */
|
|
44
|
+
|
|
45
|
+
/*! ./transport */
|
|
46
|
+
|
|
47
|
+
/*! ./transports/index */
|
|
48
|
+
|
|
49
|
+
/*! ./typeof.js */
|
|
50
|
+
|
|
51
|
+
/*! ./url */
|
|
52
|
+
|
|
53
|
+
/*! ./utf8 */
|
|
54
|
+
|
|
55
|
+
/*! ./utils */
|
|
56
|
+
|
|
57
|
+
/*! ./websocket */
|
|
58
|
+
|
|
59
|
+
/*! @babel/runtime/helpers/applyDecoratedDescriptor */
|
|
60
|
+
|
|
61
|
+
/*! @babel/runtime/helpers/asyncToGenerator */
|
|
62
|
+
|
|
63
|
+
/*! @babel/runtime/helpers/classCallCheck */
|
|
64
|
+
|
|
65
|
+
/*! @babel/runtime/helpers/createClass */
|
|
66
|
+
|
|
67
|
+
/*! @babel/runtime/helpers/defineProperty */
|
|
68
|
+
|
|
69
|
+
/*! @babel/runtime/helpers/get */
|
|
70
|
+
|
|
71
|
+
/*! @babel/runtime/helpers/getPrototypeOf */
|
|
72
|
+
|
|
73
|
+
/*! @babel/runtime/helpers/inherits */
|
|
74
|
+
|
|
75
|
+
/*! @babel/runtime/helpers/interopRequireDefault */
|
|
76
|
+
|
|
77
|
+
/*! @babel/runtime/helpers/possibleConstructorReturn */
|
|
78
|
+
|
|
79
|
+
/*! @babel/runtime/helpers/typeof */
|
|
80
|
+
|
|
81
|
+
/*! @babel/runtime/regenerator */
|
|
82
|
+
|
|
83
|
+
/*! after */
|
|
84
|
+
|
|
85
|
+
/*! arraybuffer.slice */
|
|
86
|
+
|
|
87
|
+
/*! backendless-request */
|
|
88
|
+
|
|
89
|
+
/*! backo2 */
|
|
90
|
+
|
|
91
|
+
/*! base64-arraybuffer */
|
|
92
|
+
|
|
93
|
+
/*! blob */
|
|
94
|
+
|
|
95
|
+
/*! component-bind */
|
|
96
|
+
|
|
97
|
+
/*! component-emitter */
|
|
98
|
+
|
|
99
|
+
/*! component-inherit */
|
|
100
|
+
|
|
101
|
+
/*! debug */
|
|
102
|
+
|
|
103
|
+
/*! engine.io-client */
|
|
104
|
+
|
|
105
|
+
/*! engine.io-parser */
|
|
106
|
+
|
|
107
|
+
/*! has-binary2 */
|
|
108
|
+
|
|
109
|
+
/*! has-cors */
|
|
110
|
+
|
|
1
111
|
/*! https://mths.be/utf8js v2.1.2 by @mathias */
|
|
112
|
+
|
|
113
|
+
/*! indexof */
|
|
114
|
+
|
|
115
|
+
/*! isarray */
|
|
116
|
+
|
|
117
|
+
/*! ms */
|
|
118
|
+
|
|
119
|
+
/*! parseqs */
|
|
120
|
+
|
|
121
|
+
/*! parseuri */
|
|
122
|
+
|
|
123
|
+
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
|
|
124
|
+
|
|
125
|
+
/*! socket.io-client */
|
|
126
|
+
|
|
127
|
+
/*! socket.io-parser */
|
|
128
|
+
|
|
129
|
+
/*! to-array */
|
|
130
|
+
|
|
131
|
+
/*! ws */
|
|
132
|
+
|
|
133
|
+
/*! xmlhttprequest-ssl */
|
|
134
|
+
|
|
135
|
+
/*! yeast */
|
|
136
|
+
|
|
137
|
+
/*!********************!*\
|
|
138
|
+
!*** ws (ignored) ***!
|
|
139
|
+
\********************/
|
|
140
|
+
|
|
141
|
+
/*!**********************!*\
|
|
142
|
+
!*** ./src/index.js ***!
|
|
143
|
+
\**********************/
|
|
144
|
+
|
|
145
|
+
/*!**********************!*\
|
|
146
|
+
!*** ./src/utils.js ***!
|
|
147
|
+
\**********************/
|
|
148
|
+
|
|
149
|
+
/*!***********************!*\
|
|
150
|
+
!*** ./src/client.js ***!
|
|
151
|
+
\***********************/
|
|
152
|
+
|
|
153
|
+
/*!***********************!*\
|
|
154
|
+
!*** ./src/config.js ***!
|
|
155
|
+
\***********************/
|
|
156
|
+
|
|
157
|
+
/*!***********************!*\
|
|
158
|
+
!*** ./src/socket.js ***!
|
|
159
|
+
\***********************/
|
|
160
|
+
|
|
161
|
+
/*!************************!*\
|
|
162
|
+
!*** ./src/methods.js ***!
|
|
163
|
+
\************************/
|
|
164
|
+
|
|
165
|
+
/*!************************!*\
|
|
166
|
+
!*** ./src/session.js ***!
|
|
167
|
+
\************************/
|
|
168
|
+
|
|
169
|
+
/*!**************************!*\
|
|
170
|
+
!*** ./src/constants.js ***!
|
|
171
|
+
\**************************/
|
|
172
|
+
|
|
173
|
+
/*!**************************!*\
|
|
174
|
+
!*** ./src/listeners.js ***!
|
|
175
|
+
\**************************/
|
|
176
|
+
|
|
177
|
+
/*!******************************!*\
|
|
178
|
+
!*** ./src/socket-parser.js ***!
|
|
179
|
+
\******************************/
|
|
180
|
+
|
|
181
|
+
/*!******************************!*\
|
|
182
|
+
!*** ./src/subscriptions.js ***!
|
|
183
|
+
\******************************/
|
|
184
|
+
|
|
185
|
+
/*!********************************!*\
|
|
186
|
+
!*** ./src/scope-connector.js ***!
|
|
187
|
+
\********************************/
|
|
188
|
+
|
|
189
|
+
/*!**********************************!*\
|
|
190
|
+
!*** ./node_modules/ms/index.js ***!
|
|
191
|
+
\**********************************/
|
|
192
|
+
|
|
193
|
+
/*!************************************!*\
|
|
194
|
+
!*** ./node_modules/blob/index.js ***!
|
|
195
|
+
\************************************/
|
|
196
|
+
|
|
197
|
+
/*!*************************************!*\
|
|
198
|
+
!*** ./node_modules/after/index.js ***!
|
|
199
|
+
\*************************************/
|
|
200
|
+
|
|
201
|
+
/*!*************************************!*\
|
|
202
|
+
!*** ./node_modules/yeast/index.js ***!
|
|
203
|
+
\*************************************/
|
|
204
|
+
|
|
205
|
+
/*!**************************************!*\
|
|
206
|
+
!*** ./node_modules/backo2/index.js ***!
|
|
207
|
+
\**************************************/
|
|
208
|
+
|
|
209
|
+
/*!***************************************!*\
|
|
210
|
+
!*** ./node_modules/indexof/index.js ***!
|
|
211
|
+
\***************************************/
|
|
212
|
+
|
|
213
|
+
/*!***************************************!*\
|
|
214
|
+
!*** ./node_modules/isarray/index.js ***!
|
|
215
|
+
\***************************************/
|
|
216
|
+
|
|
217
|
+
/*!***************************************!*\
|
|
218
|
+
!*** ./node_modules/parseqs/index.js ***!
|
|
219
|
+
\***************************************/
|
|
220
|
+
|
|
221
|
+
/*!****************************************!*\
|
|
222
|
+
!*** ./node_modules/has-cors/index.js ***!
|
|
223
|
+
\****************************************/
|
|
224
|
+
|
|
225
|
+
/*!****************************************!*\
|
|
226
|
+
!*** ./node_modules/parseuri/index.js ***!
|
|
227
|
+
\****************************************/
|
|
228
|
+
|
|
229
|
+
/*!****************************************!*\
|
|
230
|
+
!*** ./node_modules/to-array/index.js ***!
|
|
231
|
+
\****************************************/
|
|
232
|
+
|
|
233
|
+
/*!*****************************************!*\
|
|
234
|
+
!*** ./node_modules/debug/src/debug.js ***!
|
|
235
|
+
\*****************************************/
|
|
236
|
+
|
|
237
|
+
/*!*******************************************!*\
|
|
238
|
+
!*** ./node_modules/debug/src/browser.js ***!
|
|
239
|
+
\*******************************************/
|
|
240
|
+
|
|
241
|
+
/*!*******************************************!*\
|
|
242
|
+
!*** ./node_modules/has-binary2/index.js ***!
|
|
243
|
+
\*******************************************/
|
|
244
|
+
|
|
245
|
+
/*!**********************************************!*\
|
|
246
|
+
!*** ./node_modules/component-bind/index.js ***!
|
|
247
|
+
\**********************************************/
|
|
248
|
+
|
|
249
|
+
/*!*************************************************!*\
|
|
250
|
+
!*** ./node_modules/arraybuffer.slice/index.js ***!
|
|
251
|
+
\*************************************************/
|
|
252
|
+
|
|
253
|
+
/*!*************************************************!*\
|
|
254
|
+
!*** ./node_modules/component-emitter/index.js ***!
|
|
255
|
+
\*************************************************/
|
|
256
|
+
|
|
257
|
+
/*!*************************************************!*\
|
|
258
|
+
!*** ./node_modules/component-inherit/index.js ***!
|
|
259
|
+
\*************************************************/
|
|
260
|
+
|
|
261
|
+
/*!*************************************************!*\
|
|
262
|
+
!*** ./node_modules/socket.io-client/lib/on.js ***!
|
|
263
|
+
\*************************************************/
|
|
264
|
+
|
|
265
|
+
/*!**************************************************!*\
|
|
266
|
+
!*** ./node_modules/socket.io-client/lib/url.js ***!
|
|
267
|
+
\**************************************************/
|
|
268
|
+
|
|
269
|
+
/*!***************************************************!*\
|
|
270
|
+
!*** ./node_modules/engine.io-parser/lib/keys.js ***!
|
|
271
|
+
\***************************************************/
|
|
272
|
+
|
|
273
|
+
/*!***************************************************!*\
|
|
274
|
+
!*** ./node_modules/engine.io-parser/lib/utf8.js ***!
|
|
275
|
+
\***************************************************/
|
|
276
|
+
|
|
277
|
+
/*!****************************************************!*\
|
|
278
|
+
!*** ./node_modules/@babel/runtime/helpers/get.js ***!
|
|
279
|
+
\****************************************************/
|
|
280
|
+
|
|
281
|
+
/*!****************************************************!*\
|
|
282
|
+
!*** ./node_modules/engine.io-client/lib/index.js ***!
|
|
283
|
+
\****************************************************/
|
|
284
|
+
|
|
285
|
+
/*!****************************************************!*\
|
|
286
|
+
!*** ./node_modules/socket.io-client/lib/index.js ***!
|
|
287
|
+
\****************************************************/
|
|
288
|
+
|
|
289
|
+
/*!*****************************************************!*\
|
|
290
|
+
!*** ./node_modules/engine.io-client/lib/socket.js ***!
|
|
291
|
+
\*****************************************************/
|
|
292
|
+
|
|
293
|
+
/*!*****************************************************!*\
|
|
294
|
+
!*** ./node_modules/socket.io-client/lib/socket.js ***!
|
|
295
|
+
\*****************************************************/
|
|
296
|
+
|
|
297
|
+
/*!******************************************************!*\
|
|
298
|
+
!*** ./node_modules/engine.io-parser/lib/browser.js ***!
|
|
299
|
+
\******************************************************/
|
|
300
|
+
|
|
301
|
+
/*!******************************************************!*\
|
|
302
|
+
!*** ./node_modules/socket.io-client/lib/manager.js ***!
|
|
303
|
+
\******************************************************/
|
|
304
|
+
|
|
305
|
+
/*!*******************************************************!*\
|
|
306
|
+
!*** ./node_modules/@babel/runtime/helpers/typeof.js ***!
|
|
307
|
+
\*******************************************************/
|
|
308
|
+
|
|
309
|
+
/*!********************************************************!*\
|
|
310
|
+
!*** ./node_modules/engine.io-client/lib/transport.js ***!
|
|
311
|
+
\********************************************************/
|
|
312
|
+
|
|
313
|
+
/*!*********************************************************!*\
|
|
314
|
+
!*** ./node_modules/@babel/runtime/helpers/inherits.js ***!
|
|
315
|
+
\*********************************************************/
|
|
316
|
+
|
|
317
|
+
/*!**********************************************************!*\
|
|
318
|
+
!*** ./node_modules/@babel/runtime/regenerator/index.js ***!
|
|
319
|
+
\**********************************************************/
|
|
320
|
+
|
|
321
|
+
/*!************************************************************!*\
|
|
322
|
+
!*** ./node_modules/@babel/runtime/helpers/createClass.js ***!
|
|
323
|
+
\************************************************************/
|
|
324
|
+
|
|
325
|
+
/*!*************************************************************!*\
|
|
326
|
+
!*** ./node_modules/engine.io-client/lib/xmlhttprequest.js ***!
|
|
327
|
+
\*************************************************************/
|
|
328
|
+
|
|
329
|
+
/*!**************************************************************!*\
|
|
330
|
+
!*** ./node_modules/@babel/runtime/helpers/superPropBase.js ***!
|
|
331
|
+
\**************************************************************/
|
|
332
|
+
|
|
333
|
+
/*!***************************************************************!*\
|
|
334
|
+
!*** ./node_modules/@babel/runtime/helpers/classCallCheck.js ***!
|
|
335
|
+
\***************************************************************/
|
|
336
|
+
|
|
337
|
+
/*!***************************************************************!*\
|
|
338
|
+
!*** ./node_modules/@babel/runtime/helpers/defineProperty.js ***!
|
|
339
|
+
\***************************************************************/
|
|
340
|
+
|
|
341
|
+
/*!***************************************************************!*\
|
|
342
|
+
!*** ./node_modules/@babel/runtime/helpers/getPrototypeOf.js ***!
|
|
343
|
+
\***************************************************************/
|
|
344
|
+
|
|
345
|
+
/*!***************************************************************!*\
|
|
346
|
+
!*** ./node_modules/@babel/runtime/helpers/setPrototypeOf.js ***!
|
|
347
|
+
\***************************************************************/
|
|
348
|
+
|
|
349
|
+
/*!***************************************************************!*\
|
|
350
|
+
!*** ./node_modules/engine.io-client/lib/transports/index.js ***!
|
|
351
|
+
\***************************************************************/
|
|
352
|
+
|
|
353
|
+
/*!*****************************************************************!*\
|
|
354
|
+
!*** ./node_modules/@babel/runtime/helpers/asyncToGenerator.js ***!
|
|
355
|
+
\*****************************************************************/
|
|
356
|
+
|
|
357
|
+
/*!*****************************************************************!*\
|
|
358
|
+
!*** ./node_modules/engine.io-client/lib/transports/polling.js ***!
|
|
359
|
+
\*****************************************************************/
|
|
360
|
+
|
|
361
|
+
/*!*******************************************************************!*\
|
|
362
|
+
!*** ./node_modules/@babel/runtime/helpers/regeneratorRuntime.js ***!
|
|
363
|
+
\*******************************************************************/
|
|
364
|
+
|
|
365
|
+
/*!*******************************************************************!*\
|
|
366
|
+
!*** ./node_modules/base64-arraybuffer/lib/base64-arraybuffer.js ***!
|
|
367
|
+
\*******************************************************************/
|
|
368
|
+
|
|
369
|
+
/*!*******************************************************************!*\
|
|
370
|
+
!*** ./node_modules/engine.io-client/lib/transports/websocket.js ***!
|
|
371
|
+
\*******************************************************************/
|
|
372
|
+
|
|
373
|
+
/*!*********************************************************************!*\
|
|
374
|
+
!*** ./node_modules/engine.io-client/lib/transports/polling-xhr.js ***!
|
|
375
|
+
\*********************************************************************/
|
|
376
|
+
|
|
377
|
+
/*!**********************************************************************!*\
|
|
378
|
+
!*** ./node_modules/@babel/runtime/helpers/assertThisInitialized.js ***!
|
|
379
|
+
\**********************************************************************/
|
|
380
|
+
|
|
381
|
+
/*!**********************************************************************!*\
|
|
382
|
+
!*** ./node_modules/@babel/runtime/helpers/interopRequireDefault.js ***!
|
|
383
|
+
\**********************************************************************/
|
|
384
|
+
|
|
385
|
+
/*!**********************************************************************!*\
|
|
386
|
+
!*** ./node_modules/backendless-request/dist/backendless-request.js ***!
|
|
387
|
+
\**********************************************************************/
|
|
388
|
+
|
|
389
|
+
/*!***********************************************************************!*\
|
|
390
|
+
!*** ./node_modules/engine.io-client/lib/transports/polling-jsonp.js ***!
|
|
391
|
+
\***********************************************************************/
|
|
392
|
+
|
|
393
|
+
/*!*************************************************************************!*\
|
|
394
|
+
!*** ./node_modules/@babel/runtime/helpers/applyDecoratedDescriptor.js ***!
|
|
395
|
+
\*************************************************************************/
|
|
396
|
+
|
|
397
|
+
/*!**************************************************************************!*\
|
|
398
|
+
!*** ./node_modules/@babel/runtime/helpers/possibleConstructorReturn.js ***!
|
|
399
|
+
\**************************************************************************/
|
package/es/data/store.js
CHANGED
|
@@ -793,7 +793,7 @@ var DataStore = /*#__PURE__*/function () {
|
|
|
793
793
|
}, {
|
|
794
794
|
key: "parseRelationsResponse",
|
|
795
795
|
value: function parseRelationsResponse(result, RelationModel) {
|
|
796
|
-
return convertToClientRecords(result, RelationModel, this
|
|
796
|
+
return convertToClientRecords(result, RelationModel, this);
|
|
797
797
|
}
|
|
798
798
|
/**
|
|
799
799
|
* @private
|
|
@@ -802,7 +802,7 @@ var DataStore = /*#__PURE__*/function () {
|
|
|
802
802
|
}, {
|
|
803
803
|
key: "parseResponse",
|
|
804
804
|
value: function parseResponse(result) {
|
|
805
|
-
return convertToClientRecords(result, this.model, this
|
|
805
|
+
return convertToClientRecords(result, this.model, this);
|
|
806
806
|
}
|
|
807
807
|
/**
|
|
808
808
|
* @private
|
|
@@ -901,14 +901,15 @@ var convertToServerRecord = function () {
|
|
|
901
901
|
}();
|
|
902
902
|
|
|
903
903
|
var convertToClientRecords = function () {
|
|
904
|
-
return function (records, RootModel,
|
|
904
|
+
return function (records, RootModel, dataStore) {
|
|
905
905
|
if (!records) {
|
|
906
906
|
return records;
|
|
907
907
|
}
|
|
908
908
|
|
|
909
909
|
var context = {
|
|
910
910
|
RootModel: RootModel,
|
|
911
|
-
|
|
911
|
+
app: dataStore.app,
|
|
912
|
+
classToTableMap: dataStore.classToTableMap,
|
|
912
913
|
subIds: {},
|
|
913
914
|
postAssign: []
|
|
914
915
|
};
|
|
@@ -926,7 +927,14 @@ var convertToClientRecords = function () {
|
|
|
926
927
|
target[prop] = context.subIds[__subID];
|
|
927
928
|
delete source[prop].__subID;
|
|
928
929
|
} else {
|
|
929
|
-
var Model = context.classToTableMap[source[prop].___class]
|
|
930
|
+
var Model = context.classToTableMap[source[prop].___class];
|
|
931
|
+
|
|
932
|
+
if (!Model && context.app.useTableClassesFromGlobalScope && _utils["default"].globalScope[source[prop].___class]) {
|
|
933
|
+
// eslint-disable-next-line no-console
|
|
934
|
+
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');
|
|
935
|
+
Model = _utils["default"].globalScope[source[prop].___class];
|
|
936
|
+
}
|
|
937
|
+
|
|
930
938
|
target[prop] = Model ? new Model() : {};
|
|
931
939
|
|
|
932
940
|
if (__subID && !context.subIds[__subID]) {
|
package/es/index.js
CHANGED
|
@@ -35,7 +35,10 @@ var DEFAULT_PROPS = {
|
|
|
35
35
|
apiURI: '/api',
|
|
36
36
|
debugMode: false,
|
|
37
37
|
standalone: false,
|
|
38
|
-
XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined
|
|
38
|
+
XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined,
|
|
39
|
+
//TODO: this is a temporary to disable getting DataTable classes from the global scope
|
|
40
|
+
//TODO: it will be removed in the nearest future
|
|
41
|
+
useTableClassesFromGlobalScope: true
|
|
39
42
|
};
|
|
40
43
|
var STATELESS_PROPS = ['appId', 'apiKey', 'domain'];
|
|
41
44
|
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;
|
|
@@ -278,6 +281,15 @@ var Backendless = /*#__PURE__*/function () {
|
|
|
278
281
|
},
|
|
279
282
|
set: function set(appPath) {
|
|
280
283
|
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');
|
|
284
|
+
} ///--------useTableClassesFromGlobalScope-------///
|
|
285
|
+
|
|
286
|
+
}, {
|
|
287
|
+
key: "useTableClassesFromGlobalScope",
|
|
288
|
+
get: function get() {
|
|
289
|
+
return this.__useTableClassesFromGlobalScope;
|
|
290
|
+
},
|
|
291
|
+
set: function set(useTableClassesFromGlobalScope) {
|
|
292
|
+
this.__useTableClassesFromGlobalScope = !!useTableClassesFromGlobalScope;
|
|
281
293
|
} ///--------debugMode-------///
|
|
282
294
|
|
|
283
295
|
}, {
|
|
@@ -166,6 +166,12 @@ var Channel = (_dec = _rt.RTScopeConnector.connectionRequired(), (_class = /*#__
|
|
|
166
166
|
(0, _get2["default"])((0, _getPrototypeOf2["default"])(Channel.prototype), "addUserStatusListener", this).call(this, callback, onError);
|
|
167
167
|
return this;
|
|
168
168
|
}
|
|
169
|
+
}, {
|
|
170
|
+
key: "removeCommandListener",
|
|
171
|
+
value: function removeCommandListener(callback) {
|
|
172
|
+
(0, _get2["default"])((0, _getPrototypeOf2["default"])(Channel.prototype), "removeCommandListeners", this).call(this, callback);
|
|
173
|
+
return this;
|
|
174
|
+
}
|
|
169
175
|
}, {
|
|
170
176
|
key: "removeCommandListeners",
|
|
171
177
|
value: function removeCommandListeners(callback) {
|
package/es/rso/connection.js
CHANGED
|
@@ -155,6 +155,12 @@ var RemoteSharedObject = (_dec = _rt.RTScopeConnector.connectionRequired(), _dec
|
|
|
155
155
|
(0, _get2["default"])((0, _getPrototypeOf2["default"])(RemoteSharedObject.prototype), "addCommandListener", this).call(this, callback, onError);
|
|
156
156
|
return this;
|
|
157
157
|
}
|
|
158
|
+
}, {
|
|
159
|
+
key: "removeCommandListener",
|
|
160
|
+
value: function removeCommandListener(callback) {
|
|
161
|
+
(0, _get2["default"])((0, _getPrototypeOf2["default"])(RemoteSharedObject.prototype), "removeCommandListeners", this).call(this, callback);
|
|
162
|
+
return this;
|
|
163
|
+
}
|
|
158
164
|
}, {
|
|
159
165
|
key: "removeCommandListeners",
|
|
160
166
|
value: function removeCommandListeners(callback) {
|
package/es/users/index.js
CHANGED
|
@@ -951,14 +951,15 @@ var Users = /*#__PURE__*/function () {
|
|
|
951
951
|
}()
|
|
952
952
|
}, {
|
|
953
953
|
key: "getAuthorizationUrlLink",
|
|
954
|
-
value: function getAuthorizationUrlLink(providerCode, fieldsMapping, scope, redirect, redirectAfterLoginUrl) {
|
|
954
|
+
value: function getAuthorizationUrlLink(providerCode, fieldsMapping, scope, redirect, redirectAfterLoginUrl, callbackUrlDomain) {
|
|
955
955
|
return this.app.request.post({
|
|
956
956
|
url: this.app.urls.userAuthorizationURL(providerCode),
|
|
957
957
|
data: {
|
|
958
958
|
fieldsMapping: fieldsMapping,
|
|
959
959
|
permissions: scope,
|
|
960
960
|
redirect: redirect,
|
|
961
|
-
redirectAfterLoginUrl: redirectAfterLoginUrl
|
|
961
|
+
redirectAfterLoginUrl: redirectAfterLoginUrl,
|
|
962
|
+
callbackUrlDomain: callbackUrlDomain
|
|
962
963
|
}
|
|
963
964
|
});
|
|
964
965
|
}
|
package/lib/data/store.js
CHANGED
|
@@ -793,7 +793,7 @@ var DataStore = /*#__PURE__*/function () {
|
|
|
793
793
|
}, {
|
|
794
794
|
key: "parseRelationsResponse",
|
|
795
795
|
value: function parseRelationsResponse(result, RelationModel) {
|
|
796
|
-
return convertToClientRecords(result, RelationModel, this
|
|
796
|
+
return convertToClientRecords(result, RelationModel, this);
|
|
797
797
|
}
|
|
798
798
|
/**
|
|
799
799
|
* @private
|
|
@@ -802,7 +802,7 @@ var DataStore = /*#__PURE__*/function () {
|
|
|
802
802
|
}, {
|
|
803
803
|
key: "parseResponse",
|
|
804
804
|
value: function parseResponse(result) {
|
|
805
|
-
return convertToClientRecords(result, this.model, this
|
|
805
|
+
return convertToClientRecords(result, this.model, this);
|
|
806
806
|
}
|
|
807
807
|
/**
|
|
808
808
|
* @private
|
|
@@ -901,14 +901,15 @@ var convertToServerRecord = function () {
|
|
|
901
901
|
}();
|
|
902
902
|
|
|
903
903
|
var convertToClientRecords = function () {
|
|
904
|
-
return function (records, RootModel,
|
|
904
|
+
return function (records, RootModel, dataStore) {
|
|
905
905
|
if (!records) {
|
|
906
906
|
return records;
|
|
907
907
|
}
|
|
908
908
|
|
|
909
909
|
var context = {
|
|
910
910
|
RootModel: RootModel,
|
|
911
|
-
|
|
911
|
+
app: dataStore.app,
|
|
912
|
+
classToTableMap: dataStore.classToTableMap,
|
|
912
913
|
subIds: {},
|
|
913
914
|
postAssign: []
|
|
914
915
|
};
|
|
@@ -926,7 +927,14 @@ var convertToClientRecords = function () {
|
|
|
926
927
|
target[prop] = context.subIds[__subID];
|
|
927
928
|
delete source[prop].__subID;
|
|
928
929
|
} else {
|
|
929
|
-
var Model = context.classToTableMap[source[prop].___class]
|
|
930
|
+
var Model = context.classToTableMap[source[prop].___class];
|
|
931
|
+
|
|
932
|
+
if (!Model && context.app.useTableClassesFromGlobalScope && _utils["default"].globalScope[source[prop].___class]) {
|
|
933
|
+
// eslint-disable-next-line no-console
|
|
934
|
+
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');
|
|
935
|
+
Model = _utils["default"].globalScope[source[prop].___class];
|
|
936
|
+
}
|
|
937
|
+
|
|
930
938
|
target[prop] = Model ? new Model() : {};
|
|
931
939
|
|
|
932
940
|
if (__subID && !context.subIds[__subID]) {
|
package/lib/index.js
CHANGED
|
@@ -35,7 +35,10 @@ var DEFAULT_PROPS = {
|
|
|
35
35
|
apiURI: '/api',
|
|
36
36
|
debugMode: false,
|
|
37
37
|
standalone: false,
|
|
38
|
-
XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined
|
|
38
|
+
XMLHttpRequest: typeof XMLHttpRequest !== 'undefined' ? XMLHttpRequest : undefined,
|
|
39
|
+
//TODO: this is a temporary to disable getting DataTable classes from the global scope
|
|
40
|
+
//TODO: it will be removed in the nearest future
|
|
41
|
+
useTableClassesFromGlobalScope: true
|
|
39
42
|
};
|
|
40
43
|
var STATELESS_PROPS = ['appId', 'apiKey', 'domain'];
|
|
41
44
|
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;
|
|
@@ -278,6 +281,15 @@ var Backendless = /*#__PURE__*/function () {
|
|
|
278
281
|
},
|
|
279
282
|
set: function set(appPath) {
|
|
280
283
|
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');
|
|
284
|
+
} ///--------useTableClassesFromGlobalScope-------///
|
|
285
|
+
|
|
286
|
+
}, {
|
|
287
|
+
key: "useTableClassesFromGlobalScope",
|
|
288
|
+
get: function get() {
|
|
289
|
+
return this.__useTableClassesFromGlobalScope;
|
|
290
|
+
},
|
|
291
|
+
set: function set(useTableClassesFromGlobalScope) {
|
|
292
|
+
this.__useTableClassesFromGlobalScope = !!useTableClassesFromGlobalScope;
|
|
281
293
|
} ///--------debugMode-------///
|
|
282
294
|
|
|
283
295
|
}, {
|
|
@@ -166,6 +166,12 @@ var Channel = (_dec = _rt.RTScopeConnector.connectionRequired(), (_class = /*#__
|
|
|
166
166
|
(0, _get2["default"])((0, _getPrototypeOf2["default"])(Channel.prototype), "addUserStatusListener", this).call(this, callback, onError);
|
|
167
167
|
return this;
|
|
168
168
|
}
|
|
169
|
+
}, {
|
|
170
|
+
key: "removeCommandListener",
|
|
171
|
+
value: function removeCommandListener(callback) {
|
|
172
|
+
(0, _get2["default"])((0, _getPrototypeOf2["default"])(Channel.prototype), "removeCommandListeners", this).call(this, callback);
|
|
173
|
+
return this;
|
|
174
|
+
}
|
|
169
175
|
}, {
|
|
170
176
|
key: "removeCommandListeners",
|
|
171
177
|
value: function removeCommandListeners(callback) {
|
package/lib/rso/connection.js
CHANGED
|
@@ -155,6 +155,12 @@ var RemoteSharedObject = (_dec = _rt.RTScopeConnector.connectionRequired(), _dec
|
|
|
155
155
|
(0, _get2["default"])((0, _getPrototypeOf2["default"])(RemoteSharedObject.prototype), "addCommandListener", this).call(this, callback, onError);
|
|
156
156
|
return this;
|
|
157
157
|
}
|
|
158
|
+
}, {
|
|
159
|
+
key: "removeCommandListener",
|
|
160
|
+
value: function removeCommandListener(callback) {
|
|
161
|
+
(0, _get2["default"])((0, _getPrototypeOf2["default"])(RemoteSharedObject.prototype), "removeCommandListeners", this).call(this, callback);
|
|
162
|
+
return this;
|
|
163
|
+
}
|
|
158
164
|
}, {
|
|
159
165
|
key: "removeCommandListeners",
|
|
160
166
|
value: function removeCommandListeners(callback) {
|
package/lib/users/index.js
CHANGED
|
@@ -951,14 +951,15 @@ var Users = /*#__PURE__*/function () {
|
|
|
951
951
|
}()
|
|
952
952
|
}, {
|
|
953
953
|
key: "getAuthorizationUrlLink",
|
|
954
|
-
value: function getAuthorizationUrlLink(providerCode, fieldsMapping, scope, redirect, redirectAfterLoginUrl) {
|
|
954
|
+
value: function getAuthorizationUrlLink(providerCode, fieldsMapping, scope, redirect, redirectAfterLoginUrl, callbackUrlDomain) {
|
|
955
955
|
return this.app.request.post({
|
|
956
956
|
url: this.app.urls.userAuthorizationURL(providerCode),
|
|
957
957
|
data: {
|
|
958
958
|
fieldsMapping: fieldsMapping,
|
|
959
959
|
permissions: scope,
|
|
960
960
|
redirect: redirect,
|
|
961
|
-
redirectAfterLoginUrl: redirectAfterLoginUrl
|
|
961
|
+
redirectAfterLoginUrl: redirectAfterLoginUrl,
|
|
962
|
+
callbackUrlDomain: callbackUrlDomain
|
|
962
963
|
}
|
|
963
964
|
});
|
|
964
965
|
}
|