mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2026-02-04 14:16:21 +01:00
Compare commits
16 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2741a92d31 | ||
|
|
d809902d1e | ||
|
|
ec4232c00a | ||
|
|
dec793bfac | ||
|
|
fe3fe0527a | ||
|
|
a8855e86ed | ||
|
|
179d1c38e6 | ||
|
|
287da73a4f | ||
|
|
e9ed917888 | ||
|
|
70d842c971 | ||
|
|
bcda228e05 | ||
|
|
000dafc5e6 | ||
|
|
4ea824fe71 | ||
|
|
f72f539516 | ||
|
|
1b192a184f | ||
|
|
0edf896b4c |
4
.gitignore
vendored
4
.gitignore
vendored
@@ -62,5 +62,7 @@ celerybeat-schedule
|
||||
|
||||
#pycharm
|
||||
.idea/*
|
||||
|
||||
/nbproject/
|
||||
|
||||
#gitlab configs
|
||||
.gitlab/
|
||||
|
||||
@@ -25,14 +25,6 @@
|
||||
|
||||
coverage: '/TOTAL.+ ([0-9]{1,3}%)/'
|
||||
|
||||
|
||||
py36-dj111:
|
||||
<<: *job_definition
|
||||
image: python:3.6-stretch
|
||||
script:
|
||||
- export TOXENV=py36-dj111
|
||||
- tox
|
||||
|
||||
py36-dj20:
|
||||
<<: *job_definition
|
||||
image: python:3.6-stretch
|
||||
|
||||
14
.gitlab/issue_templates/Bug.md
Normal file
14
.gitlab/issue_templates/Bug.md
Normal file
@@ -0,0 +1,14 @@
|
||||
# Bug
|
||||
|
||||
- I have searched [issues](https://gitlab.com/allianceauth/allianceauth/issues?scope=all&utf8=%E2%9C%93&state=all) (Y/N):
|
||||
- What Version of Alliance Auth:
|
||||
- What Operating System:
|
||||
- Version of other components relevant to issue eg. Service, Database:
|
||||
|
||||
Please include a brief description of your issue here.
|
||||
|
||||
Please include steps to reproduce the issue
|
||||
|
||||
Please include any tracebacks or logs
|
||||
|
||||
Please include the results of the command `pip list`
|
||||
7
.gitlab/issue_templates/Feature Request.md
Normal file
7
.gitlab/issue_templates/Feature Request.md
Normal file
@@ -0,0 +1,7 @@
|
||||
# Feature Request
|
||||
|
||||
- Describe the feature are you requesting.
|
||||
|
||||
- Is this a Service (external integration), a Module (Alliance Auth extension) or an enhancement to an existing service/module.
|
||||
|
||||
- Describe why its useful to you or others.
|
||||
@@ -1,6 +1,6 @@
|
||||
# This will make sure the app is always imported when
|
||||
# Django starts so that shared_task will use this app.
|
||||
|
||||
__version__ = '2.1.1'
|
||||
__version__ = '2.2.0'
|
||||
NAME = 'Alliance Auth v%s' % __version__
|
||||
default_app_config = 'allianceauth.apps.AllianceAuthConfig'
|
||||
|
||||
@@ -27,7 +27,7 @@ class StateBackend(ModelBackend):
|
||||
user_obj._perm_cache.update(self.get_state_permissions(user_obj))
|
||||
return user_obj._perm_cache
|
||||
|
||||
def authenticate(self, token=None):
|
||||
def authenticate(self, request=None, token=None, **credentials):
|
||||
if not token:
|
||||
return None
|
||||
try:
|
||||
|
||||
@@ -119,7 +119,7 @@ class BackendTestCase(TestCase):
|
||||
def test_authenticate_character_record(self):
|
||||
t = Token(character_id=self.unclaimed_character.character_id, character_name=self.unclaimed_character.character_name, character_owner_hash='4')
|
||||
record = OwnershipRecord.objects.create(user=self.old_user, character=self.unclaimed_character, owner_hash='4')
|
||||
user = StateBackend().authenticate(t)
|
||||
user = StateBackend().authenticate(token=t)
|
||||
self.assertEqual(user, self.old_user)
|
||||
self.assertTrue(CharacterOwnership.objects.filter(owner_hash='4', user=self.old_user).exists())
|
||||
self.assertTrue(user.profile.main_character)
|
||||
|
||||
@@ -1,254 +1,254 @@
|
||||
{% extends "allianceauth/base.html" %}
|
||||
{% load bootstrap %}
|
||||
{% load staticfiles %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_title %}FleetUp{% endblock page_title %}
|
||||
|
||||
{% block content %}
|
||||
<div class="col-lg-12">
|
||||
{% include "fleetup/menu.html" %}
|
||||
<div>
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a data-toggle="tab" href="#operations">{% trans "Operations" %}</a></li>
|
||||
<li><a data-toggle="tab" href="#timers">{% trans "Timers" %}</a></li>
|
||||
</ul>
|
||||
|
||||
<div class="tab-content row">
|
||||
<div id="operations" class="tab-pane fade in active">
|
||||
<div class="col-lg-8">
|
||||
{% if operations_list %}
|
||||
{% for subject, start in operations_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title"><b>{{ start.subject }}</b></h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="table table-condensed">
|
||||
<tr>
|
||||
<th class="col-md-6">{% trans "Start" %}</th>
|
||||
<th class="col-md-6">{% trans "End" %}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="col-md-6">{{ start.start|date:"l d M H:i" }} <span class="label label-success">{% trans "Eve Time" %}</span></td>
|
||||
|
||||
<td class="col-md-6">{{ start.end|date:"l d M H:i" }} <span class="label label-success">{% trans "Eve Time" %}</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="col-md-6">
|
||||
<span id="localtime{{ start.operation_id }}"></span> <span class='label label-success'>Local time</span><br>
|
||||
<div id="countdown{{ start.operation_id }}"></div>
|
||||
</td>
|
||||
|
||||
<td class="col-md-6"></td>
|
||||
</tr>
|
||||
</table>
|
||||
{{ start.details|linebreaks }}
|
||||
|
||||
<table class="table table-condensed table-striped">
|
||||
<tr>
|
||||
<th class="col-md-4">{% trans "Location" %}</th>
|
||||
<th class="col-md-4">{% trans "Doctrine" %}</th>
|
||||
<th class="col-md-2">{% trans "Organizer" %}</th>
|
||||
<th class="col-md-2">{% trans "URL" %}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{ start.location }} - {{ start.location_info }} <a href="http://evemaps.dotlan.net/system/{{ start.location }}" target="_blank" class="label label-success">Dotlan</a>
|
||||
</td>
|
||||
<td>
|
||||
{% if start.doctrine %}
|
||||
{% for doctrine in start.doctrine %}
|
||||
|
||||
<a href="{% url 'fleetup:doctrine' doctrine.Id %}" class="label label-success">{{ doctrine.Name }}</a>
|
||||
|
||||
{% endfor %}
|
||||
|
||||
{% else %}
|
||||
<span class="label label-danger">{% trans "TBA" %}</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
{{ start.organizer }}
|
||||
</td>
|
||||
<td>
|
||||
{% ifequal start.url "" %}
|
||||
<div class="label label-danger">{% trans "No link" %}</div>
|
||||
{% else %}
|
||||
<a href="{{ start.url }}" target="_blank" class="label label-success">{% trans "External link" %}</a>
|
||||
{% endifequal %}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<h3>{% trans "There seems to be no Operations in the near future." %}</h3>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Current Eve Time:" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div id="current-time"></div>
|
||||
</div>
|
||||
</div>
|
||||
{% if timers_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Timers" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="table table-condensed table-hover table-striped">
|
||||
{% for notes, type in timers_list %}
|
||||
<tr>
|
||||
<td>
|
||||
{{ type.solarsystem }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.expires|date:"l d M H:i" }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div id="timers" class="tab-pane fade in">
|
||||
<div class="col-lg-12">
|
||||
{% if timers_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Timers" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="col-lg-12">
|
||||
<table class="table table-condensed table-hover table-striped">
|
||||
<tr>
|
||||
<th class="col-lg-1">{% trans "Type" %}</th>
|
||||
<th class="col-lg-1">{% trans "Structure" %}</th>
|
||||
<th class="col-lg-2">{% trans "Location" %}</th>
|
||||
<th class="col-lg-2">{% trans "Expires(EVE-time)" %}</th>
|
||||
<th class="col-lg-1">{% trans "Owner" %}</th>
|
||||
<th class="col-lg-2">{% trans "Note" %}</th>
|
||||
</tr>
|
||||
{% for notes, type in timers_list %}
|
||||
<tr>
|
||||
<td>
|
||||
{% ifequal type.type "Final" %}
|
||||
<span class="label label-danger">
|
||||
{{ type.type }}</span>{% else %}{{ type.type }}{% endifequal %}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.timer_type }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.solarsystem }} - Planet:{{ type.planet }} Moon:{{ type.moon }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.expires|date:"l d M H:i" }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.owner }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.notes }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
<h3>{% trans "There seems to be no Timers in the near future." %}</h3>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{% include 'bundles/moment-js.html' with locale=True %}
|
||||
<script src="{% static 'js/timers.js' %}"></script>
|
||||
<script type="text/javascript">
|
||||
// Data
|
||||
var timers = [
|
||||
{% for start, op in operations_list %}
|
||||
{
|
||||
'id': {{ op.operation_id }},
|
||||
'start': moment("{{ op.start | date:"c" }}"),
|
||||
'end': moment("{{ op.end | date:"c" }}"),
|
||||
'expired': false
|
||||
},
|
||||
{% endfor %}
|
||||
]
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
|
||||
timedUpdate();
|
||||
setAllLocalTimes();
|
||||
|
||||
// Start timed updates
|
||||
setInterval(timedUpdate, 1000);
|
||||
|
||||
function timedUpdate() {
|
||||
updateClock();
|
||||
updateAllTimers();
|
||||
}
|
||||
|
||||
function updateAllTimers () {
|
||||
var l = timers.length;
|
||||
for (var i=0; i < l; ++i) {
|
||||
if (timers[i].expired) continue;
|
||||
updateTimer(timers[i]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Update a timer
|
||||
* @param timer Timer information
|
||||
* @param timer.start Date of the timer
|
||||
* @param timer.id Id number of the timer
|
||||
* @param timer.expired
|
||||
*/
|
||||
function updateTimer(timer) {
|
||||
if (timer.start.isAfter(Date.now())) {
|
||||
var duration = moment.duration(timer.start - moment(), 'milliseconds');
|
||||
document.getElementById("countdown" + timer.id).innerHTML = getDurationString(duration);
|
||||
} else {
|
||||
timer.expired = true;
|
||||
document.getElementById("countdown" + timer.id).innerHTML = "";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set all local time fields
|
||||
*/
|
||||
function setAllLocalTimes() {
|
||||
var l = timers.length;
|
||||
for (var i=0; i < l; ++i) {
|
||||
setLocalTime(timers[i]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the local time info for the timer
|
||||
* @param timer Timer information
|
||||
* @param timer.start Date of the timer
|
||||
* @param timer.id Id number of the timer
|
||||
*/
|
||||
function setLocalTime(timer) {
|
||||
document.getElementById("localtime" + timer.id).innerHTML = timer.start.format("ddd @ LT");
|
||||
}
|
||||
|
||||
function updateClock() {
|
||||
document.getElementById("current-time").innerHTML = "<b>" + moment.utc().format('ddd, ll HH:mm:ss z') + "</b>";
|
||||
}
|
||||
</script>
|
||||
{% endblock content %}
|
||||
{% extends "allianceauth/base.html" %}
|
||||
{% load bootstrap %}
|
||||
{% load staticfiles %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_title %}FleetUp{% endblock page_title %}
|
||||
|
||||
{% block content %}
|
||||
<div class="col-lg-12">
|
||||
{% include "fleetup/menu.html" %}
|
||||
<div>
|
||||
<ul class="nav nav-tabs">
|
||||
<li class="active"><a data-toggle="tab" href="#operations">{% trans "Operations" %}</a></li>
|
||||
<li><a data-toggle="tab" href="#timers">{% trans "Timers" %}</a></li>
|
||||
</ul>
|
||||
|
||||
<div class="tab-content row">
|
||||
<div id="operations" class="tab-pane fade in active">
|
||||
<div class="col-lg-8">
|
||||
{% if operations_list %}
|
||||
{% for subject, start in operations_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title"><b>{{ start.subject }}</b></h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="table table-condensed">
|
||||
<tr>
|
||||
<th class="col-md-6">{% trans "Start" %}</th>
|
||||
<th class="col-md-6">{% trans "End" %}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="col-md-6">{{ start.start|date:"l d M H:i" }} <span class="label label-success">{% trans "Eve Time" %}</span></td>
|
||||
|
||||
<td class="col-md-6">{{ start.end|date:"l d M H:i" }} <span class="label label-success">{% trans "Eve Time" %}</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="col-md-6">
|
||||
<span id="localtime{{ start.operation_id }}"></span> <span class='label label-success'>Local time</span><br>
|
||||
<div id="countdown{{ start.operation_id }}"></div>
|
||||
</td>
|
||||
|
||||
<td class="col-md-6"></td>
|
||||
</tr>
|
||||
</table>
|
||||
{{ start.details|linebreaks }}
|
||||
|
||||
<table class="table table-condensed table-striped">
|
||||
<tr>
|
||||
<th class="col-md-4">{% trans "Location" %}</th>
|
||||
<th class="col-md-4">{% trans "Doctrine" %}</th>
|
||||
<th class="col-md-2">{% trans "Organizer" %}</th>
|
||||
<th class="col-md-2">{% trans "URL" %}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
{{ start.location }} - {{ start.location_info }} <a href="http://evemaps.dotlan.net/system/{{ start.location }}" target="_blank" class="label label-success">Dotlan</a>
|
||||
</td>
|
||||
<td>
|
||||
{% if start.doctrine %}
|
||||
{% for doctrine in start.doctrine %}
|
||||
|
||||
<a href="{% url 'fleetup:doctrine' doctrine.Id %}" class="label label-success">{{ doctrine.Name }}</a>
|
||||
|
||||
{% endfor %}
|
||||
|
||||
{% else %}
|
||||
<span class="label label-danger">{% trans "TBA" %}</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
{{ start.organizer }}
|
||||
</td>
|
||||
<td>
|
||||
{% ifequal start.url "" %}
|
||||
<div class="label label-danger">{% trans "No link" %}</div>
|
||||
{% else %}
|
||||
<a href="{{ start.url }}" target="_blank" class="label label-success">{% trans "External link" %}</a>
|
||||
{% endifequal %}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<h3>{% trans "There seems to be no Operations in the near future." %}</h3>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Current Eve Time:" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div id="current-time"></div>
|
||||
</div>
|
||||
</div>
|
||||
{% if timers_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Timers" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<table class="table table-condensed table-hover table-striped">
|
||||
{% for notes, type in timers_list %}
|
||||
<tr>
|
||||
<td>
|
||||
{{ type.solarsystem }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.expires|date:"l d M H:i" }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div id="timers" class="tab-pane fade in">
|
||||
<div class="col-lg-12">
|
||||
{% if timers_list %}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h2 class="panel-title">{% trans "Timers" %}</h2>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="col-lg-12">
|
||||
<table class="table table-condensed table-hover table-striped">
|
||||
<tr>
|
||||
<th class="col-lg-1">{% trans "Type" %}</th>
|
||||
<th class="col-lg-1">{% trans "Structure" %}</th>
|
||||
<th class="col-lg-2">{% trans "Location" %}</th>
|
||||
<th class="col-lg-2">{% trans "Expires(EVE-time)" %}</th>
|
||||
<th class="col-lg-1">{% trans "Owner" %}</th>
|
||||
<th class="col-lg-2">{% trans "Note" %}</th>
|
||||
</tr>
|
||||
{% for notes, type in timers_list %}
|
||||
<tr>
|
||||
<td>
|
||||
{% ifequal type.type "Final" %}
|
||||
<span class="label label-danger">
|
||||
{{ type.type }}</span>{% else %}{{ type.type }}{% endifequal %}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.timer_type }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.solarsystem }} - Planet:{{ type.planet }} Moon:{{ type.moon }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.expires|date:"l d M H:i" }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.owner }}
|
||||
</td>
|
||||
<td>
|
||||
{{ type.notes }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
<h3>{% trans "There seems to be no Timers in the near future." %}</h3>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
{% include 'bundles/moment-js.html' with locale=True %}
|
||||
<script src="{% static 'js/timers.js' %}"></script>
|
||||
<script type="text/javascript">
|
||||
// Data
|
||||
var timers = [
|
||||
{% for start, op in operations_list %}
|
||||
{
|
||||
'id': {{ op.operation_id }},
|
||||
'start': moment("{{ op.start | date:"c" }}"),
|
||||
'end': moment("{{ op.end | date:"c" }}"),
|
||||
'expired': false
|
||||
},
|
||||
{% endfor %}
|
||||
]
|
||||
</script>
|
||||
<script type="text/javascript">
|
||||
|
||||
timedUpdate();
|
||||
setAllLocalTimes();
|
||||
|
||||
// Start timed updates
|
||||
setInterval(timedUpdate, 1000);
|
||||
|
||||
function timedUpdate() {
|
||||
updateClock();
|
||||
updateAllTimers();
|
||||
}
|
||||
|
||||
function updateAllTimers () {
|
||||
var l = timers.length;
|
||||
for (var i=0; i < l; ++i) {
|
||||
if (timers[i].expired) continue;
|
||||
updateTimer(timers[i]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Update a timer
|
||||
* @param timer Timer information
|
||||
* @param timer.start Date of the timer
|
||||
* @param timer.id Id number of the timer
|
||||
* @param timer.expired
|
||||
*/
|
||||
function updateTimer(timer) {
|
||||
if (timer.start.isAfter(Date.now())) {
|
||||
var duration = moment.duration(timer.start - moment(), 'milliseconds');
|
||||
document.getElementById("countdown" + timer.id).innerHTML = getDurationString(duration);
|
||||
} else {
|
||||
timer.expired = true;
|
||||
document.getElementById("countdown" + timer.id).innerHTML = "";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set all local time fields
|
||||
*/
|
||||
function setAllLocalTimes() {
|
||||
var l = timers.length;
|
||||
for (var i=0; i < l; ++i) {
|
||||
setLocalTime(timers[i]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the local time info for the timer
|
||||
* @param timer Timer information
|
||||
* @param timer.start Date of the timer
|
||||
* @param timer.id Id number of the timer
|
||||
*/
|
||||
function setLocalTime(timer) {
|
||||
document.getElementById("localtime" + timer.id).innerHTML = timer.start.format("ddd @ LT");
|
||||
}
|
||||
|
||||
function updateClock() {
|
||||
document.getElementById("current-time").innerHTML = "<b>" + moment.utc().format('ddd, ll HH:mm:ss z') + "</b>";
|
||||
}
|
||||
</script>
|
||||
{% endblock content %}
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
# Generated by Django 2.0.8 on 2018-12-07 08:56
|
||||
|
||||
import datetime
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('groupmanagement', '0010_authgroup_states'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='requestlog',
|
||||
name='date',
|
||||
field=models.DateTimeField(default=datetime.datetime(2018, 12, 7, 8, 56, 33, 846342)),
|
||||
),
|
||||
]
|
||||
@@ -4,6 +4,7 @@ from django.db import models
|
||||
from django.db.models.signals import post_save
|
||||
from django.dispatch import receiver
|
||||
from allianceauth.authentication.models import State
|
||||
from datetime import datetime
|
||||
|
||||
|
||||
class GroupRequest(models.Model):
|
||||
@@ -30,6 +31,7 @@ class RequestLog(models.Model):
|
||||
request_info = models.CharField(max_length=254)
|
||||
action = models.BooleanField(default=0)
|
||||
request_actor = models.ForeignKey(User, on_delete=models.CASCADE)
|
||||
date = models.DateTimeField(auto_now_add=datetime.utcnow())
|
||||
|
||||
def requestor(self):
|
||||
return self.request_info.split(":")[0]
|
||||
|
||||
@@ -3,38 +3,60 @@
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_title %}{{ group }} {% trans "Audit Log" %}{% endblock page_title %}
|
||||
{% block extra_css %}{% endblock extra_css %}
|
||||
|
||||
{% block content %}
|
||||
<div class="col-lg-12">
|
||||
<br>
|
||||
{% include 'groupmanagement/menu.html' %}
|
||||
<div>
|
||||
{% if entries %}
|
||||
<h3>{{ group }} Audit Log</h3>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<th class="text-center">{% trans "Requestor" %}</th>
|
||||
<th class="text-center">{% trans "Main Character" %}</th>
|
||||
<th class="text-center">{% trans "Group" %}</th>
|
||||
<th class="text-center">{% trans "Type" %}</th>
|
||||
<th class="text-center">{% trans "Action" %}</th>
|
||||
<th class="text-center">{% trans "Actor" %}</th>
|
||||
</tr>
|
||||
{% for entry in entries %}
|
||||
<tr>
|
||||
<td class="text-center">{{ entry.requestor }}</td>
|
||||
<td class="text-center">{{ entry.req_char }}</td>
|
||||
<td class="text-center">{{ entry.group }}</td>
|
||||
<td class="text-center">{{ entry.type_to_str }}</td>
|
||||
<td class="text-center">{{ entry.action_to_str }}</td>
|
||||
<td class="text-center">{{ entry.request_actor }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
<p> All times displayed are EVE/UTC.</p>
|
||||
{% if entries %}
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped" id="log-entries">
|
||||
<thead>
|
||||
<th class="text-center" scope="col">{% trans "Date/Time" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Requestor" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Main Character" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Group" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Type" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Action" %}</th>
|
||||
<th class="text-center" scope="col">{% trans "Actor" %}</th>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for entry in entries %}
|
||||
<tr>
|
||||
<td class="text-center">{{ entry.date }}</td>
|
||||
<td class="text-center">{{ entry.requestor }}</td>
|
||||
<td class="text-center">{{ entry.req_char }}</td>
|
||||
<td class="text-center">{{ entry.group }}</td>
|
||||
<td class="text-center">{{ entry.type_to_str }}</td>
|
||||
{% if entry.request_type is None %}
|
||||
<td class="text-center"> Removed</td>
|
||||
{% else %}
|
||||
<td class="text-center">{{ entry.action_to_str }}</td>
|
||||
{% endif %}
|
||||
<td class="text-center">{{ entry.request_actor }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{% else %}
|
||||
<div class="alert alert-warning text-center">{% trans "No entries found." %}</div>
|
||||
<div class="alert alert-warning text-center">{% trans "No entries found for this group." %}</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% endblock content %}
|
||||
{% endblock %}
|
||||
{% block extra_javascript %}
|
||||
{% include 'bundles/datatables-js.html' %}
|
||||
{% endblock %}
|
||||
{% block extra_css %}
|
||||
{% include 'bundles/datatables-css.html' %}
|
||||
{% endblock %}
|
||||
{% block extra_script %}
|
||||
$(document).ready(function(){
|
||||
$('#log-entries').DataTable();
|
||||
});
|
||||
{% endblock %}
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ urlpatterns = [
|
||||
name='membership'),
|
||||
url(r'^membership/(\w+)/$', views.group_membership_list,
|
||||
name='membership_list'),
|
||||
url(r'^membership/(\w+)/audit/', views.group_membership_audit, name="audit_log"),
|
||||
url(r'^membership/(\w+)/audit/$', views.group_membership_audit, name="audit_log"),
|
||||
url(r'^membership/(\w+)/remove/(\w+)/$', views.group_membership_remove,
|
||||
name='membership_remove'),
|
||||
url(r'^request_add/(\w+)', views.group_request_add,
|
||||
|
||||
@@ -5,6 +5,7 @@ from django.contrib.auth.decorators import login_required
|
||||
from django.contrib.auth.decorators import user_passes_test
|
||||
from django.contrib.auth.models import Group
|
||||
from django.core.exceptions import ObjectDoesNotExist, PermissionDenied
|
||||
from django.core.paginator import Paginator, EmptyPage
|
||||
from django.db.models import Count
|
||||
from django.http import Http404
|
||||
from django.shortcuts import render, redirect, get_object_or_404
|
||||
@@ -83,10 +84,9 @@ def group_membership_audit(request, group_id):
|
||||
|
||||
except ObjectDoesNotExist:
|
||||
raise Http404("Group does not exist")
|
||||
|
||||
entries = RequestLog.objects.filter(group=group)
|
||||
|
||||
render_items = {'entries': entries, 'group': group.name}
|
||||
render_items = {'group': group.name}
|
||||
entries = RequestLog.objects.filter(group=group).order_by('-date')
|
||||
render_items['entries'] = entries
|
||||
|
||||
return render(request, 'groupmanagement/audit.html', context=render_items)
|
||||
|
||||
|
||||
@@ -235,7 +235,7 @@ class DiscourseManager:
|
||||
@staticmethod
|
||||
def __add_user_to_group(g_id, username):
|
||||
endpoint = ENDPOINTS['groups']['add_user']
|
||||
DiscourseManager.__exc(endpoint, g_id, usernames=[username])
|
||||
DiscourseManager.__exc(endpoint, g_id, usernames=username)
|
||||
|
||||
@staticmethod
|
||||
def __remove_user_from_group(g_id, username):
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import logging
|
||||
import urllib
|
||||
|
||||
from django.conf import settings
|
||||
from django.template.loader import render_to_string
|
||||
@@ -61,7 +62,7 @@ class MumbleService(ServicesHook):
|
||||
'service_name': self.title,
|
||||
'urls': urls,
|
||||
'service_url': self.service_url,
|
||||
'connect_url': request.user.mumble.username + '@' + self.service_url if MumbleTasks.has_account(request.user) else self.service_url,
|
||||
'connect_url': urllib.parse.quote(request.user.mumble.username, safe="") + '@' + self.service_url if MumbleTasks.has_account(request.user) else self.service_url,
|
||||
'username': request.user.mumble.username if MumbleTasks.has_account(request.user) else '',
|
||||
}, request=request)
|
||||
|
||||
|
||||
@@ -4,8 +4,8 @@ from celery import shared_task
|
||||
from django.contrib.auth.models import User
|
||||
from .hooks import ServicesHook
|
||||
from celery_once import QueueOnce as BaseTask, AlreadyQueued
|
||||
from celery_once.helpers import now_unix
|
||||
from django.core.cache import cache
|
||||
from time import time
|
||||
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -22,7 +22,7 @@ class DjangoBackend:
|
||||
|
||||
@staticmethod
|
||||
def raise_or_lock(key, timeout):
|
||||
now = now_unix()
|
||||
now = int(time())
|
||||
result = cache.get(key)
|
||||
if result:
|
||||
remaining = int(result) - now
|
||||
|
||||
@@ -38,17 +38,17 @@ class TimerForm(forms.ModelForm):
|
||||
('POS[S]', 'POS[S]'),
|
||||
('POS[M]', 'POS[M]'),
|
||||
('POS[L]', 'POS[L]'),
|
||||
('Citadel[M]', 'Citadel[M]'),
|
||||
('Citadel[L]', 'Citadel[L]'),
|
||||
('Citadel[XL]', 'Citadel[XL]'),
|
||||
('Engineering Complex[M]', 'Engineering Complex[M]'),
|
||||
('Engineering Complex[L]', 'Engineering Complex[L]'),
|
||||
('Engineering Complex[XL]', 'Engineering Complex[XL]'),
|
||||
('Refinery[M]', 'Refinery[M]'),
|
||||
('Refinery[L]', 'Refinery[L]'),
|
||||
('Cyno Beacon','Cyno Beacon'),
|
||||
('Cyno Jammer','Cyno Jammer'),
|
||||
('Jump Gate','Jump Gate'),
|
||||
('Astrahus', 'Astrahus'),
|
||||
('Fortizar', 'Fortizar'),
|
||||
('Keepstar', 'Keepstar'),
|
||||
('Raitaru', 'Raitaru'),
|
||||
('Azbel', 'Azbel'),
|
||||
('Sotiyo', 'Sotiyo'),
|
||||
('Athanor', 'Athanor'),
|
||||
('Tatara', 'Tatara'),
|
||||
('Pharolux Cyno Beacon', 'Pharolux Cyno Beacon'),
|
||||
('Tenebrex Cyno Jammer', 'Tenebrex Cyno Jammer'),
|
||||
('Ansiblex Jump Gate', 'Ansiblex Jump Gate'),
|
||||
('Moon Mining Cycle', 'Moon Mining Cycle'),
|
||||
(_('Other'), _('Other'))]
|
||||
objective_choices = [('Friendly', _('Friendly')),
|
||||
|
||||
@@ -37,128 +37,128 @@
|
||||
{% endif %}
|
||||
</tr>
|
||||
{% for timer in corp_timers %}
|
||||
{% ifequal timer.important True %}
|
||||
{% if timer.important == True %}
|
||||
<tr class="danger">
|
||||
{% else %}
|
||||
<tr class="info">
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
<td style="width:150px" class="text-center">{{ timer.details }}</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.objective "Hostile" %}
|
||||
{% if timer.objective == "Hostile" %}
|
||||
<div class="label label-danger">
|
||||
{% trans "Hostile" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Friendly" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Friendly" %}
|
||||
<div class="label label-primary">
|
||||
{% trans "Friendly" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Neutral" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Neutral" %}
|
||||
<div class="label label-default">
|
||||
{% trans "Neutral" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center"><a
|
||||
href="http://evemaps.dotlan.net/system/{{ timer.system }}">{{ timer.system }} {{ timer.planet_moon }} </a>
|
||||
</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.structure "POCO" %}
|
||||
{% if timer.structure == "POCO" %}
|
||||
<div class="label label-info">
|
||||
POCO
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "I-HUB" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "I-HUB" %}
|
||||
<div class="label label-warning">
|
||||
I-HUB
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "TCU" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "TCU" %}
|
||||
<div class="label label-danger">
|
||||
TCU
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[S]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[S]" %}
|
||||
<div class="label label-info">
|
||||
POS [S]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[M]" %}
|
||||
<div class="label label-info">
|
||||
POS [M]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[L]" %}
|
||||
<div class="label label-info">
|
||||
POS [L]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[M]" or timer.structure == "Astrahus" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [M]
|
||||
Astrahus
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[L]" or timer.structure == "Fortizar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [L]
|
||||
Fortizar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[XL]" or timer.structure == "Keepstar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [XL]
|
||||
Keepstar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[M]" or timer.structure == "Raitaru" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [M]
|
||||
Raitaru
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[L]" or timer.structure == "Azbel" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [L]
|
||||
Azbel
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[XL]" or timer.structure == "Sotiyo" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [XL]
|
||||
Sotiyo
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[M]" or timer.structure == "Athanor" %}
|
||||
<div class="label label-warning">
|
||||
Refinery [M]
|
||||
Athanor
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[L]" or timer.structure == "Tatara"%}
|
||||
<div class="label label-warning">
|
||||
Refinery [L]
|
||||
Tatara
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Beacon" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Beacon" or timer.structure == "Pharolux Cyno Beacon" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Beacon
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Jammer" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Jammer" or timer.structure == "Tenebrex Cyno Jammer" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Jammer
|
||||
Tenebrex Cyno Jammer
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Jump Gate" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Jump Gate" or timer.structure == "Ansiblex Jump Gate" %}
|
||||
<div class="label label-warning">
|
||||
Jump Gate
|
||||
Ansiblex Jump Gate
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Moon Mining Cycle" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Moon Mining Cycle" %}
|
||||
<div class="label label-success">
|
||||
Moon Mining Cycle
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Other" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Other" %}
|
||||
<div class="label label-default">
|
||||
Other
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center" nowrap>{{ timer.eve_time | date:"Y-m-d H:i" }}</td>
|
||||
<td class="text-center" nowrap>
|
||||
@@ -196,128 +196,128 @@
|
||||
{% endif %}
|
||||
</tr>
|
||||
{% for timer in future_timers %}
|
||||
{% ifequal timer.important True %}
|
||||
{% if timer.important == True %}
|
||||
<tr class="danger">
|
||||
{% else %}
|
||||
<tr class="info">
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
<td style="width:150px" class="text-center">{{ timer.details }}</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.objective "Hostile" %}
|
||||
{% if timer.objective == "Hostile" %}
|
||||
<div class="label label-danger">
|
||||
{% trans "Hostile" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Friendly" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Friendly" %}
|
||||
<div class="label label-primary">
|
||||
{% trans "Friendly" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Neutral" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Neutral" %}
|
||||
<div class="label label-default">
|
||||
{% trans "Neutral" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<a href="http://evemaps.dotlan.net/system/{{ timer.system }}">{{ timer.system }} {{ timer.planet_moon }}</a>
|
||||
</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.structure "POCO" %}
|
||||
{% if timer.structure == "POCO" %}
|
||||
<div class="label label-info">
|
||||
POCO
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "I-HUB" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "I-HUB" %}
|
||||
<div class="label label-warning">
|
||||
I-HUB
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "TCU" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "TCU" %}
|
||||
<div class="label label-danger">
|
||||
TCU
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[S]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[S]" %}
|
||||
<div class="label label-info">
|
||||
POS [S]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[M]" %}
|
||||
<div class="label label-info">
|
||||
POS [M]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[L]" %}
|
||||
<div class="label label-info">
|
||||
POS [L]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[M]" or timer.structure == "Astrahus" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [M]
|
||||
Astrahus
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[L]" or timer.structure == "Fortizar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [L]
|
||||
Fortizar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[XL]" or timer.structure == "Keepstar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [XL]
|
||||
Keepstar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[M]" or timer.structure == "Raitaru" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [M]
|
||||
Raitaru
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[L]" or timer.structure == "Azbel" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [L]
|
||||
Azbel
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[XL]" or timer.structure == "Sotiyo" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [XL]
|
||||
Sotiyo
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[M]" or timer.structure == "Athanor" %}
|
||||
<div class="label label-warning">
|
||||
Refinery [M]
|
||||
Athanor
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[L]" or timer.structure == "Tatara" %}
|
||||
<div class="label label-warning">
|
||||
Refinery [L]
|
||||
Tatara
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Beacon" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Beacon" or timer.structure == "Pharolux Cyno Beacon" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Beacon
|
||||
Pharolux Cyno Beacon
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Jammer" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Jammer" or timer.structure == "Tenebrex Cyno Jammer" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Jammer
|
||||
Tenebrex Cyno Jammer
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Jump Gate" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Jump Gate" or timer.structure == "Ansiblex Jump Gate" %}
|
||||
<div class="label label-warning">
|
||||
Jump Gate
|
||||
Ansiblex Jump Gate
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Moon Mining Cycle" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Moon Mining Cycle" %}
|
||||
<div class="label label-success">
|
||||
Moon Mining Cycle
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Other" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Other" %}
|
||||
<div class="label label-default">
|
||||
Other
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center" nowrap>{{ timer.eve_time | date:"Y-m-d H:i" }}</td>
|
||||
<td class="text-center" nowrap>
|
||||
@@ -357,128 +357,128 @@
|
||||
{% endif %}
|
||||
</tr>
|
||||
{% for timer in past_timers %}
|
||||
{% ifequal timer.important True %}
|
||||
{% if timer.important == True %}
|
||||
<tr class="danger">
|
||||
{% else %}
|
||||
<tr class="info">
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
<td style="width:150px" class="text-center">{{ timer.details }}</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.objective "Hostile" %}
|
||||
{% if timer.objective == "Hostile" %}
|
||||
<div class="label label-danger">
|
||||
{% trans "Hostile" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Friendly" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Friendly" %}
|
||||
<div class="label label-primary">
|
||||
{% trans "Friendly" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.objective "Neutral" %}
|
||||
{% endif %}
|
||||
{% if timer.objective == "Neutral" %}
|
||||
<div class="label label-default">
|
||||
{% trans "Neutral" %}
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<a href="http://evemaps.dotlan.net/system/{{ timer.system }}">{{ timer.system }} {{ timer.planet_moon }}</a>
|
||||
</td>
|
||||
<td class="text-center">
|
||||
{% ifequal timer.structure "POCO" %}
|
||||
{% if timer.structure == "POCO" %}
|
||||
<div class="label label-info">
|
||||
POCO
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "I-HUB" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "I-HUB" %}
|
||||
<div class="label label-warning">
|
||||
I-HUB
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "TCU" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "TCU" %}
|
||||
<div class="label label-danger">
|
||||
TCU
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[S]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[S]" %}
|
||||
<div class="label label-info">
|
||||
POS [S]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[M]" %}
|
||||
<div class="label label-info">
|
||||
POS [M]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "POS[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "POS[L]" %}
|
||||
<div class="label label-info">
|
||||
POS [L]
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[M]" or timer.structure == "Astrahus" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [M]
|
||||
Astrahus
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[L]" or timer.structure == "Fortizar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [L]
|
||||
Fortizar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Citadel[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Citadel[XL]" or timer.structure == "Keepstar" %}
|
||||
<div class="label label-danger">
|
||||
Citadel [XL]
|
||||
Keepstar
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[M]" or timer.structure == "Raitaru" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [M]
|
||||
Raitaru
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[L]" or timer.structure == "Azbel" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [L]
|
||||
Azbel
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Engineering Complex[XL]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Engineering Complex[XL]" or timer.structure == "Sotiyo" %}
|
||||
<div class="label label-warning">
|
||||
Engineering Complex [XL]
|
||||
Sotiyo
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[M]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[M]" or timer.structure == "Athanor" %}
|
||||
<div class="label label-warning">
|
||||
Refinery [M]
|
||||
Athanor
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Refinery[L]" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Refinery[L]" or timer.structure == "Tatara" %}
|
||||
<div class="label label-warning">
|
||||
Refinery [L]
|
||||
Tatara
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Beacon" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Beacon" or timer.structure == "Pharolux Cyno Beacon" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Beacon
|
||||
Pharolux Cyno Beacon
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Cyno Jammer" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Cyno Jammer" or timer.structure == "Tenebrex Cyno Jammer" %}
|
||||
<div class="label label-warning">
|
||||
Cyno Jammer
|
||||
Tenebrex Cyno Jammer
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Jump Gate" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Jump Gate" or timer.structure == "Ansiblex Jump Gate" %}
|
||||
<div class="label label-warning">
|
||||
Jump Gate
|
||||
Ansiblex Jump Gate
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Moon Mining Cycle" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Moon Mining Cycle" %}
|
||||
<div class="label label-success">
|
||||
Moon Mining Cycle
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% ifequal timer.structure "Other" %}
|
||||
{% endif %}
|
||||
{% if timer.structure == "Other" %}
|
||||
<div class="label label-default">
|
||||
Other
|
||||
</div>
|
||||
{% endifequal %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-center" nowrap>{{ timer.eve_time | date:"Y-m-d H:i" }}</td>
|
||||
<td class="text-center" nowrap>
|
||||
|
||||
BIN
docs/_static/images/features/group_audit_log.png
vendored
Normal file
BIN
docs/_static/images/features/group_audit_log.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 31 KiB |
@@ -66,6 +66,17 @@ Clicking on the blue eye will take you to the group member management screen. He
|
||||
|
||||

|
||||
|
||||
### Group Audit Log
|
||||
Whenever a user Joins, Leaves, or is Removed from a group, this is logged. To find the audit log for a given group, click the light-blue button to the right of the Group Member Management (blue eye) button.
|
||||
|
||||
These logs contain the Date and Time the action was taken (in EVE/UTC), the user which submitted the request being acted upon (requestor), the user's main character, the type of request (join, leave or removed), the action taken (accept, reject or remove), and the user that took the action (actor).
|
||||
|
||||

|
||||
|
||||
```eval_rst
|
||||
.. note::
|
||||
There is no tracking for "Open" groups as members are able to freely join/leave these groups.
|
||||
```
|
||||
|
||||
## Group Leaders
|
||||
|
||||
|
||||
@@ -74,6 +74,19 @@ Alliance Auth needs a MySQL user account and database. Open an SQL shell with `m
|
||||
CREATE DATABASE alliance_auth CHARACTER SET utf8;
|
||||
GRANT ALL PRIVILEGES ON alliance_auth . * TO 'allianceserver'@'localhost';
|
||||
|
||||
Add timezone tables to your mysql installation:
|
||||
|
||||
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql
|
||||
|
||||
```eval_rst
|
||||
.. note::
|
||||
You may see errors when you add the timezone tables. To make sure that they were correctly added run the following commands and check for the ``time_zone`` tables::
|
||||
|
||||
mysql -u root -p
|
||||
use mysql;
|
||||
show tables;
|
||||
```
|
||||
|
||||
Close the SQL shell and secure your database server with the `mysql_secure_installation` command.
|
||||
|
||||
## Auth Install
|
||||
|
||||
7
setup.py
7
setup.py
@@ -13,20 +13,21 @@ install_requires = [
|
||||
'semantic_version',
|
||||
|
||||
'redis<=2.10.6',
|
||||
'celery>=4.0.2',
|
||||
'celery>=4.0.2,<4.3.0',
|
||||
'celery_once',
|
||||
|
||||
'django>=1.11,<=2.0.8',
|
||||
'django>=2.0',
|
||||
'django-bootstrap-form',
|
||||
'django-registration==2.4',
|
||||
'django-sortedm2m',
|
||||
'django-redis-cache>=1.7.1',
|
||||
'django-redis-cache==1.8.1',
|
||||
'django-celery-beat<=1.1.1',
|
||||
|
||||
'openfire-restapi',
|
||||
'sleekxmpp',
|
||||
|
||||
'adarnauth-esi>=1.4.10,<2.0',
|
||||
'kombu<=4.3.0',
|
||||
]
|
||||
|
||||
testing_extras = [
|
||||
|
||||
Reference in New Issue
Block a user