@smartbit4all/ng-client 1.1.5 → 1.1.7

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.
@@ -2377,55 +2377,65 @@ class SmartViewContextService {
2377
2377
  return await this.view.downloadItem(uuid, item).toPromise();
2378
2378
  }
2379
2379
  async performAction(uuid, uiActionRequest) {
2380
- const isCompleted = new Subject();
2381
- this.apiQueueService.addToQueue({
2382
- callback: this._performAction.bind(this),
2383
- config: {
2384
- uuid,
2385
- uiActionRequest,
2386
- },
2387
- isCompleted,
2380
+ return await this._performAction({
2381
+ uuid,
2382
+ uiActionRequest,
2388
2383
  });
2389
- return await isCompleted.toPromise();
2384
+ // const isCompleted = new Subject<void>();
2385
+ // this.apiQueueService.addToQueue({
2386
+ // callback: this._performAction.bind(this),
2387
+ // config: {
2388
+ // uuid,
2389
+ // uiActionRequest,
2390
+ // },
2391
+ // isCompleted,
2392
+ // });
2393
+ // return await isCompleted.toPromise();
2390
2394
  }
2391
2395
  async performWidgetAction(uuid, widgetId, nodeId, uiActionRequest) {
2392
- const isCompleted = new Subject();
2393
- this.apiQueueService.addToQueue({
2394
- callback: this._performWidgetAction.bind(this),
2395
- config: {
2396
- uuid,
2397
- widgetId,
2398
- nodeId,
2399
- uiActionRequest,
2400
- },
2401
- isCompleted,
2402
- });
2403
- return await isCompleted.toPromise();
2396
+ return await this._performWidgetAction({ uuid, widgetId, nodeId, uiActionRequest });
2397
+ // const isCompleted = new Subject<void>();
2398
+ // this.apiQueueService.addToQueue({
2399
+ // callback: this._performWidgetAction.bind(this),
2400
+ // config: {
2401
+ // uuid,
2402
+ // widgetId,
2403
+ // nodeId,
2404
+ // uiActionRequest,
2405
+ // },
2406
+ // isCompleted,
2407
+ // });
2408
+ // return await isCompleted.toPromise();
2404
2409
  }
2405
2410
  async performWidgetMainAction(uuid, widgetId, uiActionRequest) {
2406
- const isCompleted = new Subject();
2407
- this.apiQueueService.addToQueue({
2408
- callback: this._performWidgetMainAction.bind(this),
2409
- config: {
2410
- uuid,
2411
- widgetId,
2412
- uiActionRequest,
2413
- },
2414
- isCompleted,
2415
- });
2416
- return await isCompleted.toPromise();
2411
+ return await this._performWidgetMainAction({ uuid, widgetId, uiActionRequest });
2412
+ // const isCompleted = new Subject<void>();
2413
+ // this.apiQueueService.addToQueue({
2414
+ // callback: this._performWidgetMainAction.bind(this),
2415
+ // config: {
2416
+ // uuid,
2417
+ // widgetId,
2418
+ // uiActionRequest,
2419
+ // },
2420
+ // isCompleted,
2421
+ // });
2422
+ // return await isCompleted.toPromise();
2417
2423
  }
2418
2424
  async dataChanged(uuid, dataChange) {
2419
- const isCompleted = new Subject();
2420
- this.apiQueueService.addToQueue({
2421
- callback: this._dataChanged.bind(this),
2422
- config: {
2423
- uuid,
2424
- dataChange,
2425
- },
2426
- isCompleted,
2427
- }, true);
2428
- return await isCompleted.toPromise();
2425
+ return await this._dataChanged({ uuid, dataChange });
2426
+ // const isCompleted = new Subject<void>();
2427
+ // this.apiQueueService.addToQueue(
2428
+ // {
2429
+ // callback: this._dataChanged.bind(this),
2430
+ // config: {
2431
+ // uuid,
2432
+ // dataChange,
2433
+ // },
2434
+ // isCompleted,
2435
+ // },
2436
+ // true
2437
+ // );
2438
+ // return await isCompleted.toPromise();
2429
2439
  }
2430
2440
  async _performAction(config) {
2431
2441
  return await this.handlePerformActionResponse(await this.view.performAction(config.uuid, config.uiActionRequest).toPromise());
@@ -3304,7 +3314,8 @@ class UiActionDescriptorService {
3304
3314
  }
3305
3315
  if (!actionDescriptor) {
3306
3316
  isUnkown = true;
3307
- actionDescriptor = this.basicActionDescriptors.get('UNKOWN');
3317
+ let unkownActionDescriptor = this.basicActionDescriptors.get('UNKOWN');
3318
+ actionDescriptor = { ...unkownActionDescriptor };
3308
3319
  actionDescriptor.title = code;
3309
3320
  }
3310
3321
  if (!actionDescriptor.dialog) {