Jump to content

require phone number on one-step checkout


Recommended Posts

I have it set up so when you add an address, all that is required (other than first/last/pw/email) is country and phone number. That all works. The only problem is in the one-step checkout for a new user, it doesn't require the phone number.

 

Require phone number in 'pref > customers' is checked.

 

 

in the authcontroller.php, I believe it's to do with this line:

if (Configuration::get('PS_ONE_PHONE_AT_LEAST') && !Tools::getValue('phone') && !Tools::getValue('phone_mobile') &&
(Configuration::get('PS_REGISTRATION_PROCESS_TYPE') || Configuration::get('PS_GUEST_CHECKOUT_ENABLED')))
$this->errors[] = Tools::displayError('You must register at least one phone number');

 

if i change it to:

if (Configuration::get('PS_ONE_PHONE_AT_LEAST') && !Tools::getValue('phone') && !Tools::getValue('phone_mobile'))
$this->errors[] = Tools::displayError('You must register at least one phone number');

then it requires on one-step checkout (good), but then also makes it required on one-step regular signup (which I dont want, since it doesn't add to an address). How do I tell it to NOT require phone for one-step signup, but have it required everywhere else?

 

This is on 1.5.2.

 

Cheers

Edited by cmto (see edit history)
Link to comment
Share on other sites

×
×
  • Create New...