-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactored EditTaskDetails to Edit Task
- Loading branch information
1 parent
1966692
commit 64bf569
Showing
7 changed files
with
78 additions
and
114 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
...ication_business_rules/use_cases/project_viewing_and_modification_use_cases/EditTask.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package b_application_business_rules.use_cases.project_viewing_and_modification_use_cases; | ||
|
||
import a_enterprise_business_rules.entities.Project; | ||
|
||
import b_application_business_rules.entity_models.TaskModel; | ||
|
||
import java.util.UUID; | ||
|
||
/** | ||
* A use case class for editing task details (name and description) | ||
*/ | ||
public class EditTask { | ||
|
||
private final Project currentProject; | ||
|
||
public EditTask(Project currentProject) { | ||
this.currentProject = currentProject; | ||
} | ||
|
||
/** | ||
* Edits the task's details | ||
*/ | ||
public void editTask(UUID columnID, TaskModel taskModel) { | ||
// This feature initializes calls other use cases to avoid duplicate code | ||
DeleteTask deleteTaskUseCase = new DeleteTask(currentProject); | ||
deleteTaskUseCase.deleteTask(columnID, taskModel); | ||
AddTask addTaskUseCase = new AddTask(currentProject); | ||
addTaskUseCase.addTask(columnID, taskModel); | ||
|
||
} | ||
|
||
|
||
|
||
} |
83 changes: 0 additions & 83 deletions
83
..._business_rules/use_cases/project_viewing_and_modification_use_cases/EditTaskDetails.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters