StatsSettingsRepository.php 582 B

12345678910111213141516171819202122232425
  1. <?php
  2. namespace Opentalent\OtStats\Settings;
  3. use TYPO3\CMS\Frontend\Page\PageRepository;
  4. /**
  5. * Class StatsRepository
  6. *
  7. * Give access to the website's settings for the stats module
  8. *
  9. * @package Opentalent\OtTemplating\Page
  10. */
  11. class StatsSettingsRepository extends PageRepository
  12. {
  13. /**
  14. * Returns the website registered matomo site's id
  15. * @param int $rootPageUid
  16. * @return int|null
  17. */
  18. public function getMatomoSiteId(int $rootPageUid) {
  19. $rootPage = $this->getPage($rootPageUid);
  20. return $rootPage['tx_opentalent_matomo_id'];
  21. }
  22. }