add school year model
This commit is contained in:
@@ -12,14 +12,18 @@ class AdministratorSharedService
|
||||
) {
|
||||
}
|
||||
|
||||
public function getSemester(): string
|
||||
public function getSemester(?string $override = null): string
|
||||
{
|
||||
return (string) ($this->configuration->getConfig('semester') ?? '');
|
||||
$value = trim((string) $override);
|
||||
|
||||
return $value !== '' ? $value : (string) ($this->configuration->getConfig('semester') ?? '');
|
||||
}
|
||||
|
||||
public function getSchoolYear(): string
|
||||
public function getSchoolYear(?string $override = null): string
|
||||
{
|
||||
return (string) ($this->configuration->getConfig('school_year') ?? '');
|
||||
$value = trim((string) $override);
|
||||
|
||||
return $value !== '' ? $value : (string) ($this->configuration->getConfig('school_year') ?? '');
|
||||
}
|
||||
|
||||
public function getPreviousSchoolYear(string $schoolYear): string
|
||||
@@ -146,4 +150,4 @@ class AdministratorSharedService
|
||||
|
||||
return count(array_unique($ids));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user