Skip to content

HananelSabag/WorkSchedule

Repository files navigation

๐Ÿ“… WorkSchedule - Smart Shift Management System

A modern, fully-featured Android application for intelligent work shift scheduling and management, built with Kotlin and Jetpack Compose.

โœจ Now with Dynamic Shift Templates - Create custom shifts tailored to your workplace!

Free to Use! This app is open-source and ready for anyone to use. Whether you manage a restaurant, retail store, hospital, or any business with shift workers - this tool is here to help you! โค๏ธ

๐ŸŽฏ About This Project

WorkSchedule was developed as a complete solution for shift management challenges. The app provides intuitive manual scheduling with smart blocking and customizable templates, offering the flexibility needed for real-world scenarios.

Looking for opportunities: I'm Hananel Sabag, a Software Engineering graduate actively seeking development positions. This project demonstrates my skills in Android development, clean architecture, and modern UI/UX design. Feel free to reach out!

โœจ Key Features

๐Ÿ”ง Dynamic Shift Template System (NEW!)

  • Fully Customizable Shifts - Define your own shift names, hours, and days
  • Flexible Table Configuration - Choose 2-8 shifts and 4-7 working days
  • Easy Template Management - Edit and update your shift template anytime
  • Automatic Migration - Seamlessly upgrades from previous versions

๐Ÿ‘ฅ Employee Management

  • Add, edit, and delete employees
  • Shabbat observer support (automatic blocking of Shabbat shifts)
  • "Mitgaber" status for temporarily unavailable employees
  • Clean and intuitive interface

๐Ÿšซ Smart Blocking System

  • Regular blocking (Cannot) - Mark shifts when employees are unavailable
  • Can-Only blocking - Mark only the shifts employees are available for
  • Automatic blocking for Shabbat observers
  • Prevention of mixed blocking types per employee
  • Clear warning messages and override options

๐Ÿค– Automatic Schedule Generation (NEW!)

  • Generic AI-powered algorithm - Works with any custom shift template
  • Dynamic time-based logic - Handles overlaps, rest periods, and shift conflicts
  • Respects all blocking rules - Cannot blocks, Can-Only blocks, and Shabbat observer auto-blocks
  • Employee property support - Mitgaber employees assigned last, maximum hours per day (12h)
  • Conflict detection - Prevents night-to-morning assignments and same-day overlaps
  • Fair distribution - Balances shifts across employees
  • Smart scoring system - Considers rest periods (8+ hours preferred) and workload

โœ๏ธ Manual Scheduling

  • Manual employee assignment to shifts
  • Free text support (notes, custom hours)
  • Smart blocking with override confirmation
  • Auto-save draft system
  • Continue from where you left off

๐Ÿ“Š Preview & Analytics

  • Detailed shift table with zoom capabilities
  • Direct cell editing
  • Advanced Statistics:
    • Shift count per employee
    • Smart weekly hours calculation
    • Free text support (custom hours detection)
    • Automatic employee name recognition from text

๐Ÿ“ค Export & Share

  • Export to image (PNG) with your custom shift template
  • Export to CSV/Excel format
  • Direct sharing via WhatsApp and other apps
  • Beautiful formatted text output
  • Full RTL support for Hebrew

๐Ÿ’พ History & Storage

  • Automatic schedule saving
  • Complete history of all schedules
  • Rename, edit, and manage existing schedules
  • Delete and override schedules
  • Smart Draft System:
    • Auto-save when exiting the app
    • Opens in the correct screen (blocking/manual)
    • Auto-delete when schedule is completed

๐ŸŽจ Design & UI/UX

  • Modern UI with Material Design 3
  • Beautiful redesigned History screen with modern card design
  • Centered empty states with elegant visuals
  • Full RTL support (Hebrew)
  • Complete Dark Mode support
  • Smooth animations and transitions
  • Intuitive user experience

๐Ÿ› ๏ธ Technologies

Core

  • Kotlin - Modern, concise programming language
  • Jetpack Compose - Declarative UI framework
  • Material Design 3 - Latest design system

Architecture

  • MVVM - Clean architecture pattern
  • StateFlow - Reactive state management
  • ViewModel - Separation of logic from UI
  • Coroutines - Asynchronous programming

Database & Storage

  • Room Database - Local database with migrations
  • KSP - Annotation processing
  • Gson - JSON serialization
  • Multi-table relations - Complex data management

Additional Libraries

  • Coil - Efficient image loading
  • Material Icons Extended - Comprehensive icon set

๐Ÿ“‹ System Requirements

  • Android: 8.0 (API 26) and above
  • Storage: ~10MB
  • Permissions: Storage (for image/file export)

