Remove task collection date hack
This commit is contained in:
parent
a65e2e15b5
commit
9fc8ffe10b
|
@ -119,19 +119,6 @@ func (tf *TaskCollection) ReadAll(a web.Auth, search string, page int, perPage i
|
|||
param.orderBy = getSortOrderFromString(tf.OrderBy[i])
|
||||
}
|
||||
|
||||
// Special case for pseudo date fields
|
||||
// FIXME: This is really dirty, to fix this properly the db fields should be renamed
|
||||
switch param.sortBy {
|
||||
case "done_at":
|
||||
param.sortBy = taskPropertyDoneAt
|
||||
case "due_date":
|
||||
param.sortBy = taskPropertyDueDate
|
||||
case "start_date":
|
||||
param.sortBy = taskPropertyStartDate
|
||||
case "end_date":
|
||||
param.sortBy = taskPropertyEndDate
|
||||
}
|
||||
|
||||
// Param validation
|
||||
if err := param.validate(); err != nil {
|
||||
return nil, 0, 0, err
|
||||
|
|
Loading…
Reference in New Issue