mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-12-16 07:59:30 +00:00
Use new settings system to configure the instance Name and homepage banner
This commit is contained in:
parent
26d83af298
commit
0772d85918
23 changed files with 299 additions and 230 deletions
|
|
@ -7,6 +7,7 @@ use ApiPlatform\State\ProviderInterface;
|
|||
use App\ApiResource\PartDBInfo;
|
||||
use App\Services\Misc\GitVersionInfo;
|
||||
use App\Services\System\BannerHelper;
|
||||
use App\Settings\SystemSettings\CustomizationSettings;
|
||||
use Shivas\VersioningBundle\Service\VersionManagerInterface;
|
||||
|
||||
class PartDBInfoProvider implements ProviderInterface
|
||||
|
|
@ -14,12 +15,12 @@ class PartDBInfoProvider implements ProviderInterface
|
|||
|
||||
public function __construct(private readonly VersionManagerInterface $versionManager,
|
||||
private readonly GitVersionInfo $gitVersionInfo,
|
||||
private readonly string $partdb_title,
|
||||
private readonly string $base_currency,
|
||||
private readonly BannerHelper $bannerHelper,
|
||||
private readonly string $default_uri,
|
||||
private readonly string $global_timezone,
|
||||
private readonly string $global_locale
|
||||
private readonly string $global_locale,
|
||||
private readonly CustomizationSettings $customizationSettings,
|
||||
)
|
||||
{
|
||||
|
||||
|
|
@ -31,7 +32,7 @@ class PartDBInfoProvider implements ProviderInterface
|
|||
version: $this->versionManager->getVersion()->toString(),
|
||||
git_branch: $this->gitVersionInfo->getGitBranchName(),
|
||||
git_commit: $this->gitVersionInfo->getGitCommitHash(),
|
||||
title: $this->partdb_title,
|
||||
title: $this->customizationSettings->instanceName,
|
||||
banner: $this->bannerHelper->getBanner(),
|
||||
default_uri: $this->default_uri,
|
||||
global_timezone: $this->global_timezone,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue