|
|
@ -586,7 +586,8 @@ abstract class Module extends Component |
|
|
|
Yii::$app->controller = $oldController; |
|
|
|
Yii::$app->controller = $oldController; |
|
|
|
return $result; |
|
|
|
return $result; |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
throw new InvalidRouteException('Unable to resolve the request "' . trim($this->getUniqueId() . '/' . $route, '/') . '".'); |
|
|
|
$id = $this->getUniqueId(); |
|
|
|
|
|
|
|
throw new InvalidRouteException('Unable to resolve the request "' . ($id === '' ? $route : $id . '/' . $route) . '".'); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -608,9 +609,8 @@ abstract class Module extends Component |
|
|
|
if ($route === '') { |
|
|
|
if ($route === '') { |
|
|
|
$route = $this->defaultRoute; |
|
|
|
$route = $this->defaultRoute; |
|
|
|
} |
|
|
|
} |
|
|
|
if (($pos = strpos($route, '/')) !== false) { |
|
|
|
if (strpos($route, '/') !== false) { |
|
|
|
$id = substr($route, 0, $pos); |
|
|
|
list ($id, $route) = explode('/', $route, 2); |
|
|
|
$route = substr($route, $pos + 1); |
|
|
|
|
|
|
|
} else { |
|
|
|
} else { |
|
|
|
$id = $route; |
|
|
|
$id = $route; |
|
|
|
$route = ''; |
|
|
|
$route = ''; |
|
|
|