5 [% INCLUDE 'doc-head-open.inc' %]
6 <title>Koha › Tools › Tags › [% IF ( do_it ) %]Review › [% ELSE %]Review tags[% END %]</title>
7 [% INCLUDE 'doc-head-close.inc' %]
9 .setlabel {width: 6em; font-family: courier; background-color:#E8E8E8;}
10 .rejected { color: #CC0033; }
11 .approved { color: #339900; }
12 .pending { color: #CCC; font-style: italic; }
13 tr > td input,td input[type="submit"] { font-size: 85%; padding: 1px; }
17 <body id="tags_review" class="tools">
18 [% INCLUDE 'header.inc' %]
19 [% INCLUDE 'cat-search.inc' %]
21 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › <a href="/cgi-bin/koha/tools/tools-home.pl">Tools</a> › Tags</div>
23 <div class="main container-fluid">
25 <div class="col-sm-12">
29 <div class="col-sm-8 col-sm-push-2">
31 <form method="post" action="/cgi-bin/koha/tags/review.pl">
33 [% IF ( filter_approved_all ) %]all[% END %]
34 [% IF ( filter_approved_ok ) %]approved[% END %]
35 [% IF ( filter_approved_pending ) %]pending[% END %]
36 [% IF ( filter_approved_rej ) %]rejected[% END %]
41 <div class="dialog message" id="main_status">
42 [% IF ( op == 'approve' ) %] Approved
43 [% ELSIF ( op == 'reject' ) %] Rejected
44 [% ELSIF ( op == 'test' ) %] Tested
45 [% ELSE %]Unknown Operation ([% op | html %]) on
47 [% op_count | html %] Term(s).
50 [% IF ( message_loop ) %]
51 <div class="dialog alert" id="main_error">
52 [% FOREACH message_loo IN message_loop %]
53 [% IF ( message_loo.date_from ) %]<strong>Error: </strong>"Date from" is not a legal value ("[% message_loo.date_from | html %]").
54 [% ELSIF ( message_loo.date_to ) %]<strong>Error: </strong>"Date to" is not a legal value ("[% message_loo.date_to | html %]").
55 [% ELSIF ( message_loo.failed_ok ) %]<strong>Error: </strong>Failed to approve term ([% message_loo.failed_ok | html %]).
56 [% ELSIF ( message_loo.failed_rej ) %]<strong>Error: </strong>Failed to reject term ([% message_loo.failed_rej | html %]).
57 [% ELSIF ( message_loo.approver ) %]No match for user ([% message_loo.approver | html %]). FILTER REQUIRES BORROWERNUMBER (not name).
58 [% ELSIF ( message_loo.approved_by ) %]<strong>Error: </strong>No match for borrowernumber ([% message_loo.approved_by | html %]).
59 [% ELSIF ( message_loo.op_zero ) %]<strong>Error: </strong> The root koha user in your KOHA_CONF file
60 (default: kohaadmin) is not a valid tag moderator. These actions are logged
61 by borrowernumber, so the moderator must exist in your borrowers table.
62 Please log in as a different authorized staff user to moderate tags.
63 [% ELSE %]Unrecognized error!
69 [% IF ( pagination_bar ) %]
70 <div class="pages" id="pagination_top">
71 [% pagination_bar | $raw %]
79 <th class="NoSort"> </th>
83 <th class="NoSort">Actions</th>
84 [% UNLESS ( filter_approved_pending ) %]<th>Reviewer</th>[% END %]
85 <th class="title-string">Date</th>
89 [% FOREACH tagloo IN tagloop %]
92 [% IF ( tagloo.approved == 0 ) %]
93 <input id="checkbox[% offset + loop.count | html %]" type="checkbox" value="[% tagloo.term | html %]" name="tags" class="pending" />
94 [% ELSIF ( tagloo.approved == 1 ) %]
95 <input id="checkbox[% offset + loop.count | html %]" type="checkbox" value="[% tagloo.term | html %]" name="tags" class="approved" />
97 <input id="checkbox[% offset + loop.count | html %]" type="checkbox" value="[% tagloo.term | html %]" name="tags" class="rejected" />
101 [% IF ( tagloo.approved == -1 ) %]
102 <label for="checkbox[% offset + loop.count | html %]">
103 <span class="rejected status[% offset + loop.count | html %]">Rejected</span>
105 [% ELSIF ( tagloo.approved == 1 ) %]
106 <label for="checkbox[% offset + loop.count | html %]">
107 <span class="approved status[% offset + loop.count | html %]">Approved</span>
110 <label for="checkbox[% offset + loop.count | html %]">
111 <span class="pending status[% offset + loop.count | html %]">Pending</span>
115 <td><a href="/cgi-bin/koha/tags/list.pl?tag=[% tagloo.term|uri %]">[% tagloo.term | html %]</a>
117 <td>[% tagloo.weight_total | html %]
119 [% IF ( tagloo.approved ) %]
120 <td class="actions"><span class="ajax_buttons" style="visibility:hidden">
121 [% IF ( tagloo.approved == -1 ) %]
122 <button data-num="[% offset + loop.count | html %]" class="approval_btn ok btn btn-default btn-xs" type="submit" title="[% tagloo.term | html %]" value="Approve" name="approve"><i class="fa fa-check"></i> Approve</button>
123 <button data-num="[% offset + loop.count | html %]" class="approval_btn rej btn btn-default btn-xs" disabled="disabled" type="submit" title="[% tagloo.term | html %]" value="Rejected" name="reject"><i class="fa fa-remove"></i> Rejected</button>
125 <button data-num="[% offset + loop.count | html %]" class="approval_btn ok btn btn-default btn-xs" disabled="disabled" type="submit" title="[% tagloo.term | html %]" value="Approved" name="approve"><i class="fa fa-check"></i> Approved</button>
126 <button data-num="[% offset + loop.count | html %]" class="approval_btn rej btn btn-default btn-xs" type="submit" title="[% tagloo.term | html %]" value="Reject" name="reject"><i class="fa fa-remove"></i> Reject</button>
130 <td>[% IF ( tagloo.approved_by_name ) %]<a href="/cgi-bin/koha/tags/review.pl?approved_by=[% tagloo.approved_by | uri %]&approved=all">[% tagloo.approved_by_name | html %]</a>[% ELSE %] [% END %]
133 <td class="actions"><span class="ajax_buttons" style="visibility:hidden">
134 <button data-num="[% offset + loop.count | html %]" class="approval_btn ok btn btn-default btn-xs" type="submit" title="[% tagloo.term | html %]" value="Approve" name="approve"><i class="fa fa-check"></i> Approve</button>
135 <button data-num="[% offset + loop.count | html %]" class="approval_btn rej btn btn-default btn-xs" type="submit" title="[% tagloo.term | html %]" value="Reject" name="reject"><i class="fa fa-remove"></i> Reject</button>
138 [% UNLESS ( filter_approved_pending ) %]<td> </td>[% END %]
141 <span title="[% tagloo.date_approved | html %]">[% tagloo.date_approved | $KohaDates %]</span>
148 [% IF ( tagloop ) %]<fieldset class="action">
149 <button type="submit" value="Approve" class="btn btn-default" id="approve_button" name="op-approve"><i class="fa fa-check"></i> Approve</button>
150 <button type="submit" value="Reject" class="btn btn-default" id="reject_button" name="op-reject"><i class="fa fa-remove"></i> Reject</button>
154 <div class="col-sm-2 col-sm-push-2">
156 <fieldset class="brief">
157 <h4>Terms summary</h4>
159 <li><a href="/cgi-bin/koha/tags/review.pl?approved=1">Approved</a>:
160 <span id="terms_summary_approved_count">[% approved_count | html %]</span>
162 <li><a href="/cgi-bin/koha/tags/review.pl?approved=-1">Rejected</a>:
163 <span id="terms_summary_rejected_count">[% rejected_count | html %]</span>
165 <li><a href="/cgi-bin/koha/tags/review.pl?approved=0">Pending</a>:
166 <span id="terms_summary_unapproved_count">[% unapproved_count | html %]</span>
168 <li><a href="/cgi-bin/koha/tags/review.pl?approved=all">Total</a>:
169 <span id="terms_summary_approved_total">[% approved_total | html %]</span>
172 <span id="terms_summary_status"> </span>
174 <fieldset class="brief">
176 <div class="description">Enter a word or phrase to check against approved/rejected lists: </div>
177 <form method="post" action="/cgi-bin/koha/tags/review.pl">
178 <input type="text" size="14" name="test" id="test" />
179 <fieldset class="action"><button type="submit" value="Test" class="approval_btn btn btn-default btn-sm" id="test_button" name="op-test"><i class="fa fa-check-square-o" aria-hidden="true"></i> Test</button></fieldset>
181 [% IF ( test_term ) %]
182 [% IF ( verdict_ok ) %]
183 "[% test_term | html %]" is permitted.
184 [% ELSIF ( verdict_rej ) %]
185 "[% test_term | html %]" is prohibited.
186 [% ELSIF ( verdict_indeterminate ) %]
187 "[% test_term | html %]" is neither permitted nor prohibited.
195 <div class="col-sm-2 col-sm-pull-10">
197 <form method="post" action="/cgi-bin/koha/tags/review.pl">
198 <fieldset class="brief">
201 <li><label for="tag">Term:</label> <input type="text" name="tag" id="tag" value="[% filter_tag | html %]" />
203 <li><label for="approved">Status:</label>
204 <select name="approved" id="approved">
205 [% IF ( filter_approved_all ) %]<option selected="selected" value="all">all</option>
206 [% ELSE %]<option value="all">all</option>[% END %]
207 [% IF ( filter_approved_ok ) %]<option selected="selected" value="1">approved</option>
208 [% ELSE %]<option value="1">approved</option>[% END %]
209 [% IF ( filter_approved_pending ) %]<option selected="selected" value="0">pending</option>
210 [% ELSE %]<option value="0">pending</option>[% END %]
211 [% IF ( filter_approved_rej ) %]<option selected="selected" value="-1">rejected</option>
212 [% ELSE %]<option value="-1">rejected</option>[% END %]
215 <li><label for="approver">Reviewer:</label> <input type="text" name="approver" id="approver" value="[% filter_approver | html %]" />
218 <label for="from">Date: from </label>
219 <input type="text" size="10" id="from" name="from" value="[% filter_date_approved_from | html %]" class="datepickerfrom" />
220 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
222 <label for="to">...to </label>
223 <input type="text" size="10" id="to" name="to" value="[% filter_date_approved_to | html %]" class="datepickerto" />
224 <div class="hint">[% INCLUDE 'date-format.inc' %]</div>
227 <fieldset class="action"><button type="submit" class="btn btn-default btn-sm"><i class="fa fa-filter" aria-hidden="true"></i> Apply filter(s)</button></fieldset>
237 [% MACRO jsinclude BLOCK %]
238 [% INCLUDE 'datatables.inc' %]
239 [% INCLUDE 'calendar.inc' %]
240 [% Asset.js("js/pages/tags-review.js") | $raw %]
243 [% INCLUDE 'intranet-bottom.inc' %]