@smartbit4all/ng-client 3.1.11 → 3.1.13

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.
@@ -10548,34 +10548,25 @@ class SmartGridService {
10548
10548
  }
10549
10549
  }
10550
10550
  SmartGridService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService, deps: [{ token: GridService }], target: i0.ɵɵFactoryTarget.Injectable });
10551
- SmartGridService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService, providedIn: 'root' });
10551
+ SmartGridService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService });
10552
10552
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService, decorators: [{
10553
- type: Injectable,
10554
- args: [{
10555
- providedIn: 'root',
10556
- }]
10553
+ type: Injectable
10557
10554
  }], ctorParameters: function () { return [{ type: GridService }]; } });
10558
10555
 
10559
10556
  class TableLayoutDefinerComponent {
10560
- constructor(data, service, dialogRef) {
10557
+ constructor(data, dialogRef) {
10561
10558
  this.data = data;
10562
- this.service = service;
10563
10559
  this.dialogRef = dialogRef;
10564
10560
  this._destroy$ = new Subject();
10565
10561
  this.orderedColumnsAsObject = {};
10566
10562
  this.disableSave = false;
10567
10563
  this.alwaysShowColumns = [];
10568
10564
  this.addDisabled = false;
10569
- // this.view = Object.assign(data.customComponentInputs.config.view);
10570
10565
  this.view = JSON.parse(JSON.stringify(data.customComponentInputs.config.view));
10571
10566
  this.mapOrderedColumnsToObject();
10572
10567
  this.constructForms();
10573
10568
  this.getAlwaysShowColumns();
10574
10569
  this.addDisabled = !(this.forms.length < this.view.descriptor.columns.length);
10575
- dialogRef
10576
- .beforeClosed()
10577
- .pipe(takeUntil(this._destroy$))
10578
- .subscribe(() => { });
10579
10570
  }
10580
10571
  ngOnDestroy() {
10581
10572
  this._destroy$.next();
@@ -10626,11 +10617,9 @@ class TableLayoutDefinerComponent {
10626
10617
  }, 1000);
10627
10618
  }
10628
10619
  addColumn() {
10629
- var _a, _b, _c, _d;
10630
- console.log('Mezők száma', (_a = this.forms) === null || _a === void 0 ? void 0 : _a.length);
10631
- console.log('Oszolop meták száma', (_c = (_b = this.view) === null || _b === void 0 ? void 0 : _b.descriptor) === null || _c === void 0 ? void 0 : _c.columns.length);
10620
+ var _a;
10632
10621
  if (this.forms.length < this.view.descriptor.columns.length) {
10633
- (_d = this.view) === null || _d === void 0 ? void 0 : _d.orderedColumnNames.push('');
10622
+ (_a = this.view) === null || _a === void 0 ? void 0 : _a.orderedColumnNames.push('');
10634
10623
  this.orderedColumnsAsObject[this.view.orderedColumnNames.length - 1] = '';
10635
10624
  this.constructForms();
10636
10625
  this.disableSave = true;
@@ -10686,7 +10675,7 @@ class TableLayoutDefinerComponent {
10686
10675
  orderByList: this.view.orderByList,
10687
10676
  orderedColumnNames: this.view.orderedColumnNames,
10688
10677
  };
10689
- yield this.service.update(config.uuid, config.identifier, updateData);
10678
+ yield this.data.customComponentInputs.config.service.update(config.uuid, config.identifier, updateData);
10690
10679
  this.dialogRef.close();
10691
10680
  });
10692
10681
  }
@@ -10723,7 +10712,7 @@ class TableLayoutDefinerComponent {
10723
10712
  return true;
10724
10713
  }
10725
10714
  }
