mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-10 09:22:34 +00:00
Refactor #5196
This commit is contained in:
parent
3a89a10fd5
commit
30c20d4e8a
2 changed files with 15 additions and 4 deletions
|
@ -479,6 +479,7 @@ export default {
|
|||
},
|
||||
rowClasses() {
|
||||
let rowStyleClass = [];
|
||||
let columnSelectionMode = null;
|
||||
|
||||
if (this.rowClass) {
|
||||
let rowClassValue = this.rowClass(this.rowData);
|
||||
|
@ -488,7 +489,18 @@ export default {
|
|||
}
|
||||
}
|
||||
|
||||
return [this.cx('row', { rowData: this.rowData, index: this.rowIndex }), rowStyleClass];
|
||||
if (this.columns) {
|
||||
for (let col of this.columns) {
|
||||
let _selectionMode = this.columnProp(col, 'selectionMode');
|
||||
|
||||
if (ObjectUtils.isNotEmpty(_selectionMode) && _selectionMode === 'multiple') {
|
||||
columnSelectionMode = _selectionMode;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return [this.cx('row', { rowData: this.rowData, index: this.rowIndex, columnSelectionMode }), rowStyleClass];
|
||||
},
|
||||
rowTabindex() {
|
||||
if (this.selection === null && (this.selectionMode === 'single' || this.selectionMode === 'multiple')) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue