TW-1704: Task: Use Task::identifier to reference the task
To achieve consistent output, use a helper method to generate a proper handle - ID for tasks with non-zero ID, UUID otherwise.
This commit is contained in:
committed by
Paul Beckingham
parent
1236abc7d5
commit
2d25cf6f59
@@ -88,7 +88,7 @@ int CmdDuplicate::execute (std::string&)
|
||||
dup.remove ("recur");
|
||||
dup.remove ("until");
|
||||
dup.remove ("imask");
|
||||
std::cout << format (STRING_CMD_DUPLICATE_NON_REC, task.id)
|
||||
std::cout << format (STRING_CMD_DUPLICATE_NON_REC, task.identifier ())
|
||||
<< "\n";
|
||||
}
|
||||
|
||||
@@ -96,7 +96,7 @@ int CmdDuplicate::execute (std::string&)
|
||||
else if (dup.getStatus () == Task::recurring)
|
||||
{
|
||||
dup.remove ("mask");
|
||||
std::cout << format (STRING_CMD_DUPLICATE_REC, task.id)
|
||||
std::cout << format (STRING_CMD_DUPLICATE_REC, task.identifier ())
|
||||
<< "\n";
|
||||
}
|
||||
|
||||
@@ -106,7 +106,7 @@ int CmdDuplicate::execute (std::string&)
|
||||
dup.modify (Task::modAnnotate);
|
||||
|
||||
if (permission (format (STRING_CMD_DUPLICATE_CONFIRM,
|
||||
task.id,
|
||||
task.identifier (true),
|
||||
task.get ("description")),
|
||||
filtered.size ()))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user