diff --git a/dev/build/phpstan/phpstan-baseline.neon b/dev/build/phpstan/phpstan-baseline.neon
index da4ecbdb44d..5dc51a035c4 100644
--- a/dev/build/phpstan/phpstan-baseline.neon
+++ b/dev/build/phpstan/phpstan-baseline.neon
@@ -17670,42 +17670,6 @@ parameters:
count: 2
path: ../../../htdocs/salaries/class/paymentsalary.class.php
- -
- message: '#^Call to function method_exists\(\) with \$this\(Salary\) and ''LibStatut'' will always evaluate to true\.$#'
- identifier: function.alreadyNarrowedType
- count: 1
- path: ../../../htdocs/salaries/class/salary.class.php
-
- -
- message: '#^Call to function method_exists\(\) with \$this\(Salary\) and ''getNomUrl'' will always evaluate to true\.$#'
- identifier: function.alreadyNarrowedType
- count: 1
- path: ../../../htdocs/salaries/class/salary.class.php
-
- -
- message: '#^Call to function property_exists\(\) with \$this\(Salary\) and ''amount'' will always evaluate to true\.$#'
- identifier: function.alreadyNarrowedType
- count: 1
- path: ../../../htdocs/salaries/class/salary.class.php
-
- -
- message: '#^Call to function property_exists\(\) with \$this\(Salary\) and ''type_payment'' will always evaluate to true\.$#'
- identifier: function.alreadyNarrowedType
- count: 1
- path: ../../../htdocs/salaries/class/salary.class.php
-
- -
- message: '#^Method Salary\:\:getSommePaiement\(\) return type has no value type specified in iterable type array\.$#'
- identifier: missingType.iterableValue
- count: 1
- path: ../../../htdocs/salaries/class/salary.class.php
-
- -
- message: '#^Negated boolean expression is always true\.$#'
- identifier: booleanNot.alwaysTrue
- count: 2
- path: ../../../htdocs/salaries/class/salary.class.php
-
-
message: '#^Negated boolean expression is always false\.$#'
identifier: booleanNot.alwaysFalse
diff --git a/htdocs/admin/bom.php b/htdocs/admin/bom.php
index 1ca413f7a76..b92c320d96f 100644
--- a/htdocs/admin/bom.php
+++ b/htdocs/admin/bom.php
@@ -144,24 +144,15 @@ if ($action == 'updateMask') {
// by calling method canBeActivated
dolibarr_set_const($db, "BOM_ADDON", $value, 'chaine', 0, '', $conf->entity);
-} elseif ($action == 'set_BOM_DRAFT_WATERMARK') {
+} elseif ($action == 'updateother') {
$draft = GETPOST("BOM_DRAFT_WATERMARK");
$res = dolibarr_set_const($db, "BOM_DRAFT_WATERMARK", trim($draft), 'chaine', 0, '', $conf->entity);
-
if (!($res > 0)) {
$error++;
}
- if (!$error) {
- setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
- } else {
- setEventMessages($langs->trans("Error"), null, 'errors');
- }
-} elseif ($action == 'set_BOM_FREE_TEXT') {
$freetext = GETPOST("BOM_FREE_TEXT", 'restricthtml'); // No alpha here, we want exact string
-
$res = dolibarr_set_const($db, "BOM_FREE_TEXT", $freetext, 'chaine', 0, '', $conf->entity);
-
if (!($res > 0)) {
$error++;
}
@@ -458,14 +449,35 @@ print '';
print "
";
print load_fiche_titre($langs->trans("OtherOptions"), '', '');
+print '