From: Guillaume Pellerin Date: Thu, 11 Jul 2013 21:29:30 +0000 (+0200) Subject: add push/pull commands for confs anf profs X-Git-Tag: 1.3-TC~39 X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=50c34596e30fe51175ec172b6e3a40e6e7284c59;p=teleforma.git add push/pull commands for confs anf profs --- diff --git a/teleforma/management/commands/teleforma-pull-conferences.py b/teleforma/management/commands/teleforma-pull-conferences.py new file mode 100644 index 00000000..8762da53 --- /dev/null +++ b/teleforma/management/commands/teleforma-pull-conferences.py @@ -0,0 +1,20 @@ +from optparse import make_option +from django.conf import settings +from django.core.management.base import BaseCommand, CommandError +from django.contrib.auth.models import User +from django.template.defaultfilters import slugify +from telemeta.models import * +from telemeta.util.unaccent import unaccent +from teleforma.models import * +from teleforma.views import * +import logging +import codecs + +class Command(BaseCommand): + help = "pull teleforma conferences from a remote host" + args = "host" + admin_email = 'webmaster@parisson.com' + + def handle(self, *args, **options): + view = ConferenceListView() + view.pull() diff --git a/teleforma/management/commands/teleforma-pull-professors.py b/teleforma/management/commands/teleforma-pull-professors.py new file mode 100644 index 00000000..b7ad0d63 --- /dev/null +++ b/teleforma/management/commands/teleforma-pull-professors.py @@ -0,0 +1,19 @@ +from optparse import make_option +from django.conf import settings +from django.core.management.base import BaseCommand, CommandError +from django.contrib.auth.models import User +from django.template.defaultfilters import slugify +from telemeta.models import * +from telemeta.util.unaccent import unaccent +from teleforma.models import * +from teleforma.views import * +import logging +import codecs + +class Command(BaseCommand): + help = "pull teleforma conferences from a telecaster master server" + admin_email = 'webmaster@parisson.com' + + def handle(self, *args, **options): + view = ProfessorListView() + view.pull() diff --git a/teleforma/management/commands/teleforma-push-conferences.py b/teleforma/management/commands/teleforma-push-conferences.py new file mode 100644 index 00000000..016af79a --- /dev/null +++ b/teleforma/management/commands/teleforma-push-conferences.py @@ -0,0 +1,20 @@ +from optparse import make_option +from django.conf import settings +from django.core.management.base import BaseCommand, CommandError +from django.contrib.auth.models import User +from django.template.defaultfilters import slugify +from telemeta.models import * +from telemeta.util.unaccent import unaccent +from teleforma.models import * +from teleforma.views import * +import logging +import codecs + +class Command(BaseCommand): + help = "pull teleforma conferences from a remote host" + args = "host" + admin_email = 'webmaster@parisson.com' + + def handle(self, *args, **options): + view = ConferenceListView() + view.push()