Commit d1c41fe1 by Qiang Xue

changed to trace from info.

parent 9193e477
...@@ -77,7 +77,7 @@ class Action extends Component ...@@ -77,7 +77,7 @@ class Action extends Component
throw new InvalidConfigException(get_class($this) . ' must define a "run()" method.'); throw new InvalidConfigException(get_class($this) . ' must define a "run()" method.');
} }
$args = $this->controller->bindActionParams($this, $params); $args = $this->controller->bindActionParams($this, $params);
Yii::info('Running action: ' . get_class($this) . '::run()', __METHOD__); Yii::trace('Running action: ' . get_class($this) . '::run()', __METHOD__);
if (Yii::$app->requestedParams === null) { if (Yii::$app->requestedParams === null) {
Yii::$app->requestedParams = $args; Yii::$app->requestedParams = $args;
} }
......
...@@ -46,7 +46,7 @@ class InlineAction extends Action ...@@ -46,7 +46,7 @@ class InlineAction extends Action
public function runWithParams($params) public function runWithParams($params)
{ {
$args = $this->controller->bindActionParams($this, $params); $args = $this->controller->bindActionParams($this, $params);
Yii::info('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__); Yii::trace('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__);
if (Yii::$app->requestedParams === null) { if (Yii::$app->requestedParams === null) {
Yii::$app->requestedParams = $args; Yii::$app->requestedParams = $args;
} }
......
...@@ -571,7 +571,7 @@ class Model extends Component implements IteratorAggregate, ArrayAccess ...@@ -571,7 +571,7 @@ class Model extends Component implements IteratorAggregate, ArrayAccess
public function onUnsafeAttribute($name, $value) public function onUnsafeAttribute($name, $value)
{ {
if (YII_DEBUG) { if (YII_DEBUG) {
\Yii::info("Failed to set unsafe attribute '$name' in '" . get_class($this) . "'.", __METHOD__); Yii::trace("Failed to set unsafe attribute '$name' in '" . get_class($this) . "'.", __METHOD__);
} }
} }
......
...@@ -269,7 +269,7 @@ class View extends Component ...@@ -269,7 +269,7 @@ class View extends Component
$renderer = $this->renderers[$ext]; $renderer = $this->renderers[$ext];
$output = $renderer->render($this, $viewFile, $params); $output = $renderer->render($this, $viewFile, $params);
} else { } else {
Yii::info("Rendering view file: $viewFile", __METHOD__); Yii::trace("Rendering view file: $viewFile", __METHOD__);
$output = $this->renderPhpFile($viewFile, $params); $output = $this->renderPhpFile($viewFile, $params);
} }
$this->afterRender($viewFile, $output); $this->afterRender($viewFile, $output);
......
...@@ -275,7 +275,7 @@ class Command extends \yii\base\Component ...@@ -275,7 +275,7 @@ class Command extends \yii\base\Component
$rawSql = $this->getRawSql(); $rawSql = $this->getRawSql();
Yii::info($rawSql, __METHOD__); Yii::trace($rawSql, __METHOD__);
if ($sql == '') { if ($sql == '') {
return 0; return 0;
...@@ -377,10 +377,9 @@ class Command extends \yii\base\Component ...@@ -377,10 +377,9 @@ class Command extends \yii\base\Component
private function queryInternal($method, $fetchMode = null) private function queryInternal($method, $fetchMode = null)
{ {
$db = $this->db; $db = $this->db;
$sql = $this->getSql();
$rawSql = $this->getRawSql(); $rawSql = $this->getRawSql();
Yii::info($rawSql, __METHOD__); Yii::trace($rawSql, __METHOD__);
/** @var $cache \yii\caching\Cache */ /** @var $cache \yii\caching\Cache */
if ($db->enableQueryCache && $method !== '') { if ($db->enableQueryCache && $method !== '') {
......
...@@ -74,7 +74,7 @@ EOD; ...@@ -74,7 +74,7 @@ EOD;
$class = ''; $class = '';
} }
$level = Logger::getLevelName($level); $level = Logger::getLevelName($level);
$rows[] = "<tr$class><td style=\"width: 100px;\">$time</td><td style=\"width: 100px;\">$level</td><td style=\"width: 250px;\">$category</td><td>$message</td></tr>"; $rows[] = "<tr$class><td style=\"width: 100px;\">$time</td><td style=\"width: 100px;\">$level</td><td style=\"width: 250px;\">$category</td><td><div style=\"overflow:auto\">$message</div></td></tr>";
} }
$rows = implode("\n", $rows); $rows = implode("\n", $rows);
return <<<EOD return <<<EOD
......
...@@ -113,6 +113,7 @@ class AssetBundle extends Object ...@@ -113,6 +113,7 @@ class AssetBundle extends Object
/** /**
* Initializes the bundle. * Initializes the bundle.
* If you override this method, make sure you call the parent implementation in the last.
*/ */
public function init() public function init()
{ {
......
...@@ -51,7 +51,7 @@ class AssetConverter extends Component implements IAssetConverter ...@@ -51,7 +51,7 @@ class AssetConverter extends Component implements IAssetConverter
'{to}' => escapeshellarg("$basePath/$result"), '{to}' => escapeshellarg("$basePath/$result"),
)); ));
exec($command, $output); exec($command, $output);
Yii::info("Converted $asset into $result: " . implode("\n", $output), __METHOD__); Yii::trace("Converted $asset into $result: " . implode("\n", $output), __METHOD__);
} }
return $result; return $result;
} }
......
...@@ -172,7 +172,7 @@ class UrlManager extends Component ...@@ -172,7 +172,7 @@ class UrlManager extends Component
/** @var $rule UrlRule */ /** @var $rule UrlRule */
foreach ($this->rules as $rule) { foreach ($this->rules as $rule) {
if (($result = $rule->parseRequest($this, $request)) !== false) { if (($result = $rule->parseRequest($this, $request)) !== false) {
Yii::info("Request parsed with URL rule: {$rule->name}", __METHOD__); Yii::trace("Request parsed with URL rule: {$rule->name}", __METHOD__);
return $result; return $result;
} }
} }
...@@ -196,14 +196,14 @@ class UrlManager extends Component ...@@ -196,14 +196,14 @@ class UrlManager extends Component
} }
} }
Yii::info('No matching URL rules. Using default URL parsing logic.', __METHOD__); Yii::trace('No matching URL rules. Using default URL parsing logic.', __METHOD__);
return array($pathInfo, array()); return array($pathInfo, array());
} else { } else {
$route = $request->get($this->routeVar); $route = $request->get($this->routeVar);
if (is_array($route)) { if (is_array($route)) {
$route = ''; $route = '';
} }
Yii::info('Pretty URL not enabled. Using default URL parsing logic.', __METHOD__); Yii::trace('Pretty URL not enabled. Using default URL parsing logic.', __METHOD__);
return array((string)$route, array()); return array((string)$route, array());
} }
} }
......
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