@pepperi-addons/ngx-lib 0.3.8 → 0.3.9-beta.4
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/bundles/pepperi-addons-ngx-lib-draggable-items.umd.js +173 -0
- package/bundles/pepperi-addons-ngx-lib-draggable-items.umd.js.map +1 -0
- package/bundles/pepperi-addons-ngx-lib-list.umd.js +13 -12
- package/bundles/pepperi-addons-ngx-lib-list.umd.js.map +1 -1
- package/bundles/pepperi-addons-ngx-lib-top-bar.umd.js +1 -1
- package/draggable-items/draggable-item/draggable-item.component.d.ts +8 -0
- package/draggable-items/draggable-items.component.d.ts +31 -0
- package/draggable-items/draggable-items.model.d.ts +7 -0
- package/draggable-items/draggable-items.module.d.ts +5 -0
- package/draggable-items/package.json +14 -0
- package/draggable-items/pepperi-addons-ngx-lib-draggable-items.d.ts +4 -0
- package/draggable-items/pepperi-addons-ngx-lib-draggable-items.metadata.json +1 -0
- package/draggable-items/public-api.d.ts +3 -0
- package/esm2015/draggable-items/draggable-item/draggable-item.component.js +25 -0
- package/esm2015/draggable-items/draggable-items.component.js +90 -0
- package/esm2015/draggable-items/draggable-items.model.js +2 -0
- package/esm2015/draggable-items/draggable-items.module.js +43 -0
- package/esm2015/draggable-items/pepperi-addons-ngx-lib-draggable-items.js +5 -0
- package/esm2015/draggable-items/public-api.js +7 -0
- package/esm2015/list/list.component.js +12 -11
- package/esm2015/top-bar/top-bar.component.js +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-draggable-items.js +164 -0
- package/fesm2015/pepperi-addons-ngx-lib-draggable-items.js.map +1 -0
- package/fesm2015/pepperi-addons-ngx-lib-list.js +11 -10
- package/fesm2015/pepperi-addons-ngx-lib-list.js.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-top-bar.js +1 -1
- package/package.json +1 -1
- package/src/core/style/abstracts/variables.scss +4 -0
- package/src/core/style/vendors/normalize.scss +6 -0
- package/top-bar/pepperi-addons-ngx-lib-top-bar.metadata.json +1 -1
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import { Component, Input, EventEmitter, Output, NgModule } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
import { FormControl, ReactiveFormsModule } from '@angular/forms';
|
|
4
|
+
import { PepNgxLibModule } from '@pepperi-addons/ngx-lib';
|
|
5
|
+
import { PepButtonModule } from '@pepperi-addons/ngx-lib/button';
|
|
6
|
+
import { PepSearchModule } from '@pepperi-addons/ngx-lib/search';
|
|
7
|
+
import { DragDropModule } from '@angular/cdk/drag-drop';
|
|
8
|
+
import { Subject } from 'rxjs';
|
|
9
|
+
import { takeUntil, startWith, map } from 'rxjs/operators';
|
|
10
|
+
import { pepIconSystemMove, PepIconModule, PepIconRegistry } from '@pepperi-addons/ngx-lib/icon';
|
|
11
|
+
|
|
12
|
+
class DraggableItemComponent {
|
|
13
|
+
constructor() {
|
|
14
|
+
this.title = '';
|
|
15
|
+
this.disabled = false;
|
|
16
|
+
//
|
|
17
|
+
}
|
|
18
|
+
ngOnInit() {
|
|
19
|
+
//
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
DraggableItemComponent.decorators = [
|
|
23
|
+
{ type: Component, args: [{
|
|
24
|
+
selector: 'pep-draggable-item',
|
|
25
|
+
template: "<div class=\"pep-draggable-item-container\" [ngClass]=\"{ 'disable': disabled }\">\n <div class=\"\">\n <pep-button classNames=\"lock-events\" sizeType=\"xs\" iconName=\"system_move\"></pep-button>\n </div>\n <div *ngIf=\"title !== ''\" class=\"title-container\">\n <span class=\"body-sm bold ellipsis title\" title=\"{{title}}\">{{title}}</span>\n </div>\n <div class=\"actions\">\n <ng-content select=\"[pep-actions]\"></ng-content>\n </div>\n</div>",
|
|
26
|
+
styles: [":host{display:block}.pep-draggable-item-container{height:2.5rem;width:100%;display:grid;grid-template-columns:auto 1fr auto;align-items:center;border-radius:.25rem;border-radius:var(--pep-border-radius-md,.25rem);padding-inline:.5rem;padding-inline:var(--pep-spacing-sm,.5rem);background:#fafafa;background:hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),98%);box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.08);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.08);border:1px solid hsl(0,0%,calc(10% + 30%));border:1px solid hsl(var(--pep-color-regular-h,0),var(--pep-color-regular-s,0%),calc(var(--pep-color-regular-l, 10%) + 30%));box-shadow:0 .125rem .25rem 0 rgba(26,26,26,.16);box-shadow:var(--pep-shadow-xs-offset,0 .125rem .25rem 0) hsla(var(--pep-color-system-primary-h,0),var(--pep-color-system-primary-s,0%),var(--pep-color-system-primary-l,10%),.16)}.pep-draggable-item-container.disable{opacity:.35;pointer-events:none}.pep-draggable-item-container .title-container{overflow-x:hidden;margin-inline:.5rem;margin-inline:var(--pep-spacing-sm,.5rem)}.pep-draggable-item-container .title-container .title{display:block}.pep-draggable-item-container .actions{display:inline-flex;grid-gap:.25rem;gap:.25rem;grid-gap:var(--pep-spacing-xs,.25rem);gap:var(--pep-spacing-xs,.25rem)}"]
|
|
27
|
+
},] }
|
|
28
|
+
];
|
|
29
|
+
DraggableItemComponent.ctorParameters = () => [];
|
|
30
|
+
DraggableItemComponent.propDecorators = {
|
|
31
|
+
title: [{ type: Input }],
|
|
32
|
+
data: [{ type: Input }],
|
|
33
|
+
disabled: [{ type: Input }]
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
class DraggableItemsComponent {
|
|
37
|
+
constructor() {
|
|
38
|
+
this.showSearch = false;
|
|
39
|
+
this.title = '';
|
|
40
|
+
this.titleType = 'regular';
|
|
41
|
+
this.allowMultiple = '';
|
|
42
|
+
this.itemPlaceholderType = 'none';
|
|
43
|
+
this.dropAreaIds = [];
|
|
44
|
+
this._items = [];
|
|
45
|
+
this.itemDragStarted = new EventEmitter();
|
|
46
|
+
this.itemDragEnded = new EventEmitter();
|
|
47
|
+
this.searchControl = new FormControl();
|
|
48
|
+
this.numberItemsToShowSearch = 3;
|
|
49
|
+
//
|
|
50
|
+
this._destroyed = new Subject();
|
|
51
|
+
}
|
|
52
|
+
set items(value) {
|
|
53
|
+
var _a;
|
|
54
|
+
this._items = value;
|
|
55
|
+
if (((_a = this.items) === null || _a === void 0 ? void 0 : _a.length) > 0) {
|
|
56
|
+
this.searchControl.enable();
|
|
57
|
+
}
|
|
58
|
+
else {
|
|
59
|
+
this.searchControl.disable();
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
get items() {
|
|
63
|
+
return this._items;
|
|
64
|
+
}
|
|
65
|
+
filterItems(value) {
|
|
66
|
+
const filterValue = value.toLowerCase();
|
|
67
|
+
return this.items.filter((opt) => opt.title &&
|
|
68
|
+
opt.title.toLowerCase().includes(filterValue.toLowerCase()));
|
|
69
|
+
}
|
|
70
|
+
changeCursorOnDragStart() {
|
|
71
|
+
document.body.classList.add('inheritCursors');
|
|
72
|
+
document.body.style.cursor = 'grabbing';
|
|
73
|
+
}
|
|
74
|
+
changeCursorOnDragEnd() {
|
|
75
|
+
document.body.classList.remove('inheritCursors');
|
|
76
|
+
document.body.style.cursor = 'unset';
|
|
77
|
+
}
|
|
78
|
+
getDestroyer() {
|
|
79
|
+
return takeUntil(this._destroyed);
|
|
80
|
+
}
|
|
81
|
+
ngOnInit() {
|
|
82
|
+
// If there is no item disable the search.
|
|
83
|
+
if (this.items.length === 0) {
|
|
84
|
+
this.searchControl.disable();
|
|
85
|
+
}
|
|
86
|
+
// Filter the draggableItems by the search control.
|
|
87
|
+
this.filteredItems$ = this.searchControl.valueChanges.pipe(this.getDestroyer(), startWith(''), map((option) => typeof option === 'string' ? option : option && option.value), map((value) => (value ? this.filterItems(value) : this.items)));
|
|
88
|
+
}
|
|
89
|
+
ngOnDestroy() {
|
|
90
|
+
this._destroyed.next();
|
|
91
|
+
this._destroyed.complete();
|
|
92
|
+
}
|
|
93
|
+
onDragStart(event) {
|
|
94
|
+
this.changeCursorOnDragStart();
|
|
95
|
+
this.itemDragStarted.emit(event);
|
|
96
|
+
}
|
|
97
|
+
onDragEnd(event) {
|
|
98
|
+
this.changeCursorOnDragEnd();
|
|
99
|
+
this.itemDragEnded.emit(event);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
DraggableItemsComponent.decorators = [
|
|
103
|
+
{ type: Component, args: [{
|
|
104
|
+
selector: 'pep-draggable-items',
|
|
105
|
+
template: "<div id=\"test\" class=\"pep-draggable-items-container\" cdkDropList [cdkDropListData]=\"filteredItems$ | async\"\r\n cdkDropListSortingDisabled [cdkDropListConnectedTo]=\"dropAreaIds\">\r\n\r\n <div *ngIf=\"titleType !== 'none'\" class=\"title-container\"\r\n [ngClass]=\"{ 'pep-border-bottom': titleType === 'with-bottom-border'}\">\r\n <label class=\"body-xl bold ellipsis\">{{title}}</label>\r\n <pep-search *ngIf=\"showSearch && items?.length > numberItemsToShowSearch\" sizeType=\"sm\"\r\n [searchControl]=\"searchControl\" triggerOn=\"keydown\" [shrinkInSmallScreen]=\"true\"></pep-search>\r\n </div>\r\n\r\n <pep-draggable-item *ngFor=\"let item of filteredItems$ | async; let i=index;\" class=\"draggble-item\"\r\n [title]=\"item.title\" [data]=\"item.data\" [disabled]=\"item.disabled\" cdkDrag [cdkDragData]=\"item.data\"\r\n [cdkDragDisabled]=\"item.disabled\" (cdkDragStarted)=\"onDragStart($event)\" (cdkDragEnded)=\"onDragEnd($event)\">\r\n\r\n <ng-container *ngIf=\"itemPlaceholderType !== 'regular'\">\r\n <div class=\"placeholder-item {{itemPlaceholderType}}\" *cdkDragPlaceholder></div>\r\n </ng-container>\r\n </pep-draggable-item>\r\n</div>",
|
|
106
|
+
styles: [".draggble-item{margin-bottom:.5rem;margin-bottom:var(--pep-spacing-sm,.5rem);cursor:-webkit-grab;cursor:grab}.draggble-item.cdk-drag-disabled{cursor:not-allowed}.title-container{height:2.5rem;display:flex;flex-flow:row;justify-content:space-between}.title-container.pep-border-bottom{margin-bottom:1rem;margin-bottom:var(--pep-spacing-lg,1rem)}.placeholder-item{height:2.5rem;border-radius:.25rem;border-radius:var(--pep-border-radius-md,.25rem);width:100%;margin-bottom:.5rem;margin-bottom:var(--pep-spacing-sm,.5rem)}.placeholder-item.none{opacity:0}.placeholder-item.weak{background:rgba(26,26,26,.12);background:hsla(var(--pep-color-weak-h,0),var(--pep-color-weak-s,0%),var(--pep-color-weak-l,10%),.12)}"]
|
|
107
|
+
},] }
|
|
108
|
+
];
|
|
109
|
+
DraggableItemsComponent.ctorParameters = () => [];
|
|
110
|
+
DraggableItemsComponent.propDecorators = {
|
|
111
|
+
showSearch: [{ type: Input }],
|
|
112
|
+
title: [{ type: Input }],
|
|
113
|
+
titleType: [{ type: Input }],
|
|
114
|
+
allowMultiple: [{ type: Input }],
|
|
115
|
+
itemPlaceholderType: [{ type: Input }],
|
|
116
|
+
dropAreaIds: [{ type: Input }],
|
|
117
|
+
items: [{ type: Input }],
|
|
118
|
+
itemDragStarted: [{ type: Output }],
|
|
119
|
+
itemDragEnded: [{ type: Output }]
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
class PepDraggableItemsModule {
|
|
123
|
+
constructor(pepIconRegistry) {
|
|
124
|
+
this.pepIconRegistry = pepIconRegistry;
|
|
125
|
+
this.pepIconRegistry.registerIcons([
|
|
126
|
+
pepIconSystemMove,
|
|
127
|
+
]);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
PepDraggableItemsModule.decorators = [
|
|
131
|
+
{ type: NgModule, args: [{
|
|
132
|
+
declarations: [
|
|
133
|
+
DraggableItemsComponent,
|
|
134
|
+
DraggableItemComponent
|
|
135
|
+
],
|
|
136
|
+
imports: [
|
|
137
|
+
CommonModule,
|
|
138
|
+
ReactiveFormsModule,
|
|
139
|
+
PepNgxLibModule,
|
|
140
|
+
PepButtonModule,
|
|
141
|
+
PepIconModule,
|
|
142
|
+
PepSearchModule,
|
|
143
|
+
DragDropModule
|
|
144
|
+
],
|
|
145
|
+
exports: [
|
|
146
|
+
DraggableItemsComponent,
|
|
147
|
+
DraggableItemComponent
|
|
148
|
+
],
|
|
149
|
+
},] }
|
|
150
|
+
];
|
|
151
|
+
PepDraggableItemsModule.ctorParameters = () => [
|
|
152
|
+
{ type: PepIconRegistry }
|
|
153
|
+
];
|
|
154
|
+
|
|
155
|
+
/*
|
|
156
|
+
* Public API Surface of ngx-lib/draggable-items
|
|
157
|
+
*/
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Generated bundle index. Do not edit.
|
|
161
|
+
*/
|
|
162
|
+
|
|
163
|
+
export { DraggableItemComponent, DraggableItemsComponent, PepDraggableItemsModule };
|
|
164
|
+
//# sourceMappingURL=pepperi-addons-ngx-lib-draggable-items.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pepperi-addons-ngx-lib-draggable-items.js","sources":["../../../projects/ngx-lib/draggable-items/draggable-item/draggable-item.component.ts","../../../projects/ngx-lib/draggable-items/draggable-items.component.ts","../../../projects/ngx-lib/draggable-items/draggable-items.module.ts","../../../projects/ngx-lib/draggable-items/public-api.ts","../../../projects/ngx-lib/draggable-items/pepperi-addons-ngx-lib-draggable-items.ts"],"sourcesContent":["import { Component, EventEmitter, HostBinding, Input, OnInit, Output } from '@angular/core';\n\n@Component({\n selector: 'pep-draggable-item',\n templateUrl: './draggable-item.component.html',\n styleUrls: ['./draggable-item.component.scss']\n})\nexport class DraggableItemComponent implements OnInit {\n @Input() title = '';\n @Input() data: any;\n @Input() disabled = false;\n\n constructor() {\n //\n }\n\n ngOnInit(): void {\n //\n }\n}\n","import { CdkDragEnd, CdkDragStart } from '@angular/cdk/drag-drop';\nimport { Component, EventEmitter, HostBinding, Input, OnDestroy, OnInit, Output } from '@angular/core';\nimport { FormControl } from '@angular/forms';\nimport { Observable, Subject } from 'rxjs';\nimport { map, startWith, takeUntil } from 'rxjs/operators';\nimport { IPepDraggableItem, PepDraggableItemPlaceholderType, PepDraggableItemsTitleType } from './draggable-items.model';\n\n@Component({\n selector: 'pep-draggable-items',\n templateUrl: './draggable-items.component.html',\n styleUrls: ['./draggable-items.component.scss']\n})\nexport class DraggableItemsComponent implements OnInit, OnDestroy {\n\n @Input() showSearch = false;\n @Input() title = '';\n @Input() titleType: PepDraggableItemsTitleType = 'regular';\n @Input() allowMultiple = '';\n\n @Input() itemPlaceholderType: PepDraggableItemPlaceholderType = 'none';\n\n @Input() dropAreaIds = [];\n\n private _items: Array<IPepDraggableItem> = [];\n @Input()\n set items(value: Array<IPepDraggableItem>) {\n this._items = value;\n\n if (this.items?.length > 0) {\n this.searchControl.enable();\n } else {\n this.searchControl.disable();\n }\n }\n get items(): Array<IPepDraggableItem> {\n return this._items;\n }\n\n @Output() itemDragStarted: EventEmitter<CdkDragStart<IPepDraggableItem>> = new EventEmitter<CdkDragStart<IPepDraggableItem>>();\n @Output() itemDragEnded: EventEmitter<CdkDragEnd<IPepDraggableItem>> = new EventEmitter<CdkDragEnd<IPepDraggableItem>>();\n\n filteredItems$: Observable<any>;\n searchControl = new FormControl();\n numberItemsToShowSearch = 3;\n private readonly _destroyed: Subject<void>;\n\n constructor() {\n //\n this._destroyed = new Subject();\n }\n\n private filterItems(value: string): any[] {\n const filterValue = value.toLowerCase();\n return this.items.filter(\n (opt) =>\n opt.title &&\n opt.title.toLowerCase().includes(filterValue.toLowerCase())\n );\n }\n\n private changeCursorOnDragStart() {\n document.body.classList.add('inheritCursors');\n document.body.style.cursor = 'grabbing';\n }\n\n private changeCursorOnDragEnd() {\n document.body.classList.remove('inheritCursors');\n document.body.style.cursor = 'unset';\n }\n\n protected getDestroyer() {\n return takeUntil(this._destroyed);\n }\n\n ngOnInit(): void {\n // If there is no item disable the search.\n if (this.items.length === 0) {\n this.searchControl.disable();\n }\n\n // Filter the draggableItems by the search control.\n this.filteredItems$ = this.searchControl.valueChanges.pipe(\n this.getDestroyer(),\n startWith<any>(''),\n map((option) =>\n typeof option === 'string' ? option : option && option.value\n ),\n map((value) => (value ? this.filterItems(value) : this.items))\n );\n }\n\n ngOnDestroy(): void {\n this._destroyed.next();\n this._destroyed.complete();\n }\n\n onDragStart(event: CdkDragStart) {\n this.changeCursorOnDragStart();\n this.itemDragStarted.emit(event);\n }\n\n onDragEnd(event: CdkDragEnd) {\n this.changeCursorOnDragEnd();\n this.itemDragEnded.emit(event);\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { ReactiveFormsModule } from '@angular/forms';\n\nimport { PepNgxLibModule } from '@pepperi-addons/ngx-lib';\nimport { PepButtonModule } from '@pepperi-addons/ngx-lib/button';\nimport { PepSearchModule } from '@pepperi-addons/ngx-lib/search';\n\nimport { DragDropModule } from '@angular/cdk/drag-drop';\n\nimport { DraggableItemsComponent } from './draggable-items.component';\nimport { DraggableItemComponent } from './draggable-item/draggable-item.component';\nimport {\n PepIconModule,\n PepIconRegistry,\n pepIconSystemMove,\n} from '@pepperi-addons/ngx-lib/icon';\n\n@NgModule({\n declarations: [\n DraggableItemsComponent,\n DraggableItemComponent\n ],\n imports: [\n CommonModule,\n ReactiveFormsModule,\n PepNgxLibModule,\n PepButtonModule,\n PepIconModule,\n PepSearchModule,\n DragDropModule\n ],\n exports: [\n DraggableItemsComponent,\n DraggableItemComponent\n ],\n})\nexport class PepDraggableItemsModule {\n constructor(private pepIconRegistry: PepIconRegistry) {\n this.pepIconRegistry.registerIcons([\n pepIconSystemMove,\n ]);\n }\n}\n","/*\n * Public API Surface of ngx-lib/draggable-items\n */\nexport * from './draggable-item/draggable-item.component';\n\nexport * from './draggable-items.module';\nexport * from './draggable-items.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;MAOa,sBAAsB;IAK/B;QAJS,UAAK,GAAG,EAAE,CAAC;QAEX,aAAQ,GAAG,KAAK,CAAC;;KAIzB;IAED,QAAQ;;KAEP;;;YAhBJ,SA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ClC;;;YAjGJ,SAAS,SAAC;gBACP,QAAQ,EAAE,qBAAqB;gBAC/B,2uCAA+C;;aAElD;;;;yBAGI,KAAK;oBACL,KAAK;wBACL,KAAK;4BACL,KAAK;kCAEL,KAAK;0BAEL,KAAK;oBAGL,KAAK;8BAcL,MAAM;4BACN,MAAM;;;MCFE,uBAAuB;IAChC,YAAoB,eAAgC;QAAhC,oBAAe,GAAf,eAAe,CAAiB;QAChD,IAAI,CAAC,eAAe,CAAC,aAAa,CAAC;YAC/B,iBAAiB;SACpB,CAAC,CAAC;KACN;;;YAxBJ,QAAQ,SAAC;gBACN,YAAY,EAAE;oBACV,uBAAuB;oBACvB,sBAAsB;iBACzB;gBACD,OAAO,EAAE;oBACL,YAAY;oBACZ,mBAAmB;oBACnB,eAAe;oBACf,eAAe;oBACf,aAAa;oBACb,eAAe;oBACf,cAAc;iBACjB;gBACD,OAAO,EAAE;oBACL,uBAAuB;oBACvB,sBAAsB;iBACzB;aACJ;;;YAtBG,eAAe;;;ACdnB;;;;ACAA;;;;;;"}
|
|
@@ -1897,16 +1897,17 @@ class PepListComponent {
|
|
|
1897
1897
|
}
|
|
1898
1898
|
getSelectedItemsData(isForEdit = false) {
|
|
1899
1899
|
const res = new PepSelectionData();
|
|
1900
|
+
let selectionType = 1;
|
|
1901
|
+
const items = [];
|
|
1902
|
+
const itemTypes = [];
|
|
1900
1903
|
if (this.selectionTypeForActions === 'single') {
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1904
|
+
if (this.selectedItemId.length > 0) {
|
|
1905
|
+
const tmp = this.selectedItemId.split(this.SEPARATOR);
|
|
1906
|
+
items.push(tmp[0]);
|
|
1907
|
+
itemTypes.push(tmp[1]);
|
|
1908
|
+
}
|
|
1905
1909
|
}
|
|
1906
1910
|
else if (this.selectionTypeForActions === 'multi') {
|
|
1907
|
-
const items = [];
|
|
1908
|
-
const itemTypes = [];
|
|
1909
|
-
let selectionType = 1;
|
|
1910
1911
|
let currentList = [];
|
|
1911
1912
|
// For edit - only the selected items.
|
|
1912
1913
|
if (isForEdit) {
|
|
@@ -1937,10 +1938,10 @@ class PepListComponent {
|
|
|
1937
1938
|
itemTypes.push(tmp[1]);
|
|
1938
1939
|
}
|
|
1939
1940
|
});
|
|
1940
|
-
res.selectionType = selectionType;
|
|
1941
|
-
res.rows = items;
|
|
1942
|
-
res.rowTypes = itemTypes;
|
|
1943
1941
|
}
|
|
1942
|
+
res.selectionType = selectionType;
|
|
1943
|
+
res.rows = items;
|
|
1944
|
+
res.rowTypes = itemTypes;
|
|
1944
1945
|
return res;
|
|
1945
1946
|
}
|
|
1946
1947
|
getIsItemEditable(uid) {
|