fix: don't show ungrouped column when the field type is checkbox (#4538)

This commit is contained in:
Richard Shiue 2024-01-29 17:27:59 +08:00 committed by GitHub
parent 8937856d36
commit 5c5b6d02e8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -303,12 +303,14 @@ class BoardBloc extends Bloc<BoardEvent, BoardState> {
boardController.addGroups(
groups
.where(
(group) =>
fieldController.getField(group.fieldId) != null &&
((!group.isDefault && group.isVisible) ||
(group.isDefault && !hideUngrouped)),
)
.where((group) {
final field = fieldController.getField(group.fieldId);
return field != null &&
(!group.isDefault && group.isVisible ||
group.isDefault &&
!hideUngrouped &&
field.fieldType != FieldType.Checkbox);
})
.map((group) => _initializeGroupData(group))
.toList(),
);