alab_management.task_view.completed_task_view module

alab_management.task_view.completed_task_view module#

This module contains the CompletedTaskView class, which is used to interact with the completed task database.

class CompletedTaskView[source]#

Bases: object

This class is used to interact with the completed task database.

exists(task_id)[source]#

Check if a task exists in the database.

Parameters:

task_id (Union[ObjectId, str]) – id of the task within task collection. If a string is passed, it will be converted to ObjectId

Return type:

bool

Returns:

True if task exists in the database

get_task(task_id)[source]#

Get a task from the database.

save_task(task_id)[source]#

Saves a task dictionary to the completed database. This should be copying a task from the working database to the completed database.