FIX wrong "fournisseur" var value checking

This commit is contained in:
Regis Houssin
2024-12-02 11:24:03 +01:00
parent d423633266
commit 6aa70da43f

View File

@@ -1388,7 +1388,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($canvasdisplayactio
if (getDolGlobalString('THIRDPARTY_SUPPLIER_BY_DEFAULT')) {
$default = 1;
}
print $form->selectyesno("fournisseur", (GETPOSTINT('fournisseur') != '' ? GETPOSTINT('fournisseur') : (GETPOST("type") == '' ? $default : $object->fournisseur)), 1, 0, (GETPOST("type") == '' ? 1 : 0), 1);
print $form->selectyesno("fournisseur", (GETPOSTINT('fournisseur') > 0 ? GETPOSTINT('fournisseur') : (GETPOST("type") == '' ? $default : $object->fournisseur)), 1, 0, (GETPOST("type") == '' ? 1 : 0), 1);
print '</td>';