This commit is contained in:
Leon Bösche
2025-12-17 17:55:57 +01:00
parent 209dcb3a08
commit e5a4de7aab

View File

@@ -123,21 +123,30 @@ class _HomePageState extends State<HomePage> with TickerProviderStateMixin {
builder: (context, state) { builder: (context, state) {
if (state is OrganizationLoaded) { if (state is OrganizationLoaded) {
final orgs = state.organizations; final orgs = state.organizations;
return Row( return Column(
children: [ children: [
...orgs.map( Row(
(org) => Row( children: [
children: [ ...orgs.map(
_buildOrgButton(org, org.id == state.selectedOrg?.id, () { (org) => Row(
context.read<OrganizationBloc>().add( children: [
SelectOrganization(org.id), _buildOrgButton(
); org,
}), org.id == state.selectedOrg?.id,
const SizedBox(width: 16), () {
], context.read<OrganizationBloc>().add(
), SelectOrganization(org.id),
);
},
),
const SizedBox(width: 16),
],
),
),
_buildAddButton(() => _showCreateOrgDialog(context)),
],
), ),
_buildAddButton(() => _showCreateOrgDialog(context)), const Divider(height: 1),
], ],
); );
} else { } else {
@@ -288,7 +297,6 @@ class _HomePageState extends State<HomePage> with TickerProviderStateMixin {
children: [ children: [
const SizedBox(height: 8), const SizedBox(height: 8),
_buildOrgRow(context), _buildOrgRow(context),
const Divider(height: 1),
Expanded( Expanded(
child: _buildDrive(orgState), child: _buildDrive(orgState),
), ),