diff --git a/htdocs/public/payment/newpayment.php b/htdocs/public/payment/newpayment.php index 10665af0b87..1281002218c 100644 --- a/htdocs/public/payment/newpayment.php +++ b/htdocs/public/payment/newpayment.php @@ -1816,7 +1816,7 @@ if ($source == 'member' || $source == 'membersubscription') { } // TODO Move this into previous hook - if (getDolGlobalString('MEMBER_NEWFORM_DOLIBARRTURNOVER')) { + if (getDolGlobalString('MEMBER_NEWFORM_DOLIBARRTURNOVER') && $action != 'dopayment') { $country_id = 0; if ($member->thirdparty instanceOf Societe) { $country_id = $member->thirdparty->country_id; @@ -1844,7 +1844,7 @@ if ($source == 'member' || $source == 'membersubscription') { $country_code = dol_getIdFromCode($db, $country_id, 'c_country', 'rowid', 'code'); if ($country_code === 'FR' && $checkednature === 'mor' && (GETPOST('reload') ? GETPOST('pp') : $pp)) { - print ''; + print ''; } else { $arraybudget = array('50' => '<= 100 000', '100' => '<= 200 000', '200' => '<= 500 000', '300' => '<= 1 500 000', '600' => '<= 3 000 000', '1000' => '<= 5 000 000', '2000' => '5 000 000+'); print $form->selectarray('budget', $arraybudget, GETPOSTINT('budget'), 1, 0, 0, ($checkednature === 'mor' ? 'required' :''), 0, 0, 0, ''); @@ -1924,6 +1924,9 @@ if ($source == 'member' || $source == 'membersubscription') { } if (selectcountry_id == 1) { + if (jQuery("#budget").val() == \'\') { + return null; + } if (pp) { console.log("value selected in input text field is "+jQuery("#budget").val()); newamount = Math.max(Math.round(price2numjs(jQuery("#budget").val()) * 0.005), 50);