A Django/Wagtail app to easily ask users for feedback.
Project description
wagtail_feedback
A simple wagtail application for letting users give feedback on your wagtail pages - provides easily readable and accessible aggregates in the page admin via FeedbackPanel
Quick start
-
Add
wagtail_feedback
anddjango_filters
to your INSTALLED_APPS setting like this:INSTALLED_APPS = [ ..., 'feedback', 'django_filters', ]
-
include
feedback.urls
in your URLconf.urlpatterns = [ ... include('feedback.urls') ]
-
In your template, load the feedback template tag to use the feedback form.
{% load feedback %} {# Loads the appropriate CSS styles. `{% static 'feedback/css/feedback.css'%}` #} {% feedback_css %} {# Loads HTMX, if you have HTMX loaded in your template this is not nescessary. `{% static 'feedback/js/feedback.js'%}` #} {% feedback_js %} {% feedback page=self %}
-
(Optional) Include the feedback panel in your page definition:
from wagtail.models import Page from feedback.panels import FeedbackPanel class MyPage(Page): content_panels = Page.content_panels + [ FeedbackPanel() ]
Easily configurable settings:
A class for creating custom implementations of a feedback model
FEEDBACK_MODEL_NAME
default: feedback.Feedback
A form class for saving custom fields on your own custom feedback model:
FEEDBACK_FORM_CLASS
default: feedback.forms.FeedbackForm
Filters for the admin in-panel list-view.
FEEDBACK_FILTER_CLASS
default: feedback.filters.AbstractFeedbackFilter
Backends for validating feedback before and after submit
FEEDBACK_BACKEND
default:
FEEDBACK_BACKEND = getattr(settings, "FEEDBACK_BACKEND", {
"CLASS": "feedback.backends.IPBasedFeedbackend",
"OPTIONS": {
# ... Options passed to class
}
})
Other backends include:
feedback.backends.SessionBasedFeedbackend
feedback.backends.PageBasedFeedbackend
feedback.backends.Feedbackend
(base implementation)
Django proxy settings to get IP-adress
USE_X_FORWARDED_HOST
default: False
Used for setting the appropriate IP-adress on the
feedback model / when using the backend.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.