Ejemplo n.º 1
0
Archivo: core.php Proyecto: umaxfun/x4m
 public static function getModuleList($get_actionable_only = false)
 {
     global $_PATH;
     static $moduleList;
     if (is_array($moduleList) && !$get_actionable_only) {
         return $moduleList;
     }
     if ($get_actionable_only) {
         $where = ' actionable=1 order by id ASC';
     } else {
         $where = '1 order by id ASC';
     }
     if ($moduleList = xPDO::selectIN('*', 'modules', $where)) {
         $l = Common::getModuleLang('admin', $_SESSION['lang'], 'modules');
         foreach ($moduleList as $k => $module) {
             $moduleList[$k]['alias'] = $l[$module['name']];
             if (!file_exists(xConfig::get('PATH', 'MODULES') . $module['name'] . '/js/' . $module['name'] . '.js')) {
                 unset($moduleList[$module['name']]);
             }
         }
     }
     return $moduleList;
 }
Ejemplo n.º 2
0
 function getRewrites()
 {
     return xPDO::selectIN('*', 'routes');
 }