@@ -, +, @@
---
.../prog/en/modules/tools/manage-marc-import.tt | 94 ++++++++++----------
1 files changed, 48 insertions(+), 46 deletions(-)
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt
+++ a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt
@@ -27,55 +27,57 @@ $(document).ready(function(){
$(this).parent().hide();
});
- $("#records-table").dataTable({
- "aLengthMenu": [[10, 15, 20, 25, 50, 100, -1], [10, 15, 20, 25, 50, 100, _("All")]],
- "iDisplayLength" : 20,
- "bAutoWidth": false,
- "bFilter": false,
- "bProcessing": true,
- "bServerSide": true,
- "sAjaxSource": 'batch_records_ajax.pl',
- "sPaginationType": "full_numbers",
- "sDom": '<"top pager"iflp>rt<"bottom pager"flp><"clear">',
- "aoColumns": [
- { "mDataProp": "import_record_id" },
- { "mDataProp": "citation" },
- { "mDataProp": "status" },
- { "mDataProp": "overlay_status" },
- { "mDataProp": "match_citation" },
- { "mDataProp": "matched" },
- ],
- "fnServerData": function ( sSource, aoData, fnCallback ) {
- aoData.push( { "name": "import_batch_id", "value": [% import_batch_id %] } );
+ [% IF import_batch_id %]
+ $("#records-table").dataTable({
+ "aLengthMenu": [[10, 15, 20, 25, 50, 100, -1], [10, 15, 20, 25, 50, 100, _("All")]],
+ "iDisplayLength" : 20,
+ "bAutoWidth": false,
+ "bFilter": false,
+ "bProcessing": true,
+ "bServerSide": true,
+ "sAjaxSource": 'batch_records_ajax.pl',
+ "sPaginationType": "full_numbers",
+ "sDom": '<"top pager"iflp>rt<"bottom pager"flp><"clear">',
+ "aoColumns": [
+ { "mDataProp": "import_record_id" },
+ { "mDataProp": "citation" },
+ { "mDataProp": "status" },
+ { "mDataProp": "overlay_status" },
+ { "mDataProp": "match_citation" },
+ { "mDataProp": "matched" },
+ ],
+ "fnServerData": function ( sSource, aoData, fnCallback ) {
+ aoData.push( { "name": "import_batch_id", "value": [% import_batch_id %] } );
- $.getJSON( sSource, aoData, function (json) {
- fnCallback(json)
- } );
- },
- "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
- $('td:eq(1)', nRow).html(
- '' + aData['citation'] + ''
- );
-
- if ( aData['match_id'] ) {
- $('td:eq(4)', nRow).html(
- _("Matches biblio ")
- + aData['match_id']
- + " (" + _("score") + "="
- + aData['score']
- + '):' + '' + aData['match_citation'] + ''
+ $.getJSON( sSource, aoData, function (json) {
+ fnCallback(json)
+ } );
+ },
+ "fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) {
+ $('td:eq(1)', nRow).html(
+ '' + aData['citation'] + ''
);
- }
- $('td:eq(5)', nRow).html(
- '' + aData['matched'] + ''
- );
- },
- });
+ if ( aData['match_id'] ) {
+ $('td:eq(4)', nRow).html(
+ _("Matches biblio ")
+ + aData['match_id']
+ + " (" + _("score") + "="
+ + aData['score']
+ + '):' + '' + aData['match_citation'] + ''
+ );
+ }
+
+ $('td:eq(5)', nRow).html(
+ '' + aData['matched'] + ''
+ );
+ },
+ });
+ [% END %]
});
function show_marc( id ) {
--