我有一组模型 Day1, ... ,Day7 。如何使用整数 1-7 来使用正确的模型?
class Day1 (db.Model): #Monday
courtday = db.ReferenceProperty(CourtDays)
startTime = db.TimeProperty()
endTime = db.TimeProperty()
startTimeLunch = db.TimeProperty()
endTimeLunch = db.TimeProperty()
day = "Monday"
class Day2 (db.Model): #Tuesday
courtday = db.ReferenceProperty(CourtDays)
startTime = db.TimeProperty()
endTime = db.TimeProperty()
startTimeLunch = db.TimeProperty()
endTimeLunch = db.TimeProperty()
day = "Tuesday"