From: Guillaume Pellerin Date: Thu, 19 Dec 2013 17:20:20 +0000 (+0100) Subject: more print X-Git-Tag: 2.8.1-pro~407 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=e8d82299f40c695826fa162af7a78e6859177534;p=teleforma.git more print --- diff --git a/teleforma/management/commands/teleforma-copy-seminars.py b/teleforma/management/commands/teleforma-copy-seminars.py index ed500418..155286d6 100644 --- a/teleforma/management/commands/teleforma-copy-seminars.py +++ b/teleforma/management/commands/teleforma-copy-seminars.py @@ -37,11 +37,12 @@ class Command(BaseCommand): print ('dates updated', clone) for field in seminar._meta.many_to_many: + print type(field.rel.to) if type(field.rel.to) == Document or type(field.rel.to) == Media: source = getattr(seminar, field.attname) destination = getattr(clone, field.attname) print source, destination - + for item in source.all(): print item item.period = from_period