Add ModelReflection Service as dependency injection + tests

This commit is contained in:
Eric Espie
2025-11-19 14:42:32 +01:00
parent 6678689b77
commit 65bd6d9fd0
18 changed files with 285 additions and 44 deletions

View File

@@ -169,10 +169,7 @@ abstract class Controller extends AbstractController
$this->SetViewPath($sViewPath, $aAdditionalPaths);
if ($sModuleName != 'core') {
try {
$this->aDefaultParams = [
'sIndexURL' => utils::GetAbsoluteUrlModulePage($this->m_sModule, 'index.php'),
'sAPPROOTURL' => utils::GetAbsoluteUrlAppRoot(),
];
$this->aDefaultParams = ['sIndexURL' => utils::GetAbsoluteUrlModulePage($this->m_sModule, 'index.php')];
} catch (Exception $e) {
IssueLog::Error($e->getMessage());
}
@@ -200,10 +197,7 @@ abstract class Controller extends AbstractController
$this->SetModuleName(basename($sModulePath));
$this->SetViewPath($sModulePath.'/view');
try {
$this->aDefaultParams = [
'sIndexURL' => utils::GetAbsoluteUrlModulePage($this->m_sModule, 'index.php'),
'sAPPROOTURL' => utils::GetAbsoluteUrlAppRoot(),
];
$this->aDefaultParams = ['sIndexURL' => utils::GetAbsoluteUrlModulePage($this->m_sModule, 'index.php')];
} catch (Exception $e) {
IssueLog::Error($e->getMessage());
}