diff --git a/README.md b/README.md new file mode 100644 index 0000000..533bed9 --- /dev/null +++ b/README.md @@ -0,0 +1,85 @@ +# 🧭 PlanMate - Task Management CLI App + +**PlanMate** is a command-line task management application built in **Kotlin**. +It helps teams manage their projects, tasks, and workflows efficiently using a role-based access system and an audit trail. + +The app was built using **Test-Driven Development (TDD)** and follows **SOLID** principles, ensuring high-quality, maintainable code. + +--- + +## Key Features + +### User Roles +- **Admin** + - Can manage users, projects, and workflow states. + - Can view audit logs. +- **Mate** + - Can create, edit, delete, and view tasks within assigned projects. + +### Authentication +- Users log in with a username and password. +- Passwords are stored securely using **MD5 hashing**. + +### Projects & Tasks +- Projects can be created and customized by Admins. +- Tasks belong to projects and can be managed by both Admins and Mates. +- Task states (TODO, In Progress, Done) are fully customizable by Admins. + +### Task Display (Swimlanes UI) +- Tasks are grouped and displayed by state in a clear swimlanes format in the terminal. + +### Audit Logging +- Every change to a project or task is logged with: + - The user who made the change. + - What was changed. + - When the change happened. +- Users can view logs filtered by **project ID** or **task ID**. + +--- + +## Architecture + +- **Layered Architecture**: + - `UI Layer`: Command-line interface. + - `Domain Layer`: Core business logic (clean and testable). + - `Data Layer`: Persistence (originally CSV, now MongoDB). + +- **Uni-directional Dependencies**: + - Data → Domain + - UI → Domain + +> Domain layer is independent from data and UI for better testability and maintainability. + +- **Dependency Injection**: + - Uses **Koin** for clean dependency management. + +--- + +## MongoDB Migration Update + +We are migrating the data source from local CSV files to **MongoDB** for cloud-based shared access. +--- + +## Testing + +- Developed using **Test-Driven Development (TDD)**. +- Maintains **80%+ test coverage** across: + - Business rules + - Data repositories + - UI interactions + +--- +## 🎥 Demo Video + +[Click here to watch the demo](https://drive.google.com/file/d/1lcma_BLuRiCR-yAugwBVV9GdSYL8YQoW/view?usp=drive_link) +--- +## ▶️ How to Run + +> Make sure you have Kotlin and MongoDB installed. + +```bash +# Compile the project +./gradlew build + +# Run the CLI app +./gradlew run diff --git a/csv_files/audit.csv b/csv_files/audit.csv index 427f82e..232cb91 100644 --- a/csv_files/audit.csv +++ b/csv_files/audit.csv @@ -13,3 +13,12 @@ "AUDITDDDD_14350","1747065314357","user1234","UPDATE","","TASK","refactorcc_32751" "AUDITDDDD_33128","1747065333128","user1234","DELETE","","TASK","testtaskanddbaftermergedddddd_38667" "AUDITDDDD_468","1747065400468","user1234","UPDATE","","TASK","tasctitlett_91718" +"AUDITDDD_80597","1747419580597","admin_00001","CREATE","","PROJECT","clothestt_80584" +"AUDITDDDD_77118","1747419777118","admin_00001","CREATE","","PROJECT","Taskmkkkk_77109" +"AUDITDD_5241","1747419805241","admin_00001","DELETE","","PROJECT","taskmanageraa_50797" +"AUDITDDDD_10380","1747420210387","admin_00001","UPDATE","","TASK","titlett_29143" +"AUDITD_11426","1747420311426","admin_00001","CREATE","","PROJECT","ttrhrrr_11425" +"AUDITDDDD_50097","1747421150106","admin_00001","UPDATE","","TASK","titlett_29143" +"AUDITDDD_83405","1747421183405","admin_00001","CREATE","","PROJECT","Clothesappeeeee_83404" +"AUDITDDD_28246","1747421328252","admin_00001","UPDATE","","TASK","titlett_29143" +"AUDITDDD_58834","1747421358834","admin_00001","CREATE","","PROJECT","Clothessuggestionappgggg_58833" diff --git a/csv_files/project.csv b/csv_files/project.csv index 77e5f99..39f6aa8 100644 --- a/csv_files/project.csv +++ b/csv_files/project.csv @@ -1,4 +1,8 @@ "Project Id","Project Name","Description","States","Tasks" "taskmangermmmm_97132","task manager","the ultimate project","[]","[]" -"taskmanageraa_50797","task manager","","[]","[]" "newprojctrrr_26090","new projct","","[]","[]" +"clothestt_80584"," clothes","","[]","[]" +"Taskmkkkk_77109","Task m","gjbjff","[]","[]" +"ttrhrrr_11425","ttrhr","","[]","[]" +"Clothesappeeeee_83404","Clothes app","","[]","[]" +"Clothessuggestionappgggg_58833","Clothes suggestion app","","[]","[]" diff --git a/csv_files/state.csv b/csv_files/state.csv index 77a9b62..cb01fde 100644 --- a/csv_files/state.csv +++ b/csv_files/state.csv @@ -1,4 +1,2 @@ "State Id","Name","Project Id" "tododdd_32001","todo","newprojctrrr_26090" -"doingi_58809","doing","newprojctrrr_26090" -"donennn_60752","done","newprojctrrr_26090" diff --git a/csv_files/task.csv b/csv_files/task.csv index c9789ca..6dcce37 100644 --- a/csv_files/task.csv +++ b/csv_files/task.csv @@ -5,3 +5,6 @@ "tasctitlett_91718","taskmangermmmm_97132","tasc title","desc","taskmangermmmm_97132","ahmadmmmm_70365","matetttt_16791" "refactorcc_32751","newprojctrrr_26090","refactor","","tododdd_32001","ahmadmmmm_70365","user1234" "tasctitlett_91718","taskmangermmmm_97132","tasc title","desc","taskmangermmmm_97132","matetttt_16791","matetttt_16791" +"titlett_29143","P1","titletgtrht","riothr","S1","ahmadmmmm_70365","user1234" +"titlett_29143","P1","title is add readme file","description whole app","S1","ahmadmmmm_70365","user1234" +"titlett_29143","P1","title is readme file","description whole app","S1","ahmadmmmm_70365","user1234"