forked from CGM_Public/pretix_original
Add cancel_allow_user_paid_adjust_fees_explanation (#1639)
* Add cancel_allow_user_paid_adjust_fees_explanation * Cleanup
This commit is contained in:
@@ -618,6 +618,7 @@ class EventSettingsSerializer(serializers.Serializer):
|
|||||||
'cancel_allow_user_paid_keep_fees',
|
'cancel_allow_user_paid_keep_fees',
|
||||||
'cancel_allow_user_paid_keep_percentage',
|
'cancel_allow_user_paid_keep_percentage',
|
||||||
'cancel_allow_user_paid_adjust_fees',
|
'cancel_allow_user_paid_adjust_fees',
|
||||||
|
'cancel_allow_user_paid_adjust_fees_explanation',
|
||||||
'cancel_allow_user_paid_refund_as_giftcard',
|
'cancel_allow_user_paid_refund_as_giftcard',
|
||||||
'cancel_allow_user_paid_require_approval',
|
'cancel_allow_user_paid_require_approval',
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -966,6 +966,23 @@ DEFAULTS = {
|
|||||||
help_text=_("With this option enabled, your customers can choose to get a smaller refund to support you.")
|
help_text=_("With this option enabled, your customers can choose to get a smaller refund to support you.")
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
|
'cancel_allow_user_paid_adjust_fees_explanation': {
|
||||||
|
'default': LazyI18nString.from_gettext(gettext_noop(
|
||||||
|
'However, if you want us to help keep the lights on here, please consider using the slider below to '
|
||||||
|
'request a smaller refund. Thank you!'
|
||||||
|
)),
|
||||||
|
'type': LazyI18nString,
|
||||||
|
'serializer_class': I18nField,
|
||||||
|
'form_class': I18nFormField,
|
||||||
|
'form_kwargs': dict(
|
||||||
|
label=_("Voluntary lower refund explanation"),
|
||||||
|
widget=I18nTextarea,
|
||||||
|
widget_kwargs={'attrs': {'rows': '2'}},
|
||||||
|
help_text=_("This text will be shown in between the explanation of how the refunds work and the slider "
|
||||||
|
"which your customers can use to choose the amount they would like to receive. You can use it "
|
||||||
|
"e.g. to explain choosing a lower refund will help your organisation.")
|
||||||
|
)
|
||||||
|
},
|
||||||
'cancel_allow_user_paid_require_approval': {
|
'cancel_allow_user_paid_require_approval': {
|
||||||
'default': 'False',
|
'default': 'False',
|
||||||
'type': bool,
|
'type': bool,
|
||||||
|
|||||||
@@ -572,6 +572,7 @@ class CancelSettingsForm(SettingsForm):
|
|||||||
'cancel_allow_user_paid_keep_fees',
|
'cancel_allow_user_paid_keep_fees',
|
||||||
'cancel_allow_user_paid_keep_percentage',
|
'cancel_allow_user_paid_keep_percentage',
|
||||||
'cancel_allow_user_paid_adjust_fees',
|
'cancel_allow_user_paid_adjust_fees',
|
||||||
|
'cancel_allow_user_paid_adjust_fees_explanation',
|
||||||
'cancel_allow_user_paid_refund_as_giftcard',
|
'cancel_allow_user_paid_refund_as_giftcard',
|
||||||
'cancel_allow_user_paid_require_approval',
|
'cancel_allow_user_paid_require_approval',
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -21,6 +21,9 @@
|
|||||||
{% bootstrap_field form.cancel_allow_user_paid_keep_fees layout="control" %}
|
{% bootstrap_field form.cancel_allow_user_paid_keep_fees layout="control" %}
|
||||||
{% bootstrap_field form.cancel_allow_user_paid_until layout="control" %}
|
{% bootstrap_field form.cancel_allow_user_paid_until layout="control" %}
|
||||||
{% bootstrap_field form.cancel_allow_user_paid_adjust_fees layout="control" %}
|
{% bootstrap_field form.cancel_allow_user_paid_adjust_fees layout="control" %}
|
||||||
|
<div data-display-dependency="#id_cancel_allow_user_paid_adjust_fees">
|
||||||
|
{% bootstrap_field form.cancel_allow_user_paid_adjust_fees_explanation layout="control" %}
|
||||||
|
</div>
|
||||||
{% bootstrap_field form.cancel_allow_user_paid_refund_as_giftcard layout="control" %}
|
{% bootstrap_field form.cancel_allow_user_paid_refund_as_giftcard layout="control" %}
|
||||||
{% if not gets_notification %}
|
{% if not gets_notification %}
|
||||||
<div class="alert alert-warning">
|
<div class="alert alert-warning">
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
{% load money %}
|
{% load money %}
|
||||||
{% load eventurl %}
|
{% load eventurl %}
|
||||||
{% load l10n %}
|
{% load l10n %}
|
||||||
|
{% load rich_text %}
|
||||||
{% block title %}{% trans "Cancel order" %}{% endblock %}
|
{% block title %}{% trans "Cancel order" %}{% endblock %}
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<h2>
|
<h2>
|
||||||
@@ -48,7 +49,9 @@
|
|||||||
If you want, you can request a full refund.
|
If you want, you can request a full refund.
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% trans "However, if you want us to help keep the lights on here, please consider using the slider below to request a smaller refund. Thank you!" %}
|
</p>
|
||||||
|
<p>
|
||||||
|
{{ request.event.settings.cancel_allow_user_paid_adjust_fees_explanation|rich_text }}
|
||||||
</p>
|
</p>
|
||||||
<div class="cancel-fee-slider">
|
<div class="cancel-fee-slider">
|
||||||
<div id="cancel-fee-keep">Enter how much we can keep:</div>
|
<div id="cancel-fee-keep">Enter how much we can keep:</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user