W4npnTX{fz17q#ZAF&cLxKc<*p+7mHtoQ`!t
z4Wu7x&BvoUJ{8#xW*(|Thf#a$I0owdKTAa)xQ5z%w=oRwV;!uS?)11h>W1x5GtmpR
zX@{XcpO3?E7KY91OrE7>ld05gtbuK0!Um)zMjkim1=kL9KBNCSzOF_d_1$;HRh#2X%5j
zU&BpB-%JsxsY%0BoQi+Ko%k$P=>StmFEW|)uj+%iD7=T->yHOAN7PWK_F%~@;MR{zD
zx?c+F!Rb!hZ8E87>atNc?rR;0(X@x5J}?hGa31$!s!=sKdoXf7C)r
zS&5*cH%{fhrN3!yqOy?GBTtB?Z6wi#RJlpCG}F|ur9J+OTq3i`Qj$x)A^%_WrKG=l
z1D-ljNIjgC{{P=Y!?NXP>mK|wVbJCj2_q`n)tkvDWE=UC#FKZ4%1aLBv{kIL_4PQG
z946XRD(*af?IcZ!$^!BO`B4qZGNK(Frv~L9nL{q9L1{%skjH9JHjr{;s$^g*P^Aue
zjm%Sna?inCN+!Scg`o1bL+S5-K2`5S{Setsy4mBqtdsCMxkAnny+LK=uC2_s>it()
zOcJyknp3Gy9+1D10;2MjgXxLy6E8+{3onx$ta$T~#zftvO$Im9+l-IS@mBC2Pn8@*Me`JYDY7I7$8>Lv(^pw2+jKNj7OjI+MAiB6*R#
zMf8u<;i$63q4eJp)3yG4i4U1U_7g9n(#FAji%Fy{DI(vIL{e6^+RE$rQ`tfMfP8P;
zA6i8qxnbM7uX$)2CD@mYCrgMwSwvnS4T#D>2lH9c;E){8qOj`cf{Pl(d3!EMir?%?
zNKSly!L9gk?|^I
E0Ri(+DF6Tf
diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po
index 74b942e..e40e7a9 100644
--- a/locale/fr/LC_MESSAGES/django.po
+++ b/locale/fr/LC_MESSAGES/django.po
@@ -7,8 +7,8 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2017-11-04 14:58+0000\n"
-"PO-Revision-Date: 2017-11-04 15:58+0100\n"
+"POT-Creation-Date: 2017-11-04 19:09+0000\n"
+"PO-Revision-Date: 2017-11-04 20:11+0100\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: fr\n"
@@ -34,15 +34,15 @@ msgstr "Décliné"
msgid "Waiting"
msgstr "En attente"
-#: cfp/forms.py:29 cfp/forms.py:130 cfp/forms.py:237 cfp/models.py:353
+#: cfp/forms.py:29 cfp/forms.py:130 cfp/forms.py:237 cfp/models.py:357
msgid "Confirmed"
msgstr "Confirmé"
-#: cfp/forms.py:30 cfp/models.py:355
+#: cfp/forms.py:30 cfp/models.py:359
msgid "Cancelled"
msgstr "Annulé"
-#: cfp/forms.py:62 cfp/models.py:448
+#: cfp/forms.py:62 cfp/models.py:452
msgid "Activity"
msgstr "Activité"
@@ -65,13 +65,13 @@ msgstr "Catégorie"
msgid "Title"
msgstr "Titre"
-#: cfp/forms.py:108 cfp/models.py:147 cfp/models.py:443
-#: cfp/templates/cfp/proposal_talk_details.html:67
+#: cfp/forms.py:108 cfp/models.py:151 cfp/models.py:447
+#: cfp/templates/cfp/proposal_talk_details.html:73
#: cfp/templates/cfp/staff/talk_details.html:64
msgid "Description"
msgstr "Description"
-#: cfp/forms.py:109 cfp/models.py:111 cfp/models.py:424
+#: cfp/forms.py:109 cfp/models.py:111 cfp/models.py:428
#: cfp/templates/cfp/staff/participant_details.html:19
#: cfp/templates/cfp/staff/talk_details.html:78
#: cfp/templates/cfp/staff/volunteer_details.html:20
@@ -82,7 +82,7 @@ msgstr "Notes"
msgid "Visible by speakers"
msgstr "Visible par les orateurs"
-#: cfp/forms.py:136 cfp/forms.py:243 cfp/models.py:310
+#: cfp/forms.py:136 cfp/forms.py:243 cfp/models.py:314
#: cfp/templates/cfp/staff/talk_details.html:21
#: cfp/templates/cfp/staff/talk_list.html:46
#: cfp/templates/cfp/staff/track_form.html:14
@@ -120,7 +120,7 @@ msgstr "Programmé"
msgid "Filter talks already / not yet scheduled"
msgstr "Filtrer les exposés déjà / pas encore planifiées"
-#: cfp/forms.py:160 cfp/models.py:327
+#: cfp/forms.py:160 cfp/models.py:331
#: cfp/templates/cfp/staff/talk_details.html:54
msgid "Materials"
msgstr "Supports"
@@ -157,7 +157,7 @@ msgstr "Ajouter une étiquette"
msgid "Put in a room"
msgstr "Assigner à une salle"
-#: cfp/forms.py:259 cfp/models.py:419
+#: cfp/forms.py:259 cfp/models.py:423
#: cfp/templates/cfp/staff/volunteer_details.html:11
#: cfp/templates/cfp/staff/volunteer_list.html:30
msgid "Email"
@@ -242,7 +242,7 @@ msgstr ""
"L’adresse de réponse doit être une chaine de texte formatable avec un "
"argument « token » (e.g. ponyconf+{token}@exemple.com)."
-#: cfp/models.py:99 cfp/models.py:145 cfp/models.py:197 cfp/models.py:441
+#: cfp/models.py:99 cfp/models.py:149 cfp/models.py:201 cfp/models.py:445
#: cfp/templates/cfp/staff/participant_list.html:35
#: cfp/templates/cfp/staff/volunteer_list.html:29
msgid "Name"
@@ -277,12 +277,12 @@ msgstr "Facebook"
msgid "Mastodon"
msgstr "Mastodon"
-#: cfp/models.py:109 cfp/models.py:421
+#: cfp/models.py:109 cfp/models.py:425
#: cfp/templates/cfp/staff/volunteer_details.html:14
msgid "Phone number"
msgstr "Numéro de téléphone"
-#: cfp/models.py:112 cfp/models.py:309
+#: cfp/models.py:112 cfp/models.py:313
msgid "This field is only visible by organizers."
msgstr "Ce champs est uniquement visible par les organisateurs."
@@ -290,23 +290,23 @@ msgstr "Ce champs est uniquement visible par les organisateurs."
msgid "Invited speaker"
msgstr "Orateur invité"
-#: cfp/models.py:199
+#: cfp/models.py:203
msgid "Color"
msgstr "Couleur"
-#: cfp/models.py:231
+#: cfp/models.py:235
msgid "Default duration (min)"
msgstr "Durée par défaut (min)"
-#: cfp/models.py:232
+#: cfp/models.py:236
msgid "Color on program"
msgstr "Couleur sur le programme"
-#: cfp/models.py:233
+#: cfp/models.py:237
msgid "Label on program"
msgstr "Label dans le xml du programme"
-#: cfp/models.py:304 cfp/templates/cfp/proposal_talk_details.html:51
+#: cfp/models.py:308 cfp/templates/cfp/proposal_talk_details.html:51
#: cfp/templates/cfp/staff/base.html:11
#: cfp/templates/cfp/staff/participant_list.html:8
#: cfp/templates/cfp/staff/talk_details.html:68
@@ -314,19 +314,19 @@ msgstr "Label dans le xml du programme"
msgid "Speakers"
msgstr "Orateurs"
-#: cfp/models.py:305
+#: cfp/models.py:309
msgid "Talk Title"
msgstr "Titre de la proposition"
-#: cfp/models.py:308
+#: cfp/models.py:312
msgid "Description of your talk"
msgstr "Description de votre proposition"
-#: cfp/models.py:312 cfp/templates/cfp/proposal_talk_details.html:77
+#: cfp/models.py:316 cfp/templates/cfp/proposal_talk_details.html:83
msgid "Message to organizers"
msgstr "Message aux organisateurs"
-#: cfp/models.py:313
+#: cfp/models.py:317
msgid ""
"If you have any constraint or if you have anything that may help you to "
"select your talk, like a video or slides of your talk, please write it down "
@@ -336,67 +336,67 @@ msgstr ""
"votre proposition, comme une vidéo, des slides, n'hésitez pas à les ajouter "
"ici."
-#: cfp/models.py:316
+#: cfp/models.py:320
msgid "Talk Category"
msgstr "Catégorie de proposition"
-#: cfp/models.py:317
+#: cfp/models.py:321
msgid "I'm ok to be recorded on video"
msgstr "J’accepte d’être enregistré en vidéo"
-#: cfp/models.py:319
+#: cfp/models.py:323
msgid "Video licence"
msgstr "Licence vidéo"
-#: cfp/models.py:320
+#: cfp/models.py:324
msgid "I need sound"
msgstr "J’ai besoin de son"
-#: cfp/models.py:323
+#: cfp/models.py:327
msgid "Beginning date and time"
msgstr "Date et heure de début"
-#: cfp/models.py:324
+#: cfp/models.py:328
msgid "Duration (min)"
msgstr "Durée (min)"
-#: cfp/models.py:328
+#: cfp/models.py:332
msgid ""
"You can use this field to share some materials related to your intervention."
msgstr ""
"Vous pouvez utiliser ce champs pour partager les supports de votre "
"intervention."
-#: cfp/models.py:357
+#: cfp/models.py:361
msgid "Waiting confirmation"
msgstr "En attente de confirmation"
-#: cfp/models.py:359
+#: cfp/models.py:363
msgid "Refused"
msgstr "Refusé"
-#: cfp/models.py:361
+#: cfp/models.py:365
#, python-format
msgid "Pending decision, score: %(score).1f"
msgstr "En cours, score : %(score).1f"
-#: cfp/models.py:418
+#: cfp/models.py:422
msgid "Your Name"
msgstr "Votre Nom"
-#: cfp/models.py:422
+#: cfp/models.py:426
msgid "SMS prefered"
msgstr "SMS préférés"
-#: cfp/models.py:425
+#: cfp/models.py:429
msgid "If you have some constraints, you can indicate them here."
msgstr "Si vous avez des contraintes, vous pouvez les indiquer ici."
-#: cfp/models.py:444 cfp/templates/cfp/staff/volunteer_details.html:8
+#: cfp/models.py:448 cfp/templates/cfp/staff/volunteer_details.html:8
msgid "Volunteer"
msgstr "Bénévole"
-#: cfp/models.py:449 cfp/templates/cfp/staff/volunteer_details.html:25
+#: cfp/models.py:453 cfp/templates/cfp/staff/volunteer_details.html:25
#: cfp/templates/cfp/staff/volunteer_list.html:32
msgid "Activities"
msgstr "Activités"
@@ -433,7 +433,7 @@ msgstr "Ajouter un nouvel utilisateur"
#: cfp/templates/cfp/admin/conference.html:14
#: cfp/templates/cfp/proposal_home.html:28
#: cfp/templates/cfp/proposal_mail_token.html:25
-#: cfp/templates/cfp/proposal_speaker_form.html:38
+#: cfp/templates/cfp/proposal_speaker_form.html:48
#: cfp/templates/cfp/proposal_talk_form.html:28
#: cfp/templates/cfp/staff/create_user.html:13
msgid "Save"
@@ -565,14 +565,18 @@ msgid "Edit a speaker"
msgstr "Éditer un orateur"
#: cfp/templates/cfp/proposal_speaker_form.html:15
-#: cfp/templates/cfp/proposal_talk_details.html:63
+#: cfp/templates/cfp/proposal_talk_details.html:69
msgid "Add a co-speaker"
-msgstr "Ajouter un co-orateur"
+msgstr "Ajouter un co-intervenant"
#: cfp/templates/cfp/proposal_speaker_form.html:17
msgid "Go back to the talk"
msgstr "Retourner à l’exposé"
+#: cfp/templates/cfp/proposal_speaker_form.html:36
+msgid "You may want to add one of the following speakers:"
+msgstr "Vous souhaitez peut-être ajouter un des intervenants suivants :"
+
#: cfp/templates/cfp/proposal_talk_details.html:14
msgid "My profile"
msgstr "Mon profil"
@@ -619,12 +623,16 @@ msgstr "Bonne nouvelle, je peux finalement être présent !"
msgid "Sorry, refused :-("
msgstr "Désolé, refusé :-("
-#: cfp/templates/cfp/proposal_talk_details.html:58
+#: cfp/templates/cfp/proposal_talk_details.html:59
msgid "you!"
msgstr "vous !"
-#: cfp/templates/cfp/proposal_talk_details.html:73
-#: cfp/templates/cfp/proposal_talk_details.html:83
+#: cfp/templates/cfp/proposal_talk_details.html:62
+msgid "remove"
+msgstr "supprimer"
+
+#: cfp/templates/cfp/proposal_talk_details.html:79
+#: cfp/templates/cfp/proposal_talk_details.html:89
#: cfp/templates/cfp/staff/talk_details.html:66
msgid "No description provided."
msgstr "Aucune description fournie."
@@ -1154,51 +1162,59 @@ msgstr "Nous avons enregistré votre indisponibilité."
msgid "Speaker %(speaker)s CANCELLED his/her participation."
msgstr "L’intervenant %(speaker)s a ANNULÉ sa participation."
-#: cfp/views.py:397
+#: cfp/views.py:352
+msgid "Co-speaker successfully added to the talk."
+msgstr "Co-intervenant ajouté à l’exposé avec succès."
+
+#: cfp/views.py:365
+msgid "Co-speaker successfully removed from the talk."
+msgstr "Co-intervenant supprimé de l’exposé avec succès."
+
+#: cfp/views.py:407
msgid "The speaker confirmation have been noted."
msgstr "La confirmation de l’orateur a été notée."
-#: cfp/views.py:398
+#: cfp/views.py:408
msgid "The talk have been confirmed."
msgstr "L’exposé a été confirmé."
-#: cfp/views.py:400
+#: cfp/views.py:410
msgid "The speaker unavailability have been noted."
msgstr "L’indisponibilité de l’intervenant a été notée."
-#: cfp/views.py:401
+#: cfp/views.py:411
msgid "The talk have been cancelled."
msgstr "L’exposé a été annulé."
-#: cfp/views.py:476 cfp/views.py:578
+#: cfp/views.py:486 cfp/views.py:588
msgid "The talk has been accepted."
msgstr "L’exposé a été accepté."
-#: cfp/views.py:478 cfp/views.py:580
+#: cfp/views.py:488 cfp/views.py:590
msgid "The talk has been declined."
msgstr "L’exposé a été décliné."
-#: cfp/views.py:547 cfp/views.py:640
+#: cfp/views.py:557 cfp/views.py:650
msgid "Message sent!"
msgstr "Message envoyé !"
-#: cfp/views.py:561
+#: cfp/views.py:571
msgid "Vote successfully created"
msgstr "A voté !"
-#: cfp/views.py:561
+#: cfp/views.py:571
msgid "Vote successfully updated"
msgstr "Vote mis à jour"
-#: cfp/views.py:582
+#: cfp/views.py:592
msgid "Decision taken in account"
msgstr "Décision enregistrée"
-#: cfp/views.py:668
+#: cfp/views.py:678
msgid "[{}] You have been added to the staff team"
msgstr "[{}] Vous avez été ajouté aux membres du staff"
-#: cfp/views.py:669
+#: cfp/views.py:679
msgid ""
"Hi {},\n"
"\n"
@@ -1222,15 +1238,15 @@ msgstr ""
"{}\n"
"\n"
-#: cfp/views.py:690
+#: cfp/views.py:700
msgid "Modifications successfully saved."
msgstr "Modification enregistrée avec succès."
-#: cfp/views.py:767
+#: cfp/views.py:777
msgid "User created successfully."
msgstr "Utilisateur créé avec succès."
-#: cfp/views.py:788
+#: cfp/views.py:798
#, python-format
msgid "Format '%s' not available"
msgstr "Format '%s' non disponible"
From c7f20b236298a72b371f2f1d2a89a3e8fbf89b6b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=89lie=20Bouttier?=
Date: Sat, 4 Nov 2017 21:12:58 +0100
Subject: [PATCH 6/7] notify co-speaker
---
cfp/forms.py | 5 ++
cfp/views.py | 43 +++++++++++++-
locale/fr/LC_MESSAGES/django.mo | Bin 21053 -> 21786 bytes
locale/fr/LC_MESSAGES/django.po | 102 +++++++++++++++++++++++---------
4 files changed, 120 insertions(+), 30 deletions(-)
diff --git a/cfp/forms.py b/cfp/forms.py
index a2bc667..ec862e1 100644
--- a/cfp/forms.py
+++ b/cfp/forms.py
@@ -196,12 +196,17 @@ class TalkActionForm(forms.Form):
class ParticipantForm(OnSiteNamedModelForm):
+ notify = forms.BooleanField(initial=True, required=False, label=_('Notify by mail?'))
+
def __init__(self, *args, **kwargs):
social = kwargs.pop('social', True)
+ ask_notify = kwargs.pop('ask_notify', False)
super().__init__(*args, **kwargs)
if not social:
for field in ['twitter', 'linkedin', 'github', 'website', 'facebook', 'mastodon']:
self.fields.pop(field)
+ if not ask_notify:
+ self.fields.pop('notify')
class Meta:
model = Participant
diff --git a/cfp/views.py b/cfp/views.py
index 0e7d2cf..416c6e9 100644
--- a/cfp/views.py
+++ b/cfp/views.py
@@ -326,11 +326,52 @@ def proposal_speaker_edit(request, speaker, talk_id=None, co_speaker_id=None):
co_speaker = get_object_or_404(Participant, site=request.conference.site, talk__pk=talk.pk, pk=co_speaker_id)
else:
co_speaker_candidates = speaker.co_speaker_set.exclude(pk__in=talk.speakers.values_list('pk'))
- form = ParticipantForm(request.POST or None, conference=request.conference, instance=co_speaker if talk else speaker)
+ form = ParticipantForm(request.POST or None, conference=request.conference,
+ instance=co_speaker if talk else speaker, ask_notify=talk and not co_speaker)
if request.method == 'POST' and form.is_valid():
edited_speaker = form.save()
if talk:
talk.speakers.add(edited_speaker)
+ if co_speaker_id:
+ messages.success(request, _('Changes saved.'))
+ else:
+ if form.cleaned_data['notify']:
+ base_url = ('https' if request.is_secure() else 'http') + '://' + request.conference.site.domain
+ url_dashboard = base_url + reverse('proposal-dashboard', kwargs=dict(speaker_token=edited_speaker.token))
+ url_talk_details = base_url + reverse('proposal-talk-details', kwargs=dict(speaker_token=edited_speaker.token, talk_id=talk.pk))
+ url_speaker_add = base_url + reverse('proposal-speaker-add', kwargs=dict(speaker_token=edited_speaker.token, talk_id=talk.pk))
+ body = _("""Hi {},
+
+{} add you as a co-speaker for the conference {}.
+
+Here is a summary of the talk:
+Title: {}
+Description: {}
+
+You can at anytime:
+- review and edit your profile: {}
+- review and edit the talk: {}
+- add another co-speaker: {}
+
+If you have any question, your can answer to this email.
+
+Thanks!
+
+{}
+
+""").format(
+ edited_speaker.name, speaker.name, request.conference.name,
+ talk.title, talk.description,
+ url_dashboard, url_talk_details, url_speaker_add,
+ request.conference.name,
+ )
+ Message.objects.create(
+ thread=edited_speaker.conversation,
+ author=request.conference,
+ from_email=request.conference.contact_email,
+ content=body,
+ )
+ messages.success(request, _('Co-speaker successfully added to the talk.'))
#return redirect(reverse('proposal-speaker-details', kwargs=dict(speaker_token=speaker.token, talk_id=talk.pk)))
return redirect(reverse('proposal-talk-details', kwargs=dict(speaker_token=speaker.token, talk_id=talk.pk)))
else:
diff --git a/locale/fr/LC_MESSAGES/django.mo b/locale/fr/LC_MESSAGES/django.mo
index 731ab28f779e900cd0b78be40671dc52cf19180a..62cf5537c7e6fed2d9cb8525c88498302e07a6dd 100644
GIT binary patch
delta 6060
zcmYk=33L=i0><$Q#ab>YF49eU{j<$WXv`S8u5FmfqaC~_&IjMudxdzw{|vCOrb6i
zMh)}{+x`sd_}8!{Zb8k+9@LB-K@F%Lb^aL)spH=$Xv8rrpr$4nJ(z|aa4=@!47?Io
zVlHk*t$jUeM$Vz`Fp&pI*U7TxqB`t~+TR;>UTHe(pGl#dhWBw9F2^x#SU)_5**uIl
zwlyXnXSZ|jc#Y#;;1$$E_%`y7*~7mykWe`L_+2GqkAz-XL@8ej_SkIKj;M!Z7-|5MQ6rv#dWb@(j+UU-FpSZ-8`Z%+R0jua`%%=5eTSNn
z)7GRM%>e74ML~CT73#!d)YK0{U3dac!YQbM?LsX@J!;9~JGd8ikQc!8LcM;asN>48
z8!okOM}45qU_AYsCLP_8w?y6X<)}N(z*zKHd!nYi7#m{=YJjDv<8MZtUuLaB&Bz_7
zJ70_%&{H@Rw_~W1LSiTPj^`q6X1T3z#?I9DqVDXx^)ecHGfh`(30_4#fCac3^~KzW
zx?WVSy9Aw41L}slvBF&Dzm!5h+py9e@U*Qzk8$jO3FEOAH3M6bZS)(oBsBQSeY$iW=co)E(}`LOg)YFeTspm1~cDD$Een
zlK7ETF-uV$Z$!ps-o&PO95qAd?EVYbh!>DiiU!Hz9qzF8J+2|MpMs|HfZcH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?{1`xY5a
zGVT5$c$&;50|>uL%`~EIHTesvK#r0Z$n!*-YIVrda{mddrWf~k3x6V71ZXofk@f=emECs=?&s2GLS3-`=#10-Qu{lGfy9qOFLe6F&x|?QbrgSDvmv(Do~1UownL
zCKHI~`PQU>lsgHLf!#pDO#O|b%O!NTZ|
zBHC7xmgHv=Mf}LKL|Z>Hi2O
Date: Sat, 4 Nov 2017 21:37:53 +0100
Subject: [PATCH 7/7] handle closed cfp
---
cfp/templates/cfp/closed.html | 18 ++++++++++++++++++
cfp/templates/cfp/proposal_dashboard.html | 2 ++
cfp/templates/cfp/proposal_talk_details.html | 2 ++
cfp/views.py | 2 ++
4 files changed, 24 insertions(+)
create mode 100644 cfp/templates/cfp/closed.html
diff --git a/cfp/templates/cfp/closed.html b/cfp/templates/cfp/closed.html
new file mode 100644
index 0000000..3fc2bc3
--- /dev/null
+++ b/cfp/templates/cfp/closed.html
@@ -0,0 +1,18 @@
+{% extends 'base.html' %}
+{% load i18n %}
+
+{% block proposetab %} class="active"{% endblock %}
+
+{% block content %}
+
+
+{% trans "Sorry, the Call for Participation is closed!" %}
+
+{% url 'proposal-mail-token' as mail_token_url %}
+{% blocktrans %}If you already have submitted a talk and you want to edit it, please click here.{% endblocktrans %}
+
+{% endblock %}
diff --git a/cfp/templates/cfp/proposal_dashboard.html b/cfp/templates/cfp/proposal_dashboard.html
index c1d3b28..0fabb3c 100644
--- a/cfp/templates/cfp/proposal_dashboard.html
+++ b/cfp/templates/cfp/proposal_dashboard.html
@@ -71,7 +71,9 @@
{% trans "No proposals." %}
{% endfor %}
+{% if conference.opened_categories.exists %}
{% trans "New proposal" %}
+{% endif %}
{% endblock %}
diff --git a/cfp/templates/cfp/proposal_talk_details.html b/cfp/templates/cfp/proposal_talk_details.html
index 5707479..7a0fd6a 100644
--- a/cfp/templates/cfp/proposal_talk_details.html
+++ b/cfp/templates/cfp/proposal_talk_details.html
@@ -13,9 +13,11 @@
{% trans "My profile" %}
+ {% if conference.opened_categories.exists %}
{% trans "New proposal" %}
+ {% endif %}
{% trans "Edit this proposal" %}
diff --git a/cfp/views.py b/cfp/views.py
index 416c6e9..b02ad68 100644
--- a/cfp/views.py
+++ b/cfp/views.py
@@ -143,6 +143,8 @@ def proposal_home(request):
categories = TalkCategory.objects.filter(site=request.conference.site)
else:
categories = request.conference.opened_categories
+ if not categories.exists():
+ return render(request, 'cfp/closed.html')
speaker_form = ParticipantForm(request.POST or None, conference=request.conference, social=False)
talk_form = TalkForm(request.POST or None, categories=categories)
if request.method == 'POST' and all(map(lambda f: f.is_valid(), [speaker_form, talk_form])):
|