BxForumStudioPage.php 1018 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php defined('BX_DOL') or die('hack attempt');
  2. /**
  3. * Copyright (c) UNA, Inc - https://una.io
  4. * MIT License - https://opensource.org/licenses/MIT
  5. *
  6. * @defgroup Forum Forum
  7. * @ingroup UnaModules
  8. *
  9. * @{
  10. */
  11. define('BX_DOL_STUDIO_MOD_TYPE_CATEGORIES', 'categories');
  12. class BxForumStudioPage extends BxTemplStudioModule
  13. {
  14. protected $_sModule;
  15. protected $_oModule;
  16. function __construct($sModule = "", $sPage = "")
  17. {
  18. $this->_sModule = 'bx_forum';
  19. $this->_oModule = BxDolModule::getInstance($this->_sModule);
  20. parent::__construct($sModule, $sPage);
  21. $this->aMenuItems[] = array('name' => BX_DOL_STUDIO_MOD_TYPE_CATEGORIES, 'icon' => 'bars', 'title' => '_bx_forum_lmi_cpt_categories');
  22. }
  23. protected function getCategories()
  24. {
  25. $oGrid = BxDolGrid::getObjectInstance($this->_oModule->_oConfig->CNF['OBJECT_GRID_CATEGORIES'], BxDolStudioTemplate::getInstance());
  26. if(!$oGrid)
  27. return '';
  28. return $oGrid->getCode();
  29. }
  30. }
  31. /** @} */