Initial work on re-themeing auth with Bootstrap CSS

This commit is contained in:
2011-10-27 14:25:25 +01:00
parent d5a291b520
commit 9a26bfd235
14 changed files with 427 additions and 247 deletions

View File

@@ -15,8 +15,16 @@
<h2>Corporations</h2>
<table>
<tr><th>Name</td><th>Members</th><th>Average SP</th><th>API Coverage</th><th>Director Key?</th></tr>
<script src="{{ STATIC_URL }}js/jquery.tablesorter.min.js"></script>
<script >
$(function() {
$("table#corporations").tablesorter({ sortList: [[0,0]] });
});
</script>
<table class="zebra-striped" id="corporations">
<thead>
<tr><th class="header">Name</td><th class="header">Members</th><th class="header">Average SP</th><th class="header">API Coverage</th><th class="header">Director Key?</th></tr>
</thead>
{% for corp in corporations %}
<tr><td><a href="{% url eveapi-corporation corp.id %}">{{ corp }}</a></td><td>{{ corp.member_count }}</td><td>{{ corp.average_sp|intcomma }}</td><td>{{ corp.api_key_coverage|floatformat:2 }}%</td><td>{{ corp.director_api_keys.count }}</td></tr>
{% endfor %}

View File

@@ -4,43 +4,57 @@
{% load naturaltimediff %}
{% block content %}
<div class="character_info">
<h1>{{ character.name }}</h1>
<div class="page-header">
<h1>{{ character.name }}</h1>
</div>
<div class="character_portrait">
<img src="https://image.eveonline.com/Character/{{ character.id }}_256.jpg" />
</div>
<div class="row">
<div class="span8">
<h2>Attributes</h2>
<div class="character_corporation">
<span><a href="{% url eveapi-corporation character.corporation.id %}">{{ character.corporation.ticker }}</a></span>
<img src="https://image.eveonline.com/Corporation/{{ character.corporation.id }}_64.png" />
</div>
{% if character.corporation.alliance %}
<div class="character_alliance">
<span><a href="{% url eveapi-alliance character.corporation.alliance.id %}">{{ character.corporation.alliance.ticker }}</a></span>
<img src="https://image.eveonline.com/Alliance/{{ character.corporation.alliance.id }}_64.png" />
</div>
{% endif %}
<div class="character_attributes">
<h2>Attributes</h2>
<ul>
<li><span class="stat">Race:</span> <span class="value">{{ character.get_race_display }}</span></li>
<li><span class="stat">Gender:</span> <span class="value">{{ character.get_gender_display }}</span></li>
<li><span class="stat">Corporation:</span> <a href="{% url eveapi-corporation character.corporation.id %}">{{ character.corporation.name }}</a></span></li>
<li><span class="stat">Joined Corporation:</span> <span class="value">{{ character.corporation_date|date:"Y/m/d H:i:s" }} ({{ character.corporation_date|naturaltimediff }})</span></li>
<ul>
<li><span class="stat">Race:</span> <span class="value">{{ character.get_race_display }}</span></li>
<li><span class="stat">Gender:</span> <span class="value">{{ character.get_gender_display }}</span></li>
<li><span class="stat">Corporation:</span> <a href="{% url eveapi-corporation character.corporation.id %}">{{ character.corporation.name }}</a></span></li>
<li><span class="stat">Joined Corporation:</span> <span class="value">{{ character.corporation_date|date:"Y/m/d H:i:s" }}</span></li>
{% if character.corporation.alliance %}
<li><span class="stat">Alliance:</span> <span class="value"><a href="{% url eveapi-alliance character.corporation.alliance.id %}">{{ character.corporation.alliance.name }}</a></span></li>
<li><span class="stat">Alliance:</span> <span class="value"><a href="{% url eveapi-alliance character.corporation.alliance.id %}">{{ character.corporation.alliance.name }}</a><span></li>
{% endif %}
<li><span class="stat">Security Status:</span> {{ character.security_status|floatformat:2 }}</span></li>
<li><span class="stat">Director:</span> <span class="value">{{ character.director }}</span></li>
<li><span class="stat">Security Status:</span> {{ character.security_status|floatformat:2 }}</span></li>
<li><span class="stat">Director:</span> <span class="value">{{ character.director }}</span></li>
{% if character.current_training %}
<li><spam class="stat">Training:</span> <span class="Value">{{ character.current_training.skill.name}} to Level {{ character.current_training.in_training }}</li>
<li><spam class="stat">Training:</span> <span class="Value">{{ character.current_training.skill.name}} to Level {{ ch$
{% endif %}
</ul>
</div>
</ul>
</div>
<div class="span5 offset3">
<div class="row pull-right">
<img src="https://image.eveonline.com/Character/{{ character.id }}_256.jpg" />
</div>
<div class="row pull-right">
<div class="span2">
<div class="row">
<span><a href="{% url eveapi-corporation character.corporation.id %}">{{ character.corporation.ticker }}</a></span>
</div>
<div class="row">
<img src="https://image.eveonline.com/Corporation/{{ character.corporation.id }}_64.png" class="pull-right"/>
</div>
</div>
<div class="span2">
{% if character.corporation.alliance %}
<div class="row">
<span><a href="{% url eveapi-alliance character.corporation.alliance.id %}">{{ character.corporation.alliance.ticker }}</a></span>
</div>
<div class="row">
<img src="https://image.eveonline.com/Alliance/{{ character.corporation.alliance.id }}_64.png" class="pull-left"/>
</div>
{% endif %}
</div>
</div>
</div>
</div>
<div class="character_stats">
<h2>Stats</h2>

View File

@@ -2,23 +2,29 @@
{% load humanize %}
{% block content %}
<h1>Character List</h1>
<div class="page-header">
<h1>Your Characters</h1>
</div>
<table>
<tr><th>Character Name</th><th>Corporation</th><th>Alliance</th><th>Skillpoints</th><th>Training</th></tr>
{% for acc in accounts %}
{% if acc.characters.count %}
<tr><th colspan=5>Key {{ acc.pk }} {% if acc.training == 0 %}<font color="#F87217">(No Character Training)</font>{% endif %}</th></tr>
{% for char in acc.characters.all %}
<tr><td><a href="{% url eveapi-character char.id %}">{{ char.name }}</a></td>
<td><a href="{% url eveapi-corporation char.corporation.id %}">{{ char.corporation }}</a></td>
<td>{% if char.corporation.alliance %}<a href="{% url eveapi-alliance char.corporation.alliance.id %}">{{ char.corporation.alliance }}</a>{% endif %}</td>
<td style="text-align: right;">{{ char.total_sp|intcomma }} SP</td>
<td>{% if char.current_training %}{{ char.current_training.skill.name }} to Level {{ char.current_training.in_training }}{% endif %}</td>
</tr>
{% endfor %}
{% endif %}
{% endfor %}
<thead>
<tr><th>Character Name</th><th>Corporation</th><th>Alliance</th><th>Skillpoints</th><th>Training</th></tr>
</thead>
<tbody>
{% for acc in accounts %}
{% if acc.characters.count %}
<tr><th colspan=5>Key {{ acc.pk }} {% if acc.training == 0 %}<font color="#F87217">(No Character Training)</font>{% endif %}</th></tr>
{% for char in acc.characters.all %}
<tr><td><a href="{% url eveapi-character char.id %}">{{ char.name }}</a></td>
<td><a href="{% url eveapi-corporation char.corporation.id %}">{{ char.corporation }}</a></td>
<td>{% if char.corporation.alliance %}<a href="{% url eveapi-alliance char.corporation.alliance.id %}">{{ char.corporation.alliance }}</a>{% endif %}</td>
<td style="text-align: right;">{{ char.total_sp|intcomma }} SP</td>
<td>{% if char.current_training %}{{ char.current_training.skill.name }} to Level {{ char.current_training.in_training }}{% endif %}</td>
</tr>
{% endfor %}
{% endif %}
{% endfor %}
</tbody>
</table>
{% endblock %}

View File

@@ -3,14 +3,30 @@
{% block title %}EVE API Access Logs{% endblock %}
{% block content %}
<h1>Access Logs for API Key {{ userid }}</h1>
<table>
<tr><th>Service ID</th><th>Date / Time</th><th>API</th></tr>
{% for log in logs %}
<tr><td>{{ log.service }}</td>
<td>{{ log.time_access }}</td>
<td>{{ log.document }}</td>
</tr>
{% endfor %}
<div class="page-header">
<h1>Access Logs for API Key {{ userid }}</h1>
</div>
<table class="zebra-striped" id="logs">
<thead>
<tr><th>Service ID</th><th>Date / Time</th><th>API</th></tr>
</thead>
<tbody>
{% for log in logs %}
<tr>
<td>{{ log.service }}</td>
<td>{{ log.time_access }}</td>
<td>{{ log.document }}</td>
</tr>
{% endfor %}
</tbody>
</table>
<script src="/static/js/jquery.tablesorter.min.js"></script>
<script >
$(function() {
$("table#logs").tablesorter({ sortList: [[1,0]] });
});
</script>
{% endblock %}

View File

@@ -2,13 +2,26 @@
{% block content %}
<h1>Groups List</h1>
<div class="page-header">
<h1>Your Groups</h1>
</div>
<p>This is the list of your current groups, and groups you can request to be a member of.</p>
<table>
<script src="{{ STATIC_URL }}js/jquery.tablesorter.min.js"></script>
<script >
$(function() {
$("table#groups").tablesorter({ sortList: [[0,0]] });
});
</script>
<table class="zebra-striped" id="groups">
{% if group_list %}
<thead>
<tr><th>Group Name</th><th>Description</th><th>Status</th><th>Actions</th></tr>
</thead>
<tbody>
{% for id, group, description, status, requestable, fixed, pending, moderated in group_list %}
<tr><td>{{ group }}</td>
<td>{{ description }}</td>
@@ -18,6 +31,7 @@
{% if status == 'Admin' or request.user.is_superuser %}{% if not fixed %}<a href="{% url groups.views.admin_group id %}">Admin</a>{% endif %}{% endif %}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
<b>No groups are available.</b>

View File

@@ -3,14 +3,18 @@
{% block title %}Change your E-mail address{% endblock %}
{% block content %}
<div class="page-header">
<h1>Change Email Address</h1>
</div>
<form action="" method="post">
<table>
{{ form.as_table }}
</table>
<br />
{% csrf_token %}
<input type="submit" value="Change Email" />
<fieldset>
<table>
{{ form.as_table }}
</table>
{% csrf_token %}
<input type="submit" value="Change Email" class="btn"/>
</fieldset>
</form>
{% endblock %}

View File

@@ -8,10 +8,123 @@
{% block content %}
<script type="text/javascript" src="{{ STATIC_URL }}admin/js/jquery.min.js"></script>
<script type="text/javascript">
<script src="{{ STATIC_URL }}bootstrap/js/bootstrap-tabs.js"></script>
<script src="{{ STATIC_URL }}js/jquery.tablesorter.min.js"></script>
function refresh_apikey(key) {
<div class="page-header">
<h1>Your Profile</h1>
</div>
<ul class="tabs">
<li class="active"><a href="#overview">Overview</a></li>
<li><a href="#eveapi">EVE API Keys</a></li>
{% if "reddit"|installed %}
{% ifswitch reddit %}
<li><a href="#reddit">Reddit</a></li>
{% endifswitch %}
{% endif %}
<li><a href="#services">Services</a></li>
</ul>
<div class="pill-content">
<!-- Overview Tab -->
<div class="active" id="overview">
<p>
<b>Username:</b> {{ user.username }}<br/>
<b>Email:</b> {{ user.email }}<br/>
<b>Primary Character:</b> {{ user.get_profile.primary_character }}<br/>
<b>Groups:</b> {{ user.groups.all|join:", " }}<br/>
</p>
<p>
<a href="{% url sso.views.refresh_access %}" class="btn">Update Access</a>
<a href="{% url django.contrib.auth.views.password_change %}" class="btn">Change Password</a>
<a href="{% url sso.views.email_change %}" class="btn">Change E-mail</a>
<a href="{% url sso.views.primarychar_change %}" class="btn">Change Primary Character</a>
</p>
</div>
<!-- Services Tabs -->
<div id="services">
<h2>Auth API Services</h2>
<p>Auth API Servies use Auth for your login information with the use of a seperate password. To reset your services password click the link below</p>
<p><a href="{% url sso.views.set_apipasswd %}" class="btn">Change External Services Password</a></p>
<br/>
{% if user.eveaccount_set.all %}
<h2>Service Accounts</h2>
<p>Services not fully integrated into Auth, and which a seperate username/password is required.</p>
{% if user.serviceaccount_set.all %}
<table>
<tr><th>Service</th><th>Username</th><th>URL</th><th>Active</th><th>Actions</th></tr>
{% for acc in user.serviceaccount_set.all %}
<tr><td>{{ acc.service }}</td>
<td>{{ acc.service_uid }}</td>
<td><a href="{{ acc.service.url }}">{{ acc.service.url }}</a></td>
<td>{% if acc.active %}Yes{% else %}No{% endif %}</td>
<td>
{% if acc.active %}
{% if acc.service.settings.require_password %}<a href="{% url sso.views.service_reset acc.id %}">Reset</a>&nbsp;/&nbsp;{% endif %}
<a href="{% url sso.views.service_del acc.id %}">Delete</a>
{% if acc.service.provide_login %}
&nbsp;/&nbsp;<a href="{% url sso.views.service_login acc.id %}">Login</a>
{% endif %}
{% endif %}
</td>
</tr>
{% endfor %}
</table>
{% endif %}
<p>
<a href="{% url sso.views.service_add %}" class="btn">Add Service</a>
</p>
{% endif %}
</div>
<!-- EVE API Tab -->
<div id="eveapi">
<h2>Eve API Keys</h2>
<p>Adding an Eve API key will allow you to access any services allowed for your
corporation. Limited keys are accepted for service validation. API keys
are stored for on-going authentication. As the assigned owner of a key you may
remove them at any time, but this may affect any existing services you have
setup.</p>
{% if user.eveaccount_set.all %}
<table id="eveapikeys">
<thead>
<tr><th>User ID</th><th>API Key</th><th>Description</th><th>Type</th><th>Active</th><th>Last Updated</th><th>Actions</th></tr>
</thead>
<tbody>
{% for acc in user.eveaccount_set.all %}
<tr {% if acc.api_keytype == 4 %}style="background-color: #cccccc; color: gray;"{% endif %}>
<td>{{ acc.api_user_id }}</td>
<td>{{ acc.api_key|slice:":10" }}&#8230;</td>
<td>{{ acc.description }}</td>
<td>{{ acc.get_api_keytype_display }}{% if acc.api_keytype == 4 %}&nbsp;<b><sup style="color: red;">*</sup></b>{% endif %}</td>
<td id="api-status-{{ acc.api_user_id }}">{{ acc.get_api_status_display }}</td>
<td id="api-time-{{ acc.api_user_id }}">{{ acc.api_last_updated|naturaltimediff }}</td>
<td>{% ifswitch api-disableprocessing %}{% else %}<a href="{% url eve_api.views.eveapi_refresh acc.api_user_id %}" onclick="javascript:refresh_apikey({{ acc.api_user_id }}); return false;">Refresh</a>,&nbsp;
<a href="{% url eve_api.views.eveapi_update acc.api_user_id %}">Update Key</a>,&nbsp;{% endifswitch %}
<a href="{% url eve_api.views.eveapi_log acc.api_user_id %}">Logs</a>{% ifswitch eve-keydelete %},&nbsp;
<a href="{% url eve_api.views.eveapi_del acc.api_user_id %}">Delete</a>{% endifswitch %}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endif %}
<p><span class="label important">Warning</span> Character API Keys are not included in any authorization checks, you will not be able to submit applications or access any services with them.</p>
<p>
{% ifswitch api-disableprocessing %}
{% else %}
<a href="{% url eve_api.views.eveapi_add %}" class="btn">Add a Eve API key</a>
{% endifswitch %}
</p>
<script type="text/javascript">
function refresh_apikey(key) {
$("#api-status-" + key).html("<center><img src='{{ STATIC_URL }}img/spinner.gif'/></center>");
$("#api-time-" + key).html("<center><img src='{{ STATIC_URL }}img/spinner.gif'/></center>");
$.getJSON("/eve/eveapi/refresh/" + key + "/", function(json) {
@@ -35,123 +148,53 @@ function refresh_apikey(key) {
break;
}
});
}
</script>
<h1>Your Profile</h1>
<p>
<b>Username:</b> {{ user.username }}<br/>
<b>Email:</b> {{ user.email }}<br/>
<b>Primary Character:</b> {{ user.get_profile.primary_character }}<br/>
<b>Groups:</b> {{ user.groups.all|join:", " }}<br/>
</p>
<p>
<a href="{% url sso.views.refresh_access %}" class="button">Update Access</a>
<a href="{% url django.contrib.auth.views.password_change %}" class="button">Change Password</a>
<a href="{% url sso.views.email_change %}" class="button">Change E-mail</a>
<a href="{% url sso.views.primarychar_change %}" class="button">Change Primary Character</a>
</p>
<br/>
<h2>Auth API Services</h2>
<p>Auth API Servies use Auth for your login information with the use of a seperate password. To reset your services password click the link below</p>
<p><a href="{% url sso.views.set_apipasswd %}" class="button">Change External Services Password</a></p>
<br/>
{% if user.eveaccount_set.all %}
<h2>Service Accounts</h2>
<p>Services not fully integrated into Auth, and which a seperate username/password is required.</p>
{% if user.serviceaccount_set.all %}
<table>
<tr><th>Service</th><th>Username</th><th>URL</th><th>Active</th><th>Actions</th></tr>
{% for acc in user.serviceaccount_set.all %}
<tr><td>{{ acc.service }}</td>
<td>{{ acc.service_uid }}</td>
<td><a href="{{ acc.service.url }}">{{ acc.service.url }}</a></td>
<td>{% if acc.active %}Yes{% else %}No{% endif %}</td>
<td>
{% if acc.active %}
{% if acc.service.settings.require_password %}<a href="{% url sso.views.service_reset acc.id %}">Reset</a>&nbsp;/&nbsp;{% endif %}
<a href="{% url sso.views.service_del acc.id %}">Delete</a>
{% if acc.service.provide_login %}
&nbsp;/&nbsp;<a href="{% url sso.views.service_login acc.id %}">Login</a>
{% endif %}
{% endif %}
</td>
</tr>
{% endfor %}
</table>
{% endif %}
<p>
<a href="{% url sso.views.service_add %}" class="button">Add Service</a>
</p>
<br/>
{% endif %}
<h2>Eve API Keys</h2>
<p>Adding an Eve API key will allow you to access any services allowed for your
corporation. Limited keys are accepted for service validation. API keys
are stored for on-going authentication. As the assigned owner of a key you may
remove them at any time, but this may affect any existing services you have
setup.</p>
{% if user.eveaccount_set.all %}
<table>
<tr><th>User ID</th><th>API Key</th><th>Description</th><th>Type</th><th>Active</th><th>Last Updated</th><th>Actions</th></tr>
{% for acc in user.eveaccount_set.all %}
<tr {% if acc.api_keytype == 4 %}style="background-color: #cccccc; color: gray;"{% endif %}><td>{{ acc.api_user_id }}</td>
<td>{{ acc.api_key }}</td>
<td>{{ acc.description }}</td>
<td>{{ acc.get_api_keytype_display }}{% if acc.api_keytype == 4 %}&nbsp;<b><sup style="color: red;">*</sup></b>{% endif %}</td>
<td id="api-status-{{ acc.api_user_id }}">{{ acc.get_api_status_display }}</td>
<td id="api-time-{{ acc.api_user_id }}">{{ acc.api_last_updated|naturaltimediff }}</td>
<td>{% ifswitch api-disableprocessing %}{% else %}<a href="{% url eve_api.views.eveapi_refresh acc.api_user_id %}" onclick="javascript:refresh_apikey({{ acc.api_user_id }}); return false;">Refresh</a>,&nbsp;
<a href="{% url eve_api.views.eveapi_update acc.api_user_id %}">Update Key</a>,&nbsp;{% endifswitch %}
<a href="{% url eve_api.views.eveapi_log acc.api_user_id %}">Logs</a>{% ifswitch eve-keydelete %},&nbsp;
<a href="{% url eve_api.views.eveapi_del acc.api_user_id %}">Delete</a>{% endifswitch %}
</tr>
{% endfor %}
</table>
{% endif %}
<p><b style="color: red;">*</b> - Character API Keys are not included in any authorization checks, you will not be able to submit applications or access any services with them.</p>
<p>
{% ifswitch api-disableprocessing %}
{% else %}
<a href="{% url eve_api.views.eveapi_add %}" class="button">Add a Eve API key</a>
{% endifswitch %}
</p>
<br/>
}
</script>
</div>
{% if "reddit"|installed %}
{% ifswitch reddit %}
<h2>Reddit Accounts</h2>
<p>This is a list of all your current linked Reddit accounts</p>
{% if user.redditaccount_set.all %}
<p>To validate your Reddit account, login on Reddit then click the link next to the account, fill in some text in the message and click send.</p>
<table>
<tr><th>Username</th><th>Created Date</th><th>Validated</th></tr>
{% for acc in user.redditaccount_set.all %}
<tr><td>{{ acc.username }}</td>
<td>{{ acc.date_created }}</td>
<td>{% if acc.validated %}Yes{% else %}No (<a href="http://www.reddit.com/message/compose/?to=DredditVerification&subject=Validation%3a%20{{user.username}}" target="_blank">Validate</a>){% endif %}</td>
</tr>
{% endfor %}
</table>
{% endif %}
<p>
<a href="{% url reddit-addaccount %}" class="button">Add a Reddit account</a>
</p>
<p>
Reddit account tagging is {% if user.get_profile.tag_reddit_accounts %}Enabled{% else %}Disabled{% endif %}. <a href="{% url sso.views.toggle_reddit_tagging %}">{% if user.get_profile.tag_reddit_accounts %}Disable{% else %}Enable{% endif %}</a>
<!-- Reddit Tab -->
<div id="reddit">
<h2>Reddit Accounts</h2>
<p>This is a list of all your current linked Reddit accounts</p>
{% if user.redditaccount_set.all %}
<p>To validate your Reddit account, login on Reddit then click the link next to the account, fill in some text in the message and click send.</p>
<table>
<thead>
<tr><th>Username</th><th>Created Date</th><th>Validated</th></tr>
</thead>
<tbody>
{% for acc in user.redditaccount_set.all %}
<tr>
<td>{{ acc.username }}</td>
<td>{{ acc.date_created }}</td>
<td>{% if acc.validated %}Yes{% else %}No (<a href="http://www.reddit.com/message/compose/?to=DredditVerification&subject=Validation%3a%20{{user.username}}" target="_blank">Validate</a>){% endif %}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% endif %}
<p>
<a href="{% url reddit-addaccount %}" class="btn">Add a Reddit account</a>
</p>
<p>Reddit account tagging is {% if user.get_profile.tag_reddit_accounts %}Enabled{% else %}Disabled{% endif %}. <a href="{% url sso.views.toggle_reddit_tagging %}">{% if user.get_profile.tag_reddit_accounts %}Disable{% else %}Enable{% endif %}</a></p>
</div>
{% endifswitch %}
{% endif %}
</div>
<script>
$(function () {
$('.tabs').tabs()
})
$(function() {
$("table#eveapikeys").tablesorter({ sortList: [[0,0]] });
});
</script>
{% endblock %}