๐Ÿš€ Installation

For End Users

Download & Install APK:

  1. Download: ืกื™ื“ื•ืจ ืขื‘ื•ื“ื”V2.apk from the repository root
  2. Transfer the file to your Android device
  3. On your device, enable "Install from unknown sources" in Settings (if prompted)
  4. Tap the APK file to install
  5. Grant necessary permissions (Storage for exports)
  6. Start scheduling!

Note: The APK is ready to use and includes all features of Version 2.0

For Developers

Development Requirements:

- Android Studio Hedgehog | 2023.1.1 or higher
- JDK 11
- Gradle 8.2
- Kotlin 1.9.0

Local Setup:

# Clone the repository
git clone https://github.com/YOUR_USERNAME/WorkSchedule.git

# Open in Android Studio
# Build and run on emulator or physical device

Build APK:

# Debug build
./gradlew assembleDebug

# Release build
./gradlew assembleRelease

๐Ÿ“ Project Structure

app/src/main/java/com/hananel/workschedule/
โ”œโ”€โ”€ data/                      # Data layer
โ”‚   โ”œโ”€โ”€ AppDatabase.kt        # Room database with migrations
โ”‚   โ”œโ”€โ”€ Employee.kt           # Employee entity
โ”‚   โ”œโ”€โ”€ Schedule.kt           # Schedule entity
โ”‚   โ”œโ”€โ”€ ShiftTemplate.kt      # Dynamic shift template
โ”‚   โ”œโ”€โ”€ ShiftRow.kt           # Shift row definition
โ”‚   โ”œโ”€โ”€ DayColumn.kt          # Day column definition
โ”‚   โ”œโ”€โ”€ DynamicShiftManager.kt # Template manager
โ”‚   โ””โ”€โ”€ *Dao.kt               # Data access objects
โ”œโ”€โ”€ ui/                        # Presentation layer
โ”‚   โ”œโ”€โ”€ components/           # Reusable UI components
โ”‚   โ”‚   โ”œโ”€โ”€ SimpleTable.kt    # Dynamic table component
โ”‚   โ”‚   โ””โ”€โ”€ ShiftRowEditDialog.kt # Shift editor
โ”‚   โ”œโ”€โ”€ BlockingScreen.kt     # Shift blocking interface
โ”‚   โ”œโ”€โ”€ ManualCreationScreen.kt # Manual scheduling
โ”‚   โ”œโ”€โ”€ PreviewScreen.kt      # Schedule preview & stats
โ”‚   โ”œโ”€โ”€ HistoryScreen.kt      # Beautiful schedule history
โ”‚   โ”œโ”€โ”€ EmployeeManagementScreen.kt # Employee CRUD
โ”‚   โ”œโ”€โ”€ ShiftTemplateSetupScreen.kt # Template configuration
โ”‚   โ”œโ”€โ”€ SplashScreen.kt       # App intro screen
โ”‚   โ”œโ”€โ”€ HomeScreen.kt         # Main navigation hub
โ”‚   โ””โ”€โ”€ theme/                # Theme & styling
โ”œโ”€โ”€ viewmodel/                 # Business logic layer
โ”‚   โ””โ”€โ”€ ScheduleViewModel.kt  # Main ViewModel
โ”œโ”€โ”€ utils/                     # Utilities
โ”‚   โ”œโ”€โ”€ GenericScheduleGenerator.kt # AI scheduling algorithm
โ”‚   โ”œโ”€โ”€ WhatsAppSharer.kt     # Text export
โ”‚   โ”œโ”€โ”€ ExcelExporter.kt      # CSV export
โ”‚   โ””โ”€โ”€ ImageSharer.kt        # Image export
โ””โ”€โ”€ MainActivity.kt            # App entry point

๐ŸŽฏ How to Use

First Time Setup

  1. Open the app - Welcome splash screen
  2. Add employees - Navigate to Employee Management
  3. Configure shift template - Set up your custom shifts and days
  4. Ready to schedule!

Creating a Schedule

  1. Click "New Schedule"
  2. Block unavailable shifts - Mark when employees can't work
  3. Generate schedule - Choose automatic generation or manual assignment:
    • Automatic: AI creates a fair schedule respecting all rules
    • Manual: Drag employees to shifts or type freely
  4. Review statistics - Check fairness and balance
  5. Export and share - Send via WhatsApp or save as image

Managing Templates

  1. Click "Edit Table Structure" from home screen
  2. Add shifts - Create up to 8 custom shifts with structured time input and placeholder hints
  3. Reorder shifts - Drag & drop to any position with hamburger icon (โ˜ฐ) or long press on card
  4. Edit shift details - Names and working hours with validation
  5. Enable/disable days - Choose 4-7 working days (compact 2-column layout)
  6. Auto-save - Changes save automatically, exit when done

Continuing Draft Work

  1. App remembers your progress - Auto-saved when closing
  2. Click "Continue Draft" - Picks up exactly where you left off
  3. Complete and save - Draft auto-deletes when done

๐Ÿ”„ Version History

Version 2.0 (Current) ๐Ÿš€

  • โœจ NEW: Generic Automatic Schedule Generation - AI algorithm works with any custom template
  • โœจ NEW: Dynamic Shift Template System - Fully customizable shifts (2-8 shifts, 4-7 days)
  • โœจ NEW: Advanced Drag & Drop - Reorder shifts to any position with real-time visual feedback
  • โœจ NEW: Structured Time Input - Validated hour/minute fields with placeholder hints
  • โœจ NEW: Auto-Save System - Smart saving without leaving the editing screen
  • โœจ NEW: Compact Day Selection - Space-efficient 2-column grid layout
  • โœจ NEW: Beautiful History UI - Modern card design with elegant empty states
  • โœจ NEW: Template Management Screen - Configure shifts anytime with auto-save
  • โœจ NEW: Automatic Migration - Seamless upgrade for existing users
  • โœจ NEW: Generic Employee System - No hardcoded employee data
  • โœจ NEW: First-Time Setup Flow - Guided template creation
  • โœ… Complete application generalization - works for any workplace
  • โœ… Perfect Dark Mode support across all screens
  • โœ… Real-time statistics with dynamic template support
  • โœ… CSV/Excel export with dynamic templates
  • โœ… Schedule renaming capability
  • โœ… Image export with custom shift configurations
  • โœ… Smart draft management - auto-clear when schedule saved
  • โœ… Shadow-free UI design throughout
  • โœ… UI/UX improvements throughout

Version 1.1

  • โœ… Smart hours calculation with free text support
  • โœ… Enhanced draft system with better persistence
  • โœ… Improved "Can-Only" blocking logic
  • โœ… Block persistence with schedules
  • โœ… UI/UX fixes

Version 1.0

  • ๐ŸŽ‰ Initial release
  • Manual scheduling with smart blocking
  • Employee and block management
  • History and export features
  • Basic shift definitions

๐Ÿ”ฎ Future Enhancements

Planned Features

  • Cloud Sync - Backup and sync across devices
  • Multi-workplace Support - Manage different locations/teams
  • Advanced Analytics - Detailed reports and insights
  • Notifications - Shift reminders for employees
  • Custom Themes - User-defined color schemes
  • Team Collaboration - Shared scheduling with multiple managers
  • Export to Google Calendar - Automatic calendar integration

๐Ÿค Contributing

Found a bug? Have an idea for improvement? Contributions are welcome!

How to Contribute

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Reporting Issues

  • Use the GitHub Issues tab
  • Provide detailed description and steps to reproduce
  • Include Android version and device model if relevant

๐Ÿ“„ License

This project is open source and available under the MIT License. Feel free to use, modify, and distribute - just keep the attribution! โค๏ธ

๐Ÿ‘จโ€๐Ÿ’ป Developer

Hananel Sabag
Software Engineering Graduate

Passionate about creating elegant, user-friendly solutions to real-world problems. This project showcases my skills in:

  • Modern Android development (Kotlin, Jetpack Compose)
  • Clean Architecture & MVVM pattern
  • Database design and migrations
  • Complex algorithm implementation
  • UI/UX design with Material Design 3
  • State management with Coroutines & Flow

Currently seeking software development opportunities!
If you're looking for a dedicated developer with strong technical skills and attention to detail, let's connect!

๐Ÿ™ Acknowledgments

  • Built with modern Android development best practices
  • Inspired by real-world workplace scheduling challenges
  • Designed for simplicity, efficiency, and ease of use
  • Community feedback and suggestions welcome

๐Ÿ“ž Contact & Support

For questions, suggestions, or collaboration opportunities:

  • Open an issue on GitHub
  • Check out my other projects
  • Feel free to reach out!

Built with โค๏ธ in Israel ๐Ÿ‡ฎ๐Ÿ‡ฑ

Made with Kotlin & Jetpack Compose

Free for everyone to use - Happy Scheduling! ๐Ÿ“…โœจ

About

Smart Android app for work shift scheduling with auto-generation, blocking system, and analytics - Built with Kotlin & Jetpack Compose

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors