improve handel requests

This commit is contained in:
2025-07-19 20:43:09 +03:30
parent 3102ebf567
commit 23854e1d98
8 changed files with 267 additions and 197 deletions
+8 -1
View File
@@ -24,7 +24,14 @@ abstract class BaseFormRequest
];
}
public function getRoutePath(): string
public function isRequestForThisRoute(): bool
{
return trim($this->getCurrentRoutePath(), '/') === $this->getRequestRoutePath();
}
abstract public function getRequestRoutePath(): string;
public function getCurrentRoutePath(): string
{
return $this->url['path'];
}