Use list_display instead.
This commit is contained in:
parent
c83ebfed08
commit
d6321cf5e8
|
@ -5,4 +5,5 @@ from .models import Ride
|
|||
|
||||
@admin.register(Ride)
|
||||
class RideModelAdmin(admin.ModelAdmin):
|
||||
list_display = ('location', 'when', 'seats', 'user')
|
||||
list_filter = ('camp', 'user')
|
||||
|
|
|
@ -20,11 +20,3 @@ class Ride(UUIDModel, CampRelatedModel):
|
|||
'camp_slug': self.camp.slug
|
||||
}
|
||||
)
|
||||
|
||||
def __str__(self):
|
||||
return "{} seats from {} at {} by {}".format(
|
||||
self.seats,
|
||||
self.location,
|
||||
self.when,
|
||||
self.user
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue