django-spire 0.16.9__py3-none-any.whl → 0.16.10__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.
- django_spire/consts.py +1 -1
- django_spire/core/management/commands/spire_startapp_pkg/maps.py +18 -11
- django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_detail_card.html +6 -6
- django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_form_card.html +2 -2
- django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_list_card.html +5 -5
- django_spire/core/management/commands/spire_startapp_pkg/template/templates/item/spirechildapp_item.html +9 -9
- django_spire/core/management/commands/spire_startapp_pkg/template/templates/page/spirechildapp_detail_page.html +2 -2
- django_spire/core/templates/django_spire/card/infinite_scroll_card.html +1 -1
- django_spire/core/templates/django_spire/modal/content/modal_title_content.html +1 -1
- django_spire/core/templates/django_spire/modal/modal.html +1 -1
- {django_spire-0.16.9.dist-info → django_spire-0.16.10.dist-info}/METADATA +1 -1
- {django_spire-0.16.9.dist-info → django_spire-0.16.10.dist-info}/RECORD +15 -15
- {django_spire-0.16.9.dist-info → django_spire-0.16.10.dist-info}/WHEEL +0 -0
- {django_spire-0.16.9.dist-info → django_spire-0.16.10.dist-info}/licenses/LICENSE.md +0 -0
- {django_spire-0.16.9.dist-info → django_spire-0.16.10.dist-info}/top_level.txt +0 -0
django_spire/consts.py
CHANGED
|
@@ -3,19 +3,26 @@ from __future__ import annotations
|
|
|
3
3
|
|
|
4
4
|
def generate_replacement_map(components: list[str]) -> dict[str, str]:
|
|
5
5
|
app_name = components[-1]
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
model_name = ''.join(word.title() for word in app_name.split('_'))
|
|
7
|
+
if len(components)> 1:
|
|
8
|
+
parents = components[0:-1]
|
|
9
|
+
parent = components[-2]
|
|
10
|
+
else:
|
|
11
|
+
parents = [app_name,]
|
|
12
|
+
parent = app_name
|
|
8
13
|
module = '.'.join(components)
|
|
9
14
|
|
|
15
|
+
# The sequence is important. Plurals must be replaced first;
|
|
16
|
+
# otherwise, it will generate _plural variables and names.
|
|
10
17
|
return {
|
|
11
18
|
'module': module,
|
|
12
|
-
'
|
|
13
|
-
'
|
|
14
|
-
'
|
|
15
|
-
'
|
|
16
|
-
'
|
|
17
|
-
'
|
|
18
|
-
'
|
|
19
|
-
'
|
|
20
|
-
'
|
|
19
|
+
'spire_model_name_plural': model_name + 's',
|
|
20
|
+
'spire_model_name': model_name,
|
|
21
|
+
'spire_app_name_plural': app_name.lower() + 's',
|
|
22
|
+
'spire_app_name': app_name.lower(),
|
|
23
|
+
'spire_parent_app': parent.lower(),
|
|
24
|
+
'spire_reverse_parent_path': ':'.join(parents[1:]).lower(),
|
|
25
|
+
'spire_reverse_path': ':'.join(parents[1:]).lower() + ':' + app_name.lower(),
|
|
26
|
+
'spire_label_path': '_'.join(parents[1:]).lower() + '_' + app_name.lower(),
|
|
27
|
+
'spire_template_path': '/'.join(parents[1:]).lower() + '/' + app_name.lower(),
|
|
21
28
|
}
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
{% extends 'django_spire/card/title_card.html' %}
|
|
2
2
|
|
|
3
3
|
{% block card_title %}
|
|
4
|
-
|
|
4
|
+
spire_model_name
|
|
5
5
|
{% endblock %}
|
|
6
6
|
|
|
7
7
|
{% block card_button %}
|
|
8
|
-
{% if perms.
|
|
9
|
-
{% url '
|
|
10
|
-
{% include 'django_spire/button/primary_dark_button.html' with button_text='Edit' button_icon='bi bi-pencil' button_href=
|
|
8
|
+
{% if perms.spire_label_path.change_spire_app_name %}
|
|
9
|
+
{% url 'spire_parent_app:spire_app_name:page:form' pk=spire_app_name.pk as spire_app_name_edit_url %}
|
|
10
|
+
{% include 'django_spire/button/primary_dark_button.html' with button_text='Edit' button_icon='bi bi-pencil' button_href=spire_app_name_edit_url %}
|
|
11
11
|
{% endif %}
|
|
12
12
|
{% endblock %}
|
|
13
13
|
|
|
14
14
|
{% block card_title_content %}
|
|
15
15
|
<div class="row g-3">
|
|
16
16
|
<div class="col-12">
|
|
17
|
-
{% include 'django_spire/element/attribute_element.html' with attribute_title='Name' attribute_value=
|
|
17
|
+
{% include 'django_spire/element/attribute_element.html' with attribute_title='Name' attribute_value=spire_app_name.name %}
|
|
18
18
|
</div>
|
|
19
19
|
|
|
20
20
|
<div class="col-12">
|
|
21
|
-
{% include 'django_spire/element/attribute_element.html' with attribute_title='Description' attribute_value=
|
|
21
|
+
{% include 'django_spire/element/attribute_element.html' with attribute_title='Description' attribute_value=spire_app_name.description|linebreaksbr %}
|
|
22
22
|
</div>
|
|
23
23
|
</div>
|
|
24
24
|
{% endblock %}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{% extends 'django_spire/card/title_card.html' %}
|
|
2
2
|
|
|
3
3
|
{% block card_title %}
|
|
4
|
-
|
|
4
|
+
spire_model_name
|
|
5
5
|
{% endblock %}
|
|
6
6
|
|
|
7
7
|
{% block card_title_content %}
|
|
8
|
-
{% include '
|
|
8
|
+
{% include 'spire_parent_app/spire_app_name/form/spire_app_name_form.html' %}
|
|
9
9
|
{% endblock %}
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{% extends 'django_spire/card/title_card.html' %}
|
|
2
2
|
|
|
3
3
|
{% block card_title %}
|
|
4
|
-
|
|
4
|
+
spire_model_name_plural
|
|
5
5
|
{% endblock %}
|
|
6
6
|
|
|
7
7
|
{% block card_button %}
|
|
8
|
-
{% url '
|
|
9
|
-
{% include 'django_spire/button/primary_dark_button.html' with button_text='Add' button_icon='bi bi-plus' button_href=
|
|
8
|
+
{% url 'spire_parent_app:spire_app_name:page:form' pk=0 as new_spire_app_name_url %}
|
|
9
|
+
{% include 'django_spire/button/primary_dark_button.html' with button_text='Add' button_icon='bi bi-plus' button_href=new_spire_app_name_url %}
|
|
10
10
|
{% endblock %}
|
|
11
11
|
|
|
12
12
|
{% block card_title_content %}
|
|
13
|
-
{% for
|
|
14
|
-
{% include '
|
|
13
|
+
{% for spire_app_name in spire_app_name_plural %}
|
|
14
|
+
{% include 'spire_parent_app/spire_app_name/item/spire_app_name_item.html' %}
|
|
15
15
|
{% empty %}
|
|
16
16
|
{% include 'django_spire/item/no_data_item.html' %}
|
|
17
17
|
{% endfor %}
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
{% extends 'django_spire/item/item.html' %}
|
|
2
2
|
|
|
3
3
|
{% block item_title %}
|
|
4
|
-
{% url '
|
|
5
|
-
{% include 'django_spire/element/attribute_element.html' with attribute_title='
|
|
4
|
+
{% url 'spire_parent_app:spire_app_name:page:detail' pk=spire_app_name.pk as spire_app_name_view_url %}
|
|
5
|
+
{% include 'django_spire/element/attribute_element.html' with attribute_title='spire_model_name' attribute_value=spire_app_name.name attribute_href=spire_app_name_view_url %}
|
|
6
6
|
{% endblock %}
|
|
7
7
|
|
|
8
8
|
{% block item_row_content %}
|
|
9
|
-
{% include 'django_spire/element/attribute_element.html' with attribute_title='Description' attribute_value=
|
|
9
|
+
{% include 'django_spire/element/attribute_element.html' with attribute_title='Description' attribute_value=spire_app_name.description %}
|
|
10
10
|
{% endblock %}
|
|
11
11
|
|
|
12
12
|
{% block item_button %}
|
|
13
|
-
{% url '
|
|
13
|
+
{% url 'spire_parent_app:spire_app_name:page:detail' pk=spire_app_name.pk as spire_app_name_view_url %}
|
|
14
14
|
|
|
15
|
-
{% if perms.
|
|
16
|
-
{% url '
|
|
15
|
+
{% if perms.spire_label_path.change_spire_app_name %}
|
|
16
|
+
{% url 'spire_parent_app:spire_app_name:page:form' pk=spire_app_name.pk as spire_app_name_edit_url %}
|
|
17
17
|
{% endif %}
|
|
18
18
|
|
|
19
|
-
{% if perms.
|
|
20
|
-
{% url '
|
|
19
|
+
{% if perms.spire_label_path.delete_spire_app_name %}
|
|
20
|
+
{% url 'spire_parent_app:spire_app_name:page:delete' pk=spire_app_name.pk as spire_app_name_delete_url %}
|
|
21
21
|
{% endif %}
|
|
22
22
|
|
|
23
|
-
{% include 'django_spire/dropdown/ellipsis_dropdown.html' with view_url=
|
|
23
|
+
{% include 'django_spire/dropdown/ellipsis_dropdown.html' with view_url=spire_app_name_view_url edit_url=spire_app_name_edit_url delete_url=spire_app_name_delete_url %}
|
|
24
24
|
{% endblock %}
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
{% block page_content %}
|
|
4
4
|
<div class="row g-3">
|
|
5
5
|
<div class="col-12">
|
|
6
|
-
{% include '
|
|
6
|
+
{% include 'spire_parent_app/spire_app_name/card/spire_app_name_detail_card.html' %}
|
|
7
7
|
</div>
|
|
8
8
|
|
|
9
9
|
<div class="col-4">
|
|
10
|
-
{% include 'history/card/activity_list_card.html' with activity_log=
|
|
10
|
+
{% include 'history/card/activity_list_card.html' with activity_log=spire_app_name.activity_log.prefetch_user %}
|
|
11
11
|
</div>
|
|
12
12
|
</div>
|
|
13
13
|
{% endblock %}
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
|
|
115
115
|
<div class="row justify-content-between align-items-center {% block card_title_class %}mb-2 pb-2 border-bottom-secondary{% endblock %}">
|
|
116
116
|
<div class="col">
|
|
117
|
-
<div class="card-title text-uppercase
|
|
117
|
+
<div class="card-title text-uppercase mb-0">{% block card_title %}{% endblock %}</div>
|
|
118
118
|
</div>
|
|
119
119
|
<div class="col-auto d-flex align-items-center" style="min-height: 2.0rem;">
|
|
120
120
|
{% block card_button %}
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
<div
|
|
55
55
|
class="bg-app-layer-one card shadow-lg p-3 {% block modal_content_class %}{% endblock %}"
|
|
56
56
|
{% block modal_content_attributes %}{% endblock %}
|
|
57
|
-
@
|
|
57
|
+
@mousedown.outside="close_modal()"
|
|
58
58
|
>
|
|
59
59
|
{% block modal_content %}
|
|
60
60
|
{% endblock %}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: django-spire
|
|
3
|
-
Version: 0.16.
|
|
3
|
+
Version: 0.16.10
|
|
4
4
|
Summary: A project for Django Spire
|
|
5
5
|
Author-email: Brayden Carlson <braydenc@stratusadv.com>, Nathan Johnson <nathanj@stratusadv.com>
|
|
6
6
|
License: Copyright (c) 2024 Stratus Advanced Technologies and Contributors.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
django_spire/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
2
|
django_spire/conf.py,sha256=EYC1hXqYqheYrb_b6Q93LrSgNl91JV633E4N5j-KGTo,1012
|
|
3
|
-
django_spire/consts.py,sha256=
|
|
3
|
+
django_spire/consts.py,sha256=Ow71iYq9YKFzfgl2K1b9R6Pv-3CSMsRosaHNnhKR0yQ,391
|
|
4
4
|
django_spire/exceptions.py,sha256=L5ndRO5ftMmh0pHkO2z_NG3LSGZviJ-dDHNT73SzTNw,48
|
|
5
5
|
django_spire/settings.py,sha256=NBDa_kZozESTz2UfHgy2PzhBqj54eIrjZsUsWqDgI0g,735
|
|
6
6
|
django_spire/urls.py,sha256=mKeZszb5U4iIGqddMb5Tt5fRC72U2wABEOi6mvOfEBU,656
|
|
@@ -412,16 +412,16 @@ django_spire/core/management/commands/spire_startapp.py,sha256=TWSN7c8-dgn0BBHn6
|
|
|
412
412
|
django_spire/core/management/commands/spire_startapp_pkg/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
413
413
|
django_spire/core/management/commands/spire_startapp_pkg/constants.py,sha256=PPlf_6xV2nQucGvGuqEHk64ZN8HEJiyot1Yst8jSY2A,94
|
|
414
414
|
django_spire/core/management/commands/spire_startapp_pkg/manager.py,sha256=HWgPHtApsDDsw4o1NhboSdw40kr2Yc7WP5Grh9ippkQ,5251
|
|
415
|
-
django_spire/core/management/commands/spire_startapp_pkg/maps.py,sha256=
|
|
415
|
+
django_spire/core/management/commands/spire_startapp_pkg/maps.py,sha256=F2oYHMYII2x1sKMRHEc3hF8Rd3ftjIiIxYnYUALs49A,1140
|
|
416
416
|
django_spire/core/management/commands/spire_startapp_pkg/processor.py,sha256=yEiGQMrgTOxvd-PAvmgFQjFIaAE-NBu80LD2CR5abfY,2623
|
|
417
417
|
django_spire/core/management/commands/spire_startapp_pkg/reporter.py,sha256=alxyyH7zX7f0cFO-rKJq0pP9N7UfZIUGVx2XN9yh7bs,6489
|
|
418
418
|
django_spire/core/management/commands/spire_startapp_pkg/template/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
419
|
-
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_detail_card.html,sha256=
|
|
420
|
-
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_form_card.html,sha256=
|
|
421
|
-
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_list_card.html,sha256=
|
|
419
|
+
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_detail_card.html,sha256=mLq1OENpsrJQ7FiEAwowwE4ZlhcFZuwhfZPvYN3mZs8,953
|
|
420
|
+
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_form_card.html,sha256=m-z23qNNn5R4ctuAypXoQgcti2mz-l57uvBmptBZG-E,233
|
|
421
|
+
django_spire/core/management/commands/spire_startapp_pkg/template/templates/card/spirechildapp_list_card.html,sha256=tJIZLL89SUV8As6RBRiYwIDVhEjgUu8173YRCDaRZHo,659
|
|
422
422
|
django_spire/core/management/commands/spire_startapp_pkg/template/templates/form/spirechildapp_form.html,sha256=fQ-kULFIGACH7YVWK2S4O3hEp1DwjumqxOgymp15e7E,686
|
|
423
|
-
django_spire/core/management/commands/spire_startapp_pkg/template/templates/item/spirechildapp_item.html,sha256=
|
|
424
|
-
django_spire/core/management/commands/spire_startapp_pkg/template/templates/page/spirechildapp_detail_page.html,sha256=
|
|
423
|
+
django_spire/core/management/commands/spire_startapp_pkg/template/templates/item/spirechildapp_item.html,sha256=m_R9HlPcH89eSNcKkNwD8DXnuH7oBU3pw7YrENWgrKI,1244
|
|
424
|
+
django_spire/core/management/commands/spire_startapp_pkg/template/templates/page/spirechildapp_detail_page.html,sha256=dOxIi0ISZwYpyPTrH1IuAJjWR4jWzgtpzaWpWYxSA3I,434
|
|
425
425
|
django_spire/core/management/commands/spire_startapp_pkg/template/templates/page/spirechildapp_form_page.html,sha256=9eSbAsMK8rjzSYmrq_NZOB6F1EphMIO4KIoDlv6YOrw,331
|
|
426
426
|
django_spire/core/management/commands/spire_startapp_pkg/template/templates/page/spirechildapp_list_page.html,sha256=SwTuxzNzTW6_nlZvrglSG2amithT0ZCjnNnrAd9aaA0,236
|
|
427
427
|
django_spire/core/middleware/__init__.py,sha256=peocpyT_vXsjK3MXzpWIbsNVnHBbuyybH90R9V-lN1c,243
|
|
@@ -532,7 +532,7 @@ django_spire/core/templates/django_spire/card/card.html,sha256=nF4s17lygR6vpm2Ja
|
|
|
532
532
|
django_spire/core/templates/django_spire/card/delete_confirmation_form_card.html,sha256=igJRLmsdnHIdFdfydLZ14ut21Ui6UMvm4xyl5xRiNCc,1102
|
|
533
533
|
django_spire/core/templates/django_spire/card/delete_form_card.html,sha256=7nAZ0LuIq9l2BwNiBny_C__Q9EUXYQ_CM1aFXrafd6c,212
|
|
534
534
|
django_spire/core/templates/django_spire/card/form_card.html,sha256=bctVy9CeHuf05xsuE-zEsQVOaq24Igjq6xTKgv2AO4Y,391
|
|
535
|
-
django_spire/core/templates/django_spire/card/infinite_scroll_card.html,sha256=
|
|
535
|
+
django_spire/core/templates/django_spire/card/infinite_scroll_card.html,sha256=MpJ0R9qHwX0FX7GyT8KibWYYF0VLMMr2Ivi39-OnBOs,4713
|
|
536
536
|
django_spire/core/templates/django_spire/card/title_card.html,sha256=nmBD840iBKlI3_gVLX8OvL9LemibGffmQsT0xPxF96g,1065
|
|
537
537
|
django_spire/core/templates/django_spire/container/container.html,sha256=Dfr7K8xgEbg3CZYxMleLjjiQGyRS-GNJdPySA4OYY8U,867
|
|
538
538
|
django_spire/core/templates/django_spire/container/form_container.html,sha256=FZwZs4gnIYkurV5u8v6fj2rbrm4WDX16jyUSTMniEtw,313
|
|
@@ -565,10 +565,10 @@ django_spire/core/templates/django_spire/messages/messages.html,sha256=sHSLWhrsE
|
|
|
565
565
|
django_spire/core/templates/django_spire/messages/element/messages_element.html,sha256=Cx5Emj2E7wh7JFxA7LlJfUbZC5WvT6VNqtzVt1ivk-o,1827
|
|
566
566
|
django_spire/core/templates/django_spire/modal/center_modal.html,sha256=1ceBcqThMJrzrRuxTj4m8FOTcoKrLegArVm2hJfwosU,294
|
|
567
567
|
django_spire/core/templates/django_spire/modal/dispatch_modal.html,sha256=_EOQQC6dmzN1Se1PyX5Brk1X9Hw2mYYuOqVqyK3OHEM,259
|
|
568
|
-
django_spire/core/templates/django_spire/modal/modal.html,sha256=
|
|
568
|
+
django_spire/core/templates/django_spire/modal/modal.html,sha256=jEnUweB81u-EYtQdalNMzZrCs38Ml8gU6-zQRwtRi2s,2290
|
|
569
569
|
django_spire/core/templates/django_spire/modal/title_modal.html,sha256=avPAPBnv4f7XF3O13mJ_osF3-s47iJJXDT2OqN58OjM,664
|
|
570
570
|
django_spire/core/templates/django_spire/modal/content/dispatch_modal_delete_confirmation_content.html,sha256=hvO37DLwM7RMcdF3pFM7RhWN90K_04IAtZq7EEDEBwI,968
|
|
571
|
-
django_spire/core/templates/django_spire/modal/content/modal_title_content.html,sha256=
|
|
571
|
+
django_spire/core/templates/django_spire/modal/content/modal_title_content.html,sha256=zsYlbdo6hPbYWKIxfcvl6IU2IBmZ4SH-ii6oY34InLg,725
|
|
572
572
|
django_spire/core/templates/django_spire/modal/element/model_close_element.html,sha256=yxeesbfVS5PK08UH7IUacBhdtLA7KyIQjK7FrkAOvb8,71
|
|
573
573
|
django_spire/core/templates/django_spire/navigation/mobile_navigation.html,sha256=btXoeLihu3jd_7XzKrZiwaBgffDiLoDorMSxhYrnhc4,997
|
|
574
574
|
django_spire/core/templates/django_spire/navigation/navigation_links.html,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -1041,8 +1041,8 @@ django_spire/theme/urls/page_urls.py,sha256=S8nkKkgbhG3XHI3uMUL-piOjXIrRkuY2UlM_
|
|
|
1041
1041
|
django_spire/theme/views/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
1042
1042
|
django_spire/theme/views/json_views.py,sha256=W1khC2K_EMbEzAFmMxC_P76_MFnkRH4-eVdodrRfAhw,1904
|
|
1043
1043
|
django_spire/theme/views/page_views.py,sha256=pHr8iekjtR99xs7w1taj35HEo133Svq1dvDD0y0VL1c,3933
|
|
1044
|
-
django_spire-0.16.
|
|
1045
|
-
django_spire-0.16.
|
|
1046
|
-
django_spire-0.16.
|
|
1047
|
-
django_spire-0.16.
|
|
1048
|
-
django_spire-0.16.
|
|
1044
|
+
django_spire-0.16.10.dist-info/licenses/LICENSE.md,sha256=tlTbOtgKoy-xAQpUk9gPeh9O4oRXCOzoWdW3jJz0wnA,1091
|
|
1045
|
+
django_spire-0.16.10.dist-info/METADATA,sha256=Dl8otaoxAbIa52nZpYEax00eok1uBqfcl5uBEfsoej0,4763
|
|
1046
|
+
django_spire-0.16.10.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
1047
|
+
django_spire-0.16.10.dist-info/top_level.txt,sha256=xf3QV1e--ONkVpgMDQE9iqjQ1Vg4--_6C8wmO-KxPHQ,13
|
|
1048
|
+
django_spire-0.16.10.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|