]> git.parisson.com Git - mezzo.git/commitdiff
Add title_en
authorGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Tue, 11 Oct 2016 21:43:46 +0000 (23:43 +0200)
committerGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Tue, 11 Oct 2016 21:43:46 +0000 (23:43 +0200)
app/organization/agenda/management/commands/organization-sync-eve-events.py

index 66bb83062b601235bf385b3c13ecfca88d42edd7..a16742130f4960f5c94d735e72b5fd22f78e4557 100644 (file)
@@ -49,6 +49,7 @@ class Command(BaseCommand):
             first = True
             eve_locations = []
             event_trans = eve_models.EventTranslation.objects.filter(id=eve_event, lang='fr')[0]
+            event_trans_en = eve_models.EventTranslation.objects.filter(id=eve_event, lang='en')[0]
             manifestations = eve_event.manifestations.all().order_by('happens_at')
             events = ma_models.Event.objects.filter(external_id=eve_event.id)
 
@@ -60,6 +61,7 @@ class Command(BaseCommand):
             for manifestation in manifestations:
                 if first:
                     event.title = event_trans.name
+                    event.title_en = event_trans_en.name
                     event.user = self.default_user
                     locations = ma_models.EventLocation.objects.filter(title=manifestation.location.name)
                     if locations: