Files
Gas-Tank-AR-App/GasTankAR/Domain/Leads/Lead.swift

37 lines
782 B
Swift

import Foundation
struct Lead: Identifiable, Equatable, Sendable {
let id: String
let companyName: String?
let contact: LeadContact?
let address: LeadAddress
let phoneNumber: String?
let createdAt: Date
let offerCount: Int
let unsignedContractCount: Int
var isBookmarked: Bool
}
struct LeadContact: Equatable, Sendable {
let title: String?
let firstName: String
let lastName: String
}
struct LeadAddress: Equatable, Sendable {
let street: String?
let postalCode: String
let city: String
}
enum LeadError: Error, Equatable, Sendable {
case offline
case timeout
case serviceUnavailable
case unauthorized
case forbidden
case notFound(leadID: String)
case invalidResponse
case unexpected
}