BxFilesFormsEntryHelper.php 955 B

123456789101112131415161718192021222324252627282930313233343536
  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 Files Files
  7. * @ingroup UnaModules
  8. *
  9. * @{
  10. */
  11. /**
  12. * Entry forms helper functions
  13. */
  14. class BxFilesFormsEntryHelper extends BxBaseModFilesFormsEntryHelper
  15. {
  16. public function __construct($oModule)
  17. {
  18. $this->_sDisplayForFormAdd ='bx_files_entry_upload';
  19. $this->_sObjectNameForFormAdd ='bx_files_upload';
  20. parent::__construct($oModule);
  21. }
  22. protected function redirectAfterDelete($aContentInfo, $sUrl = '')
  23. {
  24. $CNF = &$this->_oModule->_oConfig->CNF;
  25. if (($oProfile = BxDolProfile::getInstance($aContentInfo[$CNF['FIELD_AUTHOR']])) !== false)
  26. $sUrl = 'page.php?i=' . $CNF['URI_AUTHOR_ENTRIES'] . '&profile_id=' . $oProfile->id();
  27. return parent::redirectAfterDelete($aContentInfo, $sUrl);
  28. }
  29. }
  30. /** @} */