TDB2
- Updated ID:UUID mapping on ::add, which is the first part of the fix for TW-1389.
This commit is contained in:
13
src/TDB2.cpp
13
src/TDB2.cpp
@@ -140,11 +140,18 @@ void TF2::add_task (const Task& task)
|
|||||||
_tasks.push_back (hookTask); // For subsequent queries
|
_tasks.push_back (hookTask); // For subsequent queries
|
||||||
_added_tasks.push_back (hookTask); // For commit/synch
|
_added_tasks.push_back (hookTask); // For commit/synch
|
||||||
|
|
||||||
/* TODO handle 'add' and 'log'?
|
int id = task.id;
|
||||||
int id = context.tdb2.next_id ();
|
Task::status status = task.getStatus ();
|
||||||
|
if (id == 0 &&
|
||||||
|
(status == Task::pending ||
|
||||||
|
status == Task::recurring ||
|
||||||
|
status == Task::waiting))
|
||||||
|
{
|
||||||
|
id = context.tdb2.next_id ();
|
||||||
|
}
|
||||||
|
|
||||||
_I2U[id] = task.get ("uuid");
|
_I2U[id] = task.get ("uuid");
|
||||||
_U2I[task.get ("uuid")] = id;
|
_U2I[task.get ("uuid")] = id;
|
||||||
*/
|
|
||||||
|
|
||||||
_dirty = true;
|
_dirty = true;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user