Skip to content
Snippets Groups Projects
Commit c491c6f8 authored by Leonidas Poulopoulos's avatar Leonidas Poulopoulos
Browse files

Added alternate view for Helpdesk

Added view for Helpdesk with an "overview" perms attribute. This closes #2063,
closes #2046, closes #1898.
parent 72f63330
No related branches found
No related tags found
No related merge requests found
...@@ -100,3 +100,7 @@ Under the templates folder (templates), you can alter the footer.html file to in ...@@ -100,3 +100,7 @@ Under the templates folder (templates), you can alter the footer.html file to in
* Modify flatpages to suit your needs * Modify flatpages to suit your needs
* Once Apache proxying and shibboleth modules are properly setup, login to the tool. If shibboleth SP is properly setup you should see a user pending activation message and an activation email should arrive at the NOTIFY_ADMIN_MAILS accounts. * Once Apache proxying and shibboleth modules are properly setup, login to the tool. If shibboleth SP is properly setup you should see a user pending activation message and an activation email should arrive at the NOTIFY_ADMIN_MAILS accounts.
5. UPDATING:
* from 0.9.1 to 0.9.2:
- Check diff between urls
- run ./manage.py migrate accounts (data migration for perms)
# encoding: 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 'UserProfile'
db.create_table('accounts_userprofile', (
('peer', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['peers.Peer'])),
('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
('user', self.gf('django.db.models.fields.related.OneToOneField')(to=orm['auth.User'], unique=True)),
))
db.send_create_signal('accounts', ['UserProfile'])
def backwards(self, orm):
# Deleting model 'UserProfile'
db.delete_table('accounts_userprofile')
models = {
'accounts.userprofile': {
'Meta': {'object_name': 'UserProfile'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'peer': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['peers.Peer']"}),
'user': ('django.db.models.fields.related.OneToOneField', [], {'to': "orm['auth.User']", 'unique': 'True'})
},
'auth.group': {
'Meta': {'object_name': 'Group'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
},
'auth.permission': {
'Meta': {'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'},
'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'auth.user': {
'Meta': {'object_name': 'User'},
'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True', 'blank': 'True'}),
'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}),
'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
},
'contenttypes.contenttype': {
'Meta': {'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
},
'peers.peer': {
'Meta': {'object_name': 'Peer', 'db_table': "u'peer'"},
'domain_name': ('django.db.models.fields.CharField', [], {'max_length': '128', 'null': 'True', 'blank': 'True'}),
'networks': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['peers.PeerRange']", 'null': 'True', 'blank': 'True'}),
'peer_as': ('django.db.models.fields.IntegerField', [], {}),
'peer_id': ('django.db.models.fields.IntegerField', [], {'primary_key': 'True'}),
'peer_name': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'peer_tag': ('django.db.models.fields.CharField', [], {'max_length': '64'}),
'techc_emails': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['peers.TechcEmail']", 'null': 'True', 'blank': 'True'})
},
'peers.peerrange': {
'Meta': {'object_name': 'PeerRange', 'db_table': "u'peer_range'"},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'network': ('django.db.models.fields.CharField', [], {'max_length': '128'})
},
'peers.techcemail': {
'Meta': {'object_name': 'TechcEmail', 'db_table': "'techc_email'"},
'email': ('django.db.models.fields.CharField', [], {'max_length': '352', 'db_column': "'email'"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
}
}
complete_apps = ['accounts']
# encoding: utf-8
import datetime
from south.db import db
from south.v2 import DataMigration
from django.db import models
class Migration(DataMigration):
def forwards(self, orm):
"Write your forwards methods here."
ct, created = orm['contenttypes.ContentType'].objects.get_or_create(
model='userprofile', app_label='accounts') # model must be lowercase!
perm, created = orm['auth.permission'].objects.get_or_create(
content_type=ct, codename='overview', defaults=dict(name=u'Can see registered users and rules'))
def backwards(self, orm):
"Write your backwards methods here."
ct, created = orm['contenttypes.ContentType'].objects.get_or_create(
model='userprofile', app_label='accounts') # model must be lowercase!
perm, created = orm['auth.permission'].objects.get_or_create(
content_type=ct, codename='overview')
perm.delete()
models = {
'accounts.userprofile': {
'Meta': {'object_name': 'UserProfile'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'peer': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['peers.Peer']"}),
'user': ('django.db.models.fields.related.OneToOneField', [], {'to': "orm['auth.User']", 'unique': 'True'})
},
'auth.group': {
'Meta': {'object_name': 'Group'},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}),
'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'})
},
'auth.permission': {
'Meta': {'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'},
'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '50'})
},
'auth.user': {
'Meta': {'object_name': 'User'},
'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}),
'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True', 'blank': 'True'}),
'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False', 'blank': 'True'}),
'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}),
'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}),
'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}),
'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '255'})
},
'contenttypes.contenttype': {
'Meta': {'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"},
'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}),
'name': ('django.db.models.fields.CharField', [], {'max_length': '100'})
},
'peers.peer': {
'Meta': {'object_name': 'Peer', 'db_table': "u'peer'"},
'domain_name': ('django.db.models.fields.CharField', [], {'max_length': '128', 'null': 'True', 'blank': 'True'}),
'networks': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['peers.PeerRange']", 'null': 'True', 'blank': 'True'}),
'peer_as': ('django.db.models.fields.IntegerField', [], {}),
'peer_id': ('django.db.models.fields.IntegerField', [], {'primary_key': 'True'}),
'peer_name': ('django.db.models.fields.CharField', [], {'max_length': '128'}),
'peer_tag': ('django.db.models.fields.CharField', [], {'max_length': '64'}),
'techc_emails': ('django.db.models.fields.related.ManyToManyField', [], {'symmetrical': 'False', 'to': "orm['peers.TechcEmail']", 'null': 'True', 'blank': 'True'})
},
'peers.peerrange': {
'Meta': {'object_name': 'PeerRange', 'db_table': "u'peer_range'"},
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
'network': ('django.db.models.fields.CharField', [], {'max_length': '128'})
},
'peers.techcemail': {
'Meta': {'object_name': 'TechcEmail', 'db_table': "'techc_email'"},
'email': ('django.db.models.fields.CharField', [], {'max_length': '352', 'db_column': "'email'"}),
'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'})
}
}
complete_apps = ['accounts']
...@@ -7,6 +7,12 @@ class UserProfile(models.Model): ...@@ -7,6 +7,12 @@ class UserProfile(models.Model):
user = models.OneToOneField(User) user = models.OneToOneField(User)
peer = models.ForeignKey(Peer) peer = models.ForeignKey(Peer)
class Meta:
permissions = (
("overview", "Can see registered users and rules"),
)
def __unicode__(self): def __unicode__(self):
return "%s:%s" %(self.user.username, self.peer.peer_name) return "%s:%s" %(self.user.username, self.peer.peer_name)
......
...@@ -436,6 +436,22 @@ def selectinst(request): ...@@ -436,6 +436,22 @@ def selectinst(request):
form.fields['institution'] = forms.ModelChoiceField(queryset=Peer.objects.all(), empty_label=None) form.fields['institution'] = forms.ModelChoiceField(queryset=Peer.objects.all(), empty_label=None)
return render_to_response('registration/select_institution.html', {'form': form}, context_instance=RequestContext(request)) return render_to_response('registration/select_institution.html', {'form': form}, context_instance=RequestContext(request))
@never_cache
def overview(request):
user = request.user
if user.is_authenticated():
if user.has_perm('accounts.overview'):
users = User.objects.all()
group_routes = Route.objects.all()
return render_to_response('overview/index.html', {'users': users, 'routes': group_routes},
context_instance=RequestContext(request))
else:
violation=True
return render_to_response('overview/index.html', {'violation': violation},
context_instance=RequestContext(request))
else:
return HttpResponseRedirect(reverse("altlogin"))
@login_required @login_required
@never_cache @never_cache
def user_logout(request): def user_logout(request):
...@@ -471,6 +487,7 @@ def send_new_mail(subject, message, from_email, recipient_list, bcc_list): ...@@ -471,6 +487,7 @@ def send_new_mail(subject, message, from_email, recipient_list, bcc_list):
def lookupShibAttr(attrmap, requestMeta): def lookupShibAttr(attrmap, requestMeta):
for attr in attrmap: for attr in attrmap:
if (attr in requestMeta) & (len(requestMeta[attr]) > 0): if (attr in requestMeta.keys()):
return requestMeta[attr] if len(requestMeta[attr]) > 0:
return '' return requestMeta[attr]
\ No newline at end of file return ''
No preview for this file type
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2013-01-25 18:20+0200\n" "POT-Creation-Date: 2013-01-30 02:39+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Leonidas Poulopoulos <leopoul@grnet.gr>\n" "Last-Translator: Leonidas Poulopoulos <leopoul@grnet.gr>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
...@@ -123,8 +123,9 @@ msgstr "" ...@@ -123,8 +123,9 @@ msgstr ""
msgid "Port should be an integer" msgid "Port should be an integer"
msgstr "Η port θα πρέπει να είναι ένας ακέραιος αριθμός" msgstr "Η port θα πρέπει να είναι ένας ακέραιος αριθμός"
#: flowspec/models.py:107 templates/apply.html:201 #: flowspec/models.py:107 templates/apply.html:207
#: templates/user_routes.html:250 #: templates/user_routes.html:250 templates/overview/index.html:158
#: templates/overview/index.html.py:183
msgid "Name" msgid "Name"
msgstr "Όνομα" msgstr "Όνομα"
...@@ -132,50 +133,52 @@ msgstr "Όνομα" ...@@ -132,50 +133,52 @@ msgstr "Όνομα"
msgid "Network address. Use address/CIDR notation" msgid "Network address. Use address/CIDR notation"
msgstr "Διεύθυνση δικτύου/υποδικτύου. Χρησιμοποιήστε σύνταξη διεύθυνσης/CIDR" msgstr "Διεύθυνση δικτύου/υποδικτύου. Χρησιμοποιήστε σύνταξη διεύθυνσης/CIDR"
#: flowspec/models.py:109 templates/apply.html:237 #: flowspec/models.py:109 templates/apply.html:243
msgid "Source Address" msgid "Source Address"
msgstr "Διεύθυνση Πηγής" msgstr "Διεύθυνση Πηγής"
#: flowspec/models.py:110 templates/apply.html:287 #: flowspec/models.py:110 templates/apply.html:293
msgid "Source Port" msgid "Source Port"
msgstr "Port Πηγής" msgstr "Port Πηγής"
#: flowspec/models.py:111 templates/apply.html:250 #: flowspec/models.py:111 templates/apply.html:256
msgid "Destination Address" msgid "Destination Address"
msgstr "Διεύθυνση Προορισμού" msgstr "Διεύθυνση Προορισμού"
#: flowspec/models.py:112 templates/apply.html:302 #: flowspec/models.py:112 templates/apply.html:308
msgid "Destination Port" msgid "Destination Port"
msgstr "Port Προορισμού" msgstr "Port Προορισμού"
#: flowspec/models.py:113 templates/apply.html:292 templates/apply.html.py:307 #: flowspec/models.py:113 templates/apply.html:298 templates/apply.html.py:313
#: templates/apply.html:317 templates/apply.html.py:322 #: templates/apply.html:323 templates/apply.html.py:328
msgid "Port" msgid "Port"
msgstr "" msgstr ""
#: flowspec/models.py:119 templates/apply.html:263 #: flowspec/models.py:119 templates/apply.html:269
msgid "Protocol" msgid "Protocol"
msgstr "Πρωτόκολλο" msgstr "Πρωτόκολλο"
#: flowspec/models.py:121 templates/apply.html:345 #: flowspec/models.py:121 templates/apply.html:351
#: templates/user_routes.html:252 #: templates/user_routes.html:252 templates/overview/index.html:185
msgid "Then" msgid "Then"
msgstr "Ενέργειες" msgstr "Ενέργειες"
#: flowspec/models.py:124 templates/user_routes.html:253 #: flowspec/models.py:124 templates/user_routes.html:253
#: templates/overview/index.html:159 templates/overview/index.html.py:186
msgid "Status" msgid "Status"
msgstr "Κατάσταση" msgstr "Κατάσταση"
#: flowspec/models.py:127 templates/apply.html:366 #: flowspec/models.py:127 templates/apply.html:372
#: templates/user_routes.html:256 #: templates/user_routes.html:256 templates/overview/index.html:189
msgid "Expires" msgid "Expires"
msgstr "Λήγει" msgstr "Λήγει"
#: flowspec/models.py:128 templates/user_routes.html:257 #: flowspec/models.py:128 templates/user_routes.html:257
#: templates/overview/index.html:190
msgid "Response" msgid "Response"
msgstr "Απόκριση Δικτύου" msgstr "Απόκριση Δικτύου"
#: flowspec/models.py:129 templates/apply.html:382 #: flowspec/models.py:129 templates/apply.html:388
msgid "Comments" msgid "Comments"
msgstr "Σχόλια" msgstr "Σχόλια"
...@@ -281,7 +284,7 @@ msgstr "Επεξεργασία φίλτρου" ...@@ -281,7 +284,7 @@ msgstr "Επεξεργασία φίλτρου"
msgid "Create new Rule" msgid "Create new Rule"
msgstr "Δημιουργία νέου Φίλτρου" msgstr "Δημιουργία νέου Φίλτρου"
#: templates/apply.html:15 templates/apply.html.py:182 #: templates/apply.html:15 templates/apply.html.py:188
msgid "Edit rule" msgid "Edit rule"
msgstr "Επεξεργασία φίλτρου" msgstr "Επεξεργασία φίλτρου"
...@@ -289,93 +292,94 @@ msgstr "Επεξεργασία φίλτρου" ...@@ -289,93 +292,94 @@ msgstr "Επεξεργασία φίλτρου"
msgid "Create rule" msgid "Create rule"
msgstr "Δημιουργία φίλτρου" msgstr "Δημιουργία φίλτρου"
#: templates/apply.html:35 templates/apply.html.py:67 #: templates/apply.html:41 templates/apply.html.py:73
msgid "Add" msgid "Add"
msgstr "Προσθήκη" msgstr "Προσθήκη"
#: templates/apply.html:55 templates/apply.html.py:95 #: templates/apply.html:61 templates/apply.html.py:101
#: templates/user_routes.html:34 #: templates/user_routes.html:34
msgid "Cancel" msgid "Cancel"
msgstr "Άκυρο" msgstr "Άκυρο"
#: templates/apply.html:183 #: templates/apply.html:189
msgid "Apply for a new rule" msgid "Apply for a new rule"
msgstr "Αίτηση δημιουργίας νέου φίλτρου" msgstr "Αίτηση δημιουργίας νέου φίλτρου"
#: templates/apply.html:198 #: templates/apply.html:204
msgid "Rule Basic Info" msgid "Rule Basic Info"
msgstr "Βασικές Πληροφορίες Φίλτρου" msgstr "Βασικές Πληροφορίες Φίλτρου"
#: templates/apply.html:216 #: templates/apply.html:222
msgid "Admin Options" msgid "Admin Options"
msgstr "Επιλογές Διαχείρισης" msgstr "Επιλογές Διαχείρισης"
#: templates/apply.html:219 templates/user_routes.html:255 #: templates/apply.html:225 templates/user_routes.html:255
#: templates/overview/index.html:188
msgid "Applier" msgid "Applier"
msgstr "Χρήστης" msgstr "Χρήστης"
#: templates/apply.html:234 #: templates/apply.html:240
msgid "Rule Match Conditions" msgid "Rule Match Conditions"
msgstr "Όροι ταύτισης φίλτρου" msgstr "Όροι ταύτισης φίλτρου"
#: templates/apply.html:275 #: templates/apply.html:281
msgid "Ports" msgid "Ports"
msgstr "" msgstr ""
#: templates/apply.html:281 #: templates/apply.html:287
msgid "Advanced Settings (Ports)" msgid "Advanced Settings (Ports)"
msgstr "Προηγμένες Ρυθμίσεις (Ports)" msgstr "Προηγμένες Ρυθμίσεις (Ports)"
#: templates/apply.html:285 #: templates/apply.html:291
msgid "" msgid ""
"Select source/destination port(s), or select common port(s) for both source/" "Select source/destination port(s), or select common port(s) for both source/"
"destination" "destination"
msgstr "" msgstr ""
#: templates/apply.html:342 #: templates/apply.html:348
msgid "Rule Actions" msgid "Rule Actions"
msgstr "Ενέργειες Φίλτρου" msgstr "Ενέργειες Φίλτρου"
#: templates/apply.html:363 #: templates/apply.html:369
msgid "Expiration" msgid "Expiration"
msgstr "Λήξη" msgstr "Λήξη"
#: templates/apply.html:379 #: templates/apply.html:385
msgid "Use/Comments" msgid "Use/Comments"
msgstr "Χρήση/Σχόλια" msgstr "Χρήση/Σχόλια"
#: templates/apply.html:384 #: templates/apply.html:390
msgid "" msgid ""
"Give a short description of the intended use of this rule, that justifies " "Give a short description of the intended use of this rule, that justifies "
"the parameter selection above. Feel free to include any additional comments." "the parameter selection above. Feel free to include any additional comments."
msgstr "" msgstr ""
#: templates/apply.html:398 templates/registration/select_institution.html:37 #: templates/apply.html:404 templates/registration/select_institution.html:37
msgid "Apply" msgid "Apply"
msgstr "Εφαρμογή" msgstr "Εφαρμογή"
#: templates/apply.html:407 #: templates/apply.html:413
msgid "Add new port" msgid "Add new port"
msgstr "Νέα port" msgstr "Νέα port"
#: templates/base.html:59 templates/base.html.py:158 #: templates/base.html:59 templates/base.html.py:164
msgid "Welcome" msgid "Welcome"
msgstr "Καλωσήρθατε" msgstr "Καλωσήρθατε"
#: templates/base.html:73 templates/base.html.py:102 templates/profile.html:4 #: templates/base.html:73 templates/base.html.py:103 templates/profile.html:4
#: templates/profile.html.py:5 templates/profile.html:7 #: templates/profile.html.py:5 templates/profile.html:7
msgid "My profile" msgid "My profile"
msgstr "Το προφίλ μου" msgstr "Το προφίλ μου"
#: templates/base.html:75 templates/base.html.py:106 #: templates/base.html:75 templates/base.html.py:112
msgid "Admin" msgid "Admin"
msgstr "Διαχειριστής" msgstr "Διαχειριστής"
#: templates/base.html:77 templates/base.html.py:136 #: templates/base.html:77 templates/base.html.py:142
msgid "Logout" msgid "Logout"
msgstr "Έξοδος" msgstr "Έξοδος"
#: templates/base.html:80 templates/base.html.py:144 #: templates/base.html:80 templates/base.html.py:150
msgid "" msgid ""
"After clicking Retry Login, it is strongly suggested to close your browser " "After clicking Retry Login, it is strongly suggested to close your browser "
"and visit the page again" "and visit the page again"
...@@ -383,20 +387,24 @@ msgstr "" ...@@ -383,20 +387,24 @@ msgstr ""
"Αφού επιλέξετε Επανάληψη Εισόδου κλείστε τον browser σας και επισκεφθείτε " "Αφού επιλέξετε Επανάληψη Εισόδου κλείστε τον browser σας και επισκεφθείτε "
"ξανά τη σελίδα" "ξανά τη σελίδα"
#: templates/base.html:80 templates/base.html.py:144 #: templates/base.html:80 templates/base.html.py:150
msgid "Retry Login" msgid "Retry Login"
msgstr "Επανάληψη Εισόδου" msgstr "Επανάληψη Εισόδου"
#: templates/base.html:82 templates/base.html.py:141 templates/base.html:147 #: templates/base.html:82 templates/base.html.py:147 templates/base.html:153
#: templates/welcome.html:21 #: templates/welcome.html:21
msgid "Shibboleth Login" msgid "Shibboleth Login"
msgstr "Είσοδος με Shibboleth" msgstr "Είσοδος με Shibboleth"
#: templates/base.html:115 #: templates/base.html:108 templates/overview/index.html:121
msgid "Overview"
msgstr "Επισκόπηση"
#: templates/base.html:121
msgid "Language" msgid "Language"
msgstr "Γλώσσα" msgstr "Γλώσσα"
#: templates/base.html:158 templates/user_routes.html:214 #: templates/base.html:164 templates/user_routes.html:214
#: templates/user_routes.html.py:220 #: templates/user_routes.html.py:220
msgid "My rules" msgid "My rules"
msgstr "Τα φίλτρα μου" msgstr "Τα φίλτρα μου"
...@@ -448,7 +456,7 @@ msgstr "Πληροφορίες" ...@@ -448,7 +456,7 @@ msgstr "Πληροφορίες"
msgid "Service Terms" msgid "Service Terms"
msgstr "Όροι Χρήσης" msgstr "Όροι Χρήσης"
#: templates/profile.html:11 #: templates/profile.html:11 templates/overview/index.html:156
msgid "Username" msgid "Username"
msgstr "" msgstr ""
...@@ -460,7 +468,7 @@ msgstr "Όνομα" ...@@ -460,7 +468,7 @@ msgstr "Όνομα"
msgid "Last name" msgid "Last name"
msgstr "Επώνυμο" msgstr "Επώνυμο"
#: templates/profile.html:23 #: templates/profile.html:23 templates/overview/index.html:157
msgid "Email" msgid "Email"
msgstr "" msgstr ""
...@@ -486,43 +494,52 @@ msgstr "" ...@@ -486,43 +494,52 @@ msgstr ""
msgid "Suspend" msgid "Suspend"
msgstr "Κατάργηση" msgstr "Κατάργηση"
#: templates/user_routes.html:124 #: templates/user_routes.html:124 templates/overview/index.html:43
#: templates/overview/index.html.py:97
msgid "Display" msgid "Display"
msgstr "Προβολή" msgstr "Προβολή"
#: templates/user_routes.html:124 #: templates/user_routes.html:124 templates/overview/index.html:43
#: templates/overview/index.html.py:97
msgid "All" msgid "All"
msgstr "όλων των" msgstr "όλων των"
#: templates/user_routes.html:124 #: templates/user_routes.html:124 templates/overview/index.html:97
msgid "rules" msgid "rules"
msgstr "φίλτρων" msgstr "φίλτρων"
#: templates/user_routes.html:126 #: templates/user_routes.html:126 templates/overview/index.html:45
#: templates/overview/index.html.py:99
msgid "No records to display" msgid "No records to display"
msgstr "Δεν βρέθηκαν εγγραφές" msgstr "Δεν βρέθηκαν εγγραφές"
#: templates/user_routes.html:128 #: templates/user_routes.html:128 templates/overview/index.html:47
#: templates/overview/index.html.py:101
msgid "Showing 0 to 0 of 0 entries" msgid "Showing 0 to 0 of 0 entries"
msgstr "Δείχνοντας 0 εως 0 από 0 εγγραφές" msgstr "Δείχνοντας 0 εως 0 από 0 εγγραφές"
#: templates/user_routes.html:131 #: templates/user_routes.html:131 templates/overview/index.html:50
#: templates/overview/index.html.py:104
msgid "Search:" msgid "Search:"
msgstr "Αναζήτηση:" msgstr "Αναζήτηση:"
#: templates/user_routes.html:134 #: templates/user_routes.html:134 templates/overview/index.html:53
#: templates/overview/index.html.py:107
msgid "First" msgid "First"
msgstr "Πρώτη" msgstr "Πρώτη"
#: templates/user_routes.html:135 #: templates/user_routes.html:135 templates/overview/index.html:54
#: templates/overview/index.html.py:108
msgid "Previous" msgid "Previous"
msgstr "Προηγούμενη" msgstr "Προηγούμενη"
#: templates/user_routes.html:136 #: templates/user_routes.html:136 templates/overview/index.html:55
#: templates/overview/index.html.py:109
msgid "Next" msgid "Next"
msgstr "Επόμενη" msgstr "Επόμενη"
#: templates/user_routes.html:137 #: templates/user_routes.html:137 templates/overview/index.html:56
#: templates/overview/index.html.py:110
msgid "Last" msgid "Last"
msgstr "Τελευταία" msgstr "Τελευταία"
...@@ -534,11 +551,11 @@ msgstr "Κονσόλα" ...@@ -534,11 +551,11 @@ msgstr "Κονσόλα"
msgid "Add Rule" msgid "Add Rule"
msgstr "Δημιουργία φίλτρου" msgstr "Δημιουργία φίλτρου"
#: templates/user_routes.html:251 #: templates/user_routes.html:251 templates/overview/index.html:184
msgid "Match" msgid "Match"
msgstr "Όροι" msgstr "Όροι"
#: templates/user_routes.html:254 #: templates/user_routes.html:254 templates/overview/index.html:187
msgid "Details" msgid "Details"
msgstr "Λεπτομέρειες" msgstr "Λεπτομέρειες"
...@@ -547,22 +564,24 @@ msgid "Actions" ...@@ -547,22 +564,24 @@ msgid "Actions"
msgstr "Ενέργειες" msgstr "Ενέργειες"
#: templates/user_routes.html:295 templates/user_routes.html.py:309 #: templates/user_routes.html:295 templates/user_routes.html.py:309
#: templates/overview/index.html:226 templates/overview/index.html.py:240
msgid "Suspended by user" msgid "Suspended by user"
msgstr "Απενεργοποιήθηκε από το χρήστη" msgstr "Απενεργοποιήθηκε από το χρήστη"
#: templates/user_routes.html:298 templates/user_routes.html.py:309 #: templates/user_routes.html:298 templates/user_routes.html.py:309
#: templates/overview/index.html:229 templates/overview/index.html.py:240
msgid "Suspended by administrator" msgid "Suspended by administrator"
msgstr "Απενεργοποιήθηκε από το διαχειριστή" msgstr "Απενεργοποιήθηκε από το διαχειριστή"
#: templates/user_routes.html:301 #: templates/user_routes.html:301 templates/overview/index.html:232
msgid "Suspended due to expiration" msgid "Suspended due to expiration"
msgstr "Απενεργοποιήθηκε λόγω λήξης" msgstr "Απενεργοποιήθηκε λόγω λήξης"
#: templates/user_routes.html:304 #: templates/user_routes.html:304 templates/overview/index.html:235
msgid "Syncronization error. Configuration in device deffers from rule" msgid "Syncronization error. Configuration in device deffers from rule"
msgstr "Σφάλμα συγχρονισμού. Διαφορά διαμόρφωσης από συσκευή" msgstr "Σφάλμα συγχρονισμού. Διαφορά διαμόρφωσης από συσκευή"
#: templates/user_routes.html:309 #: templates/user_routes.html:309 templates/overview/index.html:240
msgid "Rule expired" msgid "Rule expired"
msgstr "Λήξη Φίλτρου" msgstr "Λήξη Φίλτρου"
...@@ -648,6 +667,42 @@ msgstr "" ...@@ -648,6 +667,42 @@ msgstr ""
"Για αντιμετώπιση σφαλμάτων και πληροφορίες, επικοινωνήστε με το Helpdesk του " "Για αντιμετώπιση σφαλμάτων και πληροφορίες, επικοινωνήστε με το Helpdesk του "
"ΕΔΕΤ" "ΕΔΕΤ"
#: templates/overview/index.html:43
msgid "users"
msgstr "χρήστες"
#: templates/overview/index.html:140
msgid "Users - Rules"
msgstr "Χρήστες - Φίλτρα"
#: templates/overview/index.html:145
msgid "Users"
msgstr "Χρήστες"
#: templates/overview/index.html:146
msgid "Rules"
msgstr "Φίλτρα"
#: templates/overview/index.html:160
msgid "Peer"
msgstr "Φορέας"
#: templates/overview/index.html:169
msgid "Active"
msgstr ""
#: templates/overview/index.html:169
msgid "Inactive"
msgstr ""
#: templates/overview/index.html:169
msgid "Key Expired"
msgstr ""
#: templates/overview/login.html:3 templates/overview/login.html.py:14
msgid "Overview Login"
msgstr "Εισόδος στην Επισκόπηση"
#: templates/registration/activate.html:3 #: templates/registration/activate.html:3
#: templates/registration/activation_complete.html:3 #: templates/registration/activation_complete.html:3
#: templates/registration/activation_complete.html:7 #: templates/registration/activation_complete.html:7
......
...@@ -98,9 +98,15 @@ body { ...@@ -98,9 +98,15 @@ body {
<ul class="nav"> <ul class="nav">
{% if user.is_authenticated %} {% if user.is_authenticated %}
{% if user.get_profile.peer %}
<li> <li>
<a href="{% url user-profile %}">{% trans "My profile" %}</a> <a href="{% url user-profile %}">{% trans "My profile" %}</a>
</li> </li>
{% endif %}
{% if perms.accounts.overview %}<li>
<a href="{% url overview %}">{% trans "Overview" %}</a>
</li>{% endif %}
{% if user.is_superuser %} {% if user.is_superuser %}
<li {% block hometop %}{% endblock %}> <li {% block hometop %}{% endblock %}>
<a href="{% url admin:index %}">{% trans "Admin" %}</a> <a href="{% url admin:index %}">{% trans "Admin" %}</a>
......
...@@ -2,14 +2,15 @@ ...@@ -2,14 +2,15 @@
<footer class="footer"> <footer class="footer">
<div id="footcontainer" class="container"> <div id="footcontainer" class="container">
{% if user.is_authenticated %} {% if user.is_authenticated %}
<p>{% trans "If you have any questions or need help, contact GRNET Helpdesk at <a href='mailto:helpdesk@grnet.gr'>helpdesk@grnet.gr</a> or 800-11-47638." %}</p> <p>{% trans "If you have any questions or need help, contact GRNET Helpdesk at <a href='mailto:helpdesk@grnet.gr'>helpdesk@grnet.gr</a> or 800-11-47638." %}</p>
{% endif %} {% endif %}
<div style="padding-top: 10px;">{% trans "Designed and developed by GRNET NOC" %}</div> <div style="padding-top: 10px;">{% trans "Designed and developed by GRNET NOC" %}
<a href="//facebook.com/noc.grnet.gr" target="_blank"><img src="/fodstatic/img/facebook_img.png" alt="GRNET NOC on Facebook" title="GRNET NOC on Facebook"/></a> <a href="//twitter.com/grnetnoc" target="_blank"><img src="/fodstatic/img/twitter_img.png" alt="GRNET NOC on Twitter" title="GRNET NOC on Twitter"/></a>
</div>
<div class="row"><a href="http://noc.grnet.gr">{% trans "GRNET" %} NOC</a> | <a href="/fod/info/{{LANGUAGE_CODE}}/">{% trans "Info" %}</a> | <a href="/fod/tos/{{LANGUAGE_CODE}}/">{% trans "Service Terms" %}</a></div> <div class="row"><a href="http://noc.grnet.gr">{% trans "GRNET" %} NOC</a> | <a href="/fod/info/{{LANGUAGE_CODE}}/">{% trans "Info" %}</a> | <a href="/fod/tos/{{LANGUAGE_CODE}}/">{% trans "Service Terms" %}</a></div>
<div style="padding-top: 10px;"> <div style="padding-top: 10px;">
<a href="//facebook.com/noc.grnet.gr" target="_blank"><img src="/fodstatic/img/facebook_img.png" alt="GRNET NOC on Facebook" title="GRNET NOC on Facebook"/></a> <a href="//twitter.com/grnetnoc" target="_blank"><img src="/fodstatic/img/twitter_img.png" alt="GRNET NOC on Twitter" title="GRNET NOC on Twitter"/></a>
</div> </div>
<div style="padding-top: 10px;"> <div style="padding-top: 10px;">
<p style="text-align: center;"><img width="46" height="40" border="0" class="image image-img_assist_custom-46x40 " src="//noc.grnet.gr/sites/default/files/images/image_PSSYGK.img_assist_custom-46x40.png" alt="Flag ΨΣ" title="Flag ΨΣ"> <img width="49" height="40" border="0" class="image image-img_assist_custom-49x40 " src="//noc.grnet.gr/sites/default/files/images/image_EEflag.img_assist_custom-49x40.png" alt="EU flag" title="EU flag"> <img width="90" height="40" border="0" class="image image-img_assist_custom-90x40 " src="//noc.grnet.gr/sites/default/files/images/image_YPDBMTH.img_assist_custom-90x40.png" alt="Flag ΥΠΔΒΜΘ" title="Flag ΥΠΔΒΜΘ"><img width="67" height="40" border="0" class="image image-img_assist_custom-67x40 " src="//noc.grnet.gr/sites/default/files/images/image_ESPA.img_assist_custom-67x40.png" alt="ESPA" title="ESPA"></p> <p style="text-align: center;"><img width="46" height="40" border="0" class="image image-img_assist_custom-46x40 " src="//noc.grnet.gr/sites/default/files/images/image_PSSYGK.img_assist_custom-46x40.png" alt="Flag ΨΣ" title="Flag ΨΣ"> <img width="49" height="40" border="0" class="image image-img_assist_custom-49x40 " src="//noc.grnet.gr/sites/default/files/images/image_EEflag.img_assist_custom-49x40.png" alt="EU flag" title="EU flag"> <img width="90" height="40" border="0" class="image image-img_assist_custom-90x40 " src="//noc.grnet.gr/sites/default/files/images/image_YPDBMTH.img_assist_custom-90x40.png" alt="Flag ΥΠΔΒΜΘ" title="Flag ΥΠΔΒΜΘ"><img width="67" height="40" border="0" class="image image-img_assist_custom-67x40 " src="//noc.grnet.gr/sites/default/files/images/image_ESPA.img_assist_custom-67x40.png" alt="ESPA" title="ESPA"></p>
......
{% extends "base.html"%}
{% load i18n %}
{% load i18n %}
{% block extrahead %}
<script type="text/javascript" src="/fodstatic/js/jquery.dataTables.js"></script>
<script type="text/javascript" src="/fodstatic/js/datatables_bootstrap.js"></script>
<style>
.tab-content {
overflow: visible;
}
</style>
<script type="text/javascript">
$(document).ready(function(){
{% if users %}
var oTableU = $('#usertable').dataTable({
"sPaginationType": "bootstrap",
"sDom": "<'row-fluid'<'span6'l><'span6'f>r>t<'row-fluid'<'span6'i><'span6'p>>",
"aoColumns": [{
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}],
"aaSorting": [[0, 'desc']],
"iDisplayLength": 25,
"oSearch": {"bSmart": false, "bRegex":true},
"oLanguage": {
"sLengthMenu": '{% trans "Display" %} <select><option value="25">25</option><option value="50">50</option><option value="-1">{% trans "All" %}</option></select> {% trans "users" %}',
"sProcessing": "Processing...",
"sZeroRecords": '{% trans "No records to display" %}',
"sInfo": "Showing _START_ to _END_ of _TOTAL_ entries",
"sInfoEmpty": "{% trans "Showing 0 to 0 of 0 entries" %}",
"sInfoFiltered": "(filtered from _MAX_ total entries)",
"sInfoPostFix": "",
"sSearch": '{% trans "Search:" %}',
"sUrl": "",
"oPaginate": {
"sFirst": '{% trans "First" %}',
"sPrevious": '{% trans "Previous" %}',
"sNext": '{% trans "Next" %}',
"sLast": '{% trans "Last" %}'
}
}
});
oTableU.fnDraw();
{% endif %}
{% if routes %}
var oTableI = $('#routes_table').dataTable({
"sPaginationType": "bootstrap",
"sDom": "<'row-fluid'<'span6'l><'span6'f>r>t<'row-fluid'<'span6'i><'span6'p>>",
"aoColumns": [{
"bVisible": false,
"bSearchable": false,
"bSortable": false
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}, {
"bSearchable": true,
"bSortable": true
}],
"aaSorting": [[0, 'desc']],
"iDisplayLength": 25,
"oSearch": {"bSmart": false, "bRegex":true},
"oLanguage": {
"sLengthMenu": '{% trans "Display" %} <select><option value="25">25</option><option value="50">50</option><option value="-1">{% trans "All" %}</option></select> {% trans "rules" %}',
"sProcessing": "Processing...",
"sZeroRecords": '{% trans "No records to display" %}',
"sInfo": "Showing _START_ to _END_ of _TOTAL_ entries",
"sInfoEmpty": "{% trans "Showing 0 to 0 of 0 entries" %}",
"sInfoFiltered": "(filtered from _MAX_ total entries)",
"sInfoPostFix": "",
"sSearch": '{% trans "Search:" %}',
"sUrl": "",
"oPaginate": {
"sFirst": '{% trans "First" %}',
"sPrevious": '{% trans "Previous" %}',
"sNext": '{% trans "Next" %}',
"sLast": '{% trans "Last" %}'
}
}
});
oTableI.fnDraw();
{% endif %}
});
</script>
{% endblock %}
{% block brcrmb_container %}
<ul class="breadcrumb"><li><a href="{% url overview %}">{% trans "Overview" %}</a></li>
</ul>
{% endblock %}
{% block content %}
<div class="container-fluid">
<div class="row-fluid">
</div>
<div class="row-fluid">
<div class="span12">
<div class="row-fluid">
<!--/span-->
<div class="span12">
{% if violation %}
<table class="table table-condensed">
<tr class="error"><td>You have no rights to access this area. Please contact your administrator<td></tr>
</table>
{% else %}
{% block subcontent %}
<h4>{% trans "Users - Rules" %}</h4>
<hr>
<ul class="nav nav-tabs">
<li class="active"><a href="#users" data-toggle="tab">{% trans "Users" %}</a></li>
<li><a href="#routes" data-toggle="tab">{% trans "Rules" %}</a></li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="users">
{% if users %}
<table cellpadding="0" cellspacing="0" border="0" class="table table-striped table-bordered" width="100%" id="usertable">
<thead>
<tr>
<th>{% trans "Username" %}</th>
<th>{% trans "Email" %}</th>
<th>{% trans "Name" %}</th>
<th>{% trans "Status" %}</th>
<th>{% trans "Peer" %}</th>
</tr>
</thead>
<tbody>
{% for user in users %}
<tr class="GradeC">
<td>{{user.username}}</td>
<td>{{user.email}}</td>
<td>{{user.first_name}} {{user.last_name}}</td>
<td>{% if user.registrationprofile_set.all %}{% if user.registrationprofile_set.all.0.activation_key == "ALREADY_ACTIVATED" %}{% trans "Active" %}{% else %}{% trans "Inactive" %} or {% trans "Key Expired" %}{% endif %}{% else %}-{% endif %}</td>
<td>{% if user.get_profile.peer %}{{user.get_profile.peer}}{% endif %}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
<div class="tab-pane" id="routes">
{% if routes %}
<table cellpadding="0" cellspacing="0" border="0" class="table table-striped table-bordered" width="100%" id="routes_table">
<thead>
<tr>
<th>Id</th>
<th>{% trans "Name" %}</th>
<th>{% trans "Match" %}</th>
<th style="text-align: center;">{% trans "Then" %}</th>
<th style="text-align: center; ">{% trans "Status" %}</th>
{% comment %}<th style="text-align: center;">{% trans "Details" %}</th>{% endcomment %}
<th style="text-align: center;">{% trans "Applier" %}</th>
<th style="text-align: center;">{% trans "Expires" %}</th>
<th style="text-align: center;">{% trans "Response" %}</th>
</tr>
</thead>
<tbody>
{% for route in routes %}
<tr class="GradeC" >
<td>{{ route.pk }}</td>
<td {% if route.comments %}style="color: #0088CC;"{% endif %}>{% if route.comments %}<span rel="tooltip" data-placement="top" title="{{route.comments}}">{{ route.name }}</span>{% else %}{{ route.name }}{% endif %}</td>
<td>{{ route.get_match|safe|escape }}</td>
<td style="text-align: center;">{{route.get_then|safe|escape}}</td>
<td style="text-align: center; ">{% if route.status == 'EXPIRED' or route.status == 'ADMININACTIVE' or route.status == 'INACTIVE' or route.status == 'OUTOFSYNC'%}
{% if route.status == 'EXPIRED' or route.status == 'ADMININACTIVE' or route.status == 'INACTIVE' %}SUSPENDED{% else %}{% if route.status == 'OUTOFSYNC' %}ERROR{% else %}{{route.status}}{% endif %}{% endif %}{% else %}{{route.status}}{% endif %}</td>
{% comment %}<td style="text-align: center;">{{ route.response }}</td>{% endcomment %}
<td style="text-align: center;">{{ route.applier }}</td>
<td style="text-align: center;" nowrap>
<span {% if route.status == 'EXPIRED' or route.status == 'ADMININACTIVE' or route.status == 'INACTIVE' or route.status == 'OUTOFSYNC'%}{% else %}{% if route.days_to_expire %}
data-placement="top"
rel = 'tooltip'
style="border-bottom:1px dashed red;"
title="Expires {% ifequal route.days_to_expire '0' %}today{% else%}in {{route.days_to_expire}} day{{ route.days_to_expire|pluralize }}{% endifequal %}"
{% endif %}{% endif %}>{{ route.expires|date:"d M y" }}</span></td>
<td style="text-align: center; {% if route.status == 'EXPIRED' %} color: #0088CC; {% endif %}">
{% if route.status == 'EXPIRED' %}
<span rel="tooltip" {% if route.status == 'EXPIRED' or route.status == 'ADMININACTIVE' or route.status == 'INACTIVE' or route.status == 'OUTOFSYNC'%}
data-placement="top"
title = "{% ifequal route.status 'INACTIVE' %}
{% trans 'Suspended by user' %}
{% else %}
{% ifequal route.status 'ADMININACTIVE' %}
{% trans 'Suspended by administrator' %}
{% else %}
{% ifequal route.status 'EXPIRED' %}
{% trans 'Suspended due to expiration' %}
{% else %}
{% ifequal route.status 'OUTOFSYNC' %}
{% trans 'Syncronization error. Configuration in device deffers from rule' %}
{% endifequal %}
{% endifequal %}
{% endifequal %}
{% endifequal %}"
{% endif %}>{% trans "Rule expired" %}</span>{% else %}{% if route.status == 'ADMININACTIVE' %}{% trans "Suspended by administrator" %}{% else %}{% if route.status == 'INACTIVE' %}{% trans "Suspended by user" %}{% else %}{{ route.response }}{% if route.status == 'PENDING' %}<img src="/fodstatic/dots.gif">{% endif %}{% endif %}{% endif %}{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
</div>
{% endblock %}
{% endif %}
</div><!--/span-->
<!--/span-->
</div><!--/row-->
</div><!--/span-->
</div><!--/row-->
</div><!--/.fluid-container-->
{% endblock %}
\ No newline at end of file
{% extends "base.html" %}
{% load i18n %}
{% block title %}{% trans "Overview Login" %}{% endblock %}
{% block content %}
<div class="container-fluid">
<div class="row-fluid">
<div class="span2">
</div><!--/span-->
<div class="span10">
<div class="row-fluid">
<!--/span-->
<h3 class="muted">{% trans "Overview Login" %}</h3>
<hr>
<form class="form-horizontal" method="post"
action="{% url altlogin %}">
{% if form.non_field_errors %} {% for err in form.non_field_errors %}
<div class="control-group error ">
<div class="controls error">
<span style="color: #B94A48;">{{err}}</span>
</div>
</div>
{% endfor %} {% endif %} {% csrf_token %}
<div class="control-group {% if form.username.errors %} error {% endif %}">
<label class="control-label" for="id_username">Username</label>
<div class="controls">
{{ form.username }} {% if form.username.errors %} <span class="help-inline"> {{ form.username.errors|join:", "}} </span> {% endif %}
</div>
</div>
<div class="control-group {% if form.password.errors %} error {% endif %}">
<label class="control-label" for="id_password">Password</label>
<div class="controls">
{{ form.password }} {% if form.password.errors %} <span
class="help-inline"> {{ form.password.errors|join:", "}} </span> {% endif %}
</div>
</div>
<div class="control-group">
<div class="controls">
<button type="submit" class="btn">Sign in</button>
<input type="hidden" name="next" value="{% url overview %}" />
</div>
</div>
</form>
<!--/span-->
</div><!--/row-->
</div><!--/span-->
</div><!--/span-->
</div><!--/.fluid-container-->
{% endblock %}
...@@ -5,13 +5,17 @@ ...@@ -5,13 +5,17 @@
{% block contentplaceholder %} {% block contentplaceholder %}
<div id="content" class="container"> <div id="content" class="container">
<div class="hero-unit" style="text-align:center"><h2>GRNET - Firewall on Demand</h2> <div class="hero-unit" style="text-align:center"><h2>GRNET - Firewall on Demand</h2>
<p><img src="/fodstatic/img/fod_footer_logo.png" /></p> <p>
<iframe width="640" height="360" src="https://www.youtube.com/embed/VZy7DG8sjSk?rel=0" frameborder="0" allowfullscreen></iframe>
</p>
<p>{% blocktrans %}Welcome to GRNET's FoD service.{% endblocktrans %}</p> <p>{% blocktrans %}Welcome to GRNET's FoD service.{% endblocktrans %}</p>
</div> </div>
<div class="row-fluid"> <div class="row-fluid">
<div class="span4 well"><h3>{% trans "What" %}?</h3><hr> <div class="span4 well"><h3>{% trans "What" %}?</h3><hr>
<p>{% blocktrans %}If you are new to the service, take some time to read the{% endblocktrans %} <a href="/fod/info/{{LANGUAGE_CODE}}/">{% trans "Service Description" %}</a></p> <p>{% blocktrans %}If you are new to the service, take some time to read the{% endblocktrans %} <a href="/fod/info/{{LANGUAGE_CODE}}/">{% trans "Service Description" %}</a></p>
<p>{% blocktrans %}Before asking why? take some time to look at the{% endblocktrans %} <a href="/fod/tos/{{LANGUAGE_CODE}}/">{% trans "Service Terms" %}</a></p> <p>{% blocktrans %}Before asking why? take some time to look at the{% endblocktrans %} <a href="/fod/tos/{{LANGUAGE_CODE}}/">{% trans "Service Terms" %}</a></p>
</div> </div>
<div class="span4 well"><h3>{% trans "How" %}?</h3><hr> <div class="span4 well"><h3>{% trans "How" %}?</h3><hr>
<p>{% blocktrans %}If you have properly set your Shibboleth attributes, you may proceed{% endblocktrans %}</p> <p>{% blocktrans %}If you have properly set your Shibboleth attributes, you may proceed{% endblocktrans %}</p>
...@@ -24,7 +28,10 @@ ...@@ -24,7 +28,10 @@
</div> </div>
</div> </div>
<div class="span4 well"><h3>{% trans "Help" %}?</h3><hr> <div class="span4 well"><h3>{% trans "Help" %}?</h3><hr>
{% blocktrans %}For troubleshooting info and remarks do not hesitate to contact GRNET's Helpdesk.{% endblocktrans %}</div> <p>
<p>{% blocktrans %}For troubleshooting info and remarks do not hesitate to contact GRNET's Helpdesk.{% endblocktrans %}</p>
</p>
</div>
</div> </div>
</div> </div>
......
...@@ -34,6 +34,10 @@ urlpatterns = patterns('', ...@@ -34,6 +34,10 @@ urlpatterns = patterns('',
# Uncomment the next line to enable the admin: # Uncomment the next line to enable the admin:
(r'^fod/admin/', include(admin.site.urls)), (r'^fod/admin/', include(admin.site.urls)),
(r'^tinymce/', include('tinymce.urls')), (r'^tinymce/', include('tinymce.urls')),
url(r'^fod/altlogin/?', 'django.contrib.auth.views.login', {'template_name': 'overview/login.html'}, name="altlogin"),
url(r'^fod/overview/?$', 'flowspy.flowspec.views.overview', name="overview"),
) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment