Guest User

Untitled

a guest
Sep 23rd, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.33 KB | None | 0 0
  1. from gamecode.models import Fixture
  2. from gamecode.models import Prediction
  3. from gamecode.models import PredictionOption
  4.  
  5. fixs = Fixture.objects.all().order_by('kickoff_time', 'pk')
  6. count = 1
  7. for f in fixs:
  8.     Prediction.objects.create(code=count, description='Result', prediction_kind='result', fixture=f)
  9.     count = count + 1
Add Comment
Please, Sign In to add comment