|
16 | 16 | use Oro\Bundle\EntityConfigBundle\Translation\ConfigTranslationHelper;
|
17 | 17 | use Oro\Bundle\EntityExtendBundle\Entity\AbstractEnumValue;
|
18 | 18 | use Oro\Bundle\EntityExtendBundle\Entity\Repository\EnumValueRepository;
|
19 |
| -use Oro\Bundle\TranslationBundle\Entity\Translation; |
| 19 | +use Oro\Bundle\TranslationBundle\Translation\Translator; |
20 | 20 |
|
21 | 21 | /**
|
22 | 22 | * @SuppressWarnings(PHPMD.ExcessiveClassComplexity)
|
@@ -90,7 +90,7 @@ public function sync()
|
90 | 90 | $enumOptions = $enumFieldConfig->get('enum_options');
|
91 | 91 |
|
92 | 92 | if (empty($locale)) {
|
93 |
| - $locale = Translation::DEFAULT_LOCALE; |
| 93 | + $locale = Translator::DEFAULT_LOCALE; |
94 | 94 | }
|
95 | 95 |
|
96 | 96 | if (!empty($enumName)) {
|
@@ -140,7 +140,7 @@ public function applyEnumNameTrans($enumCode, $enumName, $locale)
|
140 | 140 | // labels initialization
|
141 | 141 | $labelsToBeUpdated[$labelKey] = $enumName;
|
142 | 142 | $labelsToBeUpdated[$pluralLabelKey] = $enumName;
|
143 |
| - if ($locale === Translation::DEFAULT_LOCALE) { |
| 143 | + if ($locale === Translator::DEFAULT_LOCALE) { |
144 | 144 | // set empty description only for default locale
|
145 | 145 | $labelsToBeUpdated[$descriptionKey] = '';
|
146 | 146 | }
|
@@ -237,7 +237,7 @@ public function applyEnumOptions($enumValueClassName, array $options, $locale)
|
237 | 237 | }
|
238 | 238 |
|
239 | 239 | if (!empty($changes)) {
|
240 |
| - if ($locale !== Translation::DEFAULT_LOCALE) { |
| 240 | + if ($locale !== Translator::DEFAULT_LOCALE) { |
241 | 241 | foreach ($changes as $value) {
|
242 | 242 | $value->setLocale($locale);
|
243 | 243 | }
|
|
0 commit comments