mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-09 10:19:48 -04:00
Remove example personalisation from template page
This was of dubious value, and the syntax probably isn’t accurate for all languages.
This commit is contained in:
@@ -193,13 +193,9 @@ def send_from_api(service_id, template_id):
|
|||||||
service_api_client.get_service_template(service_id, template_id)['data'],
|
service_api_client.get_service_template(service_id, template_id)['data'],
|
||||||
prefix=current_service['name']
|
prefix=current_service['name']
|
||||||
)
|
)
|
||||||
personalisation = {
|
|
||||||
placeholder: "..." for placeholder in template.placeholders
|
|
||||||
}
|
|
||||||
return render_template(
|
return render_template(
|
||||||
'views/send-from-api.html',
|
'views/send-from-api.html',
|
||||||
template=template,
|
template=template
|
||||||
personalisation=json.dumps(personalisation, indent=4) if personalisation else None
|
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -32,9 +32,4 @@
|
|||||||
{{ api_key(template.id, name="Template ID", thing='template ID') }}
|
{{ api_key(template.id, name="Template ID", thing='template ID') }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% if personalisation %}
|
|
||||||
<h2 class="heading-small">Personalisation (all fields are required)</h2>
|
|
||||||
{{ personalisation|syntax_highlight_json }}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@@ -251,7 +251,7 @@ def test_api_info_page(
|
|||||||
follow_redirects=True
|
follow_redirects=True
|
||||||
)
|
)
|
||||||
assert response.status_code == 200
|
assert response.status_code == 200
|
||||||
assert 'API integration' in response.get_data(as_text=True)
|
assert 'API info' in response.get_data(as_text=True)
|
||||||
|
|
||||||
|
|
||||||
def test_download_example_csv(
|
def test_download_example_csv(
|
||||||
|
|||||||
Reference in New Issue
Block a user