Exemplo n.º 1
0
 /**
  * Apply database data updates whenever needed
  *
  * @return void
  */
 public function updateData()
 {
     foreach ($this->_moduleList->getNames() as $moduleName) {
         foreach ($this->_resourceResolver->getResourceList($moduleName) as $resourceName) {
             if (!$this->_dbVersionInfo->isDataUpToDate($moduleName, $resourceName)) {
                 $this->_setupFactory->create($resourceName, $moduleName)->applyDataUpdates();
             }
         }
     }
 }
Exemplo n.º 2
0
 /**
  * Whether a module is enabled in the configuration or not
  *
  * @param string $moduleName Fully-qualified module name
  * @return boolean
  */
 public function isEnabled($moduleName)
 {
     return $this->_moduleList->has($moduleName);
 }
Exemplo n.º 3
0
 /**
  * Whether a module is enabled in the configuration or not
  *
  * @param string $moduleName Fully-qualified module name
  * @return boolean
  */
 public function isEnabled($moduleName)
 {
     return !!$this->_moduleList->getModule($moduleName);
 }