コード例 #1
0
ファイル: ToolsController.php プロジェクト: ajaboa/crmpuan
 public function actionStore($params)
 {
     $columnModel = new GO\Base\Data\ColumnModel(false, array(), array('name', 'script'));
     $store = new GO\Base\Data\ArrayStore($columnModel);
     $store->addRecord(array('name' => GO::t('systemCheck', 'tools'), 'script' => GO::url('tools/tools/systemTest')));
     $store->addRecord(array('name' => GO::t('dbcheck', 'tools'), 'script' => GO::url('maintenance/checkDatabase')));
     $store->addRecord(array('name' => GO::t('buildsearchcache', 'tools'), 'script' => GO::url('maintenance/buildSearchCache')));
     $store->addRecord(array('name' => GO::t('rm_duplicates', 'tools'), 'script' => GO::url('maintenance/removeDuplicates')));
     if (GO::modules()->files) {
         $store->addRecord(array('name' => 'Sync filesystem with files database', 'script' => GO::url('files/folder/syncFilesystem')));
     }
     if (GO::modules()->filesearch) {
         $store->addRecord(array('name' => 'Update filesearch index', 'script' => GO::url('filesearch/filesearch/sync')));
     }
     echo $this->renderStore($store);
 }
コード例 #2
0
ファイル: CoreController.php プロジェクト: ajaboa/crmpuan
 protected function actionModules($params)
 {
     $store = new \GO\Base\Data\ArrayStore();
     $modules = GO::modules()->getAllModules(true);
     foreach ($modules as $module) {
         $store->addRecord(array('id' => $module->id, 'name' => $module->moduleManager->name()));
     }
     return $store->getData();
 }