]> git.parisson.com Git - teleforma.git/commitdiff
replace \n to spaces
authorGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Mon, 13 Nov 2017 14:43:50 +0000 (15:43 +0100)
committerGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Mon, 13 Nov 2017 14:43:50 +0000 (15:43 +0100)
teleforma/migrations/0089_auto__add_field_period_department__del_field_course_exam_scripts__add_.py

index 38c6e9f4ec16d87d9eb81d781f05b9708b1288d0..ff6988b592eedbea586fd3b9ad4472c1a0fbee20 100644 (file)
@@ -8,6 +8,10 @@ from django.db import models
 class Migration(SchemaMigration):
 
     def forwards(self, orm):
+        for profile in orm.Profile.objects.all():
+            profile.address.replace('\n', ' ')
+            profile.save()
+
         # Adding field 'Period.department'
         db.add_column('teleforma_period', 'department',
                       self.gf('telemeta.models.core.ForeignKey')(default=None, related_name='period', null=True, blank=True, to=orm['teleforma.Department']),
@@ -597,4 +601,4 @@ class Migration(SchemaMigration):
         }
     }
 
-    complete_apps = ['teleforma']
\ No newline at end of file
+    complete_apps = ['teleforma']