fix(task): add tasks table prefix for sort order (#1003)

fix: qualify task index for mysql order
This commit is contained in:
kolaente
2025-06-24 11:55:00 +02:00
committed by GitHub
parent 048e09ee12
commit 49963d88a6

View File

@@ -128,7 +128,7 @@ func getOrderByDBStatement(opts *taskSearchOptions) (orderby string, err error)
prefix = "task_positions."
}
if param.sortBy == taskPropertyID || param.sortBy == taskPropertyCreated || param.sortBy == taskPropertyUpdated {
if param.sortBy == taskPropertyID || param.sortBy == taskPropertyCreated || param.sortBy == taskPropertyUpdated || param.sortBy == taskPropertyIndex {
prefix = "tasks."
}