Remove the ‘manage templates’ page

The ‘manage templates’ page was almost identical to the ‘send text messages’
page.

This commit consolidates them into one and makes them all hang together.

Part of this means tweaks to the javascript so that files upload as soon as
you’ve chosen them.
This commit is contained in:
Chris Hill-Scott
2016-02-22 12:16:19 +00:00
parent bf3f6d7d3e
commit 97a3bf9225
14 changed files with 37 additions and 76 deletions

View File

@@ -14,8 +14,6 @@ def test_should_show_overview_page(
response = client.get(url_for('main.manage_users', service_id=55555))
assert 'Manage team' in response.get_data(as_text=True)
assert 'Henry Hadlow' in response.get_data(as_text=True)
assert 'caley.smolska' in response.get_data(as_text=True)
assert response.status_code == 200
@@ -30,7 +28,6 @@ def test_should_show_page_for_one_user(
client.login(api_user_active)
response = client.get(url_for('main.edit_user', service_id=55555, user_id=0))
assert 'Henry Hadlow' in response.get_data(as_text=True)
assert response.status_code == 200

View File

@@ -16,7 +16,7 @@ def test_should_return_list_of_all_templates(app_,
client.login(api_user_active)
service_id = str(uuid.uuid4())
response = client.get(url_for(
'.manage_service_templates', service_id=service_id))
'.manage_service_templates', service_id=service_id), follow_redirects=True)
assert response.status_code == 200
mock_get_service_templates.assert_called_with(service_id)
@@ -72,7 +72,7 @@ def test_should_redirect_when_saving_a_template(app_,
assert response.status_code == 302
assert response.location == url_for(
'.manage_service_templates', service_id=service_id, _external=True)
'.choose_sms_template', service_id=service_id, _external=True)
mock_update_service_template.assert_called_with(
template_id, name, 'sms', content, service_id)