/** * Renders HTML code for custom panel. * * @return string */ public function getPanel() { ob_start(); $translator = $this->translator ?: new MockTranslator(); $services = $this->provider->getServices(); require __DIR__ . '/templates/panel.phtml'; return ob_get_clean(); }
public function actionDefault() { $this->components = []; foreach ($this->provider->getServices() as $service) { foreach ($service->getEmails() as $email) { $this->components[] = [$this->baseForm($email['name'], $email['params'], get_class($service), $email['template']), $email['desc'], $email['variables']]; } } $this->template->services = $this->components; }