Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #1417 As a shop owner I'm warned when I've not configured the rely-to (support) email address #1418

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion subscribie/blueprints/admin/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1351,7 +1351,14 @@ def add_custom_code():

@admin.app_context_processor
def inject_template_globals():
return dict(currencyFormat=currencyFormat)
reply_to_email_address = None
setting = Setting.query.first()
if setting is not None:
reply_to_email_address = setting.reply_to_email_address
return dict(
currencyFormat=currencyFormat,
reply_to_email_address=reply_to_email_address, # noqa: E501
)


@admin.route("/subscribers")
Expand Down
5 changes: 5 additions & 0 deletions subscribie/blueprints/admin/templates/admin/dashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ <h3 class="card-title">Checklist</h3>
</a>
</li>
{% endif %}
{% if reply_to_email_address is sameas None %}
<li>
🔔 Improve support for your subscribers by <a href="{{ url_for('admin.set_reply_to_email') }}">setting your support email address 🔔</a>
</li>
{% endif %}
</ul>
</div>

Expand Down
Loading