simple-login/app/templates/admin/model/newsletter-list.html
MrMeeb 14f4829fab
Some checks failed
Build-Release-Image / Build-Image (linux/arm64) (push) Successful in 3m21s
Build-Release-Image / Build-Image (linux/amd64) (push) Has been cancelled
Build-Release-Image / Merge-Images (push) Has been cancelled
Build-Release-Image / Create-Release (push) Has been cancelled
Build-Release-Image / Notify (push) Has been cancelled
4.49.7
2024-09-03 12:00:06 +01:00

31 lines
956 B
HTML

{#
Add custom input form so admin can enter a user id to send a newsletter to
Based on https://github.com/flask-admin/flask-admin/issues/974#issuecomment-168215285
#}
{% extends 'admin/model/list.html' %}
{% block model_menu_bar_before_filters %}
<br>
<li id="here" class="form-row">
<input name="user_id"
class="form-control"
placeholder="User ID"
aria-describedby="userID" />
<input name="to_address"
class="form-control"
placeholder="Specify an address to receive the newsletter for testing"
aria-describedby="Email address" />
</li>
{% endblock %}
{% block tail %}
{{ super() }}
<script type="application/javascript">
$("input[name='user_id']").appendTo($("#action_form"))
$("input[name='to_address']").appendTo($("#action_form"))
$("#action_form").appendTo($("#here"))
$("#action_form").attr("style", "")
</script>
{% endblock %}