Changeset 11064
- Timestamp:
- Jun 26, 2009, 10:17:58 AM (16 years ago)
- Location:
- trunk/modules/boonex/events
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/modules/boonex/events/classes/BxEventsModule.php ¶
r11053 r11064 310 310 ); 311 311 312 if (!($aForum = $this->_oDb->getForumById ($iForumId))) 312 if (!($aForum = $this->_oDb->getForumById ($iForumId))) { 313 313 return $aFalse; 314 315 if (!($aDataEntry = $this->_oDb->getEntryByIdAndOwner ($aForum['event_id'], 0, true))) 314 } 315 316 if (!($aDataEntry = $this->_oDb->getEntryByIdAndOwner ($aForum['entry_id'], 0, true))) { 316 317 return $aFalse; 318 } 317 319 318 320 $aTrue = array ( … … 321 323 'post' => $this->isAllowedPostInForum ($aDataEntry, $iMemberId) ? 1 : 0, 322 324 ); 323 324 325 return $aTrue; 325 326 } -
TabularUnified trunk/modules/boonex/events/classes/BxEventsPageMy.php ¶
r11045 r11064 116 116 117 117 function getBlockCode_Manage() { 118 $sForm = $this->_oMain->_manageE vents ('user', $this->_aProfile['NickName'], false, 'bx_events_my_active', array(118 $sForm = $this->_oMain->_manageEntries ('user', $this->_aProfile['NickName'], false, 'bx_events_my_active', array( 119 119 'action_delete' => '_bx_events_admin_delete', 120 120 ), 'bx_events_my_active', 7); … … 124 124 125 125 function getBlockCode_Pending() { 126 $sForm = $this->_oMain->_manageE vents ('my_pending', '', false, 'bx_events_my_pending', array(126 $sForm = $this->_oMain->_manageEntries ('my_pending', '', false, 'bx_events_my_pending', array( 127 127 'action_delete' => '_bx_events_admin_delete', 128 128 ), 'bx_events_my_pending', 7); -
TabularUnified trunk/modules/boonex/events/classes/BxEventsPageView.php ¶
r11053 r11064 24 24 class BxEventsPageView extends BxDolTwigPageView { 25 25 26 var $oEventsMain;27 var $_oDb;28 var $aDataEntry;29 30 26 function BxEventsPageView(&$oEventsMain, &$aEvent) { 31 parent::BxDolTwigPageView('bx_events_view', $oEventsMain->_oTemplate); 32 $this->oEventsMain = &$oEventsMain; 33 $this->_oDb = $oEventsMain->_oDb; 34 $this->aDataEntry = &$aEvent; 27 parent::BxDolTwigPageView('bx_events_view', $oEventsMain, $aEvent); 35 28 } 36 29 … … 64 57 $o = new BxEventsVoting ('bx_events', (int)$this->aDataEntry['ID']); 65 58 if (!$o->isEnabled()) return ''; 66 return $o->getBigVoting ($this-> oEventsMain->isAllowedRate($this->aDataEntry));59 return $o->getBigVoting ($this->_oMain->isAllowedRate($this->aDataEntry)); 67 60 } 68 61 … … 78 71 global $oFunctions; 79 72 80 if ($this-> oEventsMain->_iProfileId || $this->oEventsMain->isAdmin()) {73 if ($this->_oMain->_iProfileId || $this->_oMain->isAdmin()) { 81 74 82 $this->aInfo['BaseUri'] = $this-> oEventsMain->_oConfig->getBaseUri();83 $this->aInfo['iViewer'] = $this-> oEventsMain->_iProfileId;75 $this->aInfo['BaseUri'] = $this->_oMain->_oConfig->getBaseUri(); 76 $this->aInfo['iViewer'] = $this->_oMain->_iProfileId; 84 77 $this->aInfo['ownerID'] = (int)$this->aDataEntry['ResponsibleID']; 85 78 $this->aInfo['ID'] = (int)$this->aDataEntry['ID']; 86 79 $this->aInfo['URI'] = (int)$this->aDataEntry['EntryUri']; 87 $this->aInfo['TitleEdit'] = $this-> oEventsMain->isAllowedEdit($this->aDataEntry) ? _t('_bx_events_action_title_edit') : '';88 $this->aInfo['TitleDelete'] = $this-> oEventsMain->isAllowedDelete($this->aDataEntry) ? _t('_bx_events_action_title_delete') : '';89 $this->aInfo['TitleJoin'] = $this-> oEventsMain->isAllowedJoin($this->aDataEntry) ? _t('_bx_events_action_title_join') : '';90 $this->aInfo['TitleInvite'] = $this-> oEventsMain->isAllowedSendInvitation($this->aDataEntry) ? _t('_bx_events_action_title_invite') : '';91 $this->aInfo['TitleShare'] = $this-> oEventsMain->isAllowedShareEvent($this->aDataEntry) ? _t('_bx_events_action_title_share') : '';92 $this->aInfo['TitleBroadcast'] = $this-> oEventsMain->isAllowedBroadcast($this->aDataEntry) ? _t('_bx_events_action_title_broadcast') : '';93 $this->aInfo['AddToFeatured'] = $this-> oEventsMain->isAllowedMarkAsFeatured($this->aDataEntry) ? ($this->aDataEntry['Featured'] ? _t('_bx_events_action_remove_from_featured') : _t('_bx_events_action_add_to_featured')) : '';80 $this->aInfo['TitleEdit'] = $this->_oMain->isAllowedEdit($this->aDataEntry) ? _t('_bx_events_action_title_edit') : ''; 81 $this->aInfo['TitleDelete'] = $this->_oMain->isAllowedDelete($this->aDataEntry) ? _t('_bx_events_action_title_delete') : ''; 82 $this->aInfo['TitleJoin'] = $this->_oMain->isAllowedJoin($this->aDataEntry) ? _t('_bx_events_action_title_join') : ''; 83 $this->aInfo['TitleInvite'] = $this->_oMain->isAllowedSendInvitation($this->aDataEntry) ? _t('_bx_events_action_title_invite') : ''; 84 $this->aInfo['TitleShare'] = $this->_oMain->isAllowedShareEvent($this->aDataEntry) ? _t('_bx_events_action_title_share') : ''; 85 $this->aInfo['TitleBroadcast'] = $this->_oMain->isAllowedBroadcast($this->aDataEntry) ? _t('_bx_events_action_title_broadcast') : ''; 86 $this->aInfo['AddToFeatured'] = $this->_oMain->isAllowedMarkAsFeatured($this->aDataEntry) ? ($this->aDataEntry['Featured'] ? _t('_bx_events_action_remove_from_featured') : _t('_bx_events_action_add_to_featured')) : ''; 94 87 95 88 if (!$this->aInfo['TitleEdit'] && !$this->aInfo['TitleDelete'] && !$this->aInfo['TitleJoin'] && !$this->aInfo['TitleInvite'] && !$this->aInfo['TitleShare'] && !$this->aInfo['AddToFeatured'] && !$this->aInfo['TitleBroadcast']) … … 104 97 function getBlockCode_Participants() { 105 98 106 if (!$this-> oEventsMain->isAllowedViewParticipants($this->aDataEntry)) return '';99 if (!$this->_oMain->isAllowedViewParticipants($this->aDataEntry)) return ''; 107 100 108 101 $iMaxNum = $this->_oDb->getParam('bx_events_perpage_participants'); … … 113 106 114 107 $aProfiles = array (); 115 $iNum = $this-> oEventsMain->_oDb->getParticipants($aProfiles, $this->aDataEntry['ID'], $iStart, $iMaxNum);108 $iNum = $this->_oMain->_oDb->getParticipants($aProfiles, $this->aDataEntry['ID'], $iStart, $iMaxNum); 116 109 if (!$iNum || !$aProfiles) 117 110 return MsgBox(_t("_Empty")); … … 128 121 $aDBBottomMenu = array(); 129 122 if ($iPages > 1) { 130 $sUrlStart = BX_DOL_URL_ROOT . $this-> oEventsMain->_oConfig->getBaseUri() . "view/".$this->aDataEntry['EntryUri'];123 $sUrlStart = BX_DOL_URL_ROOT . $this->_oMain->_oConfig->getBaseUri() . "view/".$this->aDataEntry['EntryUri']; 131 124 $sUrlStart .= (false === strpos($sUrlStart, '?') ? '?' : '&'); 132 125 if ($iPage > 1) -
TabularUnified trunk/modules/boonex/events/classes/BxEventsTemplate.php ¶
r10911 r11064 33 33 parent::BxDolTwigTemplate($oConfig); 34 34 $this->_iPageIndex = 300; 35 $aVars = array ('BaseUri' => $oConfig->getBaseUri()); 36 $GLOBALS['oTopMenu']->setCustomSubActions($aVars, 'bx_events_title', false); 35 37 } 36 38 -
TabularUnified trunk/modules/boonex/events/install/langs/en.php ¶
r11045 r11064 28 28 '_bx_events_action_remove_from_featured' => 'Remove From Featured', 29 29 '_bx_events_action_add_to_featured' => 'Add To Featured', 30 '_bx_events_action_create_event' => 'Create Event', 31 '_bx_events_action_my_events' => 'My Events', 30 32 '_bx_events_action_title_delete' => 'Delete', 31 33 '_bx_events_action_title_edit' => 'Edit', … … 33 35 '_bx_events_action_title_join' => 'Join', 34 36 '_bx_events_action_title_share' => 'Share', 35 '_bx_events_action_title_broadcast' => 'Broadcast', 37 '_bx_events_action_title_broadcast' => 'Broadcast', 36 38 '_bx_events_add_new_event_admin' => 'Create Event', 37 39 '_bx_events_user_unknown' => 'Unknown', -
TabularUnified trunk/modules/boonex/events/install/sql/install.sql ¶
r11053 r11064 252 252 ('bx_events_view', '960px', 'Event''s sounds block', '_bx_events_block_sounds', '2', '3', 'Sounds', '', '1', '71', 'non,memb', '0'), 253 253 ('bx_events_view', '960px', 'Event''s files block', '_bx_events_block_files', '2', '4', 'Files', '', '1', '71', 'non,memb', '0'), 254 ('bx_events_view', '960px', 'Event''s comments block', '_bx_events_block_comments', '2', '5', 'Comments', '', '1', '71', 'non,memb', '0'), 254 ('bx_events_view', '960px', 'Event''s comments block', '_bx_events_block_comments', '2', '5', 'Comments', '', '1', '71', 'non,memb', '0'), 255 255 256 256 ('bx_events_main', '960px', 'Upcoming Events Photo', '_bx_events_block_upcoming_photo', '2', '0', 'UpcomingPhoto', '', '1', '71', 'non,memb', '0'), … … 322 322 ('{TitleShare}', 'modules/boonex/events/|action_share.png', '', 'showPopupAnyHtml (''{BaseUri}share_popup/{ID}'');', '', '4', 'bx_events'), 323 323 ('{TitleBroadcast}', 'modules/boonex/events/|action_broadcast.png', '{BaseUri}broadcast/{ID}', '', '', '5', 'bx_events'), 324 ('{AddToFeatured}', 'modules/boonex/events/|calendar_add.png', '', 'getHtmlData( ''ajaxy_popup_result_div_{ID}'', ''{evalResult}'');return false;', '$oConfig = $GLOBALS[''oBxEventsModule'']->_oConfig; return BX_DOL_URL_ROOT . $oConfig->getBaseUri() . ''mark_featured/{ID}'';', 6, 'bx_events'); 324 ('{AddToFeatured}', 'modules/boonex/events/|calendar_add.png', '', 'getHtmlData( ''ajaxy_popup_result_div_{ID}'', ''{evalResult}'');return false;', '$oConfig = $GLOBALS[''oBxEventsModule'']->_oConfig; return BX_DOL_URL_ROOT . $oConfig->getBaseUri() . ''mark_featured/{ID}'';', 6, 'bx_events'), 325 ('{evalResult}', 'modules/boonex/events/|calendar_add.png', '{BaseUri}browse/my?bx_events_filter=add_event', '', 'return $GLOBALS[''logged''][''member''] || $GLOBALS[''logged''][''admin''] ? _t(''_bx_events_action_create_event'') : '''';', '1', 'bx_events_title'), 326 ('{evalResult}', 'modules/boonex/events/|events.png', '{BaseUri}browse/my', '', 'return $GLOBALS[''logged''][''member''] || $GLOBALS[''logged''][''admin''] ? _t(''_bx_events_action_my_events'') : '''';', '2', 'bx_events_title'); 325 327 326 328 -- top menu … … 360 362 SET @iMax = (SELECT MAX(`order`) FROM `sys_menu_admin` WHERE `parent_id` = '2'); 361 363 INSERT IGNORE INTO `sys_menu_admin` (`parent_id`, `name`, `title`, `url`, `description`, `icon`, `order`) VALUES 362 (2, 'bx_events', '_bx_events', '../modules/?r=events/administration ', 'Events module by BoonEx', 'modules/boonex/events/|events.png', @iMax+1);364 (2, 'bx_events', '_bx_events', '../modules/?r=events/administration/', 'Events module by BoonEx', 'modules/boonex/events/|events.png', @iMax+1); 363 365 364 366 -- email templates
Note: See TracChangeset
for help on using the changeset viewer.