From 3d258b929dd9952a9d874af955ec325bcd19c82c Mon Sep 17 00:00:00 2001 From: Imdad Ahad Date: Wed, 8 Mar 2017 09:57:03 +0000 Subject: [PATCH] Use page footer for back link --- app/templates/views/providers/provider.html | 50 +++++++++++---------- 1 file changed, 27 insertions(+), 23 deletions(-) diff --git a/app/templates/views/providers/provider.html b/app/templates/views/providers/provider.html index 22d7e61a4..d934e7ff0 100644 --- a/app/templates/views/providers/provider.html +++ b/app/templates/views/providers/provider.html @@ -1,5 +1,6 @@ {% extends "withoutnav_template.html" %} {% from "components/table.html" import list_table, field, text_field, link_field, right_aligned_field_heading, hidden_field_heading %} +{% from "components/page-footer.html" import page_footer %} {% block per_page_title %} Provider versions @@ -11,36 +12,39 @@ Provider versions

{{ provider_versions[0].display_name }}

- {% call(item, row_number) list_table( - provider_versions, - caption='', - caption_visible=False, - empty_message='No history for this provider', - field_headings=['Version', 'Last Updated', 'Updated By', 'Priority', 'Active'], - field_headings_visible=True - ) %} + {% call(item, row_number) list_table( + provider_versions, + caption='', + caption_visible=False, + empty_message='No history for this provider', + field_headings=['Version', 'Last Updated', 'Updated By', 'Priority', 'Active'], + field_headings_visible=True + ) %} - {{ text_field(item.version) }} + {{ text_field(item.version) }} - {% if item.updated_at %} - {{ text_field(item.updated_at|format_datetime_short) }} - {% else %} - {{ text_field('None') }} - {% endif %} + {% if item.updated_at %} + {{ text_field(item.updated_at|format_datetime_short) }} + {% else %} + {{ text_field('None') }} + {% endif %} - {% if item.created_by %} - {{ text_field(item.created_by.name) }} - {% else %} - {{ text_field('None') }} - {% endif %} + {% if item.created_by %} + {{ text_field(item.created_by.name) }} + {% else %} + {{ text_field('None') }} + {% endif %} - {{ text_field(item.priority) }} + {{ text_field(item.priority) }} - {{ text_field(item.active) }} + {{ text_field(item.active) }} - {% endcall %} + {% endcall %} - Back to Providers + {{ page_footer( + back_link=url_for('main.view_providers'), + back_link_text="Back to providers" + ) }}