Author: Do Gia Huy
Student ID: 104988294
The Swinburne E-Commerce Mobile Application is a full-featured Android mobile app designed to provide users with a seamless shopping experience. This application allows users to browse products, manage shopping carts, make purchases, track orders, and manage user accounts through an intuitive interface.
- Product Browsing: View a comprehensive catalog of products with detailed information
- Product Search & Filter: Easily find products using filters and search functionality
- Shopping Cart: Add/remove items, manage quantities, and calculate totals
- Checkout Process: Multi-step checkout with shipping and payment information
- User Authentication: Secure login and registration with Google Sign-In integration
- Order Management: View order history and track order status
- Favorite Products: Mark and manage favorite products for quick access
- User Profile: Manage user information and preferences
- Guest Checkout: Allow users to continue shopping without account creation
- Real-time Database: Firebase Firestore for scalable data management
- Modern UI/UX: Material Design components with smooth animations
- Bottom Navigation: Easy access to main sections (Home, Cart, Profile, Orders, Favorites)
- Image Optimization: Efficient image loading with Picasso and Glide
- Animations: Smooth transitions and slide animations between screens
- Language: Kotlin
- Android SDK: Target SDK 36, Min SDK 27
- Build Tool: Gradle (Kotlin DSL)
- Architecture Components: ViewModel, LiveData, Navigation, Fragment
- Firebase:
- Cloud Firestore (Database)
- Firebase Authentication
- Google Services
- UI Components:
- AndroidX Material Design (Material 3)
- ConstraintLayout
- RecyclerView
- Image Loading:
- Picasso
- Glide
- Authentication:
- Google Sign-In
- AndroidX Credentials API
- Async Operations:
- Kotlin Coroutines
- Testing:
- JUnit
- Robolectric
- Espresso
- Mockito
- AndroidX Navigation Testing
mobile/
βββ app/
β βββ src/
β β βββ main/
β β β βββ java/com/assignment3/
β β β β βββ MainActivity.kt # Main activity with navigation
β β β β βββ adapters/ # RecyclerView adapters
β β β β βββ fragments/ # UI fragments
β β β β β βββ auth/ # Login, Register, ResetPassword
β β β β β βββ home/ # Home screen
β β β β β βββ product/ # Product listing
β β β β β βββ productdetail/ # Product details
β β β β β βββ cart/ # Shopping cart
β β β β β βββ checkout/ # Checkout process
β β β β β βββ favorite/ # Favorites
β β β β β βββ order/ # Order management
β β β β β βββ profile/ # User profile
β β β β β βββ guest/ # Guest features
β β β β βββ models/ # Data models
β β β β βββ repositories/ # Data access layer
β β β β βββ interfaces/ # Interfaces and contracts
β β β βββ res/
β β β β βββ layout/ # XML layout files
β β β β βββ drawable/ # Vector drawables and resources
β β β β βββ anim/ # Animation resources
β β β β βββ values/ # Colors, strings, dimensions
β β β β βββ navigation/ # Navigation graph
β β β β βββ mipmap-*/ # App icons
β β β βββ AndroidManifest.xml # App manifest
β β βββ androidTest/ # Instrumentation tests
β β βββ test/ # Local unit tests
β βββ build.gradle.kts # App-level build configuration
β βββ google-services.json # Firebase configuration
βββ gradle/
β βββ libs.versions.toml # Centralized dependency versions
βββ build.gradle.kts # Root-level build configuration
βββ settings.gradle.kts # Project settings
βββ gradlew # Gradle wrapper (Unix)
The application uses the following core data models:
- User: User account information and authentication details
- Product: Product information including price, description, images
- CartItem: Shopping cart items with quantity and product reference
- OrderItem: Order history and status tracking
- ShippingAddress: Delivery address information
- Android Studio (latest version recommended)
- Java 11 or higher
- Android SDK 36
- Git
- Firebase account and project setup
-
Clone the Repository
git clone <repository-url> cd mobile
-
Configure Firebase
- Create a Firebase project in the Firebase Console
- Enable Firestore Database and Firebase Authentication
- Download your
google-services.jsonfile - Place it in the
app/directory
-
Build the Project
./gradlew build
-
Run the Application
- Open the project in Android Studio
- Connect an Android device or start an emulator
- Click "Run" (or press Shift+F10)
For release build:
./gradlew assembleReleaseThe APK will be available in app/release/
The project includes comprehensive test coverage:
./gradlew test./gradlew connectedAndroidTest- JUnit: Unit testing
- Robolectric: Android component testing
- Espresso: UI testing
- Mockito: Mocking framework
- AndroidX Navigation Testing: Fragment navigation testing
- App ID:
com.assignment3 - Version Code: 3
- Version Name: 1.1
- Target SDK: 36
- Minimum SDK: 27 (Android 8.1)
- Java Compatibility: Java 11
- Never commit sensitive files like
keystores/password.txtto version control - Keep
google-services.jsonsecure and out of public repositories - Use environment variables for sensitive configuration
The app uses Android Navigation Component with bottom navigation for main sections. Some screens (login, product detail, checkout) hide the bottom navigation for a cleaner experience.
The app uses LiveData and ViewModel for managing UI state. Kotlin Coroutines handle asynchronous operations.
Firebase Firestore is used for real-time data synchronization. Authentication is handled through Firebase Authentication with Google Sign-In support.
- Run
./gradlew cleanbefore building - Ensure you have the correct Android SDK versions installed
- Check that internet connection is available for dependency downloads
- Verify
google-services.jsonis in the correct location (app/) - Check Firebase project configuration matches app package name
- Ensure Firebase services are enabled in your project
- Update Android Emulator to the latest version
- For better performance, enable hardware acceleration
- If issues persist, try running on a physical device
This project is part of Swinburne University coursework.
- Name: Do Gia Huy
- Student ID: 104988294
- Institution: Swinburne University