@colijnit/corecomponents_v12 256.1.24 → 256.1.25
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/colijnit-corecomponents_v12.umd.js +157 -94
- package/bundles/colijnit-corecomponents_v12.umd.js.map +1 -1
- package/colijnit-corecomponents_v12.d.ts +17 -16
- package/colijnit-corecomponents_v12.metadata.json +1 -1
- package/esm2015/colijnit-corecomponents_v12.js +18 -17
- package/esm2015/lib/components/simple-grid/simple-grid.component.js +146 -205
- package/esm2015/lib/service/excel-export.service.js +125 -0
- package/fesm2015/colijnit-corecomponents_v12.js +265 -202
- package/fesm2015/colijnit-corecomponents_v12.js.map +1 -1
- package/lib/components/simple-grid/simple-grid.component.d.ts +5 -6
- package/lib/components/simple-grid/style/_layout.scss +5 -8
- package/lib/service/excel-export.service.d.ts +44 -0
- package/package.json +1 -1
|
@@ -9458,12 +9458,135 @@ BaseSimpleGridComponent.propDecorators = {
|
|
|
9458
9458
|
handleMouseUp: [{ type: HostListener, args: ['document:mouseup', ['$event'],] }]
|
|
9459
9459
|
};
|
|
9460
9460
|
|
|
9461
|
+
class ExcelExportService {
|
|
9462
|
+
/**
|
|
9463
|
+
* Export data to Excel file
|
|
9464
|
+
* @param data - Array of objects to export
|
|
9465
|
+
* @param columns - Column configuration (optional)
|
|
9466
|
+
* @param fileName - Name of the exported file
|
|
9467
|
+
* @param sheetName - Name of the Excel sheet
|
|
9468
|
+
*/
|
|
9469
|
+
exportToExcel(data, columns, fileName = 'export', sheetName = 'Sheet1') {
|
|
9470
|
+
// If columns are specified, transform data to match column structure
|
|
9471
|
+
let exportData = data;
|
|
9472
|
+
if (columns && columns.length > 0) {
|
|
9473
|
+
exportData = data.map(item => {
|
|
9474
|
+
const newItem = {};
|
|
9475
|
+
columns.forEach(col => {
|
|
9476
|
+
newItem[col.header] = this.getNestedValue(item, col.key);
|
|
9477
|
+
});
|
|
9478
|
+
return newItem;
|
|
9479
|
+
});
|
|
9480
|
+
}
|
|
9481
|
+
// Create workbook and worksheet
|
|
9482
|
+
const wb = XLSX.utils.book_new();
|
|
9483
|
+
const ws = XLSX.utils.json_to_sheet(exportData);
|
|
9484
|
+
// Set column widths if specified
|
|
9485
|
+
if (columns && columns.some(col => col.width)) {
|
|
9486
|
+
const colWidths = columns.map(col => ({ wch: col.width || 20 }));
|
|
9487
|
+
ws['!cols'] = colWidths;
|
|
9488
|
+
}
|
|
9489
|
+
// Add worksheet to workbook
|
|
9490
|
+
XLSX.utils.book_append_sheet(wb, ws, sheetName);
|
|
9491
|
+
// Save file
|
|
9492
|
+
XLSX.writeFile(wb, `${fileName}.xlsx`);
|
|
9493
|
+
}
|
|
9494
|
+
/**
|
|
9495
|
+
* Export multiple sheets to one Excel file
|
|
9496
|
+
* @param sheets - Array of sheet data
|
|
9497
|
+
* @param fileName - Name of the exported file
|
|
9498
|
+
*/
|
|
9499
|
+
exportMultipleSheets(sheets, fileName = 'multi-sheet-export') {
|
|
9500
|
+
const wb = XLSX.utils.book_new();
|
|
9501
|
+
sheets.forEach(sheet => {
|
|
9502
|
+
let exportData = sheet.data;
|
|
9503
|
+
if (sheet.columns && sheet.columns.length > 0) {
|
|
9504
|
+
exportData = sheet.data.map(item => {
|
|
9505
|
+
const newItem = {};
|
|
9506
|
+
sheet.columns.forEach(col => {
|
|
9507
|
+
newItem[col.header] = this.getNestedValue(item, col.key);
|
|
9508
|
+
});
|
|
9509
|
+
return newItem;
|
|
9510
|
+
});
|
|
9511
|
+
}
|
|
9512
|
+
const ws = XLSX.utils.json_to_sheet(exportData);
|
|
9513
|
+
if (sheet.columns && sheet.columns.some(col => col.width)) {
|
|
9514
|
+
const colWidths = sheet.columns.map(col => ({ wch: col.width || 20 }));
|
|
9515
|
+
ws['!cols'] = colWidths;
|
|
9516
|
+
}
|
|
9517
|
+
XLSX.utils.book_append_sheet(wb, ws, sheet.sheetName);
|
|
9518
|
+
});
|
|
9519
|
+
XLSX.writeFile(wb, `${fileName}.xlsx`);
|
|
9520
|
+
}
|
|
9521
|
+
/**
|
|
9522
|
+
* Export HTML table to Excel
|
|
9523
|
+
* @param tableId - ID of the HTML table element
|
|
9524
|
+
* @param fileName - Name of the exported file
|
|
9525
|
+
* @param sheetName - Name of the Excel sheet
|
|
9526
|
+
*/
|
|
9527
|
+
exportTableToExcel(tableId, fileName = 'table-export', sheetName = 'Sheet1') {
|
|
9528
|
+
const table = document.getElementById(tableId);
|
|
9529
|
+
if (!table) {
|
|
9530
|
+
console.error(`Table with ID '${tableId}' not found`);
|
|
9531
|
+
return;
|
|
9532
|
+
}
|
|
9533
|
+
const wb = XLSX.utils.book_new();
|
|
9534
|
+
const ws = XLSX.utils.table_to_sheet(table);
|
|
9535
|
+
XLSX.utils.book_append_sheet(wb, ws, sheetName);
|
|
9536
|
+
XLSX.writeFile(wb, `${fileName}.xlsx`);
|
|
9537
|
+
}
|
|
9538
|
+
/**
|
|
9539
|
+
* Get nested object value using dot notation
|
|
9540
|
+
* @param obj - Object to search in
|
|
9541
|
+
* @param path - Dot notation path (e.g., 'user.address.city')
|
|
9542
|
+
*/
|
|
9543
|
+
getNestedValue(obj, path) {
|
|
9544
|
+
return path.split('.').reduce((current, key) => {
|
|
9545
|
+
return current && current[key] !== undefined ? current[key] : '';
|
|
9546
|
+
}, obj);
|
|
9547
|
+
}
|
|
9548
|
+
/**
|
|
9549
|
+
* Format date for Excel export
|
|
9550
|
+
* @param date - Date to format
|
|
9551
|
+
* @param format - Format string (default: 'MM/DD/YYYY')
|
|
9552
|
+
*/
|
|
9553
|
+
formatDateForExport(date, format = 'MM/DD/YYYY') {
|
|
9554
|
+
if (!date) {
|
|
9555
|
+
return '';
|
|
9556
|
+
}
|
|
9557
|
+
const d = new Date(date);
|
|
9558
|
+
if (isNaN(d.getTime())) {
|
|
9559
|
+
return '';
|
|
9560
|
+
}
|
|
9561
|
+
const month = (d.getMonth() + 1).toString().padStart(2, '0');
|
|
9562
|
+
const day = d.getDate().toString().padStart(2, '0');
|
|
9563
|
+
const year = d.getFullYear();
|
|
9564
|
+
switch (format) {
|
|
9565
|
+
case 'MM/DD/YYYY':
|
|
9566
|
+
return `${month}/${day}/${year}`;
|
|
9567
|
+
case 'DD/MM/YYYY':
|
|
9568
|
+
return `${day}/${month}/${year}`;
|
|
9569
|
+
case 'YYYY-MM-DD':
|
|
9570
|
+
return `${year}-${month}-${day}`;
|
|
9571
|
+
default:
|
|
9572
|
+
return d.toLocaleDateString();
|
|
9573
|
+
}
|
|
9574
|
+
}
|
|
9575
|
+
}
|
|
9576
|
+
ExcelExportService.ɵprov = i0.ɵɵdefineInjectable({ factory: function ExcelExportService_Factory() { return new ExcelExportService(); }, token: ExcelExportService, providedIn: "root" });
|
|
9577
|
+
ExcelExportService.decorators = [
|
|
9578
|
+
{ type: Injectable, args: [{
|
|
9579
|
+
providedIn: 'root'
|
|
9580
|
+
},] }
|
|
9581
|
+
];
|
|
9582
|
+
|
|
9461
9583
|
class SimpleGridComponent extends BaseSimpleGridComponent {
|
|
9462
|
-
constructor(icons, _changeDetection, _formMaster) {
|
|
9584
|
+
constructor(icons, _changeDetection, _formMaster, excelExportService) {
|
|
9463
9585
|
super();
|
|
9464
9586
|
this.icons = icons;
|
|
9465
9587
|
this._changeDetection = _changeDetection;
|
|
9466
9588
|
this._formMaster = _formMaster;
|
|
9589
|
+
this.excelExportService = excelExportService;
|
|
9467
9590
|
this.defaultTextAlign = ColumnAlign.Left;
|
|
9468
9591
|
this.showAdd = false;
|
|
9469
9592
|
this.showDelete = false;
|
|
@@ -9542,13 +9665,6 @@ class SimpleGridComponent extends BaseSimpleGridComponent {
|
|
|
9542
9665
|
}
|
|
9543
9666
|
});
|
|
9544
9667
|
}
|
|
9545
|
-
isSingleColumn(column) {
|
|
9546
|
-
return column.singleColumn;
|
|
9547
|
-
}
|
|
9548
|
-
rowContainsSingleColumn(row, columns) {
|
|
9549
|
-
const singleColumn = columns.find(column => this.isSingleColumn(column) && !!row[column.field]);
|
|
9550
|
-
return !!singleColumn;
|
|
9551
|
-
}
|
|
9552
9668
|
addNewRow() {
|
|
9553
9669
|
return __awaiter(this, void 0, void 0, function* () {
|
|
9554
9670
|
if (this.inlineEdit) {
|
|
@@ -9691,74 +9807,12 @@ class SimpleGridComponent extends BaseSimpleGridComponent {
|
|
|
9691
9807
|
return obj !== col;
|
|
9692
9808
|
});
|
|
9693
9809
|
}
|
|
9694
|
-
// TODO Fix this sort method
|
|
9695
|
-
// public sortColumn(col: any, columnValue: string): void {
|
|
9696
|
-
// console.log(col);
|
|
9697
|
-
// console.log("columnValue " + columnValue);
|
|
9698
|
-
// col.isSelected = false;
|
|
9699
|
-
//
|
|
9700
|
-
// if (this.sortColumnValue === columnValue) {
|
|
9701
|
-
// this.sortDirection = this.sortDirection === 'asc' ? 'desc' : 'asc';
|
|
9702
|
-
// } else {
|
|
9703
|
-
// this.sortColumnValue = columnValue;
|
|
9704
|
-
// this.sortDirection = 'asc';
|
|
9705
|
-
// }
|
|
9706
|
-
//
|
|
9707
|
-
// console.log(this.data);
|
|
9708
|
-
// // this.data = this._sortData(this.data);
|
|
9709
|
-
//
|
|
9710
|
-
//
|
|
9711
|
-
// this.data.sort((a, b) => {
|
|
9712
|
-
// const sign = this.sortDirection === 'asc' ? 1 : -1;
|
|
9713
|
-
//
|
|
9714
|
-
// console.log("a " + a);
|
|
9715
|
-
// console.log("b " + b);
|
|
9716
|
-
// console.log(a[this.sortColumnValue]);
|
|
9717
|
-
// console.log(b[this.sortColumnValue]);
|
|
9718
|
-
// console.log("sign " + sign);
|
|
9719
|
-
//
|
|
9720
|
-
// if (a[this.sortColumnValue] < b[this.sortColumnValue]) {
|
|
9721
|
-
// return -1 * sign;
|
|
9722
|
-
// } else if (a[this.sortColumnValue] > b[this.sortColumnValue]) {
|
|
9723
|
-
// return 1 * sign;
|
|
9724
|
-
// }
|
|
9725
|
-
// return 0;
|
|
9726
|
-
// });
|
|
9727
|
-
//
|
|
9728
|
-
//
|
|
9729
|
-
//
|
|
9730
|
-
// this._detectChanges();
|
|
9731
|
-
// // this.data.sort((a, b) => a[this.sortColumnValue] - b[this.sortColumnValue]);
|
|
9732
|
-
// console.log(this.data);
|
|
9733
|
-
// }
|
|
9734
|
-
_sortData(tableData) {
|
|
9735
|
-
return tableData.sort((a, b) => {
|
|
9736
|
-
const sign = this.sortDirection === 'asc' ? 1 : -1;
|
|
9737
|
-
console.log("a " + a);
|
|
9738
|
-
console.log("b " + b);
|
|
9739
|
-
console.log(a[this.sortColumnValue]);
|
|
9740
|
-
console.log(b[this.sortColumnValue]);
|
|
9741
|
-
console.log("sign " + sign);
|
|
9742
|
-
if (a[this.sortColumnValue] < b[this.sortColumnValue]) {
|
|
9743
|
-
return -1 * sign;
|
|
9744
|
-
}
|
|
9745
|
-
else if (a[this.sortColumnValue] > b[this.sortColumnValue]) {
|
|
9746
|
-
return 1 * sign;
|
|
9747
|
-
}
|
|
9748
|
-
return 0;
|
|
9749
|
-
});
|
|
9750
|
-
}
|
|
9751
9810
|
showAllColumns() {
|
|
9752
9811
|
this.isSettingsMenuOpen = false;
|
|
9753
9812
|
this.headerColumnsCopy = this.headerColumns;
|
|
9754
9813
|
}
|
|
9755
9814
|
exportToExcel() {
|
|
9756
|
-
this.
|
|
9757
|
-
let element = document.getElementById('simple-grid-table');
|
|
9758
|
-
const ws = XLSX.utils.table_to_sheet(element);
|
|
9759
|
-
const wb = XLSX.utils.book_new();
|
|
9760
|
-
XLSX.utils.book_append_sheet(wb, ws, 'Sheet1');
|
|
9761
|
-
XLSX.writeFile(wb, 'ExcelSheet.xlsx');
|
|
9815
|
+
this.excelExportService.exportTableToExcel('simple-grid-table', 'ExcelSheet', 'Sheet1');
|
|
9762
9816
|
}
|
|
9763
9817
|
prepareDataRow(row, index) {
|
|
9764
9818
|
this.isRowDisabled(row, index);
|
|
@@ -9905,140 +9959,148 @@ SimpleGridComponent.decorators = [
|
|
|
9905
9959
|
{ type: Component, args: [{
|
|
9906
9960
|
selector: 'co-simple-grid',
|
|
9907
9961
|
template: `
|
|
9908
|
-
|
|
9909
|
-
|
|
9910
|
-
|
|
9911
|
-
|
|
9912
|
-
|
|
9913
|
-
|
|
9914
|
-
|
|
9915
|
-
|
|
9916
|
-
|
|
9917
|
-
|
|
9918
|
-
|
|
9919
|
-
|
|
9920
|
-
|
|
9921
|
-
|
|
9922
|
-
|
|
9923
|
-
|
|
9924
|
-
|
|
9925
|
-
|
|
9926
|
-
|
|
9927
|
-
|
|
9928
|
-
|
|
9929
|
-
|
|
9930
|
-
|
|
9931
|
-
|
|
9932
|
-
|
|
9933
|
-
|
|
9934
|
-
|
|
9935
|
-
|
|
9936
|
-
|
|
9937
|
-
|
|
9938
|
-
|
|
9939
|
-
|
|
9940
|
-
|
|
9941
|
-
|
|
9942
|
-
|
|
9943
|
-
|
|
9944
|
-
|
|
9945
|
-
|
|
9946
|
-
|
|
9947
|
-
|
|
9948
|
-
|
|
9949
|
-
|
|
9950
|
-
|
|
9951
|
-
|
|
9962
|
+
<co-grid-toolbar
|
|
9963
|
+
*ngIf="showToolbar" [class.right]="rightToolbar"
|
|
9964
|
+
[showEdit]="showEdit"
|
|
9965
|
+
[showAdd]="showAdd"
|
|
9966
|
+
[showDelete]="showDelete"
|
|
9967
|
+
[deleteEnabled]="selectedRowIndex > -1"
|
|
9968
|
+
(addClick)="addNewRow()"
|
|
9969
|
+
(editClick)="editRow($event)"
|
|
9970
|
+
(saveClick)="validateAndSave()"
|
|
9971
|
+
(cancelClick)="cancelEditRow()"
|
|
9972
|
+
(deleteClick)="removeRow()">
|
|
9973
|
+
</co-grid-toolbar>
|
|
9974
|
+
|
|
9975
|
+
<table
|
|
9976
|
+
id="simple-grid-table"
|
|
9977
|
+
class="simple-grid-table"
|
|
9978
|
+
[clickOutside]="editing"
|
|
9979
|
+
(clickOutside)="handleClickOutsideRow()">
|
|
9980
|
+
<colgroup>
|
|
9981
|
+
<col
|
|
9982
|
+
*ngFor="let column of headerColumnsCopy; let index = index"
|
|
9983
|
+
[class.simple-grid-column-auto-fit]="column.autoFit"
|
|
9984
|
+
[style.width.px]="column.width"
|
|
9985
|
+
[style.min-width.px]="MIN_COLUMN_WIDTH">
|
|
9986
|
+
</colgroup>
|
|
9987
|
+
<thead>
|
|
9988
|
+
<tr>
|
|
9989
|
+
<th
|
|
9990
|
+
scope="col"
|
|
9991
|
+
#headerCell
|
|
9992
|
+
class="simple-grid-column-header"
|
|
9993
|
+
*ngFor="let column of headerColumnsCopy; let index = index">
|
|
9994
|
+
<div
|
|
9995
|
+
class="simple-grid-column-header-wrapper"
|
|
9996
|
+
[class.resizable]="resizable"
|
|
9997
|
+
[class.selected]="column.isSelected"
|
|
9998
|
+
[ngClass]="column.textAlign ? column.textAlign : defaultTextAlign">
|
|
9999
|
+
<ng-container *ngIf="column.headerTemplate; else noHeaderTemplate">
|
|
10000
|
+
<ng-container [ngTemplateOutlet]="column.headerTemplate"></ng-container>
|
|
10001
|
+
</ng-container>
|
|
10002
|
+
<ng-template #noHeaderTemplate>
|
|
10003
|
+
<div
|
|
10004
|
+
class="simple-grid-column-header-label"
|
|
10005
|
+
[ngClass]="column.textAlign ? column.textAlign : defaultTextAlign"
|
|
10006
|
+
[class.with-menu]="showGridSettings"
|
|
10007
|
+
[textContent]="column.headerText || ' '"
|
|
10008
|
+
(click)="toggleColumnMenu(column)">
|
|
10009
|
+
</div>
|
|
10010
|
+
|
|
10011
|
+
<div class="column-menu" *ngIf="column.isSelected">
|
|
10012
|
+
<h3 [textContent]="'COLUMN_OPTIONS' | coreLocalize"></h3>
|
|
10013
|
+
<ul>
|
|
10014
|
+
<li (click)="hideColumn(column)">Hide Column</li>
|
|
10015
|
+
<!-- <li (click)="sortColumn(column, column.field)">Sort Column</li>-->
|
|
10016
|
+
</ul>
|
|
10017
|
+
</div>
|
|
10018
|
+
</ng-template>
|
|
10019
|
+
<div
|
|
10020
|
+
*ngIf="resizable && column.resizable"
|
|
10021
|
+
class="simple-grid-column-sizer"
|
|
10022
|
+
(mousedown)="handleSizerMouseDown($event, column)">
|
|
10023
|
+
</div>
|
|
10024
|
+
</div>
|
|
10025
|
+
</th>
|
|
10026
|
+
</tr>
|
|
10027
|
+
|
|
10028
|
+
<div *ngIf="showGridSettings" class="grid-settings">
|
|
10029
|
+
<co-button
|
|
10030
|
+
[class.selected]="isSettingsMenuOpen"
|
|
10031
|
+
[iconData]="icons.getIcon(Icons.CogWheels)"
|
|
10032
|
+
(click)="toggleSettingsMenu()">
|
|
10033
|
+
</co-button>
|
|
9952
10034
|
|
|
9953
|
-
<div class="
|
|
9954
|
-
|
|
9955
|
-
|
|
9956
|
-
|
|
9957
|
-
|
|
9958
|
-
|
|
10035
|
+
<div class="settings-menu" *ngIf="isSettingsMenuOpen">
|
|
10036
|
+
<h3 [textContent]="'GRID_OPTIONS' | coreLocalize"></h3>
|
|
10037
|
+
<ul>
|
|
10038
|
+
<li (click)="exportToExcel()">Export to Excel</li>
|
|
10039
|
+
<li *ngIf="headerColumnsCopy.length !== headerColumns.length" (click)="showAllColumns()">
|
|
10040
|
+
Show All Columns
|
|
10041
|
+
</li>
|
|
10042
|
+
</ul>
|
|
9959
10043
|
</div>
|
|
9960
|
-
</ng-template>
|
|
9961
|
-
<div *ngIf="resizable && column.resizable" class="simple-grid-column-sizer"
|
|
9962
|
-
(mousedown)="handleSizerMouseDown($event, column)"
|
|
9963
|
-
></div>
|
|
9964
10044
|
</div>
|
|
9965
|
-
</th>
|
|
9966
|
-
<th *ngIf="showGridSettings" class="simple-grid-column-header grid-settings">
|
|
9967
|
-
<co-button
|
|
9968
|
-
[class.selected]="isSettingsMenuOpen"
|
|
9969
|
-
[iconData]="icons.getIcon(Icons.CogWheels)"
|
|
9970
|
-
(click)="toggleSettingsMenu()">
|
|
9971
|
-
</co-button>
|
|
9972
10045
|
|
|
9973
|
-
|
|
9974
|
-
|
|
9975
|
-
|
|
9976
|
-
|
|
9977
|
-
|
|
9978
|
-
|
|
9979
|
-
|
|
9980
|
-
|
|
9981
|
-
|
|
9982
|
-
|
|
9983
|
-
|
|
9984
|
-
|
|
9985
|
-
|
|
9986
|
-
|
|
9987
|
-
|
|
9988
|
-
|
|
9989
|
-
|
|
9990
|
-
|
|
9991
|
-
|
|
9992
|
-
|
|
9993
|
-
|
|
9994
|
-
|
|
9995
|
-
|
|
9996
|
-
|
|
9997
|
-
|
|
9998
|
-
|
|
9999
|
-
|
|
10000
|
-
|
|
10001
|
-
|
|
10002
|
-
|
|
10003
|
-
|
|
10004
|
-
|
|
10005
|
-
|
|
10006
|
-
|
|
10007
|
-
|
|
10008
|
-
|
|
10009
|
-
|
|
10010
|
-
|
|
10011
|
-
|
|
10012
|
-
|
|
10013
|
-
|
|
10014
|
-
|
|
10015
|
-
|
|
10016
|
-
|
|
10017
|
-
|
|
10018
|
-
|
|
10019
|
-
|
|
10020
|
-
|
|
10021
|
-
|
|
10022
|
-
|
|
10023
|
-
|
|
10024
|
-
|
|
10025
|
-
|
|
10026
|
-
|
|
10027
|
-
|
|
10028
|
-
|
|
10029
|
-
<co-pagination-bar *ngIf="data?.length > rowsPerPage" class="pagination-bar"
|
|
10030
|
-
[itemsPerPage]="rowsPerPage"
|
|
10031
|
-
[currentPage]="currentPage"
|
|
10032
|
-
[totalItems]="data.length"
|
|
10033
|
-
[autoHide]="true"
|
|
10034
|
-
(previousClick)="goToPreviousPage()"
|
|
10035
|
-
(nextClick)="goToNextPage()"
|
|
10036
|
-
(pageClick)="setCurrentPage($event)"
|
|
10037
|
-
></co-pagination-bar>
|
|
10046
|
+
</thead>
|
|
10047
|
+
<tbody
|
|
10048
|
+
#dropList cdkDropList cdkDropListOrientation="vertical"
|
|
10049
|
+
class="simple-grid-drag-drop-list"
|
|
10050
|
+
[cdkDropListDisabled]="!dragDropEnabled || editing"
|
|
10051
|
+
[cdkDropListData]="data"
|
|
10052
|
+
[cdkDropListEnterPredicate]="handleCanDragDrop"
|
|
10053
|
+
(cdkDropListDropped)="handleDrop($event)">
|
|
10054
|
+
<co-form class="simple-grid-row-form">
|
|
10055
|
+
<tr
|
|
10056
|
+
class="simple-grid-row"
|
|
10057
|
+
[class.selected]="rowIndex === selectedRowIndex && !editing" observeVisibility
|
|
10058
|
+
[class.disabled]="getIsRowDisabled(rowIndex)"
|
|
10059
|
+
[class.editing]="rowIndex === editRowIndex"
|
|
10060
|
+
*ngFor="let row of (!!rowsPerPage ? (data | paginate: {itemsPerPage: rowsPerPage, currentPage: currentPage}) : data); last as last; let rowIndex = index"
|
|
10061
|
+
cdkDrag
|
|
10062
|
+
(click)="handleClickRow($event, rowIndex, row)" (dblclick)="handleDblClickRow($event, rowIndex, row)"
|
|
10063
|
+
(visibilityChange)="rowVisible.next(row)">
|
|
10064
|
+
<ng-container *ngIf="isSingleColumnRow(row)">
|
|
10065
|
+
<td class="simple-grid-single-column-cell" [attr.colspan]="headerColumnsCopy.length">
|
|
10066
|
+
<co-simple-grid-cell
|
|
10067
|
+
[column]="columns[singleColumnIndex(row)]"
|
|
10068
|
+
[row]="row"
|
|
10069
|
+
[editMode]="false">
|
|
10070
|
+
</co-simple-grid-cell>
|
|
10071
|
+
</td>
|
|
10072
|
+
</ng-container>
|
|
10073
|
+
<ng-container *ngIf="!isSingleColumnRow(row)">
|
|
10074
|
+
<ng-container *ngFor="let column of headerColumnsCopy; let columnIndex = index">
|
|
10075
|
+
<td class="simple-grid-column-cell" *ngIf="columnIndex !== singleColumnIndex(row)">
|
|
10076
|
+
<co-simple-grid-cell
|
|
10077
|
+
[column]="column"
|
|
10078
|
+
[row]="row"
|
|
10079
|
+
[editMode]="inlineEdit && editing && rowIndex === editRowIndex"
|
|
10080
|
+
[fieldEditMode]="editCellIndex === columnIndex && rowIndex === editRowIndex"
|
|
10081
|
+
(cellClick)="handleCellClick($event, row, rowIndex, columnIndex)">
|
|
10082
|
+
</co-simple-grid-cell>
|
|
10083
|
+
<div *ngIf="column.resizable" class="simple-grid-column-sizer-placeholder"></div>
|
|
10084
|
+
</td>
|
|
10085
|
+
</ng-container>
|
|
10086
|
+
</ng-container>
|
|
10087
|
+
</tr>
|
|
10088
|
+
</co-form>
|
|
10089
|
+
</tbody>
|
|
10090
|
+
</table>
|
|
10091
|
+
|
|
10092
|
+
<co-pagination-bar
|
|
10093
|
+
*ngIf="data?.length > rowsPerPage" class="pagination-bar"
|
|
10094
|
+
[itemsPerPage]="rowsPerPage"
|
|
10095
|
+
[currentPage]="currentPage"
|
|
10096
|
+
[totalItems]="data.length"
|
|
10097
|
+
[autoHide]="true"
|
|
10098
|
+
(previousClick)="goToPreviousPage()"
|
|
10099
|
+
(nextClick)="goToNextPage()"
|
|
10100
|
+
(pageClick)="setCurrentPage($event)">
|
|
10101
|
+
</co-pagination-bar>
|
|
10038
10102
|
`,
|
|
10039
|
-
providers: [
|
|
10040
|
-
FormMasterService
|
|
10041
|
-
],
|
|
10103
|
+
providers: [FormMasterService],
|
|
10042
10104
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
10043
10105
|
encapsulation: ViewEncapsulation.None
|
|
10044
10106
|
},] }
|
|
@@ -10046,7 +10108,8 @@ SimpleGridComponent.decorators = [
|
|
|
10046
10108
|
SimpleGridComponent.ctorParameters = () => [
|
|
10047
10109
|
{ type: IconCacheService },
|
|
10048
10110
|
{ type: ChangeDetectorRef },
|
|
10049
|
-
{ type: FormMasterService }
|
|
10111
|
+
{ type: FormMasterService },
|
|
10112
|
+
{ type: ExcelExportService }
|
|
10050
10113
|
];
|
|
10051
10114
|
SimpleGridComponent.propDecorators = {
|
|
10052
10115
|
headerCells: [{ type: ViewChildren, args: ['headerCell',] }],
|
|
@@ -14778,5 +14841,5 @@ HourSchedulingExpandableComponentModule.decorators = [
|
|
|
14778
14841
|
* Generated bundle index. Do not edit.
|
|
14779
14842
|
*/
|
|
14780
14843
|
|
|
14781
|
-
export { ArticleTileComponent, ArticleTileModule, BaseInputComponent, BaseInputDatePickerDirective, BaseModuleScreenConfigService, BaseModuleService, ButtonComponent, ButtonModule, CalendarComponent, CalendarModule, CardComponent, CardModule, Carousel3dComponent, Carousel3dModule, CarouselComponent, CarouselHammerConfig, CarouselModule, CheckmarkOverlayModule, ClickoutsideModule, CoDialogComponent, CoDialogModule, CoDialogWizardComponent, CoDialogWizardModule, CoDirection, CoOrientation, CollapsibleComponent, CollapsibleModule, ColorPickerComponent, ColorPickerModule, ColorSequenceService, ColumnAlign, ContentViewMode, CoreComponentsIcon, CoreComponentsTranslationModule, CoreComponentsTranslationService, CoreDialogModule, CoreDialogService, DoubleCalendarComponent, DoubleCalendarModule, FilterItemComponent, FilterItemMode, FilterItemModule, FilterItemViewmodel, FilterPipe, FilterPipeModule, FilterViewmodel, FormComponent, FormInputUserModelChangeListenerService, FormMasterService, FormModule, GridToolbarButtonComponent, GridToolbarButtonModule, GridToolbarComponent, GridToolbarModule, HourSchedulingComponent, HourSchedulingComponentModule, HourSchedulingExpandableComponent, HourSchedulingExpandableComponentModule, HourSchedulingExpandableTemplateComponent, IconCacheService, IconCollapseHandleComponent, IconCollapseHandleModule, IconComponent, IconModule, ImageComponent, ImageModule, InputCheckboxComponent, InputCheckboxModule, InputDatePickerComponent, InputDatePickerModule, InputDateRangePickerComponent, InputDateRangePickerModule, InputNumberPickerComponent, InputNumberPickerModule, InputRadioButtonComponent, InputRadioButtonModule, InputScannerComponent, InputScannerModule, InputSearchComponent, InputSearchModule, InputTextComponent, InputTextModule, InputTextareaComponent, InputTextareaModule, LevelIndicatorComponent, LevelIndicatorModule, ListOfIconsComponent, ListOfIconsModule, ListOfValuesComponent, ListOfValuesModule, ListOfValuesPopupComponent, LoaderComponent, LoaderModule, NgZoneWrapperService, ObserveVisibilityModule, OrientationOfDirection, OverlayModule, OverlayService, PaginationBarComponent, PaginationBarModule, PaginationComponent, PaginationModule, PopupButtonsComponent, PopupMessageDisplayComponent, PopupModule, PopupWindowShellComponent, PriceDisplayPipe, PriceDisplayPipeModule, PromptService, ResponsiveTextComponent, ResponsiveTextModule, SCREEN_CONFIG_ADAPTER_COMPONENT_INTERFACE_NAME, ScreenConfigurationDirective, ScreenConfigurationModule, SimpleGridColumnDirective, SimpleGridComponent, SimpleGridModule, TemplateWrapperDirective, TemplateWrapperModule, TextInputPopupComponent, TileComponent, TileModule, TileSelectComponent, TileSelectModule, TooltipDirectiveModule, ViewModeButtonsComponent, ViewModeButtonsModule, emailValidator, equalValidator, getValidatePasswordErrorString, maxStringLengthValidator, passwordValidator, precisionScaleValidator, requiredValidator, showHideDialog, InputBoolean as ɵa, RippleModule as ɵb,
|
|
14844
|
+
export { ArticleTileComponent, ArticleTileModule, BaseInputComponent, BaseInputDatePickerDirective, BaseModuleScreenConfigService, BaseModuleService, ButtonComponent, ButtonModule, CalendarComponent, CalendarModule, CardComponent, CardModule, Carousel3dComponent, Carousel3dModule, CarouselComponent, CarouselHammerConfig, CarouselModule, CheckmarkOverlayModule, ClickoutsideModule, CoDialogComponent, CoDialogModule, CoDialogWizardComponent, CoDialogWizardModule, CoDirection, CoOrientation, CollapsibleComponent, CollapsibleModule, ColorPickerComponent, ColorPickerModule, ColorSequenceService, ColumnAlign, ContentViewMode, CoreComponentsIcon, CoreComponentsTranslationModule, CoreComponentsTranslationService, CoreDialogModule, CoreDialogService, DoubleCalendarComponent, DoubleCalendarModule, FilterItemComponent, FilterItemMode, FilterItemModule, FilterItemViewmodel, FilterPipe, FilterPipeModule, FilterViewmodel, FormComponent, FormInputUserModelChangeListenerService, FormMasterService, FormModule, GridToolbarButtonComponent, GridToolbarButtonModule, GridToolbarComponent, GridToolbarModule, HourSchedulingComponent, HourSchedulingComponentModule, HourSchedulingExpandableComponent, HourSchedulingExpandableComponentModule, HourSchedulingExpandableTemplateComponent, IconCacheService, IconCollapseHandleComponent, IconCollapseHandleModule, IconComponent, IconModule, ImageComponent, ImageModule, InputCheckboxComponent, InputCheckboxModule, InputDatePickerComponent, InputDatePickerModule, InputDateRangePickerComponent, InputDateRangePickerModule, InputNumberPickerComponent, InputNumberPickerModule, InputRadioButtonComponent, InputRadioButtonModule, InputScannerComponent, InputScannerModule, InputSearchComponent, InputSearchModule, InputTextComponent, InputTextModule, InputTextareaComponent, InputTextareaModule, LevelIndicatorComponent, LevelIndicatorModule, ListOfIconsComponent, ListOfIconsModule, ListOfValuesComponent, ListOfValuesModule, ListOfValuesPopupComponent, LoaderComponent, LoaderModule, NgZoneWrapperService, ObserveVisibilityModule, OrientationOfDirection, OverlayModule, OverlayService, PaginationBarComponent, PaginationBarModule, PaginationComponent, PaginationModule, PopupButtonsComponent, PopupMessageDisplayComponent, PopupModule, PopupWindowShellComponent, PriceDisplayPipe, PriceDisplayPipeModule, PromptService, ResponsiveTextComponent, ResponsiveTextModule, SCREEN_CONFIG_ADAPTER_COMPONENT_INTERFACE_NAME, ScreenConfigurationDirective, ScreenConfigurationModule, SimpleGridColumnDirective, SimpleGridComponent, SimpleGridModule, TemplateWrapperDirective, TemplateWrapperModule, TextInputPopupComponent, TileComponent, TileModule, TileSelectComponent, TileSelectModule, TooltipDirectiveModule, ViewModeButtonsComponent, ViewModeButtonsModule, emailValidator, equalValidator, getValidatePasswordErrorString, maxStringLengthValidator, passwordValidator, precisionScaleValidator, requiredValidator, showHideDialog, InputBoolean as ɵa, RippleModule as ɵb, ObserveVisibilityDirective as ɵba, PaginationService as ɵbb, PaginatePipe as ɵbc, SimpleGridCellComponent as ɵbd, ListOfValuesMultiselectPopupComponent as ɵbe, ConfirmationDialogComponent as ɵbf, DialogBaseComponent as ɵbg, CoreDynamicComponentService as ɵbh, PrependPipeModule as ɵbi, PrependPipe as ɵbj, CheckmarkOverlayComponent as ɵbk, ScannerService as ɵbl, TooltipModule as ɵbm, TooltipComponent as ɵbn, TooltipDirective as ɵbo, HourSchedulingTestObjectComponent as ɵbp, MD_RIPPLE_GLOBAL_OPTIONS as ɵc, CoRippleDirective as ɵd, CoViewportRulerService as ɵe, CoScrollDispatcherService as ɵf, CoScrollableDirective as ɵg, StopClickModule as ɵh, StopClickDirective as ɵi, BaseModule as ɵj, AppendPipeModule as ɵk, AppendPipe as ɵl, ValidationErrorModule as ɵm, OverlayDirective as ɵn, OverlayParentDirective as ɵo, CoreLocalizePipe as ɵp, CoreDictionaryService as ɵq, ValidationErrorComponent as ɵr, CommitButtonsModule as ɵs, CommitButtonsComponent as ɵt, ClickOutsideDirective as ɵu, ClickOutsideMasterService as ɵv, CalendarTemplateComponent as ɵw, PopupShowerService as ɵx, BaseSimpleGridComponent as ɵy, ExcelExportService as ɵz };
|
|
14782
14845
|
//# sourceMappingURL=colijnit-corecomponents_v12.js.map
|