5 [% INCLUDE 'doc-head-open.inc' %]
6 <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog › Tags</title>
7 [% INCLUDE 'doc-head-close.inc' %]
10 fieldset { padding : .3em;margin:.3em 0;}
11 #tagcloud {background-color: #F3F3F3; text-align: justify;padding:7px;}
12 .tag a {text-decoration: none;}
13 .tag a:hover {text-decoration: underline;}
14 .tag {display: block; padding-left: 1em;}
15 .tagcount {display: none;}
16 .cloudweight {display: none;}
27 [% IF ( loggedinusername ) %][% INCLUDE 'bodytag.inc' bodyid='opac-usertags' bodyclass='scrollto' %][% ELSE %][% INCLUDE 'bodytag.inc' bodyid='opac-tags' bodyclass='scrollto' %][% END %]
28 [% INCLUDE 'masthead.inc' %]
31 <ul class="breadcrumb">
32 <li><a href="/cgi-bin/koha/opac-main.pl">Home</a> <span class="divider">›</span></li>
33 [% IF ( loggedinusername ) %]
34 <li><a href="/cgi-bin/koha/opac-user.pl">[% INCLUDE 'patron-title.inc' patron = logged_in_user %]</a> <span class="divider">›</span></li>
36 <li><a href="#">Tags</a></li>
39 <div class="container-fluid">
40 <div class="row-fluid">
41 [% IF ( OpacNav||loggedinusername ) %]
44 [% INCLUDE 'navigation.inc' IsPatronPage=1 %]
52 <div id="usertags" class="maincontent">
54 [% FOREACH ERROR IN ERRORS %]
56 There was a problem with this operation:
57 [% IF ( ERROR.tagsdisabled ) %]
58 Sorry, tags are not enabled on this system.
59 [% ELSIF ( ERROR.badparam ) %]
60 ERROR: illegal parameter [% ERROR.badparam | html %]
61 [% ELSIF ( ERROR.login ) %]
62 ERROR: You must log in to complete that action.
63 [% ELSIF ( ERROR.failed_delete ) %]
64 ERROR: You cannot delete the tag [% ERROR.failed_delete | html %].
65 <br />Note: you can only delete your own tags.
66 [% ELSIF ( ERROR.scrubbed ) %]
67 Note: your tag contained markup code that was removed.
68 <br />The tag was added as "[% ERROR.scrubbed | html %]".
69 [% ELSIF ( ERROR.scrubbed_all_bad ) %]
70 Note: your tag was entirely markup code. It was NOT added.
71 <br />Please try again with plain text.
72 [% ELSE %]Unrecognized error.
76 [% END # /IF ERRORS %]
79 <form method="get" action="opac-tags.pl" class="form-inline">
82 [% IF Koha.Preference( 'opacuserlogin' ) == 1 %]
83 Tags to show from other users
88 <div class="input-append">
89 <input type="text" name="limit" style="text-align: right;" maxlength="4" size="4" value="[% limit or "100" | html %]" />
90 <input type="submit" value="OK" class="btn" />
92 [% IF Koha.Preference( 'opacuserlogin' ) == 1 %]
93 [% UNLESS ( loggedinusername ) %]
95 [% IF Koha.Preference('casAuthentication') %]
96 [%# CAS authentication is too complicated for modal window %]
97 <a href="/cgi-bin/koha/opac-user.pl">Log in to see your own saved tags.</a>
99 <a class="loginModal-trigger" href="/cgi-bin/koha/opac-user.pl">Log in to see your own saved tags.</a>
109 [% FOREACH TAGLOO IN TAGLOOP %]
110 <span class="tag tagweight[% TAGLOO.stratum | html %]" id="tag[% loop.count | html %]" style="display:inline;">
111 <a href="/cgi-bin/koha/opac-search.pl?tag=[% TAGLOO.term |url %]&q=[% TAGLOO.term |url %]">[% TAGLOO.term | html %]</a>
112 <span class="tagweight">[% TAGLOO.weight_total | html %]</span>
118 [% IF ( added_count ) %]
119 <div class="dialog message">[% added_count | html %] [% IF ( added_count == 1 ) %]tag[% ELSE %]tags[% END %] successfully added.</div>
121 [% IF ( deleted_count ) %]
122 <div class="dialog message">[% deleted_count | html %] [% IF ( deleted_count == 1 ) %]tag[% ELSE %]tags[% END %] successfully deleted.</div>
127 <form id="deletetags" method="post" action="opac-tags.pl">
129 <table id="mytagst" class="table table-bordered table-striped">
130 <thead><tr><th> </th><th>Term</th><th>Title</th><th>Date added</th></tr></thead>
132 [% FOREACH MY_TAG IN MY_TAGS %]
133 [% IF MY_TAG.visible %]
136 <input type="checkbox" name="del[% MY_TAG.tag_id | html %]" value="del[% MY_TAG.tag_id | html %]">
139 <span class="tdlabel">Tag:</span>
140 [% IF MY_TAG.approved == 1 %]
141 <a href="/cgi-bin/koha/opac-search.pl?tag=[% MY_TAG.term |url %]&q=[% MY_TAG.term |url %]">[% MY_TAG.term | html %]</a>
143 [% MY_TAG.term | html %] (not approved)
147 [% IF ( MY_TAG.XSLTBloc ) %]
148 [% MY_TAG.XSLTBloc | $raw %]
150 <span class="tdlabel">Title:</span>
151 <a class="title" href="/cgi-bin/koha/opac-detail.pl?biblionumber=[% MY_TAG.biblionumber | html %]">
152 [% MY_TAG.title | html %]
153 [% IF ( MY_TAG.subtitle ) %]
154 [% FOREACH subtitle IN MY_TAG.subtitle %]
155 [% subtitle.subfield | html %]
159 [% IF ( MY_TAG.author ) %]
160 by [% MY_TAG.author | html %]
162 [% END # /IF MY_TAG.XSLTBloc %]
165 <span title="[% MY_TAG.date_created | html %]">
166 <span class="tdlabel">Date added:</span>
167 [% MY_TAG.date_created | $KohaDates %]
175 <input type="submit" value="Delete selected tags" class="btn btn-danger btn-sm delete">
178 </div> <!-- / .usertags -->
179 </div> <!-- / .span10/12 -->
180 </div> <!-- / .row-fluid -->
181 </div> <!-- / .container-fluid -->
182 </div> <!-- / .main -->
184 [% INCLUDE 'opac-bottom.inc' %]
185 [% BLOCK jsinclude %]
186 [% INCLUDE 'datatables.inc' %]
189 function checkboxesChecked() {
190 if ($("#deletetags input:checkbox:checked").length > 0) {
197 $(document).ready(function(){
198 var MSG_DELETE_TAG = _("Are you sure you want to delete the selected tag(s)?");
199 $(".delete").on("click", function(e){
200 if ( checkboxesChecked() == 1 ) {
201 return confirmDelete(MSG_DELETE_TAG);
203 alert(_("Please select a tag to delete."));
208 $("#mytagst").dataTable($.extend(true, {}, dataTablesDefaults, {
209 "sorting": [[ 2, "asc" ]],
211 { "targets": [ 0 ], "sortable": false, "searchable": false }
215 { "type": "anti-the" },
216 { "type": "title-string" },