Introduces ordering for pitstops
Pitstops are now ordered by ascending odometer value instead of their id
This commit is contained in:
parent
879669b4f7
commit
c42a667ca4
|
@ -73,7 +73,8 @@ class Vehicle(db.Model):
|
|||
owner_id = db.Column(db.Integer, db.ForeignKey('user.id'))
|
||||
name = db.Column(db.String(255))
|
||||
pitstops = db.relationship(
|
||||
'Pitstop'
|
||||
'Pitstop',
|
||||
order_by="asc(Pitstop.odometer)"
|
||||
)
|
||||
services = db.relationship(
|
||||
'Service'
|
||||
|
|
Loading…
Reference in New Issue