diff options
29 files changed, 37 insertions, 3 deletions
@@ -1,6 +1,11 @@ Version 1.0.43 (unreleased) --------------------------- +Improvements: + +* Add "[DUPLICATE]" prefix to duplicated tasks title +* Add sorting by position and start date in task list view + Bug fixes: * Add missing plugin parameter for search box (Gantt and calendar plugin) diff --git a/app/Locale/bs_BA/translations.php b/app/Locale/bs_BA/translations.php index a7e11454..63501007 100644 --- a/app/Locale/bs_BA/translations.php +++ b/app/Locale/bs_BA/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/cs_CZ/translations.php b/app/Locale/cs_CZ/translations.php index 1dce1599..f7a53619 100644 --- a/app/Locale/cs_CZ/translations.php +++ b/app/Locale/cs_CZ/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/da_DK/translations.php b/app/Locale/da_DK/translations.php index 337f32ce..f29c5b57 100644 --- a/app/Locale/da_DK/translations.php +++ b/app/Locale/da_DK/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/de_DE/translations.php b/app/Locale/de_DE/translations.php index a652a2eb..651b6da9 100644 --- a/app/Locale/de_DE/translations.php +++ b/app/Locale/de_DE/translations.php @@ -1331,4 +1331,5 @@ return array( '%d subtasks' => '%d Teilaufgaben', '%d subtask' => '%d Teilaufgabe', 'Only moving task between those columns is permitted for tasks assigned to the current user' => 'Das Bewegen einer Aufgabe zwischen diesen Spalten ist nur für Aufgaben zulässig, die dem aktuellen Benutzer zugewiesen sind', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/el_GR/translations.php b/app/Locale/el_GR/translations.php index f7891418..fcbec9be 100644 --- a/app/Locale/el_GR/translations.php +++ b/app/Locale/el_GR/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/es_ES/translations.php b/app/Locale/es_ES/translations.php index a02eee25..42c95177 100644 --- a/app/Locale/es_ES/translations.php +++ b/app/Locale/es_ES/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/fi_FI/translations.php b/app/Locale/fi_FI/translations.php index 7aa43c21..5234d7bd 100644 --- a/app/Locale/fi_FI/translations.php +++ b/app/Locale/fi_FI/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/fr_FR/translations.php b/app/Locale/fr_FR/translations.php index f6085944..48168271 100644 --- a/app/Locale/fr_FR/translations.php +++ b/app/Locale/fr_FR/translations.php @@ -1331,4 +1331,5 @@ return array( '%d subtasks' => '%d sous-tâches', '%d subtask' => '%d sous-tâche', 'Only moving task between those columns is permitted for tasks assigned to the current user' => 'Seulement le déplacement des tâches entre ces colonnes est autorisé pour l\'utilisateur courant', + '[DUPLICATE]' => '[COPIE]', ); diff --git a/app/Locale/hr_HR/translations.php b/app/Locale/hr_HR/translations.php index 7c98e694..79445ed7 100644 --- a/app/Locale/hr_HR/translations.php +++ b/app/Locale/hr_HR/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/hu_HU/translations.php b/app/Locale/hu_HU/translations.php index 4c02bd9c..fe76f77c 100644 --- a/app/Locale/hu_HU/translations.php +++ b/app/Locale/hu_HU/translations.php @@ -1245,7 +1245,7 @@ return array( 'Click here to join your team' => 'Válassza ezt, ha csatlakozni akar a csapatjához', 'Invite people' => 'Emberek meghívása', 'Emails' => 'E-mailek', - 'Enter one email address by line.' => 'Soronként egy e-mailt adjon meg', + 'Enter one email address by line.' => 'Soronként egy e-mailt adjon meg', 'Add these people to this project' => 'Ezen személyek projekthez adása', 'Add this person to this project' => 'Ezen személy projekthez adása', 'Sign-up' => 'Feliratkozás', @@ -1331,4 +1331,5 @@ return array( '%d subtasks' => '%d alfeladat', '%d subtask' => '%d alfeladat', 'Only moving task between those columns is permitted for tasks assigned to the current user' => 'Az aktuális felhasználóhoz rendelt feladatok csak az engedélyezett oszlopok között mozgathatóak', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/id_ID/translations.php b/app/Locale/id_ID/translations.php index 98a6f461..5f65018c 100644 --- a/app/Locale/id_ID/translations.php +++ b/app/Locale/id_ID/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/it_IT/translations.php b/app/Locale/it_IT/translations.php index b639284a..4fad276e 100644 --- a/app/Locale/it_IT/translations.php +++ b/app/Locale/it_IT/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/ja_JP/translations.php b/app/Locale/ja_JP/translations.php index 25794479..8e34fece 100644 --- a/app/Locale/ja_JP/translations.php +++ b/app/Locale/ja_JP/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/ko_KR/translations.php b/app/Locale/ko_KR/translations.php index 730634e6..ff0cd216 100644 --- a/app/Locale/ko_KR/translations.php +++ b/app/Locale/ko_KR/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/my_MY/translations.php b/app/Locale/my_MY/translations.php index 1079f2e0..492ec2ca 100644 --- a/app/Locale/my_MY/translations.php +++ b/app/Locale/my_MY/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/nb_NO/translations.php b/app/Locale/nb_NO/translations.php index 1109c078..c3ff6d9e 100644 --- a/app/Locale/nb_NO/translations.php +++ b/app/Locale/nb_NO/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/nl_NL/translations.php b/app/Locale/nl_NL/translations.php index d4b33d77..ef3a29a1 100644 --- a/app/Locale/nl_NL/translations.php +++ b/app/Locale/nl_NL/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/pl_PL/translations.php b/app/Locale/pl_PL/translations.php index d64da2dc..f0fe781c 100644 --- a/app/Locale/pl_PL/translations.php +++ b/app/Locale/pl_PL/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/pt_BR/translations.php b/app/Locale/pt_BR/translations.php index a1ef430c..c92a302b 100644 --- a/app/Locale/pt_BR/translations.php +++ b/app/Locale/pt_BR/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/pt_PT/translations.php b/app/Locale/pt_PT/translations.php index de2c330b..356f7c93 100644 --- a/app/Locale/pt_PT/translations.php +++ b/app/Locale/pt_PT/translations.php @@ -1331,4 +1331,5 @@ return array( '%d subtasks' => '%d subtarefas', '%d subtask' => '%d subtarefa', 'Only moving task between those columns is permitted for tasks assigned to the current user' => 'Apenas é permitido mover a tarefa entre essas colunas para tarefas atribuídas ao utilizador atual', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/ru_RU/translations.php b/app/Locale/ru_RU/translations.php index b0c0392a..e14b19fe 100644 --- a/app/Locale/ru_RU/translations.php +++ b/app/Locale/ru_RU/translations.php @@ -1331,4 +1331,5 @@ return array( '%d subtasks' => '%d подзадач', '%d subtask' => '%d подзадача', 'Only moving task between those columns is permitted for tasks assigned to the current user' => 'Текущий пользователь может перемещать назначенные ему задачи только между этими колонками', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/sr_Latn_RS/translations.php b/app/Locale/sr_Latn_RS/translations.php index 2d57f7e5..61ebb870 100644 --- a/app/Locale/sr_Latn_RS/translations.php +++ b/app/Locale/sr_Latn_RS/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/sv_SE/translations.php b/app/Locale/sv_SE/translations.php index a2bbc941..6437e46e 100644 --- a/app/Locale/sv_SE/translations.php +++ b/app/Locale/sv_SE/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/th_TH/translations.php b/app/Locale/th_TH/translations.php index ff0cd814..2863a138 100644 --- a/app/Locale/th_TH/translations.php +++ b/app/Locale/th_TH/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/tr_TR/translations.php b/app/Locale/tr_TR/translations.php index c58eaf05..2a3dac7f 100644 --- a/app/Locale/tr_TR/translations.php +++ b/app/Locale/tr_TR/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Locale/zh_CN/translations.php b/app/Locale/zh_CN/translations.php index 7229e7f9..74cea8cb 100644 --- a/app/Locale/zh_CN/translations.php +++ b/app/Locale/zh_CN/translations.php @@ -1331,4 +1331,5 @@ return array( // '%d subtasks' => '', // '%d subtask' => '', // 'Only moving task between those columns is permitted for tasks assigned to the current user' => '', + // '[DUPLICATE]' => '', ); diff --git a/app/Model/TaskDuplicationModel.php b/app/Model/TaskDuplicationModel.php index c07ebca0..eb59f555 100644 --- a/app/Model/TaskDuplicationModel.php +++ b/app/Model/TaskDuplicationModel.php @@ -47,7 +47,10 @@ class TaskDuplicationModel extends Base */ public function duplicate($task_id) { - $new_task_id = $this->save($task_id, $this->copyFields($task_id)); + $values = $this->copyFields($task_id); + $values['title'] = t('[DUPLICATE]').' '.$values['title']; + + $new_task_id = $this->save($task_id, $values); if ($new_task_id !== false) { $this->tagDuplicationModel->duplicateTaskTags($task_id, $new_task_id); diff --git a/tests/units/Model/TaskDuplicationModelTest.php b/tests/units/Model/TaskDuplicationModelTest.php index 1fff110c..e4121ff9 100644 --- a/tests/units/Model/TaskDuplicationModelTest.php +++ b/tests/units/Model/TaskDuplicationModelTest.php @@ -93,7 +93,7 @@ class TaskDuplicationModelTest extends Base $this->assertEquals(1, $task['swimlane_id']); $this->assertEquals(3, $task['column_id']); $this->assertEquals(2, $task['position']); - $this->assertEquals('test', $task['title']); + $this->assertEquals('[DUPLICATE] test', $task['title']); $this->assertEquals(0, $task['time_spent']); } |