Fix logout, share code display, loading states, and multi-user support
iOS Logout Fix: - Use @EnvironmentObject in MainTabView and ProfileTabView - Pass loginViewModel from LoginView to MainTabView - Handle logout by dismissing main tab when isAuthenticated becomes false - Logout button now properly returns user to login screen Share Code UX: - Clear share code on ManageUsers screen open (iOS & Android) - Remove auto-loading of share codes - User must explicitly generate code each time - Improves security with fresh codes Loading State Improvements: - iOS ResidenceDetailView shows loading immediately on navigation - Android ResidenceDetailScreen enhanced with "Loading residence..." text - Better user feedback during API calls Multi-User Support: - Add isPrimaryOwner and userCount to ResidenceWithTasks model - Update iOS toResidences() extension to include new fields - Sync with backend API changes for shared user access 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -462,6 +462,8 @@ extension Array where Element == ResidenceWithTasks {
|
||||
id: item.id,
|
||||
owner: KotlinInt(value: item.owner),
|
||||
ownerUsername: item.ownerUsername,
|
||||
isPrimaryOwner: item.isPrimaryOwner,
|
||||
userCount: item.userCount,
|
||||
name: item.name,
|
||||
propertyType: item.propertyType,
|
||||
streetAddress: item.streetAddress,
|
||||
|
||||
Reference in New Issue
Block a user