mirror of
https://github.com/SyncrowIOT/web.git
synced 2026-10-26 03:27:55 +00:00
Implemented space management canvas.
This commit is contained in:
+1
-1
@@ -32,7 +32,7 @@ class CommunitiesTreeSelectionBloc
|
||||
) {
|
||||
emit(
|
||||
CommunitiesTreeSelectionState(
|
||||
selectedCommunity: null,
|
||||
selectedCommunity: event.community,
|
||||
selectedSpace: event.space,
|
||||
),
|
||||
);
|
||||
|
||||
+4
-3
@@ -8,7 +8,7 @@ sealed class CommunitiesTreeSelectionEvent extends Equatable {
|
||||
}
|
||||
|
||||
final class SelectCommunityEvent extends CommunitiesTreeSelectionEvent {
|
||||
final CommunityModel? community;
|
||||
final CommunityModel community;
|
||||
|
||||
const SelectCommunityEvent({required this.community});
|
||||
@override
|
||||
@@ -16,9 +16,10 @@ final class SelectCommunityEvent extends CommunitiesTreeSelectionEvent {
|
||||
}
|
||||
|
||||
final class SelectSpaceEvent extends CommunitiesTreeSelectionEvent {
|
||||
final SpaceModel? space;
|
||||
final SpaceModel space;
|
||||
final CommunityModel community;
|
||||
|
||||
const SelectSpaceEvent({required this.space});
|
||||
const SelectSpaceEvent({required this.space, required this.community});
|
||||
|
||||
@override
|
||||
List<Object?> get props => [space];
|
||||
|
||||
+1
-1
@@ -30,7 +30,7 @@ class SpaceManagementCommunitiesTreeSpaceTile extends StatelessWidget {
|
||||
initiallyExpanded: spaceIsExpanded,
|
||||
onExpansionChanged: (expanded) {},
|
||||
onItemSelected: () => context.read<CommunitiesTreeSelectionBloc>().add(
|
||||
SelectSpaceEvent(space: space),
|
||||
SelectSpaceEvent(community: community, space: space),
|
||||
),
|
||||
children: space.children
|
||||
.map(
|
||||
|
||||
Reference in New Issue
Block a user