new: make click in choices of search box load the page of the product
This commit is contained in:
@@ -13,9 +13,10 @@
|
||||
var id = item.value;
|
||||
$('#' + field).val(id);
|
||||
|
||||
if (typeof(callback) != 'undefined') {
|
||||
var c = callback + '(' + id + ')';
|
||||
eval(c);
|
||||
if (typeof callback === 'function') {
|
||||
callback.call(this, item, evt);
|
||||
} else if (typeof callback === 'string' && callback.length && typeof window[callback] === 'function') {
|
||||
window[callback].call(this, item, evt);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user