Fix nette 3.0
This commit is contained in:
@@ -41,6 +41,7 @@ abstract class BaseFrontPresenter extends UnsecuredPresenter
|
||||
|
||||
protected function startup()
|
||||
{
|
||||
|
||||
$trs = $this->em->getRepository(Translation::class)->findBy([], ['id' => 'ASC', 'direction' => 'ASC']);
|
||||
$drs = $this->em->getRepository(Dictionary::class)->findPairs('id', 'name');
|
||||
$select = [];
|
||||
@@ -52,10 +53,10 @@ abstract class BaseFrontPresenter extends UnsecuredPresenter
|
||||
$lang = mb_substr($lang1, 0, -1);
|
||||
$lang .= "o-" . $lang2;
|
||||
$slug = Strings::webalize($lang);
|
||||
$select[$drs[$t->getDictionary()->getId()]][$t->getId()] = $lang;
|
||||
$translations[$t->getId()]["slug"] = $slug;
|
||||
$translations[$t->getId()]["lang"] = $lang;
|
||||
$translations[$t->getId()]["t"] = $t;
|
||||
$select[$drs[$t->getDictionary()->id]][$t->id] = $lang;
|
||||
$translations[$t->id]["slug"] = $slug;
|
||||
$translations[$t->id]["lang"] = $lang;
|
||||
$translations[$t->id]["t"] = $t;
|
||||
$slugs[$slug] = $t;
|
||||
}
|
||||
$this->translations = $translations;
|
||||
|
||||
Reference in New Issue
Block a user