Fix broken images for items without ISBNs in search results user/dbs/fix-broken-images-2_1
authorDan Scott <dan@coffeecode.net>
Fri, 24 Jun 2011 14:44:43 +0000 (10:44 -0400)
committerDan Scott <dan@coffeecode.net>
Fri, 24 Jun 2011 15:00:16 +0000 (11:00 -0400)
commit23175f28bd624c86f3dd1e42d149c61638f5bada
treed9ecc5a94edf674efe5e79d23dc889e04f54f2ea
parentbab001487d01455b6a1f59745a81a6ce1b0528e9
Fix broken images for items without ISBNs in search results

The search results code happily sets the src attribute of the cover
image to an empty string (as returned by cleanISBN()) if currentISBN has
not been defined (which is generally the case if an item doesn't have an
ISBN, such as a DVD or a thesis or an old book).

Protect against the empty string and set the src attribute to
'/opac/images/blank.png' to avoid broken image indicators in search
results.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Dan Scott <dan@coffeecode.net>
Open-ILS/web/opac/skin/default/js/result_common.js