From d09108919f8430f6d42b448e7da07a749091864b Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Mon, 14 Sep 2020 15:09:26 +0000 Subject: [PATCH] Bug 26456: Reindent MARC subfield structure template This patch reindents the MARC subfield structure template. The only non-whitespace changes where lines were combined or split. The diff using the '-w' flag to ignore whitespace should highlight only moved lines. Test that functionality is unaffected: Administration -> MARC bibliographic framework -> MARC structure -> Edit subfields.. Test adding, editing, and deleting subfields. Confirm that changes are saved correctly. Signed-off-by: David Nind Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- .../modules/admin/marc_subfields_structure.tt | 678 ++++++++++-------- 1 file changed, 362 insertions(+), 316 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 f9e00519d6..80c062d5d2 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 @@ -2,350 +2,396 @@ [% USE Asset %] [% SET footerjs = 1 %] [% INCLUDE 'doc-head-open.inc' %] -Koha › Administration ›[% IF ( add_form ) %][% IF ( use_heading_flags_p ) %][% IF ( heading_edit_subfields_p ) %] MARC subfield structure › Edit MARC subfields constraints[% END %][% ELSE %] MARC subfield structure › [% action | html %][% END %][% END %] -[% IF ( delete_confirm ) %] MARC subfield structure › Confirm deletion of subfield [% tagsubfield | html %][% END %][% IF ( delete_confirmed ) %] MARC subfield structure › Subfield deleted[% END %][% IF ( else ) %]MARC subfield structure[% END %] + + Koha › Administration › + [%- IF ( add_form ) -%] + [%- IF ( use_heading_flags_p ) -%] + [%- IF ( heading_edit_subfields_p ) -%] + MARC subfield structure › Edit MARC subfields constraints + [%- END -%] + [%- ELSE -%] + MARC subfield structure › [%- action | html -%] + [%- END -%] + [%- END -%] + [%- IF ( delete_confirm ) -%] + MARC subfield structure › Confirm deletion of subfield [%- tagsubfield | html -%] + [%- END -%] + [%- IF ( delete_confirmed ) -%] + MARC subfield structure › Subfield deleted + [%- END -%] + [%- IF ( else ) -%] + MARC subfield structure + [%- END -%] + [% INCLUDE 'doc-head-close.inc' %] -[% INCLUDE 'header.inc' %] -[% INCLUDE 'prefs-admin-search.inc' %] + [% INCLUDE 'header.inc' %] + [% INCLUDE 'prefs-admin-search.inc' %] - - -
-
-
-
- -[% IF ( add_form ) %] -

- [% IF ( use_heading_flags_p ) %] - [% IF ( heading_edit_subfields_p ) %]Tag [% tagfield | html %] Subfield constraints[% END %] - [% ELSE %] - [% action | html %] - [% END %] -

-
- - - -
- - - [% FOREACH loo IN loop %] -
+ [% IF ( delete_confirm ) %] + Tag [% tagfield | html %] Subfield structure › Confirm deletion of subfield [% tagsubfield | html %] + [% END %] + [% IF ( delete_confirmed ) %] + Tag [% tagfield | html %] subfield structure › Subfield deleted + [% END %] + [% IF ( else ) %] + Tag [% tagfield | html %] Subfield structure + [% END %] +
-
-
- Basic constraints -
    - [% IF ( subfieldcode == 0 || subfieldcode ) %] -
  1. Subfield code: [% loo.subfieldcode | html %]
  2. - [% ELSE %] -
  3. - [% END %] -
  4. -
  5. -
  6. - - [% IF loo.repeatable %] - - [% ELSE %] - - [% END %] -
  7. -
  8. - - [% IF loo.mandatory %] - - [% ELSE %] - - [% END %] -
  9. -
  10. - - [% IF loo.important %] - +
    +
    +
    +
    + + [% IF ( add_form ) %] +

    + [% IF ( use_heading_flags_p ) %] + [% IF ( heading_edit_subfields_p ) %]Tag [% tagfield | html %] Subfield constraints[% END %] [% ELSE %] - + [% action | html %] [% END %] -

  11. -
  12. - - (ignore means that the subfield does not display in the record editor) -
  13. -
-
-
+ + + + + -
-
- Advanced constraints -
  1. -
  2. -
  3. -
  4. - [% IF loo.hidden_protected %] - - [% ELSE %] - - [% END %] - - - - - - - - - - - -
  5. -
  6. - - [% IF loo.isurl %] - - [% ELSE %] - - [% END %] - (if checked, it means that the subfield is a URL and can be clicked) -
  7. -
  8. - - - (an index name, e.g. title or Local-Number) -
  9. -
  10. - - - - - -
  11. -
-
-
- -
-
- Other options (choose one) -
    -
  1. - - -
  2. -
  3. - - -
  4. -
  5. - - -
  6. -
-
-
-
- [% END %] -
-
- Cancel -
- -[% END %] + -[% IF ( delete_confirm ) %] + [% FOREACH loo IN loop %] +
+
+
+ Basic constraints +
    + [% IF ( subfieldcode == 0 || subfieldcode ) %] +
  1. + Subfield code: + [% loo.subfieldcode | html %] +
  2. + [% ELSE %] +
  3. + + +
  4. + [% END %] +
  5. + + +
  6. +
  7. + + +
  8. +
  9. + + [% IF loo.repeatable %] + + [% ELSE %] + + [% END %] +
  10. +
  11. + + [% IF loo.mandatory %] + + [% ELSE %] + + [% END %] +
  12. +
  13. + + [% IF loo.important %] + + [% ELSE %] + + [% END %] +
  14. +
  15. + + (ignore means that the subfield does not display in the record editor) +
  16. +
+
+
-
-

Confirm deletion of subfield [% tagsubfield | html %]?

-

Subfield: [% tagsubfield | html %]

-

Description: [% liblibrarian | html_entity %]

+
+
+ Advanced constraints +
    +
  1. + + +
  2. +
  3. + + +
  4. +
  5. + [% IF loo.hidden_protected %] + + [% ELSE %] + + [% END %] + + + + + + + + + + + +
  6. +
  7. + + [% IF loo.isurl %] + + [% ELSE %] + + [% END %] + (if checked, it means that the subfield is a URL and can be clicked) +
  8. +
  9. + + + (an index name, e.g. title or Local-Number) +
  10. +
  11. + + + + + +
  12. +
+
+
+ +
+
+ Other options (choose one) +
    +
  1. + + +
  2. +
  3. + + +
  4. +
  5. + + +
  6. +
+
+
+
+ [% END %] +
-
- - - - - -
+
+ Cancel +
+ + [% END %] + [% IF ( delete_confirm ) %] +
+

Confirm deletion of subfield [% tagsubfield | html %]?

+

Subfield: [% tagsubfield | html %]

+

Description: [% liblibrarian | html_entity %]

-
- - - - - -
-
+
+ + + + + +
-[% END %] -[% IF ( delete_confirmed ) %] +
+ + + + + +
+
+ [% END %] -

Data deleted

-
- - -
-[% END %] + [% IF ( delete_confirmed ) %] +

Data deleted

+
+ + +
+ [% END %] + [% IF ( else ) %] +

MARC subfield structure admin for [% tagfield | html %] [% IF ( frameworkcode ) %](framework [% frameworkcode | html %])[% ELSE %](default framework)[% END %]

+

This screen shows the subfields associated with the selected tag. You can edit subfields or add a new one by clicking on edit.

+

The column 'Koha field' shows that the subfield is linked with a Koha field.

-[% IF ( else ) %] -

MARC subfield structure admin for [% tagfield | html %] [% IF ( frameworkcode ) %](framework [% frameworkcode | html %])[% ELSE %](default framework)[% END %]

-

This screen shows the subfields associated with the selected tag. You can edit subfields or add a new one by clicking on edit.

-

The column 'Koha field' shows that the subfield is linked with a Koha field.

+ + + + + + + + + + + [% FOREACH loo IN loop %] + + + + + + + [% END %] + +
SubfieldTextConstraintsActions
[% loo.tagsubfield | html %] + [% IF ( loo.subfield_ignored ) %] + [% loo.liblibrarian | html_entity %] + [% ELSE %] + [% loo.liblibrarian | html_entity %] + [% END %] + + [% IF ( loo.subfield_ignored ) %] + subfield ignored + [% ELSE %] + Tab:[% loo.tab | html %], + [% IF ( loo.kohafield ) %] | Koha field: [% loo.kohafield | html %], [% END %] + [% IF ( loo.repeatable ) %]Repeatable, [% ELSE %]Not repeatable,[% END %] + [% IF ( loo.mandatory ) %]Mandatory, [% ELSE %]Not mandatory,[% END %] + [% IF ( loo.important ) %]Important, [% ELSE %]Not important,[% END %] + [% IF ( loo.seealso ) %] | See Also: [% loo.seealso | html %],[% END %] + [% IF ( loo.hidden ) %]hidden,[% END %] + [% IF ( loo.isurl ) %]is a URL,[% END %] + [% IF ( loo.authorised_value ) %] | Auth value:[% loo.authorised_value | html %],[% END %] + [% IF ( loo.authtypecode ) %] | Authority:[% loo.authtypecode | html %],[% END %] + [% IF ( loo.value_builder ) %] | Plugin:[% loo.value_builder | html %],[% END %] + [% IF ( loo.link ) %] | Link:[% loo.link | html %],[% END %] + [% END %] + + Edit + Delete +
- - - - - - - - - - -[% FOREACH loo IN loop %] - - - - - - -[% END %] - -
SubfieldTextConstraintsActions
[% loo.tagsubfield | html %] - [% IF ( loo.subfield_ignored ) %] - [% loo.liblibrarian | html_entity %] - [% ELSE %] - [% loo.liblibrarian | html_entity %] - [% END %] - - [% IF ( loo.subfield_ignored ) %] - subfield ignored - [% ELSE %] - Tab:[% loo.tab | html %], - [% IF ( loo.kohafield ) %] | Koha field: [% loo.kohafield | html %], [% END %] - [% IF ( loo.repeatable ) %]Repeatable, [% ELSE %]Not repeatable,[% END %] - [% IF ( loo.mandatory ) %]Mandatory, [% ELSE %]Not mandatory,[% END %] - [% IF ( loo.important ) %]Important, [% ELSE %]Not important,[% END %] - [% IF ( loo.seealso ) %] | See Also: [% loo.seealso | html %],[% END %] - [% IF ( loo.hidden ) %]hidden,[% END %] - [% IF ( loo.isurl ) %]is a URL,[% END %] - [% IF ( loo.authorised_value ) %] | Auth value:[% loo.authorised_value | html %],[% END %] - [% IF ( loo.authtypecode ) %] | Authority:[% loo.authtypecode | html %],[% END %] - [% IF ( loo.value_builder ) %] | Plugin:[% loo.value_builder | html %],[% END %] - [% IF ( loo.link ) %] | Link:[% loo.link | html %],[% END %] - [% END %] - - Edit - Delete -
+
+
+ + + + Cancel +
+
-
-
- - - - Cancel -
-
+ [% END %] -[% END %] + +
- - +
+ +
+ -
- -
- + [% MACRO jsinclude BLOCK %] + [% INCLUDE 'datatables.inc' %] + [% Asset.js("js/admin-menu.js") | $raw %] + [% Asset.js("js/marc_subfields_structure.js") | $raw %] + [% END %] -[% MACRO jsinclude BLOCK %] - [% INCLUDE 'datatables.inc' %] - [% Asset.js("js/admin-menu.js") | $raw %] - [% Asset.js("js/marc_subfields_structure.js") | $raw %] -[% END %] -[% INCLUDE 'intranet-bottom.inc' %] + [% INCLUDE 'intranet-bottom.inc' %] -- 2.39.5