added random activation of some campaigns
parent
e41e1e7b6d
commit
ce0d20a028
|
@ -27,6 +27,11 @@ class Command(BaseCommand):
|
|||
campaign.deadline = random_date(now + timedelta(days=5),
|
||||
now + timedelta(days=180))
|
||||
|
||||
# randomly activate some of the campaigns
|
||||
coinflip = D(randint(0,10))
|
||||
if coinflip > 5:
|
||||
campaign.activated = now
|
||||
|
||||
campaign.save()
|
||||
print "created %s" % campaign
|
||||
|
||||
|
|
Loading…
Reference in New Issue