replaced subscribe by register for events

This commit is contained in:
Danhia 2022-01-24 16:11:03 +01:00
parent 1081fb35b2
commit 6c0cc7d5c8
9 changed files with 10 additions and 10 deletions

View File

@ -111,10 +111,10 @@
<li class="list-group-item">{% trans "Starts at" %} : {{ event.start_date | date:'H:i d-m-y'}}</li>
<li class="list-group-item">{% trans "Ends at" %} : {{ event.end_date | date:'H:i d-m-y'}}</li>
{% if ended == False and IsRegistered == False %}
<form method='POST' action="{% url 'events:subscribe_event' event_slug=event.slug %}">
<form method='POST' action="{% url 'events:register_event' event_slug=event.slug %}">
{%csrf_token%}
<li class="list-group-item">
<input class="form-control" type="submit" value="{% trans "Subscribe" %}">
<input class="form-control" type="submit" value="{% trans "Register" %}">
</li>
</form>
{% endif %}

View File

@ -9,7 +9,7 @@ urlpatterns = [
path('<str:event_slug>/challenge/<str:chall_slug>', views.chall_event_info, name='event_chall_info'),
path('pwd/<str:event_slug>', views.submit_pwd, name='submit_pwd'),
path('submitEventFlag/<str:event_slug>/<str:chall_slug>', views.submit_event_flag, name='submit_event_flag'),
path('subscribe/<str:event_slug>', views.subscribe_to_event, name='subscribe_event'),
path('register/<str:event_slug>', views.register_to_event, name='register_event'),
path('create_team/<str:event_slug>', views.create_team, name='create_team'),
path('join_team/<str:event_slug>', views.join_team, name='join_team'),
path('<str:event_slug>/profile/<str:user_name>', views.profile, name='profile'),

View File

@ -197,7 +197,7 @@ def submit_pwd(request, event_slug):
@login_required
def subscribe_to_event(request, event_slug):
def register_to_event(request, event_slug):
response = redirect('events:event_info', event_slug=event_slug)
if request.method == 'POST':
if request.user.is_authenticated:

View File

@ -386,7 +386,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr ""
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127

View File

@ -386,7 +386,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr ""
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127

View File

@ -386,7 +386,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr ""
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127

View File

@ -406,7 +406,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr "Personne n'a encore gagné de point, allez-vous être le premier ?"
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127

View File

@ -386,7 +386,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr ""
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127

View File

@ -394,7 +394,7 @@ msgid "No one have earn point yet, you gonna be the first ?"
msgstr ""
#: events/templates/events/event_info.html:117
msgid "Subscribe"
msgid "Register"
msgstr ""
#: events/templates/events/event_info.html:127