同步更新

This commit is contained in:
2026-01-13 17:27:32 +08:00
parent 45785dd33f
commit 5d6e2fc5e0
38 changed files with 1211 additions and 305 deletions

View File

@@ -218,7 +218,7 @@ class Url
$controller = empty($path) ? $controller : array_pop($path);
$url = $controller . '/' . $action;
$auto = $this->route->getName('__think_auto_route__');
if (!empty($auto) && !strpos($controller,'.')) {
if (!empty($auto) && !strpos($controller, '.')) {
$module = empty($path) ? $request->layer() : array_pop($path);
$url = $module . '/' . $url;
}
@@ -368,7 +368,7 @@ class Url
}
if ($url) {
$checkName = isset($name) ? $name : $url . (isset($info['query']) ? '?' . $info['query'] : '');
$checkName = $name ?? $url . (isset($info['query']) ? '?' . $info['query'] : '');
$checkDomain = $domain && is_string($domain) ? $domain : null;
$rule = $this->route->getName($checkName, $checkDomain);