Merge pull request #18314 from ATM-Consulting/FIX_deposit_mask_tulip

FIX: using Tulip, deposit mask doesn't get saved
This commit is contained in:
Laurent Destailleur 2021-08-02 20:15:47 +02:00 committed by GitHub
commit cf072c1061
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -59,8 +59,10 @@ $specimenthirdparty->initAsSpecimen();
if ($action == 'updateMask') {
$maskconstinvoice = GETPOST('maskconstinvoice', 'alpha');
$maskconstcredit = GETPOST('maskconstcredit', 'alpha');
$maskconstdeposit = GETPOST('maskconstdeposit', 'alpha');
$maskinvoice = GETPOST('maskinvoice', 'alpha');
$maskcredit = GETPOST('maskcredit', 'alpha');
$maskdeposit = GETPOST('maskdeposit', 'alpha');
if ($maskconstinvoice) {
$res = dolibarr_set_const($db, $maskconstinvoice, $maskinvoice, 'chaine', 0, '', $conf->entity);
@ -68,6 +70,9 @@ if ($action == 'updateMask') {
if ($maskconstcredit) {
$res = dolibarr_set_const($db, $maskconstcredit, $maskcredit, 'chaine', 0, '', $conf->entity);
}
if ($maskconstdeposit) {
$res = dolibarr_set_const($db, $maskconstdeposit, $maskdeposit, 'chaine', 0, '', $conf->entity);
}
if (!($res > 0)) {
$error++;