Bug 15327: Minor tweaks to Bootstrap modal handling on Staged MARC management page
authorOwen Leonard <oleonard@myacpl.org>
Sat, 5 Dec 2015 01:37:47 +0000 (20:37 -0500)
committerKyle M Hall <kyle@bywatersolutions.com>
Wed, 30 Dec 2015 14:37:32 +0000 (14:37 +0000)
This patch makes a couple of minor corrections to the template for
staged MARC management. The MARC preview is now formatted using the
"html" option, and some obsolete Greybox-related code has been removed.

To test:

1. Apply the patch and go to Tools -> Staged MARC management.
2. Click any staged MARC file containing multiple records.
3. Click the title in the "Citation" column and confirm that a Bootstrap
   modal is triggered showing the correct data.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Modal looks much better. Works as advertised

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt

index f00929f..84dd2db 100644 (file)
@@ -90,7 +90,7 @@ $(document).ready(function(){
             [% END %]
 
             $('td:eq(1)', nRow).html(
-                '<a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=' + aData['import_record_id'] + '" class="previewMARC">' + aData['citation'] + '</a>'
+                '<a href="/cgi-bin/koha/catalogue/showmarc.pl?importid=' + aData['import_record_id'] + '&viewas=html" class="previewMARC">' + aData['citation'] + '</a>'
             );
 
             $('td:eq(2)', nRow).html(
@@ -123,7 +123,7 @@ $(document).ready(function(){
             }
             if (aData['diff_url']){
                 $('td:eq(5)', nRow).html(
-                    '<a rel="gb_page_center[960,600]" href="'+aData['diff_url']+'">View</a>'
+                    '<a href="'+aData['diff_url']+'">View</a>'
                 );
             }
             $('td:eq(6)', nRow).html(
@@ -138,7 +138,7 @@ $(document).ready(function(){
         var ltitle = $(this).text();
         var page = $(this).attr("href");
         $("#marcPreviewLabel").text(ltitle);
-        $("#marcPreview .modal-body").load(page + " pre");
+        $("#marcPreview .modal-body").load(page + " table");
         $('#marcPreview').modal({show:true});
     });
     $("#marcPreview").on("hidden", function(){