10726
- TableLayoutDefinerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: TableLayoutDefinerComponent, deps: [{ token: MAT_DIALOG_DATA }, { token: SmartGridService }, { token: i1$2.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
10715
+ TableLayoutDefinerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: TableLayoutDefinerComponent, deps: [{ token: MAT_DIALOG_DATA }, { token: i1$2.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
10727
10716
  TableLayoutDefinerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: TableLayoutDefinerComponent, selector: "app-table-layout-definer", viewQueries: [{ propertyName: "formChildren", predicate: ["forms"], descendants: true }], ngImport: i0, template: "<div class=\"edit-columns-container\">\r\n <div class=\"example-list\" cdkDropList (cdkDropListDropped)=\"drop($event)\">\r\n <div class=\"column-meta-row\" *ngFor=\"let col of forms\" cdkDrag cdkDragLockAxis=\"y\">\r\n <smart-icon color=\"primary\" icon=\"drag_handle\"></smart-icon>\r\n <smartform class=\"form\" #forms [smartForm]=\"col\"></smartform>\r\n <button\r\n *ngIf=\"isAlwaysShow(col) && (view?.orderedColumnNames)!.length > 1\"\r\n (click)=\"removeColumn(col)\"\r\n mat-icon-button\r\n color=\"primary\"\r\n >\r\n <mat-icon>delete_outline</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n\r\n <div appStickyMenu class=\"button-toolbar\">\r\n <button mat-icon-button color=\"primary\" [disabled]=\"addDisabled\" (click)=\"addColumn()\">\r\n <mat-icon>add</mat-icon>\r\n </button>\r\n <button mat-raised-button color=\"primary\" [disabled]=\"disableSave\" (click)=\"submit()\">\r\n Ment\u00E9s\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".edit-columns-container{padding:1rem;display:flex;flex-direction:column;gap:1rem}.row{display:flex;flex-direction:row;gap:.5rem}.form{flex:1}.fields{padding:1rem 0;display:flex;flex-direction:column;gap:.5rem}.example-list{display:flex;flex-direction:column;gap:1rem;width:500px;max-width:100%;max-height:80vh;overflow:auto}.column-meta-row{display:flex;flex-direction:row;gap:1rem;justify-content:space-between;border:solid 1px #ccc;padding:1rem}.buttonsContainer{display:flex;flex-direction:row;justify-content:space-between}.cdk-drag-preview{box-sizing:border-box;border-radius:4px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.cdk-drag-placeholder{opacity:0}.cdk-drag-animating{transition:transform .25s cubic-bezier(0,0,.2,1)}.example-box:last-child{border:none}.example-list.cdk-drop-list-dragging .example-box:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}h2{margin:0}.button-toolbar{display:flex;flex-direction:row;justify-content:space-between;padding:.5rem}\n"], components: [{ type: SmartIconComponent, selector: "smart-icon", inputs: ["icon", "color"] }, { type: SmartformComponent, selector: "smartform", inputs: ["smartForm"] }, { type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i1$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: i2$2.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$2.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
10728
10717
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: TableLayoutDefinerComponent, decorators: [{
10729
10718
  type: Component,
@@ -10732,7 +10721,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
10732
10721
  return [{ type: undefined, decorators: [{
10733
10722
  type: Inject,
10734
10723
  args: [MAT_DIALOG_DATA]
10735
- }] }, { type: SmartGridService }, { type: i1$2.MatDialogRef }];
10724
+ }] }, { type: i1$2.MatDialogRef }];
10736
10725
  }, propDecorators: { formChildren: [{
10737
10726
  type: ViewChildren,
10738
10727
  args: ['forms']
@@ -11595,17 +11584,11 @@ class SmartGridComponent {
11595
11584
  uuid: this.uuid,
11596
11585
  identifier: this.smartGrid.gridIdentifier,
11597
11586
  view: this.service.gridModel.view,
11587
+ service: this.service,
11598
11588
  },
11599
11589
  },
11600
11590
  };
11601
- let dialogRef = this.dialog.open(TableLayoutDefinerComponent, { data: dialogData });
11602
- dialogRef
11603
- .afterClosed()
11604
- .pipe(takeUntil(this._destroy$))
11605
- .subscribe((result) => {
11606
- this.service.gridModelChanged.next();
11607
- dialogRef.close();
11608
- });
11591
+ this.dialog.open(TableLayoutDefinerComponent, { data: dialogData });
11609
11592
  }
11610
11593
  }
11611
11594
  SmartGridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridComponent, deps: [{ token: SmartGridService }, { token: ComponentFactoryService }, { token: i1$2.MatDialog }], target: i0.ɵɵFactoryTarget.Component });