Commit 67dd874e by Carsten Brandt

renamed console controller optoins param $id to $actionId

parent 21bc2956
...@@ -115,9 +115,9 @@ class PhpDocController extends Controller ...@@ -115,9 +115,9 @@ class PhpDocController extends Controller
/** /**
* @inheritdoc * @inheritdoc
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), ['updateFiles']); return array_merge(parent::options($actionId), ['updateFiles']);
} }
protected function updateClassPropertyDocs($file, $className, $propertyDoc) protected function updateClassPropertyDocs($file, $className, $propertyDoc)
......
...@@ -159,8 +159,8 @@ class ApiController extends BaseController ...@@ -159,8 +159,8 @@ class ApiController extends BaseController
/** /**
* @inheritdoc * @inheritdoc
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), ['template', 'guide']); return array_merge(parent::options($actionId), ['template', 'guide']);
} }
} }
...@@ -114,8 +114,8 @@ class GuideController extends BaseController ...@@ -114,8 +114,8 @@ class GuideController extends BaseController
/** /**
* @inheritdoc * @inheritdoc
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), ['apiDocs']); return array_merge(parent::options($actionId), ['apiDocs']);
} }
} }
...@@ -126,8 +126,8 @@ abstract class BaseController extends Controller ...@@ -126,8 +126,8 @@ abstract class BaseController extends Controller
/** /**
* @inheritdoc * @inheritdoc
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), ['template', 'exclude']); return array_merge(parent::options($actionId), ['template', 'exclude']);
} }
} }
...@@ -171,12 +171,11 @@ class FixtureController extends \yii\console\controllers\FixtureController ...@@ -171,12 +171,11 @@ class FixtureController extends \yii\console\controllers\FixtureController
/** /**
* Returns the names of the global options for this command. * @inheritdoc
* @return array the names of the global options for this command.
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), [ return array_merge(parent::options($actionId), [
'templatePath', 'language', 'fixtureDataPath' 'templatePath', 'language', 'fixtureDataPath'
]); ]);
} }
......
...@@ -141,7 +141,6 @@ class View extends Component ...@@ -141,7 +141,6 @@ class View extends Component
public function render($view, $params = [], $context = null) public function render($view, $params = [], $context = null)
{ {
$viewFile = $this->findViewFile($view, $context); $viewFile = $this->findViewFile($view, $context);
return $this->renderFile($viewFile, $params, $context); return $this->renderFile($viewFile, $params, $context);
} }
......
...@@ -78,6 +78,7 @@ class MemCache extends Cache ...@@ -78,6 +78,7 @@ class MemCache extends Cache
*/ */
private $_servers = []; private $_servers = [];
/** /**
* Initializes this application component. * Initializes this application component.
* It creates the memcache instance and adds memcache servers. * It creates the memcache instance and adds memcache servers.
......
...@@ -264,10 +264,10 @@ class Controller extends \yii\base\Controller ...@@ -264,10 +264,10 @@ class Controller extends \yii\base\Controller
* Note that the values setting via options are not available * Note that the values setting via options are not available
* until [[beforeAction()]] is being called. * until [[beforeAction()]] is being called.
* *
* @param string $id action name * @param string $actionId the action id of the current request
* @return array the names of the options valid for the action * @return array the names of the options valid for the action
*/ */
public function options($id) public function options($actionId)
{ {
// $id might be used in subclass to provide options specific to action id // $id might be used in subclass to provide options specific to action id
return ['color', 'interactive']; return ['color', 'interactive'];
......
...@@ -33,7 +33,6 @@ use yii\test\FixtureTrait; ...@@ -33,7 +33,6 @@ use yii\test\FixtureTrait;
*/ */
class FixtureController extends Controller class FixtureController extends Controller
{ {
use FixtureTrait; use FixtureTrait;
/** /**
...@@ -57,13 +56,13 @@ class FixtureController extends Controller ...@@ -57,13 +56,13 @@ class FixtureController extends Controller
'yii\test\InitDb', 'yii\test\InitDb',
]; ];
/** /**
* Returns the names of the global options for this command. * @inheritdoc
* @return array the names of the global options for this command.
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), [ return array_merge(parent::options($actionId), [
'namespace', 'globalFixtures' 'namespace', 'globalFixtures'
]); ]);
} }
......
...@@ -92,14 +92,13 @@ class MigrateController extends Controller ...@@ -92,14 +92,13 @@ class MigrateController extends Controller
public $db = 'db'; public $db = 'db';
/** /**
* Returns the names of the global options for this command. * @inheritdoc
* @return array the names of the global options for this command.
*/ */
public function options($id) public function options($actionId)
{ {
return array_merge(parent::options($id), return array_merge(parent::options($actionId),
['migrationPath', 'migrationTable', 'db'], // global for all actions ['migrationPath', 'migrationTable', 'db'], // global for all actions
($id == 'create') ? ['templateFile'] : [] // action create ($actionId == 'create') ? ['templateFile'] : [] // action create
); );
} }
......
...@@ -342,7 +342,7 @@ class BaseHtml ...@@ -342,7 +342,7 @@ class BaseHtml
/** /**
* Generates an image tag. * Generates an image tag.
* @param string $src the image URL. This parameter will be processed by [[yii\helpers\Url::to()]]. * @param array|string $src the image URL. This parameter will be processed by [[yii\helpers\Url::to()]].
* @param array $options the tag options in terms of name-value pairs. These will be rendered as * @param array $options the tag options in terms of name-value pairs. These will be rendered as
* the attributes of the resulting tag. The values will be HTML-encoded using [[encode()]]. * the attributes of the resulting tag. The values will be HTML-encoded using [[encode()]].
* If a value is null, the corresponding attribute will not be rendered. * If a value is null, the corresponding attribute will not be rendered.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment