* fix phan

* fix

* fix

* fix

* fix

* Update baseline.txt

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
This commit is contained in:
Frédéric FRANCE 2024-09-18 00:58:16 +02:00 committed by GitHub
parent 5e261844b0
commit 1e4d36dfd2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 4 additions and 12 deletions

View File

@ -104,6 +104,7 @@ if ($action == 'updateMask') {
$module = new $classname($db);
'@phan-var-force ModelePDFCommandes $module';
/** @var ModelePDFCommandes $module */
if ($module->write_file($commande, $langs) > 0) {
header("Location: ".DOL_URL_ROOT."/document.php?modulepart=commande&file=SPECIMEN.pdf");
return;

View File

@ -99,6 +99,7 @@ if ($action == 'updateMask') {
$module = new $classname($db);
'@phan-var-force ModelePDFPropales $module';
/** @var ModelePDFPropales $module */
if ($module->write_file($propal, $langs) > 0) {
header("Location: ".DOL_URL_ROOT."/document.php?modulepart=propal&file=SPECIMEN.pdf");
return;

View File

@ -12,7 +12,7 @@
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
* Copyright (C) 2018 Nicolas ZABOURI <info@inovea-conseil.com>
* Copyright (C) 2018 Ferran Marcet <fmarcet@2byte.es.com>
* Copyright (C) 2018-2022 Frédéric France <frederic.france@netlogic.fr>
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2022-2023 George Gkantinas <info@geowv.eu>
* Copyright (C) 2023 Nick Fragoulis
* Copyright (C) 2023 Alexandre Janniaux <alexandre.janniaux@gmail.com>
@ -856,7 +856,6 @@ if (empty($reshook)) {
$clone->fournisseur = 0;
$clone->client = 0;
$db->begin();
$clone->context['createfromclone'] = 'createfromclone';
@ -864,16 +863,7 @@ if (empty($reshook)) {
if ($id > 0) {
$clone->id = $id;
} else {
if ($clone->error == 'ErrorProductAlreadyExists') {
$refalreadyexists++;
$action = "";
$mesg = $langs->trans("ErrorProductAlreadyExists", $clone->ref);
$mesg .= ' <a href="' . $_SERVER["PHP_SELF"] . '?ref=' . $clone->ref . '">' . $langs->trans("ShowCardHere") . '</a>.';
setEventMessages($mesg, null, 'errors');
} else {
setEventMessages(empty($clone->error) ? '' : $langs->trans($clone->error), $clone->errors, 'errors');
}
setEventMessages($clone->error, $clone->errors, 'errors');
$error++;
}