// Refactoring of shop class with new context
This commit is contained in:
@@ -155,8 +155,8 @@ class CustomerCore extends ObjectModel
|
||||
|
||||
public function add($autodate = true, $nullValues = true)
|
||||
{
|
||||
$this->id_shop = ($this->id_shop) ? $this->id_shop : Shop::getCurrentShop();
|
||||
$this->id_group_shop = ($this->id_group_shop) ? $this->id_group_shop : Shop::getCurrentGroupShop();
|
||||
$this->id_shop = ($this->id_shop) ? $this->id_shop : Context::getContext()->shop->getID();
|
||||
$this->id_group_shop = ($this->id_group_shop) ? $this->id_group_shop : Context::getContext()->shop->getGroupID();
|
||||
$this->birthday = (empty($this->years) ? $this->birthday : (int)($this->years).'-'.(int)($this->months).'-'.(int)($this->days));
|
||||
$this->secure_key = md5(uniqid(rand(), true));
|
||||
$this->last_passwd_gen = date('Y-m-d H:i:s', strtotime('-'.Configuration::get('PS_PASSWD_TIME_FRONT').'minutes'));
|
||||
|
||||
Reference in New Issue
Block a user