Bug 17840: adding classes to notes in checkouts
authorEmma Smith <emma.nakamura.smith@gmail.com>
Tue, 17 Jan 2017 03:23:18 +0000 (03:23 +0000)
committerKyle M Hall <kyle@bywatersolutions.com>
Fri, 3 Mar 2017 17:56:43 +0000 (17:56 +0000)
Test Plan
1) Add an internal and a public note to an item.
2) Check out the item.
3) Verify that both notes are shown in between title and barcode in the
second column of the details table.
4) Verify there is an empty class="" in the HTML source code for each
5) Apply patch and refresh page
6) View page source, confirm that class has been changed

I tested this by first applying the patch for bug 17919 to catch the
check-in software error. Patch working as expected :)

Signed-off-by: Claire Gravely <claire_gravely@hotmail.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
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/js/checkouts.js

index f12743f..1ef2375 100644 (file)
@@ -239,18 +239,12 @@ $(document).ready(function() {
                         }
 
                         if ( oObj.itemnotes ) {
-                            var span_class = "";
-                            if ( $.datepicker.formatDate('yy-mm-dd', new Date(oObj.issuedate) ) == ymd ) {
-                                span_class = "circ-hlt";
-                            }
+                            var span_class = "text-muted";
                             title += " - <span class='" + span_class + "'>" + oObj.itemnotes + "</span>"
                         }
 
                         if ( oObj.itemnotes_nonpublic ) {
-                            var span_class = "";
-                            if ( $.datepicker.formatDate('yy-mm-dd', new Date(oObj.issuedate) ) == ymd ) {
-                                span_class = "circ-hlt";
-                            }
+                            var span_class = "text-danger";
                             title += " - <span class='" + span_class + "'>" + oObj.itemnotes_nonpublic + "</span>"
                         }