4 +--------------------------------------------------------------------+
5 | CiviCRM version 4.6 |
6 +--------------------------------------------------------------------+
7 | Copyright CiviCRM LLC (c) 2004-2014 |
8 +--------------------------------------------------------------------+
9 | This file is a part of CiviCRM. |
11 | CiviCRM is free software; you can copy, modify, and distribute it |
12 | under the terms of the GNU Affero General Public License |
13 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
15 | CiviCRM is distributed in the hope that it will be useful, but |
16 | WITHOUT ANY WARRANTY; without even the implied warranty of |
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
18 | See the GNU Affero General Public License for more details. |
20 | You should have received a copy of the GNU Affero General Public |
21 | License and the CiviCRM Licensing Exception along |
22 | with this program; if not, contact CiviCRM LLC |
23 | at info[AT]civicrm[DOT]org. If you have questions about the |
24 | GNU Affero General Public License or the licensing of CiviCRM, |
25 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
26 +--------------------------------------------------------------------+
30 * This file hard-codes the path entries for the queueing UI, which
31 * allows us to use these paths during upgrades.
34 * @copyright CiviCRM LLC (c) 2004-2014
39 require_once 'CRM/Core/I18n.php';
42 * Class CRM_Queue_Menu
44 class CRM_Queue_Menu
{
48 * The path for which we are trying to locate the route.
49 * @param array $menuPath
52 public static function alter($path, &$menuPath) {
54 case 'civicrm/queue/runner':
55 case 'civicrm/upgrade/queue/runner':
56 $menuPath['path'] = $path;
57 $menuPath['title'] = 'Queue Runner';
58 $menuPath['page_callback'] = 'CRM_Queue_Page_Runner';
59 $menuPath['access_arguments'][0][] = 'access CiviCRM';
60 $menuPath['access_callback'] = array('CRM_Core_Permission', 'checkMenu');
63 case 'civicrm/queue/ajax/runNext':
64 case 'civicrm/upgrade/queue/ajax/runNext':
65 $menuPath['path'] = $path;
66 $menuPath['page_callback'] = array('CRM_Queue_Page_AJAX', 'runNext');
67 $menuPath['access_arguments'][0][] = 'access CiviCRM';
68 $menuPath['access_callback'] = array('CRM_Core_Permission', 'checkMenu');
71 case 'civicrm/queue/ajax/skipNext':
72 case 'civicrm/upgrade/queue/ajax/skipNext':
73 $menuPath['path'] = $path;
74 $menuPath['page_callback'] = array('CRM_Queue_Page_AJAX', 'skipNext');
75 $menuPath['access_arguments'][0][] = 'access CiviCRM';
76 $menuPath['access_callback'] = array('CRM_Core_Permission', 'checkMenu');
79 case 'civicrm/queue/ajax/onEnd':
80 case 'civicrm/upgrade/queue/ajax/onEnd':
81 $menuPath['path'] = $path;
82 $menuPath['page_callback'] = array('CRM_Queue_Page_AJAX', 'onEnd');
83 $menuPath['access_arguments'][0][] = 'access CiviCRM';
84 $menuPath['access_callback'] = array('CRM_Core_Permission', 'checkMenu');