remove browsableitem

it was only used by the choose service page, and then only in kludgy
ways (eg: creating a list containing one item called "add service"),
so lets rip it out and make this page bespoke. Especially now that it's
changed so much.
This commit is contained in:
Leo Hemsted
2018-03-08 14:15:01 +00:00
parent c651ca3f36
commit 1cd8000236
5 changed files with 28 additions and 85 deletions

View File

@@ -3,8 +3,6 @@ from flask_login import current_user, login_required
from app import user_api_client
from app.main import main
from app.notify_client.service_api_client import ServicesBrowsableItem
from app.notify_client.organisations_api_client import OrganisationBrowsableItem
from app.utils import is_gov_user
@@ -12,13 +10,6 @@ from app.utils import is_gov_user
@login_required
def choose_service():
orgs_and_services = user_api_client.get_organisations_and_services_for_user(current_user)
from pprint import pprint
orgs_and_services['organisations'] = [
OrganisationBrowsableItem(org) for org in orgs_and_services['organisations']
]
orgs_and_services['services_without_organisations'] = [
ServicesBrowsableItem(x) for x in orgs_and_services['services_without_organisations']
]
return render_template(
'views/choose-service.html',