Remove API pagination and fix contractor UI issues

- Remove pagination from all Django REST Framework endpoints
- Update Kotlin API clients to return direct lists instead of paginated responses
- Update iOS ViewModels to handle direct list responses
- Remove ContractorListResponse, DocumentListResponse, and PaginatedResponse models
- Fix contractor form specialty selector loading with improved DataCache access
- Fix contractor sheet presentation to use full screen (.presentationDetents([.large]))
- Improve UI test scrolling to handle lists of any size with smart end detection

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Trey t
2025-11-21 22:56:43 -06:00
parent 93bd50ac3e
commit e40aed31a7
25 changed files with 145 additions and 151 deletions

View File

@@ -38,7 +38,7 @@ struct ContractorFormSheet: View {
@State private var contractorSpecialties: [ContractorSpecialty] = []
private var specialties: [String] {
contractorSpecialties.map { $0.name }
return DataCache.shared.contractorSpecialties.value.map { $0.name }
}
private var canSave: Bool {
@@ -290,11 +290,10 @@ struct ContractorFormSheet: View {
}
}
}
.presentationDetents([.medium, .large])
.presentationDetents([.large])
}
.onAppear {
loadContractorData()
loadContractorSpecialties()
}
.handleErrors(
error: viewModel.errorMessage,
@@ -324,16 +323,6 @@ struct ContractorFormSheet: View {
isFavorite = contractor.isFavorite
}
private func loadContractorSpecialties() {
Task {
await MainActor.run {
if let specialties = DataCache.shared.contractorSpecialties.value as? [ContractorSpecialty] {
self.contractorSpecialties = specialties
}
}
}
}
// MARK: - Save Action
private func saveContractor() {