diff --git a/.fvmrc b/.fvmrc index a6fc383..5618e75 100644 --- a/.fvmrc +++ b/.fvmrc @@ -1,5 +1,5 @@ { - "flutter": "3.35.2", + "flutter": "3.32.0", "runPubGetOnSdkChanges": true, "updateVscodeSettings": true, "updateGitIgnore": true diff --git a/.vscode/settings.json b/.vscode/settings.json index 97f1308..17f2bdf 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,3 +1,3 @@ { - "dart.flutterSdkPath": ".fvm/versions/3.35.2" + "dart.flutterSdkPath": ".fvm/versions/3.32.0" } \ No newline at end of file diff --git a/LICENSE b/LICENSE deleted file mode 100644 index cbdcdc6..0000000 --- a/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2025 Patrick Alvin Alcala - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/README.md b/README.md index 44164d8..db372a3 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,51 @@ -![Logo](assets/icon/icon.png) +# Pharmacy Mobile App -# OFA Mobile App +The Pharmacy Mobile App is a Flutter application designed to provide a seamless experience for customers interacting with a pharmacy service. This app includes features such as buying medicine, viewing menus, managing cart items, and accessing user profiles. + +## Table of Contents +1. [Features](#features) +2. [Prerequisites](#prerequisites) +3. [Getting Started](#getting-started) +4. [Contributing](#contributing) +5. [License](#license) ## Features +- **Login/Logout**: Customers can sign in and out of the app. +- **Menu View**: Access a menu with various medicine options. +- **Cart Management**: Add items to a cart and proceed to checkout. +- **Profile Management**: Update user profiles and manage personal information. -- **Stock Monitoring** -- **Consultation** -- **Symptoms Identification** -- **Cart Identification** -- **Profile Management** +## Prerequisites +Before running the project, ensure you have the following installed: +- [Flutter SDK](https://flutter.dev/docs/get-started/install) +- [Dart SDK](https://dart.dev/get-dart) + +## Getting Started +1. Clone this repository to your local machine. + ```sh + git clone https://github.com/yourusername/pharmacy_mobile.git + ``` +2. Navigate to the project directory. + ```sh + cd pharmacy_mobile + ``` +3. Install dependencies. + ```sh + flutter pub get + ``` +4. Run the application on a simulator or device. + ```sh + flutter run + ``` + +## Contributing +Contributions are welcome! Please follow these steps: + +1. Fork this repository. +2. Create a new branch (`feature/your-feature`). +3. Make your changes and commit them (`git commit -m 'Add some feature'`). +4. Push the branch to your forked repository (`git push origin feature/your-feature`). +5. Open a pull request in the original repository. ## License - -This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. \ No newline at end of file diff --git a/lib/pages/add_distributor_page.dart b/lib/pages/add_distributor_page.dart index 5761bb1..1335093 100644 --- a/lib/pages/add_distributor_page.dart +++ b/lib/pages/add_distributor_page.dart @@ -26,7 +26,7 @@ class _AddDistributorPageState extends State { final _addressController = TextEditingController(); final _refDistributors = RefDistributors(); - bool _isLoading = false; + late bool _isLoading = false; Future _getDistributorListCache() async { final distributorList = await _refDistributors.getList(); diff --git a/lib/pages/add_generics_page.dart b/lib/pages/add_generics_page.dart index ed5e1b4..97a3b7e 100644 --- a/lib/pages/add_generics_page.dart +++ b/lib/pages/add_generics_page.dart @@ -30,12 +30,12 @@ class _AddGenericsPageState extends State { final _nameController = TextEditingController(); final _formKey = GlobalKey(); - bool _isLoading = false; + late bool _isLoading = false; // late final List _categoryListCache = []; - late List _categoryList; - late String _selectedCategory; - late String _categoryUUID; + late List _categoryList = []; + late String _selectedCategory = ''; + late String _categoryUUID = ''; Future _getGenericListCache() async { final genericNameList = await _refGenericNames.getList(); diff --git a/lib/pages/add_manufacturer_page.dart b/lib/pages/add_manufacturer_page.dart index 2b01c05..117ce70 100644 --- a/lib/pages/add_manufacturer_page.dart +++ b/lib/pages/add_manufacturer_page.dart @@ -26,7 +26,7 @@ class _AddManufacturerPageState extends State { final _addressController = TextEditingController(); final _refManufacturers = RefManufacturers(); - bool _isLoading = false; + late bool _isLoading = false; Future _getManufacturerListCache() async { final manufacturerList = await _refManufacturers.getList(); diff --git a/lib/pages/add_medicine_page.dart b/lib/pages/add_medicine_page.dart index a2fd663..84bfdd1 100644 --- a/lib/pages/add_medicine_page.dart +++ b/lib/pages/add_medicine_page.dart @@ -55,24 +55,23 @@ class _AddMedicinePageState extends State { final _nameController = TextEditingController(); final _barcodeController = TextEditingController(); - bool _isLoading = false; - bool imageUploaded = false; - bool uploaded = false; - - late List _genericNameList; - late String _selectedGeneric; - late String _selectedCategory; - late List _typeList; - late String _selectedType; - late List _manufacturerList; - late List _distributorList; - late List _supplierList; - late String _selectedManufacturer; - late String _selectedDistributor; - late String _selectedSupplier; - late String uuid; - late String imageUrl; - late String imageUUID; + late bool _isLoading = false; + late List _genericNameList = []; + late String _selectedGeneric = ''; + late String _selectedCategory = ''; + late List _typeList = []; + late String _selectedType = ''; + late List _manufacturerList = []; + late List _distributorList = []; + late List _supplierList = []; + late String _selectedManufacturer = ''; + late String _selectedDistributor = ''; + late String _selectedSupplier = ''; + late String uuid = ''; + late bool imageUploaded = false; + late String imageUrl = ''; + late bool uploaded = false; + late String imageUUID = ''; Future _getGenerics() async { _genericNameList = await _refGenericNames.getList(); diff --git a/lib/pages/add_stock_page.dart b/lib/pages/add_stock_page.dart index 8df2d9c..cb12e13 100644 --- a/lib/pages/add_stock_page.dart +++ b/lib/pages/add_stock_page.dart @@ -34,12 +34,11 @@ class _AddStockPageState extends State with WidgetsBindingObserver final _priceController = TextEditingController(); final _stocks = Stocks(); - late List _medicineList; - late String _selectedMedicine; - late String barcode; - - bool _isLoading = false; - DateTime selectedDate = DateTime.now(); + late bool _isLoading = false; + late List _medicineList = []; + late String _selectedMedicine = ''; + late DateTime selectedDate = DateTime.now(); + late String barcode = ''; final sampleBarcode = '8992185411017'; diff --git a/lib/pages/add_supplier_page.dart b/lib/pages/add_supplier_page.dart index 08ba0f9..3d79329 100644 --- a/lib/pages/add_supplier_page.dart +++ b/lib/pages/add_supplier_page.dart @@ -25,7 +25,7 @@ class _AddSupplierPageState extends State { final _nameController = TextEditingController(); final _refSuppliers = RefSuppliers(); - bool _isLoading = false; + late bool _isLoading = false; Future _getSupplierListCache() async { final supplierList = await _refSuppliers.getList(); diff --git a/lib/pages/delete_stock_page.dart b/lib/pages/delete_stock_page.dart index 7f2486c..cef51b6 100644 --- a/lib/pages/delete_stock_page.dart +++ b/lib/pages/delete_stock_page.dart @@ -29,13 +29,12 @@ class _DeleteStockPageState extends State { final _stocks = Stocks(); final _quantityController = TextEditingController(); - bool _aboveQuantity = false; - bool _noStock = false; - double _serverQuantity = 0; - - late List _stockList; - late String _selectedStock; - late String _selectedUUID; + late List _stockList = []; + late String _selectedStock = ''; + late bool _aboveQuantity = false; + late bool _noStock = false; + late double _serverQuantity = 0; + late String _selectedUUID = ''; void _getStocks() async { _stockList = await _stocks.getList(); diff --git a/lib/pages/list_stocks_page.dart b/lib/pages/list_stocks_page.dart index b26460e..4372210 100644 --- a/lib/pages/list_stocks_page.dart +++ b/lib/pages/list_stocks_page.dart @@ -18,8 +18,8 @@ class ListStocksPage extends StatefulWidget { class _ListStocksPageState extends State { final _stocks = Stocks(); + late List _stockList = []; bool _isLoading = false; - late List _stockList; List _createRows() { final today = DateTime.now().toUtc(); diff --git a/lib/pages/login_page.dart b/lib/pages/login_page.dart index a7cbb5d..720c187 100644 --- a/lib/pages/login_page.dart +++ b/lib/pages/login_page.dart @@ -26,8 +26,8 @@ class _LoginPageState extends State { final _passwordController = TextEditingController(); final FocusNode _focusNode = FocusNode(); - bool _isLoading = false; - double containerHeight = 0.35; + late bool _isLoading = false; + late double containerHeight = 0.35; void _signIn() async { final email = _emailController.text; diff --git a/lib/pages/main_page.dart b/lib/pages/main_page.dart index 9035bb0..cddb7f8 100644 --- a/lib/pages/main_page.dart +++ b/lib/pages/main_page.dart @@ -45,7 +45,7 @@ class _MainPageState extends State { final _refDistributors = RefDistributors(); final _refSuppliers = RefSuppliers(); - bool _isLoading = false; + late bool _isLoading = false; void signOut() async { try { diff --git a/lib/pages/register_page.dart b/lib/pages/register_page.dart index 6b3597f..a1e6951 100644 --- a/lib/pages/register_page.dart +++ b/lib/pages/register_page.dart @@ -25,8 +25,8 @@ class _RegisterPageState extends State { final _confirmPasswordController = TextEditingController(); final FocusNode _focusNode = FocusNode(); - bool _isLoading = false; - double containerHeight = 0.44; + late bool _isLoading = false; + late double containerHeight = 0.44; Future _signUp() async { final email = _emailController.text; diff --git a/pubspec.lock b/pubspec.lock index 2f5cbdf..31709c5 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -556,26 +556,26 @@ packages: dependency: transitive description: name: leak_tracker - sha256: "8dcda04c3fc16c14f48a7bb586d4be1f0d1572731b6d81d51772ef47c02081e0" + sha256: "6bb818ecbdffe216e81182c2f0714a2e62b593f4a4f13098713ff1685dfb6ab0" url: "https://pub.dev" source: hosted - version: "11.0.1" + version: "10.0.9" leak_tracker_flutter_testing: dependency: transitive description: name: leak_tracker_flutter_testing - sha256: "1dbc140bb5a23c75ea9c4811222756104fbcd1a27173f0c34ca01e16bea473c1" + sha256: f8b613e7e6a13ec79cfdc0e97638fddb3ab848452eff057653abd3edba760573 url: "https://pub.dev" source: hosted - version: "3.0.10" + version: "3.0.9" leak_tracker_testing: dependency: transitive description: name: leak_tracker_testing - sha256: "8d5a2d49f4a66b49744b23b018848400d23e54caf9463f4eb20df3eb8acb2eb1" + sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" url: "https://pub.dev" source: hosted - version: "3.0.2" + version: "3.0.1" lints: dependency: transitive description: @@ -993,10 +993,10 @@ packages: dependency: transitive description: name: test_api - sha256: "522f00f556e73044315fa4585ec3270f1808a4b186c936e612cab0b565ff1e00" + sha256: fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd url: "https://pub.dev" source: hosted - version: "0.7.6" + version: "0.7.4" typed_data: dependency: transitive description: @@ -1105,10 +1105,10 @@ packages: dependency: transitive description: name: vector_math - sha256: d530bd74fea330e6e364cda7a85019c434070188383e1cd8d9777ee586914c5b + sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" url: "https://pub.dev" source: hosted - version: "2.2.0" + version: "2.1.4" vm_service: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index d3b6056..0f6450a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,7 +2,7 @@ name: pharmacy_mobile description: "Ofelia Franco-Alcala Pharmacy App." publish_to: "none" -version: 1.8.27 +version: 1.0.0+1 environment: sdk: ^3.6.1