Пример #1
0
 /**
  * {@inheritdoc}
  */
 public function slash()
 {
     foreach (di()->getServices() as $service) {
         if (!method_exists($def = $service->getDefinition(), 'afterModuleRun')) {
             continue;
         }
         $def->afterModuleRun();
     }
     $table = $this->table(['Method', 'Path', 'Controller', 'Action', 'Assigned Name'], $this->extractRoutes(Route::getRoutes()));
     $table->render();
 }
Пример #2
0
 /**
  * {@inheritdoc}
  */
 public function slash()
 {
     # load non-loaded routes based for each module
     foreach (di('module')->all() as $module_name => $module) {
         $path = Kernel::buildRoute($module_name);
         if (file_exists($path)) {
             require_once $path;
         }
     }
     $table = $this->table(['Method', 'Path', 'Controller', 'Action', 'Assigned Name'], $this->extractRoutes(Route::getRoutes()));
     $table->render();
 }
Пример #3
0
<?php

use Clarity\Facades\Route;
Route::add('/acme/test', ['module' => 'acme', 'controller' => 'Acme', 'action' => 'test']);