18 lines
547 B
JavaScript
18 lines
547 B
JavaScript
jQuery(function($) {
|
|
$('.st_product_options_stock').change(function(e) {
|
|
var checkbox = $(e.target);
|
|
var container = $(this);
|
|
|
|
if (checkbox.is('.st_product_options_stock_checkbox'))
|
|
{
|
|
var input = container.find('.st_product_options_stock_value');
|
|
|
|
if (checkbox.prop('checked')) {
|
|
input.removeAttr('disabled');
|
|
} else {
|
|
input.attr('disabled', true);
|
|
}
|
|
// checkbox.next().val(!this.checked | 0);
|
|
}
|
|
});
|
|
}); |