[Koha-patches] [PATCH] Bug 9957 - Missing cancel link on subfield editing page

Owen Leonard oleonard at myacpl.org
Tue Apr 30 20:43:32 CEST 2013


The subfield edit page has an edit bottom at the top of the page. Almost
no other edit screens do this. It would be more consistent to put it at
the bottom. Also missing is a "cancel" link. This patch fixes both
issues.

The patch also adds "Default" to the breadcrumbs when editing a subfield
in the default framework.

To test, apply the patch and edit a subfield: MARC frameworks -> MARC
structure -> Subfields -> Edit. The "Save changes" button should appear
at the bottom of the page alonside a "Cancel" link. Both should work
correctly.
---
 .../en/modules/admin/marc_subfields_structure.tt   |    8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tt
index e4918e0..716b129 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/marc_subfields_structure.tt
@@ -177,7 +177,7 @@ function populateHiddenCheckboxes(tab) {
 [% INCLUDE 'cat-search.inc' %]
 
 <div id="breadcrumbs">
-  <a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> › <a href="/cgi-bin/koha/admin/biblio_framework.pl">MARC frameworks</a> › <a href="/cgi-bin/koha/admin/marctagstructure.pl?frameworkcode=[% frameworkcode %]&searchfield=[% tagfield %]">[% frameworkcode %] framework structure</a> ›
+  <a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> › <a href="/cgi-bin/koha/admin/biblio_framework.pl">MARC frameworks</a> › <a href="/cgi-bin/koha/admin/marctagstructure.pl?frameworkcode=[% frameworkcode %]&searchfield=[% tagfield %]">[% frameworkcode or "Default" %] framework structure</a> ›
   [% IF ( add_form ) %]
   [% IF ( use_heading_flags_p ) %]
   [% IF ( heading_edit_subfields_p ) %] <a href="/cgi-bin/koha/admin/marc_subfields_structure.pl?tagfield=[% tagfield %]&frameworkcode=[% frameworkcode %]">Tag [% tagfield %] subfield structure</a> › Edit subfields constraints
@@ -210,8 +210,7 @@ function populateHiddenCheckboxes(tab) {
     <input type="hidden" name="op" value="add_validate" />
 	<input type="hidden" name="tagfield" value="[% tagfield %]" />
     <input type="hidden" name="frameworkcode" value="[% frameworkcode %]" />
-    <input type="submit" value="Save changes" />
-    
+
     <div id="subfieldtabs" class="toptabs numbered">
    <ul>
         [% FOREACH loo IN loop %]
@@ -280,6 +279,9 @@ function populateHiddenCheckboxes(tab) {
         </div><!-- /content_sub -->
         [% END %]
 		</div><!-- /content -->
+    <fieldset class="action">
+        <input type="submit" value="Save changes" /> <a href="/cgi-bin/koha/admin/marc_subfields_structure.pl?tagfield=[% tagfield %]&frameworkcode=[% frameworkcode %]" class="cancel">Cancel</a>
+    </fieldset>
     </form>
 [% END %]
 
-- 
1.7.9.5


More information about the Koha-patches mailing list