Skip to content
Snippets Groups Projects
Commit 625f53a7 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

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.
parent cc22f25d
No related branches found
No related tags found
No related merge requests found
......@@ -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');
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment