fix track ordering
This commit is contained in:
parent
b04a2afd07
commit
60930e5d5c
@ -2,9 +2,9 @@ import Model, enum from require "lapis.db.model"
|
||||
|
||||
class Tracks extends Model
|
||||
next: =>
|
||||
return Tracks\select("WHERE id < ? ORDER BY id DESC LIMIT 1", @id)[1]
|
||||
previous: =>
|
||||
return Tracks\select("WHERE id > ? ORDER BY id ASC LIMIT 1", @id)[1]
|
||||
previous: =>
|
||||
return Tracks\select("WHERE id < ? ORDER BY id DESC LIMIT 1", @id)[1]
|
||||
|
||||
@statuses: enum {
|
||||
new: 1 -- needs to be checked out / downloaded / bought
|
||||
|
Reference in New Issue
Block a user