aa-structures 2.16.0__py3-none-any.whl → 3.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {aa_structures-2.16.0.dist-info → aa_structures-3.0.0.dist-info}/METADATA +5 -4
- {aa_structures-2.16.0.dist-info → aa_structures-3.0.0.dist-info}/RECORD +27 -26
- {aa_structures-2.16.0.dist-info → aa_structures-3.0.0.dist-info}/WHEEL +1 -1
- structures/__init__.py +1 -1
- structures/core/notification_embeds/corporate_embeds.py +58 -0
- structures/core/notification_embeds/main.py +8 -2
- structures/core/notification_types.py +86 -76
- structures/core/serializers.py +6 -6
- structures/migrations/0009_add_project_goal_notifications.py +152 -0
- structures/models/owners.py +1 -1
- structures/static/structures/js/public.js +9 -3
- structures/static/structures/js/structures.js +5 -1
- structures/templates/structures/base.html +39 -6
- structures/templates/structures/modals/poco_details.html +15 -15
- structures/templates/structures/modals/starbase_detail.html +19 -20
- structures/templates/structures/modals/structure_details.html +19 -21
- structures/templates/structures/partials/menu.html +2 -2
- structures/templates/structures/public.html +28 -34
- structures/templates/structures/statistics.html +11 -19
- structures/templates/structures/structures.html +89 -99
- structures/templates/structures/templatetags/list_asset.html +7 -5
- structures/templates/structures/templatetags/list_item.html +3 -3
- structures/templates/structures/templatetags/list_tax_item.html +3 -3
- structures/templates/structures/templatetags/list_title.html +1 -1
- structures/tests/testdata/entities.json +30 -0
- structures/tests/testdata/generate_notifications.py +1 -1
- {aa_structures-2.16.0.dist-info → aa_structures-3.0.0.dist-info/licenses}/LICENSE +0 -0
@@ -6,22 +6,18 @@
|
|
6
6
|
{% block details %}
|
7
7
|
|
8
8
|
<!-- Nav tabs -->
|
9
|
-
<ul
|
10
|
-
|
11
|
-
|
12
|
-
|
9
|
+
<ul class="nav nav-tabs" role="tablist">
|
10
|
+
<li role="presentation" class="nav-item">
|
11
|
+
<button class="nav-link active" aria-controls="summary" role="tab" data-bs-toggle="tab" data-bs-toggle="#summary">
|
12
|
+
{% trans "Summary" %}
|
13
|
+
</button>
|
13
14
|
</li>
|
14
|
-
|
15
15
|
</ul>
|
16
16
|
|
17
|
-
<div class="
|
18
|
-
<div class="
|
19
|
-
<div class="tab-
|
20
|
-
|
21
|
-
<div role="tabpanel" class="tab-pane active" id="summary">
|
22
|
-
{% include "structures/partials/statistics/structure_summary.html" %}
|
23
|
-
</div>
|
24
|
-
|
17
|
+
<div class="card card-default card-tabs border-0">
|
18
|
+
<div class="card-body tab-content">
|
19
|
+
<div role="tabpanel" class="tab-pane show active" id="summary">
|
20
|
+
{% include "structures/partials/statistics/structure_summary.html" %}
|
25
21
|
</div>
|
26
22
|
</div>
|
27
23
|
</div>
|
@@ -33,18 +29,14 @@
|
|
33
29
|
|
34
30
|
{% block extra_javascript %}
|
35
31
|
{% include 'bundles/datatables-js.html' %}
|
36
|
-
|
37
|
-
type="application/javascript"
|
38
|
-
src="{% static 'structures/vendor/datatables/plugins/filterDropDown.min.js' %}">
|
39
|
-
</script>
|
32
|
+
{% include "bundles/filterdropdown-js.html" %}
|
40
33
|
<script type="application/javascript" src="{% static 'structures/js/global.js' %}"></script>
|
41
34
|
<script type="application/javascript" src="{% static 'structures/js/statistics.js' %}"></script>
|
42
35
|
|
43
36
|
{% endblock %}
|
44
37
|
|
45
38
|
{% block extra_css %}
|
46
|
-
{% include 'bundles/datatables-css.html' %}
|
47
|
-
|
39
|
+
{% include 'bundles/datatables-css-bs5.html' %}
|
48
40
|
<link rel="stylesheet" href="{% static 'structures/css/global.css' %}" type="text/css" media="screen">
|
49
41
|
<link rel="stylesheet" href="{% static 'structures/css/main.css' %}" type="text/css" media="screen">
|
50
42
|
<link rel="stylesheet" href="{% static 'structures/css/statistics.css' %}" type="text/css" media="screen">
|
@@ -5,134 +5,126 @@
|
|
5
5
|
{% load humanize %}
|
6
6
|
|
7
7
|
{% block details %}
|
8
|
+
<ul class="nav nav-tabs" role="tablist">
|
8
9
|
|
9
|
-
|
10
|
-
|
11
|
-
{% if tags_exist %}
|
12
|
-
{% if active_tags %}
|
13
|
-
<button
|
14
|
-
type="button"
|
15
|
-
class="btn btn-warning btn-tabs"
|
16
|
-
data-toggle="modal"
|
17
|
-
data-target="#modalTagsFilter">
|
18
|
-
{% translate "Tags Filter (Active)" %}
|
19
|
-
</button>
|
20
|
-
{% else %}
|
21
|
-
<button
|
22
|
-
type="button"
|
23
|
-
class="btn btn-default btn-tabs"
|
24
|
-
data-toggle="modal"
|
25
|
-
data-target="#modalTagsFilter">
|
26
|
-
{% translate "Tags Filter" %}
|
27
|
-
</button>
|
28
|
-
{% endif %}
|
29
|
-
{% else %}
|
30
|
-
<button
|
31
|
-
type="button"
|
32
|
-
class="btn btn-default btn-tabs"
|
33
|
-
data-toggle="modal"
|
34
|
-
data-target="#modalTagsFilter"
|
35
|
-
disabled="disabled">
|
36
|
-
{% translate "Tags Filter" %}
|
37
|
-
</button>
|
38
|
-
{% endif %}
|
39
|
-
</span>
|
40
|
-
|
41
|
-
<!-- Nav tabs -->
|
42
|
-
<ul id="structure-tabs" class="nav nav-tabs" role="tablist">
|
43
|
-
|
44
|
-
<li role="presentation">
|
45
|
-
<a href="#structures" aria-controls="structures" role="tab" data-toggle="tab">
|
10
|
+
<li role="presentation" class="nav-item">
|
11
|
+
<button class="nav-link active" aria-controls="structures" role="tab" data-bs-toggle="tab" data-bs-target="#structures">
|
46
12
|
{% trans "Upwell Structures" %} <small>({{ structures_count|default:"-" }})</small>
|
47
|
-
</
|
13
|
+
</button>
|
48
14
|
</li>
|
49
15
|
|
50
|
-
<li role="presentation">
|
51
|
-
<
|
16
|
+
<li role="presentation" class="nav-item">
|
17
|
+
<button class="nav-link" aria-controls="orbitals" role="tab" data-bs-toggle="tab" data-bs-target="#orbitals">
|
52
18
|
{% trans "Orbitals" %} <small>({{ orbitals_count|default:"-" }})</small>
|
53
|
-
</
|
19
|
+
</button>
|
54
20
|
</li>
|
55
21
|
|
56
|
-
<li role="presentation">
|
57
|
-
<
|
22
|
+
<li role="presentation" class="nav-item">
|
23
|
+
<button class="nav-link" aria-controls="starbases" role="tab" data-bs-toggle="tab" data-bs-target="#starbases">
|
58
24
|
{% trans "Starbases" %} <small>({{ starbases_count|default:"-" }})</small>
|
59
|
-
</
|
25
|
+
</button>
|
60
26
|
</li>
|
61
27
|
|
62
28
|
{% if show_jump_gates_tab %}
|
63
|
-
<li role="presentation">
|
64
|
-
<a
|
29
|
+
<li role="presentation" class="nav-item">
|
30
|
+
<a class="nav-link" aria-controls="jump-gates" role="tab" data-bs-toggle="tab" data-bs-target="#jump-gates">
|
65
31
|
{% trans "Jump Gates" %} <small>({{ jump_gates_count|default:"-" }})</small>
|
66
32
|
</a>
|
67
33
|
</li>
|
68
34
|
{% endif %}
|
69
35
|
|
70
|
-
|
36
|
+
<li role="presentation" class="nav-item ms-auto">
|
37
|
+
{% if tags_exist %}
|
38
|
+
{% if active_tags %}
|
39
|
+
<button
|
40
|
+
type="button"
|
41
|
+
class="btn btn-warning"
|
42
|
+
data-bs-toggle="modal"
|
43
|
+
data-bs-target="#modalTagsFilter">
|
44
|
+
{% translate "Tags Filter (Active)" %}
|
45
|
+
</button>
|
46
|
+
{% else %}
|
47
|
+
<button
|
48
|
+
type="button"
|
49
|
+
class="btn btn-secondary"
|
50
|
+
data-bs-toggle="modal"
|
51
|
+
data-bs-target="#modalTagsFilter">
|
52
|
+
{% translate "Tags Filter" %}
|
53
|
+
</button>
|
54
|
+
{% endif %}
|
55
|
+
{% else %}
|
56
|
+
<button
|
57
|
+
type="button"
|
58
|
+
class="btn btn-secondary"
|
59
|
+
data-bs-toggle="modal"
|
60
|
+
data-bs-target="#modalTagsFilter"
|
61
|
+
disabled="disabled">
|
62
|
+
{% translate "Tags Filter" %}
|
63
|
+
</button>
|
64
|
+
{% endif %}
|
65
|
+
</li>
|
71
66
|
|
72
|
-
|
73
|
-
<div class="panel-body">
|
74
|
-
<div class="tab-content">
|
67
|
+
</ul>
|
75
68
|
|
76
|
-
|
77
|
-
|
78
|
-
</div>
|
69
|
+
<div class="card card-default card-tabs border-0">
|
70
|
+
<div class="card-body tab-content">
|
79
71
|
|
80
|
-
|
81
|
-
|
82
|
-
|
72
|
+
<div class="tab-pane show active" id="structures" role="tabpanel">
|
73
|
+
{% include "structures/partials/structures/structure_list.html" %}
|
74
|
+
</div>
|
83
75
|
|
84
|
-
|
85
|
-
|
86
|
-
|
76
|
+
<div class="tab-pane" id="orbitals" role="tabpanel">
|
77
|
+
{% include "structures/partials/structures/orbital_list.html" %}
|
78
|
+
</div>
|
87
79
|
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
</div>
|
92
|
-
{% endif %}
|
80
|
+
<div class="tab-pane" id="starbases" role="tabpanel">
|
81
|
+
{% include "structures/partials/structures/starbase_list.html" %}
|
82
|
+
</div>
|
93
83
|
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
84
|
+
{% if show_jump_gates_tab %}
|
85
|
+
<div class="tab-pane" id="jump-gates" role="tabpanel">
|
86
|
+
{% include "structures/partials/structures/jump_gate_list.html" %}
|
87
|
+
</div>
|
88
|
+
{% endif %}
|
99
89
|
|
100
|
-
|
90
|
+
<p class="text-muted">
|
91
|
+
{% translate "All dates are EVE time" %}
|
92
|
+
| {% translate "Data can be outdated by up to 1 hour due to API caching" %}
|
93
|
+
| {% translate "Last updated" %} {{ last_updated|naturaltime|default:"?" }}
|
94
|
+
</p>
|
101
95
|
|
102
96
|
</div>
|
103
97
|
</div>
|
104
98
|
|
105
99
|
<!-- Tags Filter Modal -->
|
106
|
-
<div class="modal" id="modalTagsFilter" tabindex="-1"
|
107
|
-
<div class="modal-dialog"
|
108
|
-
<
|
109
|
-
<div class="modal-
|
110
|
-
<
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
<h4 class="modal-title">{% translate "Tags Filter" %}</h4>
|
115
|
-
</div>
|
100
|
+
<div class="modal" id="modalTagsFilter" tabindex="-1">
|
101
|
+
<div class="modal-dialog">
|
102
|
+
<div class="modal-content">
|
103
|
+
<div class="modal-header">
|
104
|
+
<h5 class="modal-title">{% translate "Tags Filter" %}</h5>
|
105
|
+
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
106
|
+
</div>
|
107
|
+
<form method="post">
|
116
108
|
<div class="modal-body">
|
117
109
|
{% csrf_token %}
|
118
110
|
{{ tags_filter_form|bootstrap }}
|
119
111
|
</div>
|
120
112
|
<div class="modal-footer">
|
121
|
-
<a class="btn btn-
|
113
|
+
<a class="btn btn-secondary pull-left" href="{% url 'structures:index' %}" role="button">
|
122
114
|
{% translate "Reset Filter" %}
|
123
115
|
</a>
|
124
|
-
<a class="btn btn-
|
116
|
+
<a class="btn btn-secondary pull-left" href="{% url 'structures:structure_list' %}" role="button">
|
125
117
|
{% translate "Clear Filter" %}
|
126
118
|
</a>
|
127
|
-
<button type="button" class="btn btn-
|
119
|
+
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">
|
128
120
|
{% translate "Cancel" %}
|
129
121
|
</button>
|
130
122
|
<button type="submit" class="btn btn-primary">
|
131
123
|
{% translate "Apply Filter" %}
|
132
124
|
</button>
|
133
125
|
</div>
|
134
|
-
</
|
135
|
-
</
|
126
|
+
</form>
|
127
|
+
</div>
|
136
128
|
</div>
|
137
129
|
</div>
|
138
130
|
|
@@ -141,8 +133,8 @@
|
|
141
133
|
<div class="modal-dialog" role="document">
|
142
134
|
<div class="modal-content" id="modalUpwellDetailsContent">
|
143
135
|
<div class="modal-header">
|
144
|
-
<
|
145
|
-
<
|
136
|
+
<h5 class="modal-title">Loading...</h5>
|
137
|
+
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
146
138
|
</div>
|
147
139
|
<div class="modal-body">
|
148
140
|
</div>
|
@@ -151,12 +143,12 @@
|
|
151
143
|
</div>
|
152
144
|
|
153
145
|
<!-- Poco details modal -->
|
154
|
-
<div class="modal" id="modalPocoDetails" tabindex="-1"
|
155
|
-
<div class="modal-dialog"
|
146
|
+
<div class="modal" id="modalPocoDetails" tabindex="-1" aria-labelledby="modalPocoDetails">
|
147
|
+
<div class="modal-dialog">
|
156
148
|
<div class="modal-content" id="modalPocoDetailsContent">
|
157
149
|
<div class="modal-header">
|
158
|
-
<
|
159
|
-
<
|
150
|
+
<h5 class="modal-title">Loading...</h5>
|
151
|
+
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
160
152
|
</div>
|
161
153
|
<div class="modal-body">
|
162
154
|
</div>
|
@@ -169,8 +161,8 @@
|
|
169
161
|
<div class="modal-dialog" role="document">
|
170
162
|
<div class="modal-content" id="modalStarbaseDetailContent">
|
171
163
|
<div class="modal-header">
|
172
|
-
<
|
173
|
-
<
|
164
|
+
<h5 class="modal-title">Loading...</h5>
|
165
|
+
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
174
166
|
</div>
|
175
167
|
<div class="modal-body">
|
176
168
|
</div>
|
@@ -184,18 +176,16 @@
|
|
184
176
|
{% endblock %}
|
185
177
|
|
186
178
|
{% block extra_javascript %}
|
187
|
-
{% include
|
188
|
-
|
189
|
-
|
190
|
-
src="{% static 'structures/vendor/datatables/plugins/filterDropDown.min.js' %}">
|
191
|
-
</script>
|
179
|
+
{% include "bundles/datatables-js-bs5.html" %}
|
180
|
+
{% include "bundles/filterdropdown-js.html" %}
|
181
|
+
|
192
182
|
<script type="application/javascript" src="{% static 'structures/js/global.js' %}"></script>
|
193
183
|
<script type="application/javascript" src="{% static 'structures/js/structures.js' %}"></script>
|
194
184
|
|
195
185
|
{% endblock %}
|
196
186
|
|
197
187
|
{% block extra_css %}
|
198
|
-
{% include 'bundles/datatables-css.html' %}
|
188
|
+
{% include 'bundles/datatables-css-bs5.html' %}
|
199
189
|
|
200
190
|
<link rel="stylesheet" href="{% static 'structures/css/global.css' %}" type="text/css" media="screen">
|
201
191
|
<link rel="stylesheet" href="{% static 'structures/css/main.css' %}" type="text/css" media="screen">
|
@@ -1,9 +1,11 @@
|
|
1
1
|
<li class="list-group-item">
|
2
|
-
|
3
|
-
<
|
4
|
-
|
2
|
+
<div class="d-flex w-100 justify-content-between">
|
3
|
+
<span>
|
4
|
+
<img src="{{ icon_url }}" style="height: 32px; width: 32px;">
|
5
|
+
<a href="{{ profile_url }}" target="_blank">{{ name }}</a>
|
6
|
+
</span>
|
5
7
|
{% if not is_singleton %}
|
6
|
-
<span
|
8
|
+
<span>{{ quantity|default_if_none:"?"|floatformat:"0g" }}</span>
|
7
9
|
{% endif %}
|
8
|
-
</
|
10
|
+
</div>
|
9
11
|
</li>
|
@@ -1,13 +1,13 @@
|
|
1
1
|
{% load humanize %}
|
2
2
|
|
3
3
|
<li class="list-group-item">
|
4
|
-
|
4
|
+
<div class="d-flex w-100 justify-content-between">
|
5
5
|
{% if is_muted %}
|
6
6
|
<span class="text-muted">{{ title }}</span>
|
7
7
|
{% else %}
|
8
8
|
{{ title }}
|
9
9
|
{% endif %}
|
10
|
-
<span
|
10
|
+
<span>
|
11
11
|
{% if value is False or value is None %}
|
12
12
|
<i class="fas fa-times text-danger" title="Disabled"></i>
|
13
13
|
{% elif value is True %}
|
@@ -18,5 +18,5 @@
|
|
18
18
|
{{ value }}
|
19
19
|
{% endif %}
|
20
20
|
</span>
|
21
|
-
</
|
21
|
+
</div>
|
22
22
|
</li>
|
@@ -1,9 +1,9 @@
|
|
1
1
|
{% load i18n %}
|
2
2
|
|
3
3
|
<li class="list-group-item">
|
4
|
-
|
4
|
+
<div class="d-flex w-100 justify-content-between">
|
5
5
|
{{ title }}
|
6
|
-
<span
|
6
|
+
<span>
|
7
7
|
{% widthratio value 1 100 %} %
|
8
8
|
{% if has_access is False %}
|
9
9
|
<i class="fas fa-ban text-danger" title="{% translate 'No Access' %}"></i>
|
@@ -11,5 +11,5 @@
|
|
11
11
|
<i class="fas fa-check text-success" title="{% translate 'Has Access' %}"></i>
|
12
12
|
{% endif %}
|
13
13
|
</span>
|
14
|
-
</
|
14
|
+
</div>
|
15
15
|
</li>
|
@@ -1 +1 @@
|
|
1
|
-
<li class="list-group-item
|
1
|
+
<li class="list-group-item active">{{ title }}</li>
|
@@ -806,6 +806,36 @@
|
|
806
806
|
"is_read": false,
|
807
807
|
"is_sent": false
|
808
808
|
},
|
809
|
+
{
|
810
|
+
"notification_id": 1000001401,
|
811
|
+
"type": "CorporationGoalClosed",
|
812
|
+
"sender_id": 2901,
|
813
|
+
"sender_type": "corporation",
|
814
|
+
"timestamp": "2019-11-18 20:00:00",
|
815
|
+
"text": "closer_id: 1011\ncorporation_id: 2001\ncreator_id: 1001\ngoal_id: 287804106856621566338600488094573709306\ngoal_name: Strawberry Jam",
|
816
|
+
"is_read": false,
|
817
|
+
"is_sent": false
|
818
|
+
},
|
819
|
+
{
|
820
|
+
"notification_id": 1000001402,
|
821
|
+
"type": "CorporationGoalCompleted",
|
822
|
+
"sender_id": 2901,
|
823
|
+
"sender_type": "corporation",
|
824
|
+
"timestamp": "2019-11-18 20:00:00",
|
825
|
+
"text": "corporation_id: 2001\ncreator_id: 1001\ngoal_id: 287804106856621566338600488094573709306\ngoal_name: Strawberry Jam",
|
826
|
+
"is_read": false,
|
827
|
+
"is_sent": false
|
828
|
+
},
|
829
|
+
{
|
830
|
+
"notification_id": 1000001403,
|
831
|
+
"type": "CorporationGoalCreated",
|
832
|
+
"sender_id": 2901,
|
833
|
+
"sender_type": "corporation",
|
834
|
+
"timestamp": "2019-11-18 20:00:00",
|
835
|
+
"text": "corporation_id: 2001\ncreator_id: 1001\ngoal_id: 287804106856621566338600488094573709306\ngoal_name: Strawberry Jam",
|
836
|
+
"is_read": false,
|
837
|
+
"is_sent": false
|
838
|
+
},
|
809
839
|
{
|
810
840
|
"notification_id": 1999999999,
|
811
841
|
"type": "UnknownNotificationType",
|
@@ -80,7 +80,7 @@ def main():
|
|
80
80
|
}
|
81
81
|
structure, _ = Structure.objects.update_or_create_from_dict(structure, owner)
|
82
82
|
|
83
|
-
p = Path(__file__).parent / "
|
83
|
+
p = Path(__file__).parent / "entities.json"
|
84
84
|
with p.open(mode="r", encoding="utf-8") as fp:
|
85
85
|
data = json.load(fp)
|
86
86
|
|
File without changes
|