View File

@@ -1,31 +1,64 @@
{% load installed %}
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html lang="en">
<head>
<title>TEST Auth</title>
<link rel="stylesheet" href="{{ STATIC_URL }}css/style.css" type="text/css" media="screen">
<link rel="stylesheet" href="{{ STATIC_URL }}bootstrap/bootstrap.css" type="text/css" media="screen">
<style type="text/css">
html {
background-color: #9FB190;
}
body {
background-color: #9FB190;
padding-top: 40px;
}
div.topbar div.fill {
background-color: #5F6757;
background-image: -khtml-gradient(linear, left top, left bottom, from(#333333), to(#5F6757));
background-image: -moz-linear-gradient(top, #333333, #5F6757);
background-image: -ms-linear-gradient(top, #333333, #5F6757);
background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #333333), color-stop(100%, #5F6757));
background-image: -webkit-linear-gradient(top, #333333, #5F6757);
background-image: -o-linear-gradient(top, #333333, #5F6757);
background-image: linear-gradient(top, #333333, #5F6757);
}
div.content {
background-color: white;
padding: 20px;
margin: 0 -20px;
-webkit-border-radius: 0 0 6px 6px;
-moz-border-radius: 0 0 6px 6px;
border-radius: 0 0 6px 6px;
-webkit-box-shadow: 0 1px 2px rgba(0,0,0,.15);
-moz-box-shadow: 0 1px 2px rgba(0,0,0,.15);
box-shadow: 0 1px 2px rgba(0,0,0,.15);
}
</style>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
<script src="{{ STATIC_URL }}bootstrap/js/bootstrap-dropdown.js"></script>
<script src="{{ STATIC_URL }}bootstrap/js/bootstrap-alerts.js"></script>
{% block HeadTag %}{% endblock %}
</head>
<body>
<div id="container">
<div id="header">
<!--<h1>TEST Auth - {% block title %}{% endblock %}</h1>-->
</div>
<div id="navigation">
<ul>
<div class="topbar">
<div class="fill">
<div class="container">
<a class="brand" href="/">TEST Auth</a>
<ul class="nav">
{% if request.user.is_authenticated %}
<li><a href="{% url sso.views.profile %}">Profile</a></li>
{% if "groups"|installed %}
<li><a href="{% url groups.views.group_list %}">Groups</a></li>
{% endif %}
{% if "api"|installed %}
<li><a href="{% url oauth-list-tokens %}">Application Access</a></li>
{% endif %}
<li class="dropdown" data-dropdown="dropdown"><a href="#" class="dropdown-toggle">{{ request.user.username}}</a>
<ul class="dropdown-menu">
<li><a href="{% url sso.views.profile %}">Your Profile</a></li>
{% if "groups"|installed %}<li><a href="{% url groups.views.group_list %}"> Your Groups</a></li>{% endif %}
<li><a href="{% url eve_api.views.eveapi_character %}">Your Characters</a></li>
<li class="divider"></li>
{% if "api"|installed %}<li><a href="{% url oauth-list-tokens %}">3rd Party App Access</a></li>{% endif %}
</ul>
</li>
{% if "hr"|installed %}
<li><a href="{% url hr-index %}">HR</a></li>
{% endif %}
<li><a href="{% url eve_api.views.eveapi_character %}">Characters</a></li>
{% if perms.sso.can_search_users %}
<li><a href="{% url sso.views.user_lookup %}">Lookup User</a></li>
{% endif %}
@@ -39,19 +72,26 @@
{% else %}
<li><a href="{% url django.contrib.auth.views.login %}">Login</a></li>
{% endif %}
</ul>
</div>
<div id="content">
{% if messages %}
<ul id="messagelist">
{% for message in messages %}
<li>{{ message }}</li>
{% endfor %}
</ul>
{% endif %}
{% block content %}{% endblock %}
</div>
</div>
</ul>
</div>
</div>
</div>
<div class="container">
<div class="content">
{% if messages %}
{% for message in messages %}
<div class="alert-message fade in {{ message.tags }}" data-alert="alert">
<a class="close" href="#">x</a>
<p>{{ message }}</p>
</div>
{% endfor %}
{% endif %}
{% block content %}{% endblock %}
</div>
</div>
</body>
</html>

View File

@@ -3,20 +3,23 @@
{% block title %}OAuth Access Authorization{% endblock %}
{% block content %}
<div class="page-header">
<h1>Access Authorization</h1>
</div>
<h1>Access Authorization</h1>
<p>You have come here because you are in the process of allowing a external application to access your private Auth data. If you are not, then please close this window. Otherwise, please confirm below if you wish to give access to your private Auth data. This can be revoked at any time from the main Auth panel.</p>
<p>You have come here because you are in the process of allowing a external application to access your private Auth data. If you are not, then please close this window. Otherwise, please confirm below if you wish to give access to your private Auth data. This can be revoked at any time from the main Auth panel.</p>
<p><b>{{ consumer.name }}</b></p>
<p>{{ consumer.description }}</p>
<p><b>{{ consumer.name }}</b></p>
<p>{{ consumer.description }}</p>
<form action="{% url piston.authentication.oauth_user_auth %}" method="POST">
<table>
<form action="{% url piston.authentication.oauth_user_auth %}" method="POST">
<fieldset>
<table>
{{ form.as_table }}
</table>
{% csrf_token %}
<button type="submit">Confirm</button>
</form>
</table>
{% csrf_token %}
<button type="submit">Confirm</button>
</fieldset>
</form>
{% endblock %}

View File

@@ -4,10 +4,12 @@
{% block content %}
<h1>Access Authorization</h1>
<div class="page-header">
<h1>Access Authorization</h1>
</div>
<p>Access is now enabled for the requesting application. It seems the application did not provide a way to give it the required information so you need to provide this to it. This has happened either due to it being a desktop application or not being configured properly.</p>
<p>Access is now enabled for the requesting application. It seems the application did not provide a way to give it the required information so you need to provide this to it. This has happened either due to it being a desktop application or not being configured properly.</p>
<p>Token/PIN: <b>{{ token.verifier }}</td></p>
<p>Token/PIN: <b>{{ token.verifier }}</td></p>
{% endblock %}

View File

@@ -1,7 +1,12 @@
{% extends "registration/registration_base.html" %}
{% block title %}{% if account %}Activation complete{% else %}Activation problem{% endif %}{% endblock %}
{% block content %}
{% if account %}
<div class="page-header">
<h1>Account Activation</h1>
</div>
<p>Thanks {{ account }}, activation complete! You may now <a href='{% url auth_login %}'>login</a> using the username and password you set at registration.</p>
{% else %}
<p>Oops &ndash; it seems that your activation key is invalid. Please check the url again.</p>

View File

@@ -3,25 +3,40 @@
{% block content %}
{% if form.errors %}
<p>Your username and password didn't match. Please try again.</p>
<div class="alert-message fade in error" data-alert="alert">
<a class="close" href="#">x</a>
<p>Your username or password was incorrect, please try again.</p>
</div>
{% endif %}
<form method="post" action="{% url django.contrib.auth.views.login %}">
<table>
<tr>
<td>{{ form.username.label_tag }}</td>
<td>{{ form.username }}</td>
</tr>
<tr>
<td>{{ form.password.label_tag }}</td>
<td>{{ form.password }}</td>
</tr>
</table>
<p><a href="{% url auth_password_reset %}">Forgot</a> your password? <a href="{% url registration_register %}">Need an account</a>?</p>
<fieldset>
<legend>Login</legend>
<div class="clearfix">
{{ form.username.label_tag }}
<div class="input">
<td>{{ form.username }}</td>
</div>
</div>
<div class="clearfix">
{{ form.password.label_tag }}
<div class="input">
<td>{{ form.password }}</td>
</div>
</div>
<input type="submit" value="login" />
<input type="hidden" name="next" value="{{ next }}" />
{% csrf_token %}
<div class="row">
<div class="span10">
<a href="{% url auth_password_reset %}" class="btn">Forgotten Password</a>
<a href="{% url registration_register %}" class="btn success">Create Account</a>
</div>
<div class="span6">
<input type="submit" value="Login" class="btn primary pull-right"/>
</div>
</div>
<input type="hidden" name="next" value="{{ next }}" />
{% csrf_token %}
</fieldset>
</form>
{% endblock %}

View File

@@ -1,5 +1,8 @@
{% extends "registration/registration_base.html" %}
{% block title %}Logged out{% endblock %}
{% block HeadTag %}
<meta http-equiv="refresh" content="3; url=/">
{% endblock %}
{% block content %}
<p>Successfully logged out!</p>
{% endblock %}

View File

@@ -1,15 +1,22 @@
{% extends "registration/registration_base.html" %}
{% block title %}Register for an account{% endblock %}
{% block content %}
<h3>Registration</h3>
<div class="page-header">
<h1>Registration</h1>
</div>
<p>Please complete this form to register for a new Auth account, please be aware that you are required to confirm your email account so please use a valid address.</p>
<h3>Problematic Providers</h3>
<h2>Problematic Providers</h2>
<p>In addition, some providers maybe blocked form auth due to their draconian spam detection routines, which has flagged this server numerous times for no reason. These include AT&T services, Cox, and a few other mainland US ISPs. If you have a Google Mail account please consider using that instead of your ISP email account.</p>
<form method='post' action=''>
<table>
{{ form }}
</table>
{% csrf_token %}
<input type="submit" value="Send activation email" />
<table>
{{ form }}
</table>
{% csrf_token %}
<input type="submit" value="Send activation email" class="btn primary"/>
</form>
{% endblock %}