Closed sandstromviktor closed 7 months ago
Hi @sandstromviktor
Thanks for your report. I have received reports like this in email. Thank you for your advice. I'll fix this.
Great!
I solved this temporarily by creating a custom class and overriding the form_valid
function. As such
class CustomCreateSurveyFormView(CreateSurveyFormView):
def form_valid(self, form):
# Call the superclass's form_valid method to ensure the form is saved
super().form_valid(form)
return render(self.request, 'success.html', {
'success_message': "Form sent successfully."})
but it involved some messing with the urls to make it work properly.
Hi @sandstromviktor
I'm forget, now you can set SURVEY_ANONYMOUS_VIEW_LIST = True
on settings.py
to make behavior anonymous make sanse. This feature available on version 2.0.4 or lastest
ref https://github.com/irfanpule/django-form-surveys/pull/70 https://github.com/irfanpule/django-form-surveys/pull/73
I think success page still needed to handle SURVEY ANONYMOUS VIEW_LIST = False
. So I will fix it.
Hi @sandstromviktor
I have finish this https://github.com/irfanpule/django-form-surveys/pull/87 look forward to the next release
When submitting an anonymous survey, the user gets rerouted to login page, which doesn't really make sense.
It is probably due to the
success_url
Suggestions: Add a customizable success page and redirect to that, or do not redirect and only display the success message.