# Subtasks 🔖

{% hint style="info" %}
<http://localhost:8080/#/subtasks>
{% endhint %}

## Subtask Overview Table

This view provides the general information about the Subtasks, such as the Subtask Name, Number of Tasks, Assigned Analyst, Progress of the subtask, number of Findings, Due Date of each Subtask. The Subtask Overview Table page is composed of two files, `Subtasks.vue` and `SubtaskOverviewTable.vue.`

| Title | Task | Analyst | Progress    | No. of Findings | Due Date (DD-MM-YYYY) |
| ----- | ---- | ------- | ----------- | --------------- | --------------------- |
| foo   | 2    | A.O     | Not Started | 2               | 11-11-2020            |
| bar   | 1    | A.O     | In Progress | 1               | 12-01-2020            |

### Methods:

| Name                 | Description                                                                              |
| -------------------- | ---------------------------------------------------------------------------------------- |
| getSubtaskData()     | This is used to grab substask information from the Backend                               |
| trashModal()         | This is used for the archive button for each Subtask                                     |
| removeRow()          | This is used to clear the row of an archived Subtask from the table                      |
| trashConfirm()       | This is used to confirm if the Subtask has been removed                                  |
| trashCancel()        | This is used to cancel a Subtask from being removed                                      |
| logAction()          | This is used to log actions that happen with a Subtask                                   |
| displayError(e)      | This is used to display any error message that may occur                                 |
| removeItemAction()   | This is used to check if we are on the Subtasks page or Archive page                     |
| iconType()           | This is used to display an icon depending if we are on the Subtasks page or Archive page |
| setRemoveItemColor() | This is used to display a color depending if we are on the Subtasks page or Archive page |

### Subtask.vue

#### Subtask Methods:

| Name             | Description                                                      |
| ---------------- | ---------------------------------------------------------------- |
| subtaskHelp()    | This displays summery about Subtasks in the info pop up          |
| onSearchToggle() | This is used to search for the subtasked typed in the search bar |
