Просмотр исходного кода

Merge tag 'hotfix_1426' into develop

hotfix_1426
feature/souke
Guillaume Bourgeois 1 год назад
Родитель
Сommit
ab6a2c38f9
1 измененных файлов: 8 добавлений и 6 удалений
  1. +8
    -6
      backend/controllers/UserController.php

+ 8
- 6
backend/controllers/UserController.php Просмотреть файл

} else { } else {
if ($model->load(\Yii::$app->request->post()) && $model->validate() && YII_ENV != 'demo') { if ($model->load(\Yii::$app->request->post()) && $model->validate() && YII_ENV != 'demo') {


$model = $userModule->getBuilder()->createUser(
User::TYPE_INDIVIDUAL,
$userCreate = $userModule->getBuilder()->createUser(
$model->type,
$model->email, $model->email,
$model->name, $model->name,
$model->lastname, $model->lastname,
Password::generate(), Password::generate(),
$model->send_mail_welcome $model->send_mail_welcome
); );
$userCreate->points_sale = $model->points_sale;
$userCreate->user_groups = $model->user_groups;


$this->processLinkPointSale($model);
$this->processLinkUserGroup($model);
$this->processProductPricePercent($model);
$this->processLinkPointSale($userCreate);
$this->processLinkUserGroup($userCreate);
//$this->processProductPricePercent($model);


$this->setFlash('success', 'Utilisateur créé.'); $this->setFlash('success', 'Utilisateur créé.');


} }
$this->processLinkPointSale($model); $this->processLinkPointSale($model);
$this->processLinkUserGroup($model); $this->processLinkUserGroup($model);
$this->processProductPricePercent($model);
//$this->processProductPricePercent($model);


if($model->newsletter) { if($model->newsletter) {
$userModule->getNewsletterManager()->subscribeUserNewsletter($model); $userModule->getNewsletterManager()->subscribeUserNewsletter($model);

Загрузка…
Отмена
Сохранить