target unicode representation and target selection
This commit is contained in:
@@ -953,7 +953,7 @@ class TrainingTarget(models.Model):
|
||||
ownerfirst = ''
|
||||
ownerlast = ''
|
||||
|
||||
stri = u'{id} {n} {d} {ownerfirst} {ownerlast}'.format(
|
||||
stri = u'#{id}: {n} {d} {ownerfirst} {ownerlast}'.format(
|
||||
ownerfirst = ownerfirst,
|
||||
ownerlast = ownerlast,
|
||||
d = date.strftime('%Y-%m-%d'),
|
||||
|
||||
@@ -16188,7 +16188,10 @@ def rower_create_trainingplan(request,userid=0):
|
||||
p.rowers.add(therower)
|
||||
|
||||
|
||||
targets = TrainingTarget.objects.filter(rowers=therower).order_by("date")
|
||||
targets = TrainingTarget.objects.filter(
|
||||
rowers=therower,
|
||||
date__gte=datetime.date.today(),
|
||||
).order_by("date")
|
||||
targetform = TrainingTargetForm()
|
||||
|
||||
plans = TrainingPlan.objects.filter(rowers=therower).order_by("-startdate")
|
||||
|
||||
Reference in New Issue
Block a user