View | Details | Raw Unified | Return to bug 1709 | Differences between
and this patch

Collapse All | Expand All

(-)pages/manager/ManagerHandler.inc.php (-1 / +1 lines)
 Lines 35-41    Link Here 
35
		$journal =& Request::getJournal();
35
		$journal =& Request::getJournal();
36
		$templateMgr =& TemplateManager::getManager();
36
		$templateMgr =& TemplateManager::getManager();
37
		$templateMgr->assign_by_ref('roleSettings', $this->retrieveRoleAssignmentPreferences($journal->getJournalId()));
37
		$templateMgr->assign_by_ref('roleSettings', $this->retrieveRoleAssignmentPreferences($journal->getJournalId()));
38
		$templateMgr->assign('subscriptionsEnabled', $journal->getSetting('enableSubscriptions'));
38
		$templateMgr->assign('subscriptionsEnabled', $journal->getSetting('publishingMode'));
39
		$templateMgr->assign('announcementsEnabled', $journal->getSetting('enableAnnouncements'));
39
		$templateMgr->assign('announcementsEnabled', $journal->getSetting('enableAnnouncements'));
40
		$session =& Request::getSession();
40
		$session =& Request::getSession();
41
		$session->unsetSessionVar('enrolmentReferrer');
41
		$session->unsetSessionVar('enrolmentReferrer');
(-)pages/user/UserHandler.inc.php (-6 / +6 lines)
 Lines 88-94    Link Here 
88
			$this->getRoleDataForJournal($userId, $journalId, $submissionsCount, $isValid);
88
			$this->getRoleDataForJournal($userId, $journalId, $submissionsCount, $isValid);
89
			
89
			
90
			$subscriptionTypeDAO =& DAORegistry::getDAO('SubscriptionTypeDAO');
90
			$subscriptionTypeDAO =& DAORegistry::getDAO('SubscriptionTypeDAO');
91
			$subscriptionsEnabled = $journal->getSetting('enableSubscriptions') && ($subscriptionTypeDAO->subscriptionTypesExistByInstitutional($journalId, false) || $subscriptionTypeDAO->subscriptionTypesExistByInstitutional($journalId, true)) ? true : false;
91
			$subscriptionsEnabled = $journal->getSetting('publishingMode') && ($subscriptionTypeDAO->subscriptionTypesExistByInstitutional($journalId, false) || $subscriptionTypeDAO->subscriptionTypesExistByInstitutional($journalId, true)) ? true : false;
92
			$templateMgr->assign('subscriptionsEnabled', $subscriptionsEnabled);
92
			$templateMgr->assign('subscriptionsEnabled', $subscriptionsEnabled);
93
93
94
			import('payment.ojs.OJSPaymentManager');
94
			import('payment.ojs.OJSPaymentManager');
 Lines 121-127    Link Here 
121
121
122
		$journal =& Request::getJournal();
122
		$journal =& Request::getJournal();
123
		if (!$journal) Request::redirect(null, 'user');
123
		if (!$journal) Request::redirect(null, 'user');
124
		if (!$journal->getSetting('enableSubscriptions')) Request::redirect(null, 'user');
124
		if (!$journal->getSetting('publishingMode')) Request::redirect(null, 'user');
125
		
125
		
126
		$journalId = $journal->getJournalId();
126
		$journalId = $journal->getJournalId();
127
		$subscriptionTypeDAO =& DAORegistry::getDAO('SubscriptionTypeDAO');
127
		$subscriptionTypeDAO =& DAORegistry::getDAO('SubscriptionTypeDAO');
 Lines 395-401    Link Here 
395
395
396
		$journal =& Request::getJournal();
396
		$journal =& Request::getJournal();
397
		if (!$journal) Request::redirect(null, 'user');
397
		if (!$journal) Request::redirect(null, 'user');
398
		if (!$journal->getSetting('enableSubscriptions')) Request::redirect(null, 'user');
398
		if (!$journal->getSetting('publishingMode')) Request::redirect(null, 'user');
399
399
400
		import('payment.ojs.OJSPaymentManager');
400
		import('payment.ojs.OJSPaymentManager');
401
		$paymentManager =& OJSPaymentManager::getManager();
401
		$paymentManager =& OJSPaymentManager::getManager();
 Lines 465-471    Link Here 
465
465
466
		$journal =& Request::getJournal();
466
		$journal =& Request::getJournal();
467
		if (!$journal) Request::redirect(null, 'user');
467
		if (!$journal) Request::redirect(null, 'user');
468
		if (!$journal->getSetting('enableSubscriptions')) Request::redirect(null, 'user');
468
		if (!$journal->getSetting('publishingMode')) Request::redirect(null, 'user');
469
469
470
		import('payment.ojs.OJSPaymentManager');
470
		import('payment.ojs.OJSPaymentManager');
471
		$paymentManager =& OJSPaymentManager::getManager();
471
		$paymentManager =& OJSPaymentManager::getManager();
 Lines 560-566    Link Here 
560
560
561
		$journal =& Request::getJournal();
561
		$journal =& Request::getJournal();
562
		if (!$journal) Request::redirect(null, 'user');
562
		if (!$journal) Request::redirect(null, 'user');
563
		if (!$journal->getSetting('enableSubscriptions')) Request::redirect(null, 'user');
563
		if (!$journal->getSetting('publishingMode')) Request::redirect(null, 'user');
564
564
565
		import('payment.ojs.OJSPaymentManager');
565
		import('payment.ojs.OJSPaymentManager');
566
		$paymentManager =& OJSPaymentManager::getManager();
566
		$paymentManager =& OJSPaymentManager::getManager();
 Lines 606-612    Link Here 
606
606
607
		$journal =& Request::getJournal();
607
		$journal =& Request::getJournal();
608
		if (!$journal) Request::redirect(null, 'user');
608
		if (!$journal) Request::redirect(null, 'user');
609
		if (!$journal->getSetting('enableSubscriptions')) Request::redirect(null, 'user');
609
		if (!$journal->getSetting('publishingMode')) Request::redirect(null, 'user');
610
610
611
		import('payment.ojs.OJSPaymentManager');
611
		import('payment.ojs.OJSPaymentManager');
612
		$paymentManager =& OJSPaymentManager::getManager();
612
		$paymentManager =& OJSPaymentManager::getManager();
(-)plugins/blocks/subscription/SubscriptionBlockPlugin.inc.php (-1 / +1 lines)
 Lines 74-80    Link Here 
74
		$journalId = ($journal)?$journal->getJournalId():null;
74
		$journalId = ($journal)?$journal->getJournalId():null;
75
		if (!$journal) return '';
75
		if (!$journal) return '';
76
76
77
		if (!$journal->getSetting('enableSubscriptions')) return '';
77
		if (!$journal->getSetting('publishingMode')) return '';
78
78
79
		$user =& Request::getUser();
79
		$user =& Request::getUser();
80
		$userId = ($user)?$user->getId():null;
80
		$userId = ($user)?$user->getId():null;

Return to bug 1709