|
@@ -7,11 +7,9 @@ from django import forms
|
|
|
from django.forms import formset_factory
|
|
|
from django.shortcuts import render, redirect
|
|
|
|
|
|
-from .models import MaillingList
|
|
|
+from .models import MaillingList, SyncCommandError
|
|
|
from coin.members.models import Member
|
|
|
|
|
|
-#MaillingListFormSet = modelformset_factory(MaillingList, fields=)
|
|
|
-
|
|
|
|
|
|
class SubscriptionForm(forms.Form):
|
|
|
subscribed = forms.BooleanField(widget=forms.Select(choices=(
|
|
@@ -58,7 +56,7 @@ def lists_list(request):
|
|
|
|
|
|
for mail_list in old_subscriptions - new_subscriptions:
|
|
|
request.user.subscribed_maillinglists.remove(mail_list)
|
|
|
- except SystemError as e:
|
|
|
+ except SyncCommandError as e:
|
|
|
messages.error(
|
|
|
request,
|
|
|
"Impossible de sauvegarder tes abonnements. "
|