Fix silent failure when attempting to delete a LI
whose type or cost was not set; dojo.string.subtitute
does not like replacement values to be null.
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
git-svn-id: svn://svn.open-ils.org/ILS/trunk@19160
dcc99617-32d9-48b4-a31d-
7c20da2025e4
var cost = widgetRegistry.acqii[item.id()].cost_billed.getFormattedValue();
var msg = dojo.string.substitute(
localeStrings.INVOICE_CONFIRM_ITEM_DELETE, [
- cost,
- widgetRegistry.acqii[item.id()].inv_item_type.getFormattedValue()
+ cost || 0,
+ widgetRegistry.acqii[item.id()].inv_item_type.getFormattedValue() || ''
]
);
if(!confirm(msg)) return;