Skip to content

Dinesh-Sowndar/flutter_billing_app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🛒 Mobile POS & Billing App

A feature-rich, high-performance offline-first billing and Point of Sale (POS) application built with Flutter. Designed for seamless retail checkout operations featuring barcode scanning, thermal Bluetooth printing, and robust local data persistence.

Screenshot

flutter_biiling_app.mp4

🎯 Project Scope

This application serves as a complete offline POS system for small to medium-sized retail shops. It streamlines the checkout process, catalog management, and receipt generation securely entirely on-device.

Core Features:

  • Product Management System: Complete CRUD operations for inventory items with barcode/QR code support.
  • Smart Checkout System: Rapid cart building via camera-based barcode scanning or manual entry, and robust order calculation functionality.
  • Bluetooth Thermal Printing: Direct integration with thermal printers (print_bluetooth_thermal) to instantly output physical receipts.
  • Shop Settings & Customization: Centrally managed shop details printed dynamically on receipts.
  • Offline-First Architecture: Powered by Hive for lightning-fast localized NoSQL data storage. No active internet connectivity required.

🛠 Tech Stack & Architecture

Built leveraging industry-standard architectural principles (Clean Architecture & Feature-Driven Design) ensuring scalability, separation of concerns, and robust testability.

  • Framework: Flutter (SDK >=3.1.0)
  • State Management: flutter_bloc
  • Dependency Injection: get_it
  • Routing: go_router
  • Local Database: hive & hive_flutter
  • Data Modeling: json_serializable, equatable
  • Functional Programming: fpdart
  • Hardware Integrations: mobile_scanner (barcodes), print_bluetooth_thermal

📁 File Structure

The codebase is organized using a Feature-First Clean Architecture utilizing domain-driven concepts.

lib/
├── core/                       # Core application utilities and shared components
│   ├── data/                   # Global data sources (e.g., Hive initialization)
│   ├── error/                  # Standardized Failure/Exception models (fpdart compatible)
│   ├── theme/                  # UI aesthetics, typography, styling
│   ├── usecase/                # Base UseCase contracts
│   ├── utils/                  # Helpers (e.g., PrinterHelper, formatters)
│   ├── widgets/                # Reusable global UI widgets (AppBars, generic buttons)
│   └── service_locator.dart    # get_it dependency injection setup
│
└── features/                   # Independent feature modules
    ├── billing/                # Core POS operations: Cart, Checkout, Invoice Generation
    ├── product/                # Inventory management: Adding, Listing, Scanning products
    ├── settings/               # App configuration: Printer connections, App settings
    └── shop/                   # Shop details configuration

Note: Each feature is further subdivided internally into Clean Architecture layers: data, domain, and presentation.

💡 Use Cases

  • Rapid Billing Entry: A cashier launches the app, navigates to the checkout page, and uses the device camera to instantly scan product barcodes. The products are added to the cart, the total is calculated including taxes, and a receipt is finalized.
  • Physical Receipt Generation: After checkout confirmation, the app triggers a connected external Bluetooth thermal POS printer to instantly print an itemized paper receipt with the shop’s header.
  • Inventory Sideloading: A manager opens the Product feature to add new stock to the local database, taking a picture of the barcode to bind the SKU for future lightning-fast checkouts.
  • No-Connection Operation: The business operates a stall at an exhibition with poor networking. The app functions entirely via its embedded Hive local database and Bluetooth, completely undisturbed by network drops.

🚀 Getting Started

Prerequisites

  • Flutter SDK ^3.1.0 or higher
  • Android Studio / Xcode for emulators and building.
  • Optional: A physical Android/iOS device and a Bluetooth Thermal Printer for testing hardware integrations natively.

Installation

  1. Clone the repository and navigate to the project directory:

    git clone <repository_url>
    cd billing_app
  2. Fetch dependencies:

    flutter pub get
  3. Run code generation (required for Hive adapters and JSON serialization):

    dart run build_runner build --delete-conflicting-outputs
  4. Run the project:

    flutter run

🤝 Contributing Guidelines

As a senior-focused project, please adhere to:

  1. Clean Architecture Rules: Maintain strict boundaries between domain, data, and presentation layers.
  2. Immutable States: Emit only immutable states from BLoCs utilizing equatable.
  3. No Direct Exceptions in Domain: Utilize fpdart's Either<Failure, Type> pattern to handle control flow for exceptions.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages