Lines 289-298
Link Here
|
289 |
|
289 |
|
290 |
[% IF ( deleted ) %]<div class="alert alert-info">The selected suggestions have been deleted.</div>[% END %] |
290 |
[% IF ( deleted ) %]<div class="alert alert-info">The selected suggestions have been deleted.</div>[% END %] |
291 |
|
291 |
|
292 |
[% IF ( suggestions_loop ) %] |
292 |
[% IF suggestions_loop OR title_filter %] |
293 |
[% SET can_delete_suggestion = 0 %] |
|
|
294 |
<form action="/cgi-bin/koha/opac-suggestions.pl" class="form-inline" id="search_suggestions_form" method="get"> |
293 |
<form action="/cgi-bin/koha/opac-suggestions.pl" class="form-inline" id="search_suggestions_form" method="get"> |
295 |
<div class="form-row"> |
294 |
<div class="form-row"> |
|
|
295 |
<label for="title_filter">Search for:</label> |
296 |
<input type="text" name="title_filter" id="title_filter" value="[% title_filter | html %]" /> |
296 |
[% IF Koha.Preference( 'OPACViewOthersSuggestions' ) == 1 %] |
297 |
[% IF Koha.Preference( 'OPACViewOthersSuggestions' ) == 1 %] |
297 |
[% IF loggedinusername %] |
298 |
[% IF loggedinusername %] |
298 |
<div class="col-auto my-1"> |
299 |
<div class="col-auto my-1"> |
Lines 307-319
Link Here
|
307 |
[% END %] |
308 |
[% END %] |
308 |
</select> |
309 |
</select> |
309 |
</div> |
310 |
</div> |
310 |
<div class="col-auto my-1"> |
|
|
311 |
<button type="submit" class="btn btn-sm btn-primary">Go</button> |
312 |
</div> |
313 |
[% END %] |
311 |
[% END %] |
314 |
[% END %] |
312 |
[% END %] |
|
|
313 |
<div class="col-auto my-1"> |
314 |
<button type="submit" class="btn btn-sm btn-primary">Go</button> |
315 |
</div> |
315 |
</div> |
316 |
</div> |
316 |
</form> |
317 |
</form> |
|
|
318 |
[% END %] |
319 |
[% IF suggestions_loop %] |
320 |
[% SET can_delete_suggestion = 0 %] |
317 |
<form action="/cgi-bin/koha/opac-suggestions.pl" method="post" id="delete_suggestions"> |
321 |
<form action="/cgi-bin/koha/opac-suggestions.pl" method="post" id="delete_suggestions"> |
318 |
<input type="hidden" name="op" value="delete_confirm" /> |
322 |
<input type="hidden" name="op" value="delete_confirm" /> |
319 |
[% IF ( loggedinusername || ( Koha.Preference( 'AnonSuggestions' ) == 1 ) ) %] |
323 |
[% IF ( loggedinusername || ( Koha.Preference( 'AnonSuggestions' ) == 1 ) ) %] |
Lines 434-451
Link Here
|
434 |
</form> |
438 |
</form> |
435 |
[% ELSE %] |
439 |
[% ELSE %] |
436 |
[% IF Koha.Preference( 'OPACViewOthersSuggestions' ) %] |
440 |
[% IF Koha.Preference( 'OPACViewOthersSuggestions' ) %] |
437 |
[% IF ( loggedinusername ) %] |
441 |
[% IF title_filter %] |
438 |
[% IF ( suggested_by_anyone ) %] |
442 |
<p>There are no pending purchase suggestions matching your search.</p> |
439 |
<p>There are no pending purchase suggestions.</p> |
443 |
[% ELSIF loggedinusername AND NOT suggested_by_anyone %] |
440 |
[% ELSE %] |
444 |
<p>You have no pending purchase suggestions. <a href="/cgi-bin/koha/opac-suggestions.pl?suggested_by_anyone=1">View all suggestions</a></p> |
441 |
<p>You have no pending purchase suggestions. <a href="/cgi-bin/koha/opac-suggestions.pl?suggested_by_anyone=1">View all suggestions</a></p> |
|
|
442 |
[% END %] |
443 |
[% ELSE %] |
445 |
[% ELSE %] |
444 |
<p>There are no pending purchase suggestions.</p> |
446 |
<p>There are no pending purchase suggestions.</p> |
445 |
[% END %] |
447 |
[% END %] |
446 |
[% ELSE %] |
448 |
[% ELSE %] |
447 |
[% IF ( loggedinusername ) %] |
449 |
[% IF ( loggedinusername ) %] |
448 |
<p>You have no pending purchase suggestions.</p> |
450 |
[% IF title_filter %] |
|
|
451 |
<p>There are no pending purchase suggestions matching your search.</p> |
452 |
[% ELSE %] |
453 |
<p>You have no pending purchase suggestions.</p> |
454 |
[% END %] |
449 |
[% ELSE %] |
455 |
[% ELSE %] |
450 |
<p>You are not authorized to see pending purchase suggestions.</p> |
456 |
<p>You are not authorized to see pending purchase suggestions.</p> |
451 |
[% END %] |
457 |
[% END %] |
Lines 489-495
Link Here
|
489 |
$(function() { |
495 |
$(function() { |
490 |
$("#suggestt").dataTable($.extend(true, {}, dataTablesDefaults, { |
496 |
$("#suggestt").dataTable($.extend(true, {}, dataTablesDefaults, { |
491 |
"order": [[ 1, "asc" ]], |
497 |
"order": [[ 1, "asc" ]], |
492 |
"dom": '<"top"<"table_entries"><"table_controls"f>>t', |
|
|
493 |
"autoWidth": false, |
498 |
"autoWidth": false, |
494 |
"columnDefs": [ |
499 |
"columnDefs": [ |
495 |
[% IF ( loggedinusername ) %]{ "targets": [ 0 ], "sortable": false, "searchable": false }[% END %] |
500 |
[% IF ( loggedinusername ) %]{ "targets": [ 0 ], "sortable": false, "searchable": false }[% END %] |