added singleUserMode and removed StaffSection from forms

This commit is contained in:
2026-05-13 15:41:35 +02:00
parent efb82b0d4a
commit c610d68b9c
9 changed files with 138 additions and 84 deletions

View File

@@ -79,7 +79,10 @@ class StaffSelectorModal extends StatelessWidget {
);
}
Widget _buildStaffGrid(BuildContext context, List<dynamic> staffList) {
Widget _buildStaffGrid(
BuildContext context,
List<StaffMemberModel> staffList,
) {
return Wrap(
spacing: 16,
runSpacing: 16,
@@ -98,7 +101,7 @@ class StaffSelectorModal extends StatelessWidget {
decoration: BoxDecoration(
color: Theme.of(
context,
).colorScheme.surfaceContainerHighest.withOpacity(0.3),
).colorScheme.surfaceContainerHighest.withValues(alpha: 0.3),
borderRadius: BorderRadius.circular(16),
border: Border.all(color: Theme.of(context).dividerColor),
),
@@ -109,7 +112,7 @@ class StaffSelectorModal extends StatelessWidget {
backgroundColor: Theme.of(context).colorScheme.primary,
foregroundColor: Theme.of(context).colorScheme.onPrimary,
child: Text(
staff['name'].substring(0, 1).toUpperCase(),
staff.name.substring(0, 1).toUpperCase(),
style: const TextStyle(
fontSize: 24,
fontWeight: FontWeight.bold,
@@ -118,7 +121,7 @@ class StaffSelectorModal extends StatelessWidget {
),
const SizedBox(height: 12),
Text(
staff['name'],
staff.name,
style: const TextStyle(fontWeight: FontWeight.bold),
overflow: TextOverflow.ellipsis,
),