Lines 6-12
Link Here
|
6 |
[% USE raw %] |
6 |
[% USE raw %] |
7 |
[% USE Asset %] |
7 |
[% USE Asset %] |
8 |
[% USE To %] |
8 |
[% USE To %] |
9 |
|
9 |
[% USE AuthorisedValues %] |
10 |
[% SET search_results_block_id = 'searchresults' %] |
10 |
[% SET search_results_block_id = 'searchresults' %] |
11 |
|
11 |
|
12 |
[%# Display a simple form %] |
12 |
[%# Display a simple form %] |
Lines 318-323
Link Here
|
318 |
[% CASE %] |
318 |
[% CASE %] |
319 |
let patron_search_url = '/api/v1/patrons'; |
319 |
let patron_search_url = '/api/v1/patrons'; |
320 |
[% END %] |
320 |
[% END %] |
|
|
321 |
|
322 |
const av_bsort1= new Map([% To.json(AuthorisedValues.Get('Bsort1')) | $raw %].map( av => [av.authorised_value, av.lib])); |
323 |
const av_bsort2= new Map([% To.json(AuthorisedValues.Get('Bsort2')) | $raw %].map( av => [av.authorised_value, av.lib])); |
324 |
|
321 |
$(document).ready(function(){ |
325 |
$(document).ready(function(){ |
322 |
|
326 |
|
323 |
let parent_block = $("#[% search_results_block_id | html %]"); |
327 |
let parent_block = $("#[% search_results_block_id | html %]"); |
Lines 633-639
Link Here
|
633 |
"searchable": true, |
637 |
"searchable": true, |
634 |
"orderable": true, |
638 |
"orderable": true, |
635 |
"render": function( data, type, row, meta ) { |
639 |
"render": function( data, type, row, meta ) { |
636 |
return escape_str(data); |
640 |
let bsort1_lib = av_bsort1.get( data.toString() ) || data; |
|
|
641 |
return escape_str( bsort1_lib ); |
637 |
} |
642 |
} |
638 |
} |
643 |
} |
639 |
|
644 |
|
Lines 643-649
Link Here
|
643 |
"searchable": true, |
648 |
"searchable": true, |
644 |
"orderable": true, |
649 |
"orderable": true, |
645 |
"render": function( data, type, row, meta ) { |
650 |
"render": function( data, type, row, meta ) { |
646 |
return escape_str(data); |
651 |
let bsort2_lib = av_bsort2.get( data.toString() ) || data; |
|
|
652 |
return escape_str( bsort2_lib ); |
647 |
} |
653 |
} |
648 |
} |
654 |
} |
649 |
|
655 |
|
650 |
- |
|
|