mirror of
https://github.com/yiisoft/yii2.git
synced 2025-08-14 14:28:27 +08:00
docs/guide/structure-modules.md small fix (#15974) [skip ci]
This commit is contained in:

committed by
Alexander Makarov

parent
c57637bf65
commit
a544457488
@ -176,12 +176,12 @@ only contains the module ID, then the [[yii\base\Module::defaultRoute]] property
|
||||
will determine which controller/action should be used. This means a route `forum` would represent the `default`
|
||||
controller in the `forum` module.
|
||||
|
||||
URL manager routes should be added before [[yii\web\UrlManager::parseRequest()]] is fired. That means doing it
|
||||
in module's `init()` won't work because module will be initialized when routes were already processed. Thus, routes
|
||||
The URL manager rules for the modules should be added before [[yii\web\UrlManager::parseRequest()]] is fired. That means doing it
|
||||
in module's `init()` won't work because module will be initialized when routes were already processed. Thus, the rules
|
||||
should be added at [bootstrap stage](structure-extensions.md#bootstrapping-classes). It is a also a good practice
|
||||
to wrap module's URL rules with [[\yii\web\GroupUrlRule]].
|
||||
|
||||
In case module is used to [version API](rest-versioning.md), routes should be added directly in `urlManager`
|
||||
In case a module is used to [version API](rest-versioning.md), its URL rules should be added directly in `urlManager`
|
||||
section of the application config.
|
||||
|
||||
|
||||
|
@ -308,9 +308,9 @@ Same command options like: `namespace`, `globalFixtures` also can be applied to
|
||||
|
||||
### Configure Command Globally
|
||||
|
||||
While command line options allow us to configure the migration command
|
||||
While command line options allow us to configure the fixture command
|
||||
on-the-fly, sometimes we may want to configure the command once for all. For example you can configure
|
||||
different migration path as follows:
|
||||
different fixture path as follows:
|
||||
|
||||
```
|
||||
'controllerMap' => [
|
||||
|
Reference in New Issue
Block a user