mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-12 10:52:37 +01:00
Fix 4: test on selected value was lenght > 0 but if value is 0, lenght
is 1 and we want flase here. Fix 5: Button Add is enabled once a predefined product is selected.
This commit is contained in:
@@ -217,7 +217,7 @@ $(document).ready(function() {
|
||||
$('#service_duration_area').hide();
|
||||
|
||||
$('#idprod').change(function() {
|
||||
if ($(this).val().length > 0)
|
||||
if ($(this).val() > 0)
|
||||
{
|
||||
<?php if (! empty($conf->fckeditor->enabled) && ! empty($conf->global->FCKEDITOR_ENABLE_DETAILS)) { ?>
|
||||
// We use CKEditor
|
||||
@@ -226,8 +226,9 @@ $(document).ready(function() {
|
||||
// We use a simple textarea
|
||||
$('#product_desc').focus();
|
||||
<?php } ?>
|
||||
|
||||
} else {
|
||||
$('#addlinebutton').removeAttr('disabled');
|
||||
} else {
|
||||
$('#addlinebutton').attr('disabled','disabled');
|
||||
$('#update_desc_checkbox').removeAttr('checked').trigger('change');
|
||||
$('#update_price_checkbox').removeAttr('checked').trigger('change');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user