Added success message to deleteview.

This commit is contained in:
Marcus Scholz 2020-08-12 20:56:37 +02:00
parent 0b3aff1d1d
commit 564d20c73e

View File

@ -46,7 +46,7 @@ class SignUpView(SuccessMessageMixin, CreateView):
form_class = ExplorerCreationForm
success_url = reverse_lazy('login')
template_name = 'signup.html'
success_message = 'User created'
success_message = 'User created.'
class PlaceListView(IsAuthenticated, View):
def get(self, request):
@ -138,6 +138,5 @@ class PlaceCreateView(IsAuthenticated, View):
class PlaceDeleteView(IsAuthenticated, IsSubmitter, SuccessMessageMixin, DeleteView):
template_name = 'place/place_delete.html'
model = Place
success_url = reverse_lazy('place_list')
success_message = 'Successfully deleted place.'
success_url = reverse_lazy('place_list')