├── Back-and do projeto app iOS SKYPat ├── Configuração-do-APP-iOS │ ├── AppDelegate.swift │ ├── Infor.plist.swift │ └── SceneDelegate.swift ├── Models │ ├── Pet.swift │ └── User.swift ├── Networking │ ├── APIClient.swift │ └── Endpoints.swift ├── Resources │ ├── Assets.xcassets.swift │ └── LaunchScreen.storyboard.swift ├── Service │ ├── PetService.swift │ └── UserService.swift ├── SupportingFiles │ └── Info.plist.swift ├── View │ ├── LoginView.swift │ ├── PetDetailView.swift │ ├── PetView.swift │ └── RegisterView.swift └── ViewModels │ ├── PetViewModel.swift │ └── UserViewModel.swift └── README.md /Back-and do projeto app iOS SKYPat/Configuração-do-APP-iOS/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | 3 | @UIApplicationMain 4 | class AppDelegate: UIResponder, UIApplicationDelegate { 5 | var window: UIWindow? 6 | 7 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool { 8 | return true 9 | } 10 | 11 | func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration { 12 | return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role) 13 | } 14 | 15 | func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set) {} 16 | } 17 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Configuração-do-APP-iOS/Infor.plist.swift: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/P4dro-Dev/iOS-Pedy-APP/6bcec3673d945daed9258a9c77ad425d9d71f12d/Back-and do projeto app iOS SKYPat/Configuração-do-APP-iOS/Infor.plist.swift -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Configuração-do-APP-iOS/SceneDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import SwiftUI 3 | 4 | class SceneDelegate: UIResponder, UIWindowSceneDelegate { 5 | var window: UIWindow? 6 | 7 | func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) { 8 | let contentView = LoginView() 9 | 10 | if let windowScene = scene as? UIWindowScene { 11 | let window = UIWindow(windowScene: windowScene) 12 | window.rootViewController = UIHostingController(rootView: contentView) 13 | self.window = window 14 | window.makeKeyAndVisible() 15 | } 16 | } 17 | 18 | func sceneDidDisconnect(_ scene: UIScene) {} 19 | 20 | func sceneDidBecomeActive(_ scene: UIScene) {} 21 | 22 | func sceneWillResignActive(_ scene: UIScene) {} 23 | 24 | func sceneWillEnterForeground(_ scene: UIScene) {} 25 | 26 | func sceneDidEnterBackground(_ scene: UIScene) {} 27 | } 28 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Models/Pet.swift: -------------------------------------------------------------------------------- 1 | // Modelos (Models) 2 | // modelos representam os dados que o aplicativo manipula. 3 | 4 | //Pet.swift 5 | // Este modelo representa um pet com propriedades como nome, raça, idade e descrição. 6 | 7 | import Foundation 8 | 9 | struct Pet: Identifiable { 10 | var id = UUID() 11 | var name: String 12 | var breed: String 13 | var age: Int 14 | var description: String 15 | } 16 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Models/User.swift: -------------------------------------------------------------------------------- 1 | // User.swift 2 | // Este modelo representa um usuário com propriedades como nome de usuário, email e senha. 3 | 4 | import Foundation 5 | 6 | struct User: Identifiable { 7 | var id = UUID() 8 | var username: String 9 | var email: String 10 | var password: String 11 | } 12 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Networking/APIClient.swift: -------------------------------------------------------------------------------- 1 | //Networking 2 | //A camada de networking é responsável por fazer requisições HTTP para um servidor remoto. 3 | 4 | //APIClient.swift 5 | //Este arquivo contém a lógica para fazer requisições HTTP. 6 | 7 | import Foundation 8 | 9 | class APIClient { 10 | static let shared = APIClient() 11 | 12 | func request(endpoint: Endpoint, completion: @escaping (Result) -> Void) { 13 | guard let url = URL(string: endpoint.url) else { 14 | completion(.failure(NSError(domain: "Invalid URL", code: -1, userInfo: nil))) 15 | return 16 | } 17 | 18 | var request = URLRequest(url: url) 19 | request.httpMethod = endpoint.method.rawValue 20 | 21 | URLSession.shared.dataTask(with: request) { data, response, error in 22 | if let error = error { 23 | completion(.failure(error)) 24 | return 25 | } 26 | 27 | guard let data = data else { 28 | completion(.failure(NSError(domain: "No data", code: -1, userInfo: nil))) 29 | return 30 | } 31 | 32 | do { 33 | let decodedData = try JSONDecoder().decode(T.self, from: data) 34 | completion(.success(decodedData)) 35 | } catch { 36 | completion(.failure(error)) 37 | } 38 | }.resume() 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Networking/Endpoints.swift: -------------------------------------------------------------------------------- 1 | //Endpoints.swift 2 | //Este arquivo define os endpoints da API. 3 | 4 | import Foundation 5 | 6 | enum HTTPMethod: String { 7 | case GET 8 | case POST 9 | } 10 | 11 | struct Endpoint { 12 | var url: String 13 | var method: HTTPMethod 14 | } 15 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Resources/Assets.xcassets.swift: -------------------------------------------------------------------------------- 1 | // O Assets.xcassets é usado para gerenciar os recursos gráficos do seu aplicativo, como imagens, ícones e cores. -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Resources/LaunchScreen.storyboard.swift: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Service/PetService.swift: -------------------------------------------------------------------------------- 1 | //Serviços (Services) 2 | //Os serviços são responsáveis por realizar operações de negócios, como buscar dados ou autenticar usuários. 3 | 4 | //PetService.swift 5 | //Este serviço fornece uma lista de pets. 6 | 7 | import Foundation 8 | 9 | class PetService { 10 | func fetchPets() -> [Pet] { 11 | return [ 12 | Pet(name: "Buddy", breed: "Golden Retriever", age: 3), 13 | Pet(name: "Milo", breed: "Beagle", age: 2), 14 | Pet(name: "Bella", breed: "Poodle", age: 4) 15 | ] 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/Service/UserService.swift: -------------------------------------------------------------------------------- 1 | //UserService: 2 | //Este serviço lida com a autenticação de usuários. 3 | 4 | import Foundation 5 | 6 | class UserService { 7 | func login(username: String, password: String) -> Bool { 8 | // Implementar lógica de autenticação 9 | return true 10 | } 11 | 12 | func register(username: String, email: String, password: String) -> Bool { 13 | // Implementar lógica de registro 14 | return true 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/SupportingFiles/Info.plist.swift: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | CFBundleName 7 | SKY PET 8 | CFBundleIdentifier 9 | com.yourcompany.skypet 10 | CFBundleVersion 11 | 1.0 12 | CFBundleShortVersionString 13 | 1.0 14 | UILaunchStoryboardName 15 | LaunchScreen 16 | UIMainStoryboardFile 17 | Main 18 | LSRequiresIPhoneOS 19 | 20 | UIRequiredDeviceCapabilities 21 | 22 | armv7 23 | 24 | UISupportedInterfaceOrientations 25 | 26 | UIInterfaceOrientationPortrait 27 | UIInterfaceOrientationLandscapeLeft 28 | UIInterfaceOrientationLandscapeRight 29 | 30 | 31 | 32 | NSCameraUsageDescription 33 | Este aplicativo precisa acessar a câmera para tirar fotos dos pets. 34 | NSLocationWhenInUseUsageDescription 35 | Este aplicativo precisa acessar sua localização para mostrar pets próximos. 36 | 37 | 38 | CFBundleURLTypes 39 | 40 | 41 | CFBundleURLName 42 | com.yourcompany.skypet 43 | CFBundleURLSchemes 44 | 45 | skypet 46 | 47 | 48 | 49 | 50 | 51 | UIBackgroundModes 52 | 53 | fetch 54 | remote-notification 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/View/LoginView.swift: -------------------------------------------------------------------------------- 1 | //LoginView.swift 2 | //Esta view exibe a tela de login. 3 | 4 | import SwiftUI 5 | 6 | struct LoginView: View { 7 | @ObservedObject var viewModel = UserViewModel() 8 | @State private var username = "" 9 | @State private var password = "" 10 | 11 | var body: some View { 12 | VStack { 13 | TextField("Username", text: $username) 14 | .padding() 15 | .background(Color.gray.opacity(0.2)) 16 | .cornerRadius(5.0) 17 | SecureField("Password", text: $password) 18 | .padding() 19 | .background(Color.gray.opacity(0.2)) 20 | .cornerRadius(5.0) 21 | Button(action: { 22 | viewModel.login(username: username, password: password) 23 | }) { 24 | Text("Login") 25 | .font(.headline) 26 | .foregroundColor(.white) 27 | .padding() 28 | .frame(width: 220, height: 60) 29 | .background(Color.blue) 30 | .cornerRadius(15.0) 31 | } 32 | } 33 | .padding() 34 | } 35 | } 36 | 37 | struct LoginView_Previews: PreviewProvider { 38 | static var previews: some View { 39 | LoginView() 40 | } 41 | } 42 | 43 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/View/PetDetailView.swift: -------------------------------------------------------------------------------- 1 | //PetDetailView.swift 2 | //Esta view exibe os detalhes de um pet. 3 | 4 | import SwiftUI 5 | 6 | struct PetDetailView: View { 7 | var pet: Pet 8 | 9 | var body: some View { 10 | VStack(alignment: .leading) { 11 | Text(pet.name) 12 | .font(.largeTitle) 13 | Text(pet.breed) 14 | .font(.title) 15 | Text("Age: \(pet.age)") 16 | .font(.title2) 17 | Text(pet.description) 18 | .font(.body) 19 | Spacer() 20 | } 21 | .padding() 22 | .navigationTitle(pet.name) 23 | } 24 | } 25 | 26 | struct PetDetailView_Previews: PreviewProvider { 27 | static var previews: some View { 28 | PetDetailView(pet: Pet(name: "Buddy", breed: "Golden Retriever", age: 3, description: "Friendly and energetic")) 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/View/PetView.swift: -------------------------------------------------------------------------------- 1 | import SwiftUI 2 | 3 | struct LoginView: View { 4 | @ObservedObject var viewModel = UserViewModel() 5 | @State private var username = "" 6 | @State private var password = "" 7 | 8 | var body: some View { 9 | VStack { 10 | TextField("Username", text: $username) 11 | .padding() 12 | .background(Color.gray.opacity(0.2)) 13 | .cornerRadius(5.0) 14 | SecureField("Password", text: $password) 15 | .padding() 16 | .background(Color.gray.opacity(0.2)) 17 | .cornerRadius(5.0) 18 | Button(action: { 19 | viewModel.login(username: username, password: password) 20 | }) { 21 | Text("Login") 22 | .font(.headline) 23 | .foregroundColor(.white) 24 | .padding() 25 | .frame(width: 220, height: 60) 26 | .background(Color.blue) 27 | .cornerRadius(15.0) 28 | } 29 | } 30 | .padding() 31 | } 32 | } 33 | 34 | struct LoginView_Previews: PreviewProvider { 35 | static var previews: some View { 36 | LoginView() 37 | } 38 | } 39 | 40 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/View/RegisterView.swift: -------------------------------------------------------------------------------- 1 | //RegisterView.swift 2 | //Esta view exibe a tela de registro. 3 | 4 | import SwiftUI 5 | 6 | struct RegisterView: View { 7 | @ObservedObject var viewModel = UserViewModel() 8 | @State private var username = "" 9 | @State private var email = "" 10 | @State private var password = "" 11 | 12 | var body: some View { 13 | VStack { 14 | TextField("Username", text: $username) 15 | .padding() 16 | .background(Color.gray.opacity(0.2)) 17 | .cornerRadius(5.0) 18 | TextField("Email", text: $email) 19 | .padding() 20 | .background(Color.gray.opacity(0.2)) 21 | .cornerRadius(5.0) 22 | SecureField("Password", text: $password) 23 | .padding() 24 | .background(Color.gray.opacity(0.2)) 25 | .cornerRadius(5.0) 26 | Button(action: { 27 | viewModel.register(username: username, email: email, password: password) 28 | }) { 29 | Text("Register") 30 | .font(.headline) 31 | .foregroundColor(.white) 32 | .padding() 33 | .frame(width: 220, height: 60) 34 | .background(Color.green) 35 | .cornerRadius(15.0) 36 | } 37 | } 38 | .padding() 39 | } 40 | } 41 | 42 | struct RegisterView_Previews: PreviewProvider { 43 | static var previews: some View { 44 | RegisterView() 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/ViewModels/PetViewModel.swift: -------------------------------------------------------------------------------- 1 | //ViewModels 2 | //Os ViewModels são responsáveis por ligar os modelos às views, gerenciando a lógica de apresentação. 3 | 4 | //PetViewModel.swift 5 | //Este ViewModel gerencia a lista de pets. 6 | 7 | import SwiftUI 8 | 9 | struct PetView: View { 10 | @ObservedObject var viewModel = PetViewModel() 11 | 12 | var body: some View { 13 | NavigationView { 14 | List(viewModel.pets) { pet in 15 | VStack(alignment: .leading) { 16 | Text(pet.name) 17 | .font(.headline) 18 | Text(pet.breed) 19 | .font(.subheadline) 20 | Text("Age: \(pet.age)") 21 | .font(.subheadline) 22 | } 23 | } 24 | .navigationTitle("Pets") 25 | .onAppear { 26 | viewModel.loadPets() 27 | } 28 | } 29 | } 30 | } 31 | 32 | struct PetView_Previews: PreviewProvider { 33 | static var previews: some View { 34 | PetView() 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /Back-and do projeto app iOS SKYPat/ViewModels/UserViewModel.swift: -------------------------------------------------------------------------------- 1 | //UserViewModel.swift: 2 | //Este ViewModel gerencia a autenticação do usuário. 3 | 4 | import Foundation 5 | 6 | class UserViewModel: ObservableObject { 7 | @Published var isAuthenticated = false 8 | private var userService = UserService() 9 | 10 | func login(username: String, password: String) { 11 | self.isAuthenticated = userService.login(username: username, password: password) 12 | } 13 | 14 | func register(username: String, email: String, password: String) { 15 | self.isAuthenticated = userService.register(username: username, email: email, password: password) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # 💻| Pedy 📲🍎🐶🐱🐾 2 | 3 | ## 🗒️| Descrição 4 | Pedy é um aplicativo para iOS, de cuidados com pets que surgiu da necessida de de auxiliar tutores de animais no gerenciamento das atividades diárias e lembretes. O app foi pensado para ser intuitivo, eficiente e focado em oferecer uma experiência personalizada para cada pet. 5 | 6 | ## 🗂️| Estrutura do Projeto 7 | 8 | - `SKYPet/`: Diretório principal do projeto. 9 | - `AppDelegate.swift`: Arquivo de configuração do aplicativo. 10 | - `SceneDelegate.swift`: Gerencia as diferentes cenas do aplicativo. 11 | - `ViewControllers/`: Contém todos os view controllers do aplicativo. 12 | - `MainViewController.swift`: Tela principal do aplicativo. 13 | - `PetDetailsViewController.swift`: Tela de detalhes do pet. 14 | - `HealthRecordViewController.swift`: Tela de registro de saúde. 15 | - `Models/`: Contém os modelos de dados do aplicativo. 16 | - `Pet.swift`: Modelo de dados para os pets. 17 | - `HealthRecord.swift`: Modelo de dados para os registros de saúde. 18 | - `Views/`: Contém as views personalizadas do aplicativo. 19 | - `PetTableViewCell.swift`: Célula personalizada para e 20 | xibir informações dos pets. 21 | - `Resources/`: Contém recursos como imagens, arquivos JSON, etc. 22 | - `Services/`: Contém serviços para manipulação de dados e integração com APIs. 23 | - `PetService.swift`: Serviço para gerenciar dados dos pets. 24 | - `HealthRecordService.swift`: Serviço para gerenciar registros de saúde. 25 | - `Utils/`: Contém utilitários e extensões. 26 | - `DateFormatter.swift`: Extensões para formatação de datas. 27 | - `Assets.xcassets`: Contém os assets do aplicativo, como ícones e imagens. 28 | - `Info.plist`: Arquivo de configuração do projeto. 29 | 30 | ## 🔎| Funcionalidades 31 | - Registro de informações dos pets (nome, idade, raça, etc.). 32 | - Agendamento de lembretes de cuidados em relação aos pets. 33 | 34 | ## 🗃️| Imagens do protótipo de alta fidelidade do projeto no Figma: 35 | 36 | ## 🖥️| Tela de Cadastro do app 37 | 38 | ![Tela de início iOS SKY Pedy ](https://github.com/user-attachments/assets/65ef2a3c-7f57-40c8-a93f-f9f23e4a18b8) 39 | 40 | ## 📱| Home, e telas principais 41 | 42 | ![Imagens do protótipo de alta fidelidade no Figma: Home, e telas principais](https://github.com/user-attachments/assets/0df17b6a-110d-4153-8e43-c6c32186b23f) 43 | 44 | ## 📨| Telas Adicionar lembretes 45 | 46 | ![Telas para adicionar lembretes](https://github.com/user-attachments/assets/1220a6ac-0a43-460f-bac2-413277593366) 47 | 48 | ## 👤| Telas de perfis 49 | 50 | ![Imagens das telas de perfis do Figma](https://github.com/user-attachments/assets/52411e5b-9c89-4f8a-9638-5e520e7243f4) 51 | 52 | 🔗| link do Prótotipo de Alta qualidade no Figma 53 | 54 | [![Figma](https://img.shields.io/badge/Figma-F24E1E?style=for-the-badge&logo=figma&logoColor=white)](https://www.figma.com/design/DcVQ3puW6gIoyx2XBCfZBr/Pedy?node-id=0-1&p=f&t=QjosPPoNli5W4KEc-0) 55 | 56 | ## 📋| Requisitos 57 | - Xcode 12 ou superior. 58 | - Swift 5.0 ou superior. 59 | - iOS 13.0 ou superior. 60 | 61 | ## 💻| Como Executar 62 | 1. Clone este repositório: 63 | 64 | ```bash 65 | git clone https://github.com/BackandDeveloper/SKY-Pet.git 66 | 67 | 2. Abra o Xcode.: 68 | 69 | ```bash 70 | Abra o Xcode. Selecione "File" > "Open" e escolha o diretório do projeto clonado. 71 | 72 | 3. Execute o aplicativo:: 73 | 74 | ```bash 75 | Selecione o dispositivo ou simulador desejado. Clique no botão "Run" (ou pressione Cmd + R) para compilar e executar o aplicativo 76 | 77 | ## 🌐| Site que contém toda a documentação do projeto 78 | 79 | ## 👥| Contribuições: 80 | 81 | Caso tenham alguma ideia, experiência, e conhecimento na linguagem de programação Swift, sinta-se avontade de me mandar um e-mail solicitando! 82 | 83 | ## 📑| Licença 84 | Este projeto está licenciado sob a MIT License. 85 | 86 | ## ⚙️| Equipe completa, na qual fazem parte do desenvolvimento: 87 | 88 | 💡| Desenvolvedores Back-and: Pedro Henrique / José Gabriel 89 | 90 | 🖌️| Designers: Davi Santos / Thalia / Vinícius 91 | 92 | 👥| Voluntário que nos forneceu a API: Victor Santos 93 | 94 | ## 📩| Contato 95 | 96 | Para mais informações, ou dúvidas sobre o projeto: 97 | 98 | 📧| Email: henrique.pedro62@aluno.ifce.edu.br | jose.soares.santos9888@gmail.com | davidosantosqueiroz@outlook.com | vinicioolivindo81@gmail.com | thaliasantosfd@gmail.com 99 | 100 | 101 | 102 | 103 | --------------------------------------------------------------------------------