dont show project in folder new

This commit is contained in:
Erik Winter 2021-09-23 06:50:54 +02:00
parent 33c473eadf
commit 9557525b1e
1 changed files with 5 additions and 2 deletions

View File

@ -26,11 +26,14 @@ func FormatTaskTable(tasks []*task.LocalTask) string {
var output string var output string
for _, t := range tasks { for _, t := range tasks {
var updateStr string var projectStr, updateStr string
if t.LocalStatus == task.STATUS_UPDATED { if t.LocalStatus == task.STATUS_UPDATED {
updateStr = " *" updateStr = " *"
} }
output += fmt.Sprintf("%d%s\t%s\t%s (%s)\n", t.LocalId, updateStr, t.Due.String(), t.Action, t.Project) if t.Folder != task.FOLDER_NEW {
projectStr = fmt.Sprintf(" (%s)", t.Project)
}
output += fmt.Sprintf("%d%s\t%s\t%s%s\n", t.LocalId, updateStr, t.Due.String(), t.Action, projectStr)
} }
return fmt.Sprintf("%s\n", output) return fmt.Sprintf("%s\n", output)