mirror of
https://gitlab.crans.org/bde/nk20
synced 2025-07-03 14:22:49 +02:00
Compare commits
14 Commits
420a24ebac
...
v1.0.1
Author | SHA1 | Date | |
---|---|---|---|
5c702187e5 | |||
3191dba31f | |||
9b8caa7fa1 | |||
f1dac73c08 | |||
1ed74021a2 | |||
81ad38927d | |||
2f6c7ed156 | |||
2b2dde85dc | |||
863150d200 | |||
ebe6ce61e4 | |||
3c636e9f71 | |||
d054d58661 | |||
9f42ecb97a | |||
1fd7d76412 |
@ -13,29 +13,15 @@ SPDX-License-Identifier: GPL-3.0-or-later
|
||||
{% if additional_fee_renewal %}
|
||||
<div class="alert alert-warning">
|
||||
{% if renewal %}
|
||||
{% if club.name == "Kfet" %} {# Auto-renewal #}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
The user is not a member of the club·s {{ clubs }}. An additional fee of {{ pretty_fee }}
|
||||
will be charged to renew automatically the membership in this/these club·s.
|
||||
{% endblocktrans %}
|
||||
{% else %}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
The user is not a member of the club·s {{ clubs }}. Please create the required memberships,
|
||||
otherwise it will fail.
|
||||
{% endblocktrans %}
|
||||
{% endif %}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
The user is not a member of the club·s {{ clubs }}. An additional fee of {{ pretty_fee }}
|
||||
will be charged to renew automatically the membership in this/these club·s.
|
||||
{% endblocktrans %}
|
||||
{% else %}
|
||||
{% if club.name == "Kfet" %}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
This club has parents {{ clubs }}. An additional fee of {{ pretty_fee }}
|
||||
will be charged to adhere automatically to this/these club·s.
|
||||
{% endblocktrans %}
|
||||
{% else %}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
This club has parents {{ clubs }}. Please make sure that the user is a member of this or these club·s,
|
||||
otherwise the creation of this membership will fail.
|
||||
{% endblocktrans %}
|
||||
{% endif %}
|
||||
{% blocktrans trimmed with clubs=clubs_renewal|join:", " pretty_fee=additional_fee_renewal|pretty_money %}
|
||||
This club has parents {{ clubs }}. An additional fee of {{ pretty_fee }}
|
||||
will be charged to adhere automatically to this/these club·s.
|
||||
{% endblocktrans %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
@ -610,9 +610,6 @@ class ClubAddMemberView(ProtectQuerysetMixin, ProtectedCreateView):
|
||||
bank = form.cleaned_data["bank"]
|
||||
soge = form.cleaned_data["soge"] and not user.profile.soge and (club.name == "BDE" or club.name == "Kfet")
|
||||
|
||||
if not credit_type:
|
||||
credit_amount = 0
|
||||
|
||||
if not soge and user.note.balance + credit_amount < fee and not Membership.objects.filter(
|
||||
club__name="Kfet",
|
||||
user=user,
|
||||
@ -634,16 +631,6 @@ class ClubAddMemberView(ProtectQuerysetMixin, ProtectedCreateView):
|
||||
form.add_error('user', _('User is already a member of the club'))
|
||||
error = True
|
||||
|
||||
# Must join the parent club before joining this club, except for the Kfet club where it can be at the same time.
|
||||
if club.name != "Kfet" and club.parent_club and not Membership.objects.filter(
|
||||
user=form.instance.user,
|
||||
club=club.parent_club,
|
||||
date_start__lte=club.parent_club.membership_start,
|
||||
date_end__gte=club.parent_club.membership_end,
|
||||
).exists():
|
||||
form.add_error('user', _('User is not a member of the parent club') + ' ' + club.parent_club.name)
|
||||
error = True
|
||||
|
||||
if club.membership_start and form.instance.date_start < club.membership_start:
|
||||
form.add_error('user', _("The membership must start after {:%m-%d-%Y}.")
|
||||
.format(form.instance.club.membership_start))
|
||||
|
@ -253,7 +253,7 @@ function consume (source, source_alias, dest, quantity, amount, reason, type, ca
|
||||
template: template
|
||||
}).done(function () {
|
||||
reset()
|
||||
addMsg(gettext("La transaction n'a pas pu être validée pour cause de solde insuffisant."), 'danger', 10000)
|
||||
addMsg("La transaction n'a pas pu être validée pour cause de solde insuffisant.", 'danger', 10000)
|
||||
}).fail(function () {
|
||||
reset()
|
||||
errMsg(e.responseJSON)
|
||||
|
@ -159,7 +159,7 @@ SPDX-License-Identifier: GPL-3.0-or-later
|
||||
{% endblock %}
|
||||
|
||||
{% block extrajavascript %}
|
||||
<script type="text/javascript" src="{% static "note/js/consos.js" 'javascript-catalog' %}"></script>
|
||||
<script type="text/javascript" src="{% static "note/js/consos.js" %}"></script>
|
||||
<script type="text/javascript">
|
||||
{% for button in highlighted %}
|
||||
{% if button.display %}
|
||||
|
@ -2775,22 +2775,6 @@
|
||||
"description": "Modifier n'importe quel profil non encore inscrit"
|
||||
}
|
||||
},
|
||||
{
|
||||
"model": "permission.permission",
|
||||
"pk": 178,
|
||||
"fields": {
|
||||
"model": [
|
||||
"note",
|
||||
"alias"
|
||||
],
|
||||
"query": "{}",
|
||||
"type": "view",
|
||||
"mask": 3,
|
||||
"field": "",
|
||||
"permanent": false,
|
||||
"description": "Voir tous les alias, y compris ceux des non adhérents"
|
||||
}
|
||||
},
|
||||
{
|
||||
"model": "permission.role",
|
||||
"pk": 1,
|
||||
@ -3002,8 +2986,7 @@
|
||||
174,
|
||||
175,
|
||||
176,
|
||||
177,
|
||||
178
|
||||
177
|
||||
]
|
||||
}
|
||||
},
|
||||
@ -3185,8 +3168,7 @@
|
||||
174,
|
||||
175,
|
||||
176,
|
||||
177,
|
||||
178
|
||||
177
|
||||
]
|
||||
}
|
||||
},
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -3,7 +3,7 @@
|
||||
"model": "sites.site",
|
||||
"pk": 1,
|
||||
"fields": {
|
||||
"domain": "note.crans.org",
|
||||
"domain": "localhost",
|
||||
"name": "La Note Kfet \ud83c\udf7b"
|
||||
}
|
||||
}
|
||||
|
@ -6,7 +6,6 @@ from django.conf.urls.static import static
|
||||
from django.urls import path, include
|
||||
from django.views.defaults import bad_request, permission_denied, page_not_found, server_error
|
||||
from django.views.generic import RedirectView
|
||||
from django.views.i18n import JavaScriptCatalog
|
||||
|
||||
from member.views import CustomLoginView
|
||||
|
||||
@ -35,9 +34,6 @@ urlpatterns = [
|
||||
|
||||
# Make coffee
|
||||
path('coffee/', include('django_htcpcp_tea.urls')),
|
||||
|
||||
# Translate js
|
||||
path('jsi18n/', JavaScriptCatalog.as_view(), name='javascript-catalog'),
|
||||
]
|
||||
|
||||
# During development, serve media files
|
||||
|
Reference in New Issue
Block a user