public function renderDetail($idGallery, $lang) { $gallery = $this->gallery->getGallery($idGallery, $lang); if (!$gallery) { $this->error($this->translator->trans('admin.commons.error')); } $this->title($this->translator->translate('admin.gallery.detail.title', ['title' => $gallery->name])); $this->navigation->addItem('admin.gallery.title', 'Gallery:'); $this->template->gallery = $gallery; $this->template->galleryPath = galleryPath . $gallery->idGallery . '_' . $gallery->lang; $this->lang = $gallery->lang; $this['galleryForm']->setDefaults($gallery->toArray()); }
public function renderDetail($id) { $gallery = $this->gallery->getGallery($id, $this->translator->getLocale()); $this->template->galleryPath = galleryPath . $gallery->idGallery . '_' . $gallery->lang; $this->template->gallery = $gallery; }