Restaurant CRM Dashboard is a legacy Java Swing desktop application developed for restaurant customer relationship management, customer and staff survey collection, serial-connected feedback devices, and reporting using an Apache Derby database.
This project was originally built more than 10 years ago as a practical desktop system. The modernization work in this repository focuses on making the project understandable, buildable, and recruiter-friendly while preserving the original behavior, UI layout, database model, and hardware assumptions.
The application is a Persian right-to-left restaurant CRM/dashboard. It supports login-based access, question and scenario banks, sending survey messages to external serial devices, health checks for survey nodes, and chart-based survey result views.
This is intentionally presented as a professionally preserved legacy system rather than a rewritten modern application.
This repository preserves the original application while improving documentation, repository organization, and build portability.
The goal is to demonstrate software engineering practices applied to a real-world legacy Java desktop application rather than to redesign or modernize the application's architecture.
- Swing desktop UI with login dialog and tabbed workflow
- Role/access-control table for question bank, scenario bank, and chart permissions
- Restaurant operations tabs for: Daily sales management, Chef recommendations / daily specials, Finished food management
- Survey question bank management
- Survey scenario bank management
- Serial message sending through RXTX
- Serial answer ingestion into Derby
- Node health-check workflow
- JFreeChart bar charts for survey results
- Embedded legacy Derby database directory for historical demo data
- Java Swing
- NetBeans Java SE project metadata
- Apache Ant build
- Apache Derby Network Server
- JDBC
- RXTX serial communication
- JFreeChart / JCommon
- Legacy third-party Java libraries
RestaurantMain starts serial communication, starts Derby Network Server on port 1527, opens the login dialog, and then shows the main Swing frame. RestaurantPane and SurveyPane organize the top-level and survey-specific tabs. Screen classes build UI controls directly and use the Database helper for SQL operations.
More detail is available in docs/architecture.md.
src/com/paydaran/Restaurant/ Java Swing source code
lib/ Legacy jar dependencies
Restaurant_DB/ Preserved Derby database files
nbproject/ NetBeans Ant project metadata
docs/ Portfolio and maintenance documentation
screenshots/ Placeholder folder for real screenshots
- JDK 8 recommended for best RXTX compatibility
JAVA_HOMEpointing to a JDK- Apache Ant
- RXTX native library installed for real serial hardware use
ant jarjava -cp "dist/Restaurant.jar:lib/*" com.paydaran.Restaurant.RestaurantMainOn Windows, use ; instead of : in the classpath.
The application starts Derby Network Server automatically and connects to:
jdbc:derby://localhost:1527/Restaurant_DB
Default legacy login:
username: admin
password: admin
Database credentials used by the application:
username: paydaran
password: 123
Use demo mode when serial hardware or RXTX native libraries are unavailable:
java -Drestaurant.demoMode=true -cp "dist/Restaurant.jar:lib/*" com.paydaran.Restaurant.RestaurantMainDemo mode skips serial initialization and serial writes. For screenshots, it also uses the existing Restaurant_DB/ files through embedded Derby instead of requiring a Derby Network Server. It does not change UI layout, business logic, schema, or stored data.
The modernization is intentionally conservative. It adds documentation, build portability, dependency clarity, repository hygiene, and a narrow demo mode for machines without serial hardware. It does not rewrite the UI, replace Derby, alter schema, migrate to another framework, or change product workflows.
These are good candidates for separate branches because they may affect behavior:
- Export the Derby schema to SQL scripts and add explicit seed data.
- Add automated smoke tests around login and database connectivity.
- Replace raw SQL string concatenation with prepared statements.
- Move credentials to environment-specific configuration.
- Replace RXTX with a maintained serial library after protocol verification.
- Add a Maven or Gradle build while keeping NetBeans/Ant compatibility.
- Remove generated binaries from Git history after preserving required runtime dependencies.
- Java Swing desktop application
- Apache Derby database integration
- Serial communication with external hardware devices
- Role-based access control
- Real-time survey collection and reporting
- JFreeChart data visualization
- Persian (RTL) user interface
- Legacy application preserved and documented for long-term maintainability
Recommended GitHub topics:
java, swing, desktop-application, legacy-modernization, apache-derby, rxtx, serial-communication, jfreechart, restaurant-management, crm, netbeans, ant




