]> git.parisson.com Git - teleforma.git/commitdiff
add video source (telecaster) selection page by rooms
authorGuillaume Pellerin <yomguy@parisson.com>
Thu, 30 Jan 2014 13:45:22 +0000 (14:45 +0100)
committerGuillaume Pellerin <yomguy@parisson.com>
Thu, 30 Jan 2014 13:45:22 +0000 (14:45 +0100)
15 files changed:
example/settings.py
example/urls.py
teleforma/models/sources.py [deleted file]
teleforma/sources/__init__.py [new file with mode: 0644]
teleforma/sources/admin.py [new file with mode: 0644]
teleforma/sources/migrations/0001_initial.py [new file with mode: 0644]
teleforma/sources/migrations/0002_auto__add_field_monitor_record_path.py [new file with mode: 0644]
teleforma/sources/migrations/__init__.py [new file with mode: 0644]
teleforma/sources/models.py [new file with mode: 0644]
teleforma/sources/tests.py [new file with mode: 0644]
teleforma/sources/urls.py [new file with mode: 0644]
teleforma/sources/views.py [new file with mode: 0644]
teleforma/templates/teleforma/source_detail.html [new file with mode: 0644]
teleforma/templates/telemeta/base.html
teleforma/views/core.py

index 80fdda5df7fdc6c16713d69b70f9d27db4b24976..d8fa64c58bcd5618843e0c65ad4130251cc594e2 100644 (file)
@@ -19,10 +19,10 @@ MANAGERS = ADMINS
 
 DATABASES = {
     'default': {
-        'ENGINE': 'django.db.backends.mysql', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
-        'NAME': 'teleforma',                      # Or path to database file if using sqlite3.
-        'USER': 'teleforma',                      # Not used with sqlite3.
-        'PASSWORD': 'HMYsrZLEtYeBrvER',                  # Not used with sqlite3.
+        'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
+        'NAME': 'teleforma.sql',                      # Or path to database file if using sqlite3.
+        'USER': '',                      # Not used with sqlite3.
+        'PASSWORD': '',                  # Not used with sqlite3.
         'HOST': '',                      # Set to empty string for localhost. Not used with sqlite3.
         'PORT': '',                      # Set to empty string for default. Not used with sqlite3.
     }
@@ -146,7 +146,8 @@ INSTALLED_APPS = (
     'jqchat',
 #    'follow',
      'googletools',
-     'telecaster',
+#     'telecaster',
+     'teleforma.sources',
 )
 
 TEMPLATE_CONTEXT_PROCESSORS = (
index 8bacff02afee8de78cbbb8c62f6efe946c062c13..7173c4e1d253a0c2bd2eea07888845fc2cb5da7f 100644 (file)
@@ -20,7 +20,7 @@ urlpatterns = patterns('',
 
     # TeleForma
     (r'^', include('teleforma.urls')),
-    (r'^telecaster/', include('telecaster.urls')),
+    (r'^', include('teleforma.sources.urls')),
 
     # Languages
     (r'^i18n/', include('django.conf.urls.i18n')),
diff --git a/teleforma/models/sources.py b/teleforma/models/sources.py
deleted file mode 100644 (file)
index 409b6af..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-
-from teleforma.models.core import *
-
-
-class Monitor(Model):
-    "Streaming source monitor"
-    
-    mime_types = [('audio/ogg', 'audio/ogg'), ('audio/mp3', 'audio/mp3'), 
-            ('video/webm', 'video/webm'), ('video/mp4', 'video/mp4')]
-    
-    port             = IntegerField(_('port'))
-    mount_point      = CharField(_('public_id'), max_length=255)
-    mime_type        = CharField(_('type'), choices=mime_types, max_length=255)
-
-    @property
-    def slug(self):
-        return ':' + str(self.port) + '/' + self.mount_point
-
-    class Meta:
-        db_table = app_label + '_' + 'monitor'
-
-    def __unicode__(self):
-        return self.slug + '(' + self.type + ')'
-
-
-class Source(Model):
-    "Streaming source"
-
-    public_id         = CharField(_('public_id'), max_length=255)
-    ip                = GenericIPAddressField(_('IP'))
-    room              = ForeignKey(Room, related_name='source', verbose_name=_('room'), 
-                                    blank=True, null=True, on_delete=models.SET_NULL)
-    monitors          = ManyToManyField(Monitor, related_name="source", 
-                                    verbose_name=_('monitors'), blank=True, null=True)    
-    class Meta:
-        db_table = app_label + '_' + 'source'
-        ordering = ['public_id']
-
-    def __unicode__(self):
-        return '-'.join([self.public_id, self.room, self.ip])
-
diff --git a/teleforma/sources/__init__.py b/teleforma/sources/__init__.py
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/teleforma/sources/admin.py b/teleforma/sources/admin.py
new file mode 100644 (file)
index 0000000..7c88691
--- /dev/null
@@ -0,0 +1,15 @@
+# -*- coding: utf-8 -*-
+
+from teleforma.sources.models import *
+from django.contrib import admin
+
+
+class SourceAdmin(admin.ModelAdmin):
+    model = Source
+
+class MonitorAdmin(admin.ModelAdmin):
+    model = Monitor
+
+
+admin.site.register(Source)
+admin.site.register(Monitor)
diff --git a/teleforma/sources/migrations/0001_initial.py b/teleforma/sources/migrations/0001_initial.py
new file mode 100644 (file)
index 0000000..cac9e93
--- /dev/null
@@ -0,0 +1,80 @@
+# -*- coding: utf-8 -*-
+import datetime
+from south.db import db
+from south.v2 import SchemaMigration
+from django.db import models
+
+
+class Migration(SchemaMigration):
+
+    def forwards(self, orm):
+        # Adding model 'Monitor'
+        db.create_table('teleforma_monitor', (
+            ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
+            ('port', self.gf('telemeta.models.core.IntegerField')(default=0, blank=True)),
+            ('mount_point', self.gf('telemeta.models.core.CharField')(default='', max_length=255, blank=True)),
+            ('mime_type', self.gf('telemeta.models.core.CharField')(default='', max_length=255, blank=True)),
+        ))
+        db.send_create_signal('sources', ['Monitor'])
+
+        # Adding model 'Source'
+        db.create_table('teleforma_source', (
+            ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
+            ('public_id', self.gf('telemeta.models.core.CharField')(default='', max_length=255, blank=True)),
+            ('ip', self.gf('django.db.models.fields.GenericIPAddressField')(max_length=39)),
+            ('room', self.gf('telemeta.models.core.ForeignKey')(related_name='source', on_delete=models.SET_NULL, default=None, to=orm['teleforma.Room'], blank=True, null=True)),
+        ))
+        db.send_create_signal('sources', ['Source'])
+
+        # Adding M2M table for field monitors on 'Source'
+        db.create_table('teleforma_source_monitors', (
+            ('id', models.AutoField(verbose_name='ID', primary_key=True, auto_created=True)),
+            ('source', models.ForeignKey(orm['sources.source'], null=False)),
+            ('monitor', models.ForeignKey(orm['sources.monitor'], null=False))
+        ))
+        db.create_unique('teleforma_source_monitors', ['source_id', 'monitor_id'])
+
+
+    def backwards(self, orm):
+        # Deleting model 'Monitor'
+        db.delete_table('teleforma_monitor')
+
+        # Deleting model 'Source'
+        db.delete_table('teleforma_source')
+
+        # Removing M2M table for field monitors on 'Source'
+        db.delete_table('teleforma_source_monitors')
+
+
+    models = {
+        'sources.monitor': {
+            'Meta': {'object_name': 'Monitor', 'db_table': "'teleforma_monitor'"},
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'mime_type': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'mount_point': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'port': ('telemeta.models.core.IntegerField', [], {'default': '0', 'blank': 'True'})
+        },
+        'sources.source': {
+            'Meta': {'ordering': "['public_id']", 'object_name': 'Source', 'db_table': "'teleforma_source'"},
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'ip': ('django.db.models.fields.GenericIPAddressField', [], {'max_length': '39'}),
+            'monitors': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'source'", 'null': 'True', 'symmetrical': 'False', 'to': "orm['sources.Monitor']"}),
+            'public_id': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'room': ('telemeta.models.core.ForeignKey', [], {'related_name': "'source'", 'on_delete': 'models.SET_NULL', 'default': 'None', 'to': "orm['teleforma.Room']", 'blank': 'True', 'null': 'True'})
+        },
+        'teleforma.organization': {
+            'Meta': {'object_name': 'Organization'},
+            'description': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'name': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'})
+        },
+        'teleforma.room': {
+            'Meta': {'object_name': 'Room'},
+            'description': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'name': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'organization': ('telemeta.models.core.ForeignKey', [], {'related_name': "'room'", 'to': "orm['teleforma.Organization']"})
+        }
+    }
+
+    complete_apps = ['sources']
\ No newline at end of file
diff --git a/teleforma/sources/migrations/0002_auto__add_field_monitor_record_path.py b/teleforma/sources/migrations/0002_auto__add_field_monitor_record_path.py
new file mode 100644 (file)
index 0000000..5a02b4f
--- /dev/null
@@ -0,0 +1,54 @@
+# -*- coding: utf-8 -*-
+import datetime
+from south.db import db
+from south.v2 import SchemaMigration
+from django.db import models
+
+
+class Migration(SchemaMigration):
+
+    def forwards(self, orm):
+        # Adding field 'Monitor.record_path'
+        db.add_column('teleforma_monitor', 'record_path',
+                      self.gf('telemeta.models.core.CharField')(default='', max_length=255, blank=True),
+                      keep_default=False)
+
+
+    def backwards(self, orm):
+        # Deleting field 'Monitor.record_path'
+        db.delete_column('teleforma_monitor', 'record_path')
+
+
+    models = {
+        'sources.monitor': {
+            'Meta': {'object_name': 'Monitor', 'db_table': "'teleforma_monitor'"},
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'mime_type': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'mount_point': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'port': ('telemeta.models.core.IntegerField', [], {'default': '0', 'blank': 'True'}),
+            'record_path': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'})
+        },
+        'sources.source': {
+            'Meta': {'ordering': "['public_id']", 'object_name': 'Source', 'db_table': "'teleforma_source'"},
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'ip': ('django.db.models.fields.GenericIPAddressField', [], {'max_length': '39'}),
+            'monitors': ('django.db.models.fields.related.ManyToManyField', [], {'blank': 'True', 'related_name': "'source'", 'null': 'True', 'symmetrical': 'False', 'to': "orm['sources.Monitor']"}),
+            'public_id': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'room': ('telemeta.models.core.ForeignKey', [], {'related_name': "'source'", 'on_delete': 'models.SET_NULL', 'default': 'None', 'to': "orm['teleforma.Room']", 'blank': 'True', 'null': 'True'})
+        },
+        'teleforma.organization': {
+            'Meta': {'object_name': 'Organization'},
+            'description': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'name': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'})
+        },
+        'teleforma.room': {
+            'Meta': {'object_name': 'Room'},
+            'description': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
+            'name': ('telemeta.models.core.CharField', [], {'default': "''", 'max_length': '255', 'blank': 'True'}),
+            'organization': ('telemeta.models.core.ForeignKey', [], {'related_name': "'room'", 'to': "orm['teleforma.Organization']"})
+        }
+    }
+
+    complete_apps = ['sources']
\ No newline at end of file
diff --git a/teleforma/sources/migrations/__init__.py b/teleforma/sources/migrations/__init__.py
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/teleforma/sources/models.py b/teleforma/sources/models.py
new file mode 100644 (file)
index 0000000..ea89c97
--- /dev/null
@@ -0,0 +1,50 @@
+
+from teleforma.models.core import *
+from django.utils.translation import ugettext_lazy as _
+
+
+class Monitor(Model):
+    "Streaming source monitor"
+    
+    mime_types = [('audio/ogg', 'audio/ogg'), ('audio/mp3', 'audio/mp3'), 
+            ('video/webm', 'video/webm'), ('video/mp4', 'video/mp4')]
+    
+    port             = IntegerField(_('port'))
+    mount_point      = CharField(_('mount point'), max_length=255)
+    mime_type        = CharField(_('type'), choices=mime_types, max_length=255)
+    record_path      = CharField(_('record path'), max_length=255)
+
+    @property
+    def slug(self):
+        return ':' + str(self.port) + '/' + self.mount_point
+
+    class Meta:
+        db_table = app_label + '_' + 'monitor'
+
+    def __unicode__(self):
+        return self.slug + '(' + self.mime_type + ')'
+
+
+class Source(Model):
+    "Streaming source"
+
+    public_id         = CharField(_('public_id'), max_length=255)
+    ip                = GenericIPAddressField(_('IP'))
+    room              = ForeignKey(Room, related_name='source', verbose_name=_('room'), 
+                                    blank=True, null=True, on_delete=models.SET_NULL)
+    monitors          = ManyToManyField(Monitor, related_name="source", 
+                                    verbose_name=_('monitors'), blank=True, null=True)    
+    class Meta:
+        db_table = app_label + '_' + 'source'
+        ordering = ['public_id']
+
+    def __unicode__(self):
+        return '-'.join([self.public_id, self.room.name, self.ip])
+
+    @property
+    def default_monitor_url(self):
+        return 'http://' + str(self.ip) + self.monitors.all()[0].slug
+
+    @property
+    def default_record_url(self):
+        return 'http://' + self.public_id + '/' + self.monitors.all()[0].record_path
diff --git a/teleforma/sources/tests.py b/teleforma/sources/tests.py
new file mode 100644 (file)
index 0000000..501deb7
--- /dev/null
@@ -0,0 +1,16 @@
+"""
+This file demonstrates writing tests using the unittest module. These will pass
+when you run "manage.py test".
+
+Replace this with more appropriate tests for your application.
+"""
+
+from django.test import TestCase
+
+
+class SimpleTest(TestCase):
+    def test_basic_addition(self):
+        """
+        Tests that 1 + 1 always equals 2.
+        """
+        self.assertEqual(1 + 1, 2)
diff --git a/teleforma/sources/urls.py b/teleforma/sources/urls.py
new file mode 100644 (file)
index 0000000..d65dd63
--- /dev/null
@@ -0,0 +1,44 @@
+# -*- coding: utf-8 -*-
+# Copyright (c) 2007-2012 Parisson SARL
+
+# This software is a computer program whose purpose is to backup, analyse,
+# transcode and stream any audio content with its metadata over a web frontend.
+
+# This software is governed by the CeCILL  license under French law and
+# abiding by the rules of distribution of free software.  You can  use,
+# modify and/ or redistribute the software under the terms of the CeCILL
+# license as circulated by CEA, CNRS and INRIA at the following URL
+# "http://www.cecill.info".
+
+# As a counterpart to the access to the source code and  rights to copy,
+# modify and redistribute granted by the license, users are provided only
+# with a limited warranty  and the software's author,  the holder of the
+# economic rights,  and the successive licensors  have only  limited
+# liability.
+
+# In this respect, the user's attention is drawn to the risks associated
+# with loading,  using,  modifying and/or developing or reproducing the
+# software by the user in light of its specific status of free software,
+# that may mean  that it is complicated to manipulate,  and  that  also
+# therefore means  that it is reserved for developers  and  experienced
+# professionals having in-depth computer knowledge. Users are therefore
+# encouraged to load and test the software's suitability as regards their
+# requirements in conditions enabling the security of their systems and/or
+# data to be ensured and,  more generally, to use and operate it in the
+# same conditions as regards security.
+
+# The fact that you are presently reading this means that you have had
+# knowledge of the CeCILL license and that you accept its terms.
+#
+# Authors: Guillaume Pellerin <yomguy@parisson.com>
+
+import os.path
+from django.conf.urls.defaults import *
+from teleforma.sources.views import *
+
+urlpatterns = patterns('',
+
+    url(r'^desk/sources/$', SourcesView.as_view(), name="teleforma-sources"),
+    url(r'^desk/sources/(?P<pk>.*)/$', SourceView.as_view(), name="teleforma-source-detail"),
+
+)
diff --git a/teleforma/sources/views.py b/teleforma/sources/views.py
new file mode 100644 (file)
index 0000000..ed59fcb
--- /dev/null
@@ -0,0 +1,22 @@
+
+from teleforma.views.core import *
+from teleforma.sources.models import *
+
+
+class SourcesView(RedirectView):
+
+       def get_redirect_url(self):
+               sources = Source.objects.all()
+               print sources[0].pk
+               return reverse('teleforma-source-detail', args=(sources[0].pk,))
+               
+
+class SourceView(DetailView):
+
+    model = Source
+    template_name='teleforma/source_detail.html'
+
+    def get_context_data(self, **kwargs):
+        context = super(SourceView, self).get_context_data(**kwargs)
+        context['sources'] = Source.objects.all()
+        return context
diff --git a/teleforma/templates/teleforma/source_detail.html b/teleforma/templates/teleforma/source_detail.html
new file mode 100644 (file)
index 0000000..c47fe49
--- /dev/null
@@ -0,0 +1,49 @@
+{% extends "teleforma/course_media.html" %}
+{% load telemeta_utils %}
+{% load teleforma_tags %}
+{% load i18n %}
+
+{% block extra_javascript %}
+{% endblock extra_javascript %}
+
+{% block modules %}
+<div class="module">
+
+<h3><img src="{{ STATIC_URL }}telemeta/images/module_playlist.png" alt="playlists" style="vertical-align:middle" />Salles</h3>
+<div style="background: white;">
+<ul>
+{% block courses %}
+{% for source in sources %}
+   <li><a href="{% url teleforma-source-detail source.id %}">{{ source.room.name }}</a></li>
+{% endfor %}
+{% endblock courses %}
+</ul>
+
+</div>
+
+</div>
+
+{% block module-action %}
+  <div class="module_action">
+   <a href="{{ object.default_record_url }}" class="component_icon button" id="action_red">{% trans "Record and stream" %}</a>
+  </div>
+{% endblock module-action %}
+
+
+{% endblock modules %}
+
+
+{% block course %}
+<div class="course_media">
+
+<div class="course_title">{{ object.room.name }}</div>
+
+<div class="video">
+<video width="864" height="480" controls autoplay>
+<source src="{{ object.default_monitor_url }}" type="video/webm" />
+</video>
+</div>
+
+</div>
+{% endblock course %}
+
index eef9708cdd871f9e5283358943d1ae5839560b25..e9f900cea714b5ecef949896e3ba29762ba02bb2 100644 (file)
@@ -82,54 +82,23 @@ alt="logo" />
 <ul id="nav">
 
  {% if user.is_authenticated %}
-
-  {% if periods|length > 1 %}
-    <li><a href="#desk#" class="red">&nbsp;{% trans "Desk" %}&nbsp;</a>
-      <ul>
-       {% for period in periods %}
-        <li><a href="{% url teleforma-desk-period-list period.id %}" class="red">{{ period.name }}</a></li>
-       {% endfor %}
-      </ul>
-    </li>
-  {% else %}
-   <li><a href="{% url teleforma-home %}" class="red">{% trans "Desk" %}</a></li>
-  {% endif %}
-
+  <li><a href="{% url teleforma-desk %}" class="red">{% trans "Desk" %}</a></li>
  {% else %}
   <li><a href="{% url teleforma-login %}" class="red">{% trans "Home" %}</a></li>
  {% endif %}
 
  {% if user.is_authenticated %}
 
- <li><a href="{% url postman_inbox %}" class="orange">{% trans "Messaging" %}{% if postman_unread_count %} ({{ postman_unread_count }}){% endif %}</a></li>
-
- {% if user.is_staff %}
-  <li><a href="{% url teleforma-users 0 0 0 %}" class="yellow">{% trans "Users" %}</a></li>
- {% else %}
-  <li><a href="{% url teleforma-annals %}" class="yellow">{% trans "Annals" %}</a></li>
- {% endif %}
-
- {% if user.is_authenticated %}
-  {% if user.is_staff %}
-   <li><a href="#archives#" class="green">{% trans "Archives" %}</a>
- <ul>
- <li><a href="{% url telemeta-search-criteria %}">{% trans "Search" %}</a></li>
- <li><a href="{% url telemeta-collections %}">{% trans "Collections" %}</a></li>
- <li><a href="{% url telemeta-items %}">{% trans "Items" %}</a></li>
- <li><a href="{% url teleforma-annals %}">{% trans "Annals" %}</a></li>
- </ul>
- </li>
  <li><a href="{% url telemeta-admin-general %}" class="blue">{% trans "Admin" %}</a></li>
-  {% else %}
-   <li><a href="{% url teleforma-help %}" class="green">{% trans "Help" %}</a></li>
- {% endif %}
 
  <li style="a.active{background-image:{{ STATIC_URL }}telemeta/images/user_tr_bk.png; background-repeat: no-repeat;
-    background-position: 1ex .5ex;}"><a href="#accounts#" class="blue">{% if user.first_name and user.last_name %}
- {{ user.first_name }} {{ user.last_name }}
- {% else %}
+    background-position: 1ex .5ex;}"><a href="#accounts#" class="blue">
+{% if user.first_name and user.last_name %}
+ {{ user.first_name }} {{ user.last_name }} 
+{% else %}
  {{ user.username }}
- {% endif %}</a>
+{% endif %}</a>
+
     <ul>
     <li><a href="{% url telemeta-profile-detail user.username %}" class="yellow">{% trans "Profile" %}</a></li>
     {% if user.is_staff %}
@@ -140,7 +109,6 @@ alt="logo" />
     </ul>
  </li>
 
- {% endif %}
 {% endif %}
 
 </ul>
index 8d7e06cb34036fc44db6914b84ac0569cd7001d1..49874726106a4fb27ec401e97919e4b4b275b48b 100644 (file)
@@ -177,7 +177,7 @@ class HomeRedirectView(View):
     def get(self, request):
         if request.user.is_authenticated():
             periods = get_periods(request.user)
-            return HttpResponseRedirect(reverse('teleforma-desk-period-list', kwargs={'period_id': periods[0].id}))
+            return HttpResponseRedirect(reverse('teleforma-sources'))
         else:
             return HttpResponseRedirect(reverse('teleforma-login'))