Browse Source

changed to trace from info.

tags/2.0.0-beta
Qiang Xue 11 years ago
parent
commit
d1c41fe144
  1. 2
      framework/yii/base/Action.php
  2. 2
      framework/yii/base/InlineAction.php
  3. 2
      framework/yii/base/Model.php
  4. 2
      framework/yii/base/View.php
  5. 5
      framework/yii/db/Command.php
  6. 2
      framework/yii/debug/panels/LogPanel.php
  7. 1
      framework/yii/web/AssetBundle.php
  8. 2
      framework/yii/web/AssetConverter.php
  9. 6
      framework/yii/web/UrlManager.php

2
framework/yii/base/Action.php

@ -77,7 +77,7 @@ class Action extends Component
throw new InvalidConfigException(get_class($this) . ' must define a "run()" method.');
}
$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) {
Yii::$app->requestedParams = $args;
}

2
framework/yii/base/InlineAction.php

@ -46,7 +46,7 @@ class InlineAction extends Action
public function runWithParams($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) {
Yii::$app->requestedParams = $args;
}

2
framework/yii/base/Model.php

@ -571,7 +571,7 @@ class Model extends Component implements IteratorAggregate, ArrayAccess
public function onUnsafeAttribute($name, $value)
{
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__);
}
}

2
framework/yii/base/View.php

@ -269,7 +269,7 @@ class View extends Component
$renderer = $this->renderers[$ext];
$output = $renderer->render($this, $viewFile, $params);
} else {
Yii::info("Rendering view file: $viewFile", __METHOD__);
Yii::trace("Rendering view file: $viewFile", __METHOD__);
$output = $this->renderPhpFile($viewFile, $params);
}
$this->afterRender($viewFile, $output);

5
framework/yii/db/Command.php

@ -275,7 +275,7 @@ class Command extends \yii\base\Component
$rawSql = $this->getRawSql();
Yii::info($rawSql, __METHOD__);
Yii::trace($rawSql, __METHOD__);
if ($sql == '') {
return 0;
@ -377,10 +377,9 @@ class Command extends \yii\base\Component
private function queryInternal($method, $fetchMode = null)
{
$db = $this->db;
$sql = $this->getSql();
$rawSql = $this->getRawSql();
Yii::info($rawSql, __METHOD__);
Yii::trace($rawSql, __METHOD__);
/** @var $cache \yii\caching\Cache */
if ($db->enableQueryCache && $method !== '') {

2
framework/yii/debug/panels/LogPanel.php

@ -74,7 +74,7 @@ EOD;
$class = '';
}
$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);
return <<<EOD

1
framework/yii/web/AssetBundle.php

@ -113,6 +113,7 @@ class AssetBundle extends Object
/**
* Initializes the bundle.
* If you override this method, make sure you call the parent implementation in the last.
*/
public function init()
{

2
framework/yii/web/AssetConverter.php

@ -51,7 +51,7 @@ class AssetConverter extends Component implements IAssetConverter
'{to}' => escapeshellarg("$basePath/$result"),
));
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;
}

6
framework/yii/web/UrlManager.php

@ -172,7 +172,7 @@ class UrlManager extends Component
/** @var $rule UrlRule */
foreach ($this->rules as $rule) {
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;
}
}
@ -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());
} else {
$route = $request->get($this->routeVar);
if (is_array($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());
}
}

Loading…
Cancel
Save