3 [% USE AuthorisedValues %]
5 [% INCLUDE 'doc-head-open.inc' %]
8 [% IF heading_add_tag_p %]
9 Add tag [% searchfield | html %]
11 Modify tag [% searchfield | html %]
12 [% END %] › [% END %]
14 [% IF ( delete_confirm ) %]
15 Confirm deletion of tag '[% searchfield | html %]' › [% END %]
17 [% IF ( delete_confirmed ) %]
18 Data deleted › [% END %]
19 MARC frameworks › Administration › Koha
21 [% INCLUDE 'doc-head-close.inc' %]
24 <body id="admin_marctagstructure" class="admin">
25 [% INCLUDE 'header.inc' %]
26 [% INCLUDE 'prefs-admin-search.inc' %]
28 <nav id="breadcrumbs" aria-label="Breadcrumb" class="breadcrumb">
31 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
34 <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a>
37 <a href="/cgi-bin/koha/admin/biblio_framework.pl">MARC frameworks</a>
42 <a href="/cgi-bin/koha/admin/marctagstructure.pl?frameworkcode=[% framework.frameworkcode | uri %]">
44 [% framework.frameworktext | html %] ([% framework.frameworkcode | html %])
46 <span>Default MARC framework</span>
51 <a href="#" aria-current="page">
52 [% IF heading_add_tag_p %]
56 [% END %] [% searchfield | html %]
62 <a href="#" aria-current="page">
64 [% framework.frameworktext | html %] ([% framework.frameworkcode | html %])
66 Default MARC framework
71 [% ELSIF ( delete_confirm ) %]
73 <a href="/cgi-bin/koha/admin/marctagstructure.pl?frameworkcode=[% framework.frameworkcode | uri %]">
75 [% framework.frameworktext | html %] ([% framework.frameworkcode | html %])
77 Default MARC framework
82 <a href="#" aria-current="page">
83 Confirm deletion of tag '[% searchfield | html %]'
87 [% ELSIF ( delete_confirmed ) %]
89 <a href="/cgi-bin/koha/admin/marctagstructure.pl?frameworkcode=[% framework.frameworkcode | uri %]">
91 [% framework.frameworktext | html %] ([% framework.frameworkcode | html %])
93 Default MARC framework
98 <a href="#" aria-current="page">
106 <div class="main container-fluid">
108 <div class="col-sm-10 col-sm-push-2">
112 <div id="toolbar" class="btn-toolbar">
113 <a class="btn btn-default" id="addtag" href="/cgi-bin/koha/admin/marctagstructure.pl?op=add_form&frameworkcode=[% framework.frameworkcode | uri %]"><i class="fa fa-plus"></i> New tag</a>
116 <h1>MARC Framework for [% IF framework %][% framework.frameworktext | html %] ([% framework.frameworkcode | html %])[% ELSE %]default MARC framework[% END %]</h1>
118 [% IF ( add_form ) %]
120 <form action="[% script_name | html %]" name="Aform" method="post" class="validated">
122 <fieldset class="rows">
124 [% IF heading_add_tag_p %]
127 Modify tag <input type="hidden" name="modif" value="1" />[% searchfield | html %]
130 <input type="hidden" name="op" value="add_validate" />
131 <input type="hidden" name="frameworkcode" value="[% framework.frameworkcode | html %]" />
134 [% IF ( heading_modify_tag_p ) %]
135 <input type="hidden" name="tagfield" value="[% searchfield | html %]" />
136 <span class="label">Tag:</span>
137 [% searchfield | html %]
139 <label for="tagfield" class="required">Tag: </label>
140 <input id="tagfield" type="text" name="tagfield" value="[% searchfield | html %]" maxlength="3" size="3" required="required" class="required" />
141 <span class="required">Required</span>
144 <li><label for="liblibrarian">Label for lib: </label><input type="text" id="liblibrarian" name="liblibrarian" value="[% liblibrarian | html %]" size="40" maxlength="100" /></li>
145 <li><label for="libopac">Label for opac: </label><input type="text" id="libopac" name="libopac" value="[% libopac | html %]" size="40" maxlength="100" /></li>
146 <li><label for="repeatable">Repeatable: </label>
147 [% IF ( repeatable ) %]
148 <input type="checkbox" name="repeatable" id="repeatable" value="1" checked="checked" />
150 <input type="checkbox" name="repeatable" id="repeatable" value="1" />
153 <li><label for="mandatory">Mandatory: </label>
154 [% IF ( mandatory ) %]
155 <input type="checkbox" name="mandatory" id="mandatory" value="1" checked="checked" />
157 <input type="checkbox" name="mandatory" id="mandatory" value="1" />
160 <li><label for="important">Important: </label>
161 [% IF ( important ) %]
162 <input type="checkbox" name="important" id="important" value="1" checked="checked" />
164 <input type="checkbox" name="important" id="important" value="1" />
167 <li><label for="ind1_defaultvalue">First indicator default value: </label>
168 <input id="ind1_defaultvalue" type="text" name="ind1_defaultvalue" value="[% ind1_defaultvalue | html %]" maxlength="1" size="1" />
170 <li><label for="ind2_defaultvalue">Second indicator default value: </label>
171 <input id="ind2_defaultvalue" type="text" name="ind2_defaultvalue" value="[% ind2_defaultvalue | html %]" maxlength="1" size="1" />
173 <li><label for="authorised_value">Authorized value: </label>
174 <select name="authorised_value" id="authorised_value">
175 <option value=""></option>
176 [% PROCESS options_for_authorised_value_categories authorised_value_categories => AuthorisedValues.GetCategories( selected => authorised_value ) %]
178 (if you select a value here, the indicators will be limited to the authorized value list)</li>
180 <fieldset class="action">
181 <input type="submit" value="Save changes" />
182 <a class="cancel" href="[% script_name | url %]?frameworkcode=[% framework.frameworkcode | uri %]">Cancel</a>
188 [% IF ( delete_confirm ) %]
189 <div class="dialog alert">
190 <h3>Confirm deletion of tag <span class="ex">'[% searchfield | html %]'</span>?</h3>
191 <p>Tag: [% searchfield | html %]</p>
192 <p>Description: [% liblibrarian | html %]</p>
193 <form action="[% script_name | html %]" method="post">
194 <input type="hidden" name="op" value="delete_confirmed" />
195 <input type="hidden" name="searchfield" value="[% searchfield | html %]" />
196 <input type="hidden" name="frameworkcode" value="[% framework.frameworkcode | html %]" />
197 <button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> Yes, delete this tag</button>
199 <form action="[% script_name | html %]" method="get"><input type="hidden" name="frameworkcode" value="[% framework.frameworkcode | html %]" />
200 <button type="submit" class="deny"><i class="fa fa-fw fa-remove"></i> No, do not delete</button>
205 [% IF ( delete_confirmed ) %]
207 <div class="dialog message"><h3>Tag deleted</h3>
208 <form action="[% script_name | html %]" method="post"><input type="hidden" name="frameworkcode" value="[% framework.frameworkcode | html %]" />
209 <button type="submit" class="approve"><i class="fa fa-fw fa-check"></i> OK</button>
212 [% IF ( framework_create ) %]
214 <form action="[% script_name | html %]" method="post">
215 <input type="hidden" name="op" value="framework_create_confirm" />
216 <input type="hidden" name="frameworkcode" value="[% framework.frameworkcode | html %]" />
217 Create framework for [% framework.frameworkcode | html %] ([% framework.frameworktext | html %]) using
218 <select name="existingframeworkcode">
219 <option value="">Default</option>
220 [% FOREACH fw IN existing_frameworks%]
221 <option value="[% fw.frameworkcode | html %]">[% fw.frameworktext | html %]</option>
224 <input type="submit" value="OK" />
230 <form name="f" action="[% script_name | html %]" method="post">
231 <fieldset style="padding:.5em;">
232 <label for="tag_search"><strong>Search for tag:</strong> </label>
233 <input type="text" name="searchfield" id="tag_search" size="4" value="[% searchfield | html %]" />
235 <label for="frameworkcode"><strong>In framework:</strong> </label>
236 <select id="frameworkcode" name="frameworkcode">
237 <option value="">Default</option>
238 [% FOREACH f IN frameworks %]
239 [% IF f.frameworkcode == framework.frameworkcode %]
240 <option value="[% f.frameworkcode | html %]" selected="selected">[% f.frameworktext | html %]</option>
242 <option value="[% f.frameworkcode | html %]">[% f.frameworktext | html %]</option>
246 <input type="submit" value="Search" />
247 <p> <label for="select_display">Display only used tags/subfields</label>
248 [% IF ( select_display ) %]
249 <input type="checkbox" name="select_display" id="select_display" value="True" checked="checked" />
251 <input type="checkbox" name="select_display" id="select_display" value="True" />
256 <table id="table_marctagstructure">
271 [% FOREACH loo IN loop %]
273 <td>[% loo.tagfield | html %]</td>
275 [% loo.liblibrarian | html %]
276 [% IF ( select_display ) %]
277 [% FOREACH subfield IN loo.subfields %]
279 Tab:[% subfield.tab | html %] | $[% subfield.tagsubfield | html %]
280 [% subfield.liblibrarian | html %] [% IF ( subfield.kohafield ) %][% subfield.kohafield | html %][% END %][% IF ( subfield.repeatable ) %], repeatable[% END %][% IF ( subfield.mandatory ) %], Mandatory[% END %][% IF ( subfield.seealso ) %], See [% subfield.seealso | html %][% END %][% IF ( subfield.authorised_value ) %], [% subfield.authorised_value | html %][% END %][% IF ( subfield.authtypecode ) %], [% subfield.authtypecode | html %][% END %][% IF ( subfield.value_builder ) %], [% subfield.value_builder | html %][% END %]
285 <td>[% IF ( loo.repeatable ) %]Yes[% ELSE %]No[% END %]</td>
286 <td>[% IF ( loo.mandatory ) %]Yes[% ELSE %]No[% END %]</td>
287 <td>[% IF ( loo.important ) %]Yes[% ELSE %]No[% END %]</td>
288 <td>[% loo.authorised_value | html %]</td>
289 <td>[% loo.ind1_defaultvalue | html %]</td>
290 <td>[% loo.ind2_defaultvalue | html %]</td>
292 <div class="btn-group dropup">
293 <a class="btn btn-default btn-xs dropdown-toggle" id="marctagactions[% loo.tagfield | html %]" role="button" data-toggle="dropdown" href="#">
294 Actions <b class="caret"></b></a>
295 <ul class="dropdown-menu pull-right" role="menu" aria-labelledby="marctagactions[% loo.tagfield | html %]">
296 <li><a href="?op=add_form&searchfield=[% loo.tagfield | uri %]&frameworkcode=[% framework.frameworkcode | uri %]"><i class="fa fa-pencil"></i> Edit tag</a></li>
297 <li><a href="/cgi-bin/koha/admin/marc_subfields_structure.pl?tagfield=[% loo.tagfield | uri %]&frameworkcode=[% framework.frameworkcode | uri %]"><i class="fa fa-eye"></i> View subfields</a></li>
298 <li><a href="/cgi-bin/koha/admin/marc_subfields_structure.pl?op=add_form&tagfield=[% loo.tagfield | uri %]&frameworkcode=[% framework.frameworkcode | uri %]"><i class="fa fa-pencil"></i> Edit subfields</a></li>
299 <li><a href="?op=delete_confirm&searchfield=[% loo.tagfield | uri %]&frameworkcode=[% framework.frameworkcode | uri %]"><i class="fa fa-trash"></i> Delete</a></li>
310 </div> <!-- /.col-sm-10.col-sm-push-2 -->
312 <div class="col-sm-2 col-sm-pull-10">
314 [% INCLUDE 'admin-menu.inc' %]
316 </div> <!-- /.col-sm-2.col-sm-pull-10 -->
317 </div> <!-- /.row -->
319 [% MACRO jsinclude BLOCK %]
320 [% INCLUDE 'datatables.inc' %]
321 [% Asset.js("js/admin-menu.js") | $raw %]
323 $(document).ready(function() {
324 $("#table_marctagstructure").dataTable($.extend(true, {}, dataTablesDefaults, {
326 { "aTargets": [ -1 ], "bSortable": false, "bSearchable": false },
328 "sPaginationType": "full"
330 $("#select_display").on("change",function(){
331 var checked = $(this).prop("checked") ? 1: 0;
332 Cookies.set("marctagstructure_selectdisplay", checked, { sameSite: 'Lax' });
338 [% INCLUDE 'intranet-bottom.inc' %]