FIX check parameter socid before cloning a customer proposal (#28085)

This commit is contained in:
lvessiller-opendsi 2024-02-09 14:09:03 +01:00 committed by GitHub
parent b2fad54f1f
commit e3ad92df44
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -179,8 +179,8 @@ if (empty($reshook)) {
// Action clone object
if ($action == 'confirm_clone' && $confirm == 'yes' && $usercancreate) {
if (!GETPOST('socid', 3)) {
setEventMessages($langs->trans("NoCloneOptionsSpecified"), null, 'errors');
if (!($socid > 0)) {
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('IdThirdParty')), null, 'errors');
} else {
if ($object->id > 0) {
if (!empty($conf->global->PROPAL_CLONE_DATE_DELIVERY)) {