16
21
serves_hot_dogs = models.BooleanField()
17
22
serves_pizza = models.BooleanField()
22
28
class ItalianRestaurant(Restaurant):
23
29
serves_gnocchi = models.BooleanField()
29
36
# An explicit link to the parent (we can control the attribute name).
30
37
parent = models.OneToOneField(Place, primary_key=True, parent_link=True)
31
38
capacity = models.IntegerField()
36
43
class ParkingLot2(Place):
37
44
# In lieu of any other connector, an existing OneToOneField will be