Jump to content

the dni or identification number is not saved in database


Recommended Posts

  • 3 months later...

Hello,

 

I have noticed that the dni is not being stored in the database, I also would like to add it to the invoice,

 

Any ideas?

 

 

Thank you

 

Hello,

 

edit http://controllers/front/AddressController.php

 

find lines

if ($country->isNeedDni() && (!Tools::getValue('dni') || !Validate::isDniLite(Tools::getValue('dni'))))
    $this->errors[] = Tools::displayError('The identification number is incorrect or has already been used.');
else if (!$country->isNeedDni())
    $address->dni = null;

replace it with:

if (Tools::getValue('dni') && !Validate::isDniLite(Tools::getValue('dni')))
    $this->errors[] = Tools::displayError('The identification number is incorrect or has already been used.');
 

Solution found here

  • Like 1
Link to comment
Share on other sites

×
×
  • Create New...