Ver código fonte

Merge tag 'hotfix_1431' into develop

hotfix_1431
feature/souke
Guillaume Bourgeois 1 ano atrás
pai
commit
4254059a5f
1 arquivos alterados com 3 adições e 2 exclusões
  1. +3
    -2
      common/logic/Product/ProductPrice/Service/ProductPriceSolver.php

+ 3
- 2
common/logic/Product/ProductPrice/Service/ProductPriceSolver.php Ver arquivo

@@ -9,6 +9,7 @@ use common\logic\SolverInterface;
use common\logic\User\User\Model\User;
use common\logic\User\User\Service\UserSolver;
use common\logic\User\UserGroup\Model\UserGroup;
use common\logic\User\UserGroup\Repository\UserGroupRepository;

class ProductPriceSolver extends AbstractService implements SolverInterface
{
@@ -90,7 +91,7 @@ class ProductPriceSolver extends AbstractService implements SolverInterface
{
// @TODO : trouver une solution pour hydrater autrement cette donnée
if($productPrice->id_user_group && !$productPrice->userGroup) {
$userGroup = UserGroup::searchOne(['id' => $productPrice->id_user_group]);
$userGroup = UserGroupRepository::getInstance()->findOneUserGroupById($productPrice->id_user_group);
if($userGroup) {
$productPrice->populateUserGroup($userGroup);
}
@@ -126,7 +127,7 @@ class ProductPriceSolver extends AbstractService implements SolverInterface
{
// @TODO : trouver une solution pour hydrater autrement cette donnée
if($productPrice->id_user_group && !$productPrice->userGroup) {
$userGroup = UserGroup::searchOne(['id' => $productPrice->id_user_group]);
$userGroup = UserGroupRepository::getInstance()->findOneUserGroupById($productPrice->id_user_group);
if($userGroup) {
$productPrice->populateUserGroup($userGroup);
}

Carregando…
Cancelar
Salvar