Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
LandingInstaller.php
Go to the documentation of this file.
1 <?php
7 
8 use Zend\Mvc\Controller\AbstractActionController;
9 use Zend\View\Model\ViewModel;
10 
14 class LandingInstaller extends AbstractActionController
15 {
19  protected $productMetadata;
20 
24  public function __construct(\Magento\Framework\App\ProductMetadata $productMetadata)
25  {
26  $this->productMetadata = $productMetadata;
27  }
28 
32  public function indexAction()
33  {
34  $welcomeMsg = "Welcome to Magento Admin, your online store headquarters.<br>"
35  . "Click 'Agree and Set Up Magento' or read ";
36  $docRef = "http://devdocs.magento.com/guides/v1.0/install-gde/install/install-web.html";
37  $agreeButtonText = "Agree and Setup Magento";
38  $view = new ViewModel;
39  $view->setTerminal(true);
40  $view->setTemplate('/magento/setup/landing.phtml');
41  $view->setVariable('version', $this->productMetadata->getVersion());
42  $view->setVariable('welcomeMsg', $welcomeMsg);
43  $view->setVariable('docRef', $docRef);
44  $view->setVariable('agreeButtonText', $agreeButtonText);
45  return $view;
46  }
47 }
__construct(\Magento\Framework\App\ProductMetadata $productMetadata)