@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.
- package/esm2020/lib/smart-grid/components/table-layout-definer/table-layout-definer.component.mjs +13 -22
- package/esm2020/lib/smart-grid/smart-grid.component.mjs +3 -9
- package/esm2020/lib/smart-grid/smart-grid.service.mjs +3 -6
- package/fesm2015/smartbit4all-ng-client.mjs +10 -27
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +8 -25
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/smart-grid/components/table-layout-definer/table-layout-definer.component.d.ts +2 -2
- package/lib/smart-grid/smart-grid.service.d.ts +1 -1
- package/package.json +1 -1
- package/smartbit4all-ng-client-3.1.13.tgz +0 -0
- package/smartbit4all-ng-client-3.1.11.tgz +0 -0
|
@@ -10465,34 +10465,25 @@ class SmartGridService {
|
|
|
10465
10465
|
}
|
|
10466
10466
|
}
|
|
10467
10467
|
SmartGridService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService, deps: [{ token: GridService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
10468
|
-
SmartGridService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService
|
|
10468
|
+
SmartGridService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService });
|
|
10469
10469
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartGridService, decorators: [{
|
|
10470
|
-
type: Injectable
|
|
10471
|
-
args: [{
|
|
10472
|
-
providedIn: 'root',
|
|
10473
|
-
}]
|
|
10470
|
+
type: Injectable
|
|
10474
10471
|
}], ctorParameters: function () { return [{ type: GridService }]; } });
|
|
10475
10472
|
|
|
10476
10473
|
class TableLayoutDefinerComponent {
|
|
10477
|
-
constructor(data,
|
|
10474
|
+
constructor(data, dialogRef) {
|
|
10478
10475
|
this.data = data;
|
|
10479
|
-
this.service = service;
|
|
10480
10476
|
this.dialogRef = dialogRef;
|
|
10481
10477
|
this._destroy$ = new Subject();
|
|
10482
10478
|
this.orderedColumnsAsObject = {};
|
|
10483
10479
|
this.disableSave = false;
|
|
10484
10480
|
this.alwaysShowColumns = [];
|
|
10485
10481
|
this.addDisabled = false;
|
|
10486
|
-
// this.view = Object.assign(data.customComponentInputs.config.view);
|
|
10487
10482
|
this.view = JSON.parse(JSON.stringify(data.customComponentInputs.config.view));
|
|
10488
10483
|
this.mapOrderedColumnsToObject();
|
|
10489
10484
|
this.constructForms();
|
|
10490
10485
|
this.getAlwaysShowColumns();
|
|
10491
10486
|
this.addDisabled = !(this.forms.length < this.view.descriptor.columns.length);
|
|
10492
|
-
dialogRef
|
|
10493
|
-
.beforeClosed()
|
|
10494
|
-
.pipe(takeUntil(this._destroy$))
|
|
10495
|
-
.subscribe(() => { });
|
|
10496
10487
|
}
|
|
10497
10488
|
ngOnDestroy() {
|
|
10498
10489
|
this._destroy$.next();
|
|
@@ -10541,8 +10532,6 @@ class TableLayoutDefinerComponent {
|
|
|
10541
10532
|
}, 1000);
|
|
10542
10533
|
}
|
|
10543
10534
|
addColumn() {
|
|
10544
|
-
console.log('Mezők száma', this.forms?.length);
|
|
10545
|
-
console.log('Oszolop meták száma', this.view?.descriptor?.columns.length);
|
|
10546
10535
|
if (this.forms.length < this.view.descriptor.columns.length) {
|
|
10547
10536
|
this.view?.orderedColumnNames.push('');
|
|
10548
10537
|
this.orderedColumnsAsObject[this.view.orderedColumnNames.length - 1] = '';
|
|
@@ -10597,7 +10586,7 @@ class TableLayoutDefinerComponent {
|
|
|
10597
10586
|
orderByList: this.view.orderByList,
|
|
10598
10587
|
orderedColumnNames: this.view.orderedColumnNames,
|
|
10599
10588
|
};
|
|
10600
|
-
await this.service.update(config.uuid, config.identifier, updateData);
|
|
10589
|
+
await this.data.customComponentInputs.config.service.update(config.uuid, config.identifier, updateData);
|
|
10601
10590
|
this.dialogRef.close();
|
|
10602
10591
|
}
|
|
10603
10592
|
getUpdatedOrderedColumns() {
|
|
@@ -10630,7 +10619,7 @@ class TableLayoutDefinerComponent {
|
|
|
10630
10619
|
return true;
|
|
10631
10620
|
}
|
|
10632
10621
|
}
|
|
10633
|
-
TableLayoutDefinerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: TableLayoutDefinerComponent, deps: [{ token: MAT_DIALOG_DATA }, { token:
|
|
10622
|
+
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 });
|
|
10634
10623
|
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"] }] });
|
|
10635
10624
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: TableLayoutDefinerComponent, decorators: [{
|
|
10636
10625
|
type: Component,
|
|
@@ -10638,7 +10627,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
10638
10627
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
10639
10628
|
type: Inject,
|
|
10640
10629
|
args: [MAT_DIALOG_DATA]
|
|
10641
|
-
}] }, { type:
|
|
10630
|
+
}] }, { type: i1$2.MatDialogRef }]; }, propDecorators: { formChildren: [{
|
|
10642
10631
|
type: ViewChildren,
|
|
10643
10632
|
args: ['forms']
|
|
10644
10633
|
}] } });
|
|
@@ -11498,17 +11487,11 @@ class SmartGridComponent {
|
|
|
11498
11487
|
uuid: this.uuid,
|
|
11499
11488
|
identifier: this.smartGrid.gridIdentifier,
|
|
11500
11489
|
view: this.service.gridModel.view,
|
|
11490
|
+
service: this.service,
|
|
11501
11491
|
},
|
|
11502
11492
|
},
|
|
11503
11493
|
};
|
|
11504
|
-
|
|
11505
|
-
dialogRef
|
|
11506
|
-
.afterClosed()
|
|
11507
|
-
.pipe(takeUntil(this._destroy$))
|
|
11508
|
-
.subscribe((result) => {
|
|
11509
|
-
this.service.gridModelChanged.next();
|
|
11510
|
-
dialogRef.close();
|
|
11511
|
-
});
|
|
11494
|
+
this.dialog.open(TableLayoutDefinerComponent, { data: dialogData });
|
|
11512
11495
|
}
|
|
11513
11496
|
}
|
|
11514
11497
|
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 });
|