Skip to content

asadbaidar/flutter_absence_manager

Repository files navigation

Crewmeister | Absence Manager

Crewmeister absence manager using supabase as backend.

Features

  • List of absences including the names of the employees.
  • 10 absences per page, with the ability to paginate.
  • Total number of absences.
  • For each absence, details include: Member name, Type of absence, Period, Member note (when available), Status ('Requested', 'Confirmed' or 'Rejected'), Admitter note (when available)
  • Filter absences by type.
  • Filter absences by date.
  • Loading state until the list is available.
  • Error state if the list is unavailable.
  • Empty state if there are no results.
  • BLoC pattern for state management.
  • Dependency injection using get_it.
  • Localization for English and Deutsch using easy_localization.
  • Unit tests for Entity, DataSource, Model, Repository, and Bloc.
  • Multi-flavor setup for dev, qa, stage, and prod environments.
  • GoRouter for navigation.
  • Dio for network calls.
  • Supabase for backend.
  • Responsive material design for various screen sizes.
  • Clean architecture with Data, Domain, and Presentation layers.
  • Deployed on Github Pages here.

Pre-requisites

Make sure you have following or latest flutter/dart sdk installed on your machine. If not, follow the instructions here.

flutter: 3.24.5 dart: 3.5.4

Setup

  1. Add supabase apikey in app/crewmeister/lib/environment.dart file.
  static const apiToken = 'SUPABASE_API_KEY';
  1. To setup the project, use the following commands:
$ flutter pub get
$ dart run build_runner build --delete-conflicting-outputs
  1. To run the app, use the following commands:
$ cd app/crewmeister
$ flutter run --flavor dev --target lib/main_dev.dart
  1. To build the binaries, use the following commands:
$ cd app/crewmeister
$ flutter build web --base-href /flutter_absence_manager/
$ flutter build apk --flavor dev --target lib/main_dev.dart
$ flutter build appbundle --flavor dev --target lib/main_dev.dart
$ flutter build ipa --flavor dev --target lib/main_dev.dart

Local Test Coverage

To run test coverage and generate report, lcov is required. Install it before running the command.

$ sh test_coverage.sh

Project Structure

├── app
│   └── crewmeister
│       ├── android
│       ├── ios
│       ├── web
│       └── lib
│           ├── environment.dart
│           ├── main.dart
│           ├── main_dev.dart
│           ├── main_prod.dart
│           ├── main_qa.dart
│           └── main_stage.dart
├── lib
│   ├── app
│   │   └── app_view.dart
│   ├── common
│   │   ├── injector.dart
│   │   ├── launcher.dart
│   │   └── router
│   ├── feature
│   │   ├── absence
│   │   │   ├── data
│   │   │   │   ├── entity
│   │   │   │   ├── remote
│   │   │   │   └── repository
│   │   │   ├── domain
│   │   │   │   ├── model
│   │   │   │   └── repository
│   │   │   └── presentation
│   │   │       ├── bloc
│   │   │       ├── listener
│   │   │       ├── page
│   │   │       ├── view
│   │   │       └── widget
│   │   └── employee
│   │       ├── data
│   │       │   ├── entity
│   │       │   ├── remote
│   │       │   └── repository
│   │       ├── domain
│   │       │   ├── model
│   │       │   └── repository
│   │       └── presentation
│   │           ├── bloc
│   │           ├── page
│   │           ├── view
│   │           └── widget
│   └── tab
│       └── presentation
│           ├── bloc
│           ├── page
│           ├── presentation.dart
│           ├── view
│           └── widget
└── packages
    ├── common
    │   ├── assets
    │   └── lib
    │       ├── constants
    │       ├── theme
    │       ├── utils
    │       └── widgets
    └── locale
        ├── lib
        │   └──locale.dart
        └── translations
            ├── de-DE.json
            └── en-US.json

About

Flutter app for managing employee absences

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published