File tree Expand file tree Collapse file tree 7 files changed +7
-22
lines changed Expand file tree Collapse file tree 7 files changed +7
-22
lines changed Original file line number Diff line number Diff line change 3333$ form = new FormValidator ('translate ' , 'POST ' , $ currentUrl );
3434$ form ->addHidden ('id ' , $ fieldId );
3535
36- $ extraField ->setLocale (Container::getParameter ('locale ' ));
36+ $ extraField ->setTranslatableLocale (Container::getParameter ('locale ' ));
3737$ em ->refresh ($ extraField );
3838
3939$ form ->addHeader ($ extraField ->getDisplayText ());
Original file line number Diff line number Diff line change 2424/** @var ExtraFieldOptions|null $extraFieldOption */
2525$ extraFieldOption = $ extraFieldOptionsRepo ->find ($ fieldId );
2626
27- $ extraFieldOption ->setLocale (Container::getParameter ('locale ' ));
27+ $ extraFieldOption ->setTranslatableLocale (Container::getParameter ('locale ' ));
2828$ em ->refresh ($ extraFieldOption );
2929
3030if (null === $ extraFieldOption ) {
Original file line number Diff line number Diff line change 3131
3232$ em = Database::getManager ();
3333$ skill = $ em ->find (Skill::class, $ skillId );
34- $ skill ->setLocale (Container::getParameter ('locale ' ));
34+ $ skill ->setTranslatableLocale (Container::getParameter ('locale ' ));
3535$ em ->refresh ($ skill );
3636
3737if (empty ($ skillInfo )) {
Original file line number Diff line number Diff line change 5252
5353$ translateUrl = api_get_self ().'? ' .http_build_query (['skill ' => $ skill ->getId (), 'action ' => $ action ]);
5454
55- $ skill ->setLocale ($ defaultLocale );
55+ $ skill ->setTranslatableLocale ($ defaultLocale );
5656$ em ->refresh ($ skill );
5757
5858$ defaults = [
Original file line number Diff line number Diff line change @@ -382,12 +382,7 @@ public function setAutoRemove(bool $autoRemove): self
382382 return $ this ;
383383 }
384384
385- public function getLocale (): string
386- {
387- return $ this ->locale ;
388- }
389-
390- public function setLocale (string $ locale ): self
385+ public function setTranslatableLocale (string $ locale ): static
391386 {
392387 $ this ->locale = $ locale ;
393388
Original file line number Diff line number Diff line change @@ -131,12 +131,7 @@ public function setPriorityMessage(string $priorityMessage): self
131131 return $ this ;
132132 }
133133
134- public function getLocale (): string
135- {
136- return $ this ->locale ;
137- }
138-
139- public function setLocale (string $ locale ): self
134+ public function setTranslatableLocale (string $ locale ): self
140135 {
141136 $ this ->locale = $ locale ;
142137
Original file line number Diff line number Diff line change @@ -448,12 +448,7 @@ public function addToCourse(SkillRelCourse $item): void
448448 $ this ->courses [] = $ item ;
449449 }
450450
451- public function getLocale (): string
452- {
453- return $ this ->locale ;
454- }
455-
456- public function setLocale (string $ locale ): self
451+ public function setTranslatableLocale (string $ locale ): self
457452 {
458453 $ this ->locale = $ locale ;
459454
You can’t perform that action at this time.
0 commit comments