Esempio n. 1
0
 /**
  * Configure the Linkbar.
  *
  * @param	string	The name of the active view.
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('COM_LANGUAGES_SUBMENU_INSTALLED_SITE'), Route::url('index.php?option=com_languages&view=installed&client=0'), $vName == 'installed');
     Submenu::addEntry(Lang::txt('COM_LANGUAGES_SUBMENU_INSTALLED_ADMINISTRATOR'), Route::url('index.php?option=com_languages&view=installed&client=1'), $vName == 'installed');
     Submenu::addEntry(Lang::txt('COM_LANGUAGES_SUBMENU_CONTENT'), Route::url('index.php?option=com_languages&view=languages'), $vName == 'languages');
     Submenu::addEntry(Lang::txt('COM_LANGUAGES_SUBMENU_OVERRIDES'), Route::url('index.php?option=com_languages&view=overrides'), $vName == 'overrides');
 }
Esempio n. 2
0
 /**
  * Configure the Linkbar.
  *
  * @param	string	The name of the active view.
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('COM_NEWSFEEDS_SUBMENU_NEWSFEEDS'), Route::url('index.php?option=com_newsfeeds&view=newsfeeds'), $vName == 'newsfeeds');
     Submenu::addEntry(Lang::txt('COM_NEWSFEEDS_SUBMENU_CATEGORIES'), Route::url('index.php?option=com_categories&extension=com_newsfeeds'), $vName == 'categories');
     if ($vName == 'categories') {
         Toolbar::title(Lang::txt('COM_CATEGORIES_CATEGORIES_TITLE', Lang::txt('com_newsfeeds')), 'newsfeeds-categories');
     }
 }
Esempio n. 3
0
 /**
  * Configure the Linkbar.
  *
  * @param	string	$vName	The name of the active view.
  *
  * @return	void
  * @since	1.6
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('JGLOBAL_ARTICLES'), Route::url('index.php?option=com_content&view=articles'), $vName == 'articles');
     Submenu::addEntry(Lang::txt('COM_CONTENT_SUBMENU_CATEGORIES'), Route::url('index.php?option=com_categories&extension=com_content'), $vName == 'categories');
     /*Submenu::addEntry(
     			Lang::txt('COM_CONTENT_SUBMENU_FEATURED'),
     			Route::url('index.php?option=com_content&view=featured'),
     			$vName == 'featured'
     		);*/
 }
Esempio n. 4
0
 /**
  * Configure the Linkbar.
  *
  * @param   string  $vName  The name of the active view.
  *
  * @return  void
  *
  * @since   1.6
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('COM_USERS_SUBMENU_MEMBERS'), Route::url('index.php?option=com_members&view=users'), $vName == 'users');
     // Groups and Levels are restricted to core.admin
     $canDo = self::getActions();
     if ($canDo->get('core.admin')) {
         Submenu::addEntry(Lang::txt('COM_USERS_SUBMENU_GROUPS'), Route::url('index.php?option=com_users&view=groups'), $vName == 'groups');
         Submenu::addEntry(Lang::txt('COM_USERS_SUBMENU_LEVELS'), Route::url('index.php?option=com_users&view=levels'), $vName == 'levels');
         Submenu::addEntry(Lang::txt('COM_USERS_SUBMENU_NOTES'), Route::url('index.php?option=com_users&view=notes'), $vName == 'notes');
         $extension = Request::getString('extension');
         Submenu::addEntry(Lang::txt('COM_USERS_SUBMENU_NOTE_CATEGORIES'), Route::url('index.php?option=com_categories&extension=com_users'), $vName == 'categories' || $extension == 'com_users');
     }
 }
Esempio n. 5
0
 /**
  * Configure the Linkbar.
  *
  * @param   string  $vName  The name of the active view.
  * @return  void
  */
 public static function addSubmenu($vName = 'install')
 {
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_INSTALL'), Route::url('index.php?option=com_installer'), $vName == 'install');
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_UPDATE'), Route::url('index.php?option=com_installer&controller=update'), $vName == 'update');
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_MANAGE'), Route::url('index.php?option=com_installer&controller=manage'), $vName == 'manage');
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_DISCOVER'), Route::url('index.php?option=com_installer&controller=discover'), $vName == 'discover');
     /*Submenu::addEntry(
     			Lang::txt('COM_INSTALLER_SUBMENU_DATABASE'),
     			Route::url('index.php?option=com_installer&controller=database'),
     			$vName == 'database'
     		);*/
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_WARNINGS'), Route::url('index.php?option=com_installer&controller=warnings'), $vName == 'warnings');
     Submenu::addEntry(Lang::txt('COM_INSTALLER_SUBMENU_LANGUAGES'), Route::url('index.php?option=com_installer&controller=languages'), $vName == 'languages');
 }
Esempio n. 6
0
if (!\User::authorise('core.manage', 'com_support')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
include_once dirname(__DIR__) . DS . 'tables' . DS . 'ticket.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'watching.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'comment.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'message.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'attachment.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'category.php';
include_once dirname(__DIR__) . DS . 'helpers' . DS . 'utilities.php';
include_once dirname(__DIR__) . DS . 'helpers' . DS . 'acl.php';
$controllerName = \Request::getCmd('controller', 'tickets');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'tickets';
}
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_TICKETS'), \Route::url('index.php?option=com_support&controller=tickets'), $controllerName == 'tickets');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_CATEGORIES'), \Route::url('index.php?option=com_support&controller=categories'), $controllerName == 'categories');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_QUERIES'), \Route::url('index.php?option=com_support&controller=queries'), $controllerName == 'queries');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_MESSAGES'), \Route::url('index.php?option=com_support&controller=messages'), $controllerName == 'messages');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_STATUSES'), \Route::url('index.php?option=com_support&controller=statuses'), $controllerName == 'statuses');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_ABUSE'), \Route::url('index.php?option=com_support&controller=abusereports'), $controllerName == 'abusereports');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_STATS'), \Route::url('index.php?option=com_support&controller=stats'), $controllerName == 'stats');
\Submenu::addEntry(\Lang::txt('COM_SUPPORT_ACL'), \Route::url('index.php?option=com_support&controller=acl'), $controllerName == 'acl');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 7
0
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\System\Admin;

if (!\User::authorise('core.manage', 'com_system')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'html.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', \Request::getCmd('view', 'info'));
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'info';
}
\Submenu::addEntry(\Lang::txt('COM_SYSTEM_LDAP'), \Route::url('index.php?option=com_system&controller=ldap'), $controllerName == 'ldap');
\Submenu::addEntry(\Lang::txt('COM_SYSTEM_GEO'), \Route::url('index.php?option=com_system&controller=geodb'), $controllerName == 'geodb');
\Submenu::addEntry(\Lang::txt('COM_SYSTEM_APC'), \Route::url('index.php?option=com_system&controller=apc'), $controllerName == 'apc');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 8
0
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2011 Purdue University. All rights reserved.
 * @license   http://www.gnu.org/licenses/lgpl-3.0.html LGPLv3
 */
namespace Components\Storefront\Admin;

$option = 'com_storefront';
if (!\User::authorise('core.manage', $option)) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'models' . DS . 'Archive.php';
require_once __DIR__ . DS . 'helpers' . DS . 'permissions.php';
$scope = \Request::getCmd('scope', 'site');
$controllerName = \Request::getCmd('controller', 'products');
\Submenu::addEntry(Lang::txt('COM_STOREFRONT_PRODUCTS'), \Route::url('index.php?option=com_storefront&id=0'), $controllerName == 'products');
\Submenu::addEntry(Lang::txt('COM_STOREFRONT_COLLECTIONS'), \Route::url('index.php?option=com_storefront&controller=collections&id=0'), $controllerName == 'collections');
\Submenu::addEntry(Lang::txt('COM_STOREFRONT_OPTION_GROUPS'), \Route::url('index.php?option=com_storefront&controller=optiongroups&id=0'), $controllerName == 'optiongroups');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'products';
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
// No direct access.
defined('_HZEXEC_') or die;
Toolbar::title(Lang::txt('Search: Setup Result Permissions'));
Toolbar::custom('saveRuleset', 'save', '', 'Save Ruleset', false);
Toolbar::cancel();
$this->css('solr');
$option = $this->option;
\Submenu::addEntry(Lang::txt('Overview'), 'index.php?option=' . $option . '&task=configure');
\Submenu::addEntry(Lang::txt('Search Index'), 'index.php?option=' . $option . '&task=searchindex');
\Submenu::addEntry(Lang::txt('Index Blacklist'), 'index.php?option=' . $option . '&task=manageBlacklist');
?>
<style>
/* Desktop View */
.search-container {
	background: #FFFFFF;
	height: 100%;
	width: 100%;
}

.search-container .inner {
	height: 100%;
	width: 100%;
	display:table;
}
Esempio n. 10
0
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Wiki\Admin;

// Authorization check
if (!\User::authorise('core.manage', 'com_wiki')) {
    return \App::abort(403, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
include_once dirname(__DIR__) . DS . 'helpers' . DS . 'parser.php';
include_once dirname(__DIR__) . DS . 'models' . DS . 'book.php';
// Initiate controller
$controllerName = \Request::getCmd('controller', 'pages');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'pages';
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
\Submenu::addEntry(\Lang::txt('COM_WIKI_PAGES'), \Route::url('index.php?option=com_wiki'), true);
require_once dirname(dirname(__DIR__)) . DS . 'com_plugins' . DS . 'admin' . DS . 'helpers' . DS . 'plugins.php';
if (\Components\Plugins\Admin\Helpers\Plugins::getActions()->get('core.manage')) {
    \Submenu::addEntry(\Lang::txt('COM_WIKI_PLUGINS'), \Route::url('index.php?option=com_plugins&view=plugins&filter_folder=wiki&filter_type=wiki'));
}
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
Esempio n. 11
0
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Courses\Admin;

if (!\User::authorise('core.manage', 'com_courses')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'log.php';
$controllerName = \Request::getCmd('controller', 'courses');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'courses';
}
\Submenu::addEntry(\Lang::txt('COM_COURSES_COURSES'), \Route::url('index.php?option=com_courses&controller=courses'), !in_array($controllerName, array('students', 'roles', 'pages')));
\Submenu::addEntry(\Lang::txt('COM_COURSES_PAGES'), \Route::url('index.php?option=com_courses&controller=pages&course=0'), $controllerName == 'pages');
\Submenu::addEntry(\Lang::txt('COM_COURSES_STUDENTS'), \Route::url('index.php?option=com_courses&controller=students&offering=0&section=0'), $controllerName == 'students');
\Submenu::addEntry(\Lang::txt('COM_COURSES_ROLES'), \Route::url('index.php?option=com_courses&controller=roles'), $controllerName == 'roles');
require_once PATH_CORE . DS . 'components' . DS . 'com_plugins' . DS . 'admin' . DS . 'helpers' . DS . 'plugins.php';
$canDo = \Components\Plugins\Admin\Helpers\Plugins::getActions();
if ($canDo->get('core.manage')) {
    \Submenu::addEntry(\Lang::txt('COM_COURSES_PLUGINS'), \Route::url('index.php?option=com_plugins&view=plugins&filter_folder=courses&filter_type=courses'));
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 12
0
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Kb\Admin;

if (!\User::authorise('core.manage', 'com_kb')) {
    throw new \Exception(\Lang::txt('JERROR_ALERTNOAUTHOR'), 403);
}
// Include scripts
require_once dirname(__DIR__) . DS . 'models' . DS . 'archive.php';
require_once __DIR__ . DS . 'helpers' . DS . 'html.php';
require_once __DIR__ . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'articles');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'articles';
}
\Submenu::addEntry(\Lang::txt('COM_KB_ARTICLES'), \Route::url('index.php?option=com_kb&controller=articles', false), $controllerName == 'articles');
\Submenu::addEntry(\Lang::txt('COM_KB_CATEGORIES'), \Route::url('index.php?option=com_categories&extension=com_kb', false));
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 13
0
 /**
  * Configure the Linkbar.
  *
  * @param	string	The name of the active view.
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('COM_TEMPLATES_SUBMENU_STYLES'), Route::url('index.php?option=com_templates&view=styles'), $vName == 'styles');
     Submenu::addEntry(Lang::txt('COM_TEMPLATES_SUBMENU_TEMPLATES'), Route::url('index.php?option=com_templates&view=templates'), $vName == 'templates');
 }
Esempio n. 14
0
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Wishlist\Admin;

// Authorization check
if (!\User::authorise('core.manage', 'com_wishlist')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
include_once dirname(__DIR__) . DS . 'tables' . DS . 'wishlist.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'owner.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'ownergroup.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'wish.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'wish' . DS . 'plan.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'wish' . DS . 'rank.php';
include_once dirname(__DIR__) . DS . 'tables' . DS . 'wish' . DS . 'attachment.php';
include_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'lists');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'lists';
}
\Submenu::addEntry(\Lang::txt('COM_WISHLIST_LISTS'), \Route::url('index.php?option=com_wishlist&controller=lists'), $controllerName == 'lists');
\Submenu::addEntry(\Lang::txt('COM_WISHLIST_WISHES'), \Route::url('index.php?option=com_wishlist&controller=wishes&wishlist=-1'), $controllerName == 'wishes');
\Submenu::addEntry(\Lang::txt('COM_WISHLIST_COMMENTS'), \Route::url('index.php?option=com_wishlist&controller=comments&wish=-1'), $controllerName == 'comments');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Initiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 15
0
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Events\Admin;

if (!\User::authorise('core.manage', 'com_events')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'models' . DS . 'tags.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'date.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'category.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'event.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'config.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'page.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'respondent.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'html.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'csv.php';
$controllerName = \Request::getCmd('controller', 'events');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'events';
}
\Submenu::addEntry(\Lang::txt('COM_EVENTS'), \Route::url('index.php?option=com_events&controller=events'), $controllerName == 'events');
\Submenu::addEntry(\Lang::txt('COM_EVENTS_CATEGORIES'), \Route::url('index.php?option=com_categories&extension=com_events'), $controllerName == 'categories');
\Submenu::addEntry(\Lang::txt('COM_EVENTS_CONFIGURATION'), \Route::url('index.php?option=com_events&controller=configure'), $controllerName == 'configure');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 16
0
namespace Components\Citations\Admin;

if (!\User::authorise('core.manage', 'com_citations')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'tables' . DS . 'citation.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'association.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'author.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'secondary.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'tags.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'type.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'sponsor.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'format.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'format.php';
require_once dirname(__DIR__) . DS . 'models' . DS . 'format.php';
$controllerName = \Request::getCmd('controller', 'citations');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'citations';
}
\Submenu::addEntry(\Lang::txt('CITATIONS'), \Route::url('index.php?option=com_citations&controller=citations'), $controllerName == 'citations' && \Request::getVar('task', '') != 'stats');
\Submenu::addEntry(\Lang::txt('CITATION_STATS'), \Route::url('index.php?option=com_citations&controller=citations&task=stats'), $controllerName == 'citations' && \Request::getVar('task', '') == 'stats');
\Submenu::addEntry(\Lang::txt('CITATION_TYPES'), \Route::url('index.php?option=com_citations&controller=types'), $controllerName == 'types');
\Submenu::addEntry(\Lang::txt('CITATION_SPONSORS'), \Route::url('index.php?option=com_citations&controller=sponsors'), $controllerName == 'sponsors');
\Submenu::addEntry(\Lang::txt('CITATION_FORMAT'), \Route::url('index.php?option=com_citations&controller=format'), $controllerName == 'format');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Initiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 17
0
namespace Components\Tools\Admin;

if (!\User::authorise('core.manage', 'com_tools')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'utils.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'helper.php';
require_once dirname(__DIR__) . DS . 'models' . DS . 'tool.php';
$controllerName = \Request::getCmd('controller', 'pipeline');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'pipeline';
}
\Submenu::addEntry(\Lang::txt('COM_TOOLS_PIPELINE'), \Route::url('index.php?option=com_tools&controller=pipeline'), $controllerName == 'pipeline');
\Submenu::addEntry(\Lang::txt('COM_TOOLS_HOSTS'), \Route::url('index.php?option=com_tools&controller=hosts'), $controllerName == 'hosts');
\Submenu::addEntry(\Lang::txt('COM_TOOLS_HOST_TYPES'), \Route::url('index.php?option=com_tools&controller=hosttypes'), $controllerName == 'hosttypes');
if (\Component::params('com_tools')->get('zones')) {
    \Submenu::addEntry(\Lang::txt('COM_TOOLS_ZONES'), \Route::url('index.php?option=com_tools&controller=zones'), $controllerName == 'zones');
}
\Submenu::addEntry(\Lang::txt('COM_TOOLS_SESSIONS'), \Route::url('index.php?option=com_tools&controller=sessions'), $controllerName == 'sessions');
\Submenu::addEntry(\Lang::txt('COM_TOOLS_USER_PREFS'), \Route::url('index.php?option=com_tools&controller=preferences'), $controllerName == 'preferences');
\Submenu::addEntry(\Lang::txt('COM_TOOLS_HANDLERS'), \Route::url('index.php?option=com_tools&controller=handlers'), $controllerName == 'handlers');
if (\Component::params('com_tools')->get('windows_key_id')) {
    \Submenu::addEntry(\Lang::txt('COM_TOOLS_WINDOWS'), \Route::url('index.php?option=com_tools&controller=windows'), $controllerName == 'windows');
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 18
0
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Oaipmh\Admin;

if (!\User::authorise('core.manage', 'com_oaipmh')) {
    return \App::abort(403, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once __DIR__ . DS . 'controllers' . DS . 'config.php';
$task = \Request::getCmd('task');
\Submenu::addEntry(\Lang::txt('COM_OAIPMH_ABOUT'), \Route::url('index.php?option=com_oaipmh'), !$task || $task == 'display');
\Submenu::addEntry(\Lang::txt('COM_OAIPMH_SCHEMAS'), \Route::url('index.php?option=com_oaipmh&task=schemas'), $task == 'schemas');
require_once dirname(dirname(__DIR__)) . DS . 'com_plugins' . DS . 'admin' . DS . 'helpers' . DS . 'plugins.php';
if (\Components\Plugins\Admin\Helpers\Plugins::getActions()->get('core.manage')) {
    \Submenu::addEntry(\Lang::txt('COM_OAIPMH_PLUGINS'), \Route::url('index.php?option=com_plugins&view=plugins&filter_folder=oaipmh&filter_type=oaipmh'));
}
// Instantiate controller
$controller = new Controllers\Config();
$controller->execute();
Esempio n. 19
0
 * of this software and associated documentation files (the "Software"), to deal
 * in the Software without restriction, including without limitation the rights
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the Software is
 * furnished to do so, subject to the following conditions:
 *
 * The above copyright notice and this permission notice shall be included in
 * all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
Submenu::addEntry(Lang::txt('COM_GROUPS_PAGES'), Route::url('index.php?option=com_groups&controller=pages&gid=' . $this->group->get('cn')), Request::getVar('controller', 'pages') == 'pages');
Submenu::addEntry(Lang::txt('COM_GROUPS_PAGES_CATEGORIES'), Route::url('index.php?option=com_groups&controller=categories&gid=' . $this->group->get('cn')), Request::getVar('controller', 'pages') == 'categories');
// load group params
$config = Component::params('com_groups');
// only show modules if Super group
if ($this->group->isSuperGroup() || $config->get('page_modules', 0)) {
    Submenu::addEntry(Lang::txt('COM_GROUPS_PAGES_MODULES'), Route::url('index.php?option=com_groups&controller=modules&gid=' . $this->group->get('cn')), Request::getVar('controller', 'pages') == 'modules');
}
Esempio n. 20
0
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Alissa Nedossekina <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Answers\Admin;

if (!\User::authorise('core.manage', 'com_answers')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'economy.php';
require_once dirname(__DIR__) . DS . 'models' . DS . 'question.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'questions');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'questions';
}
\Submenu::addEntry(\Lang::txt('COM_ANSWERS_QUESTIONS'), \Route::url('index.php?option=com_answers'), $controllerName == 'questions');
\Submenu::addEntry(\Lang::txt('COM_ANSWERS_RESPONSES'), \Route::url('index.php?option=com_answers&controller=answers&qid=0'), $controllerName == 'answers');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// initiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 21
0
 /**
  * Configure the Linkbar.
  *
  * @param	string	The name of the active view.
  */
 public static function addSubmenu($vName)
 {
     Submenu::addEntry(Lang::txt('COM_MENUS_SUBMENU_MENUS'), Route::url('index.php?option=com_menus&view=menus'), $vName == 'menus');
     Submenu::addEntry(Lang::txt('COM_MENUS_SUBMENU_ITEMS'), Route::url('index.php?option=com_menus&view=items'), $vName == 'items');
 }
Esempio n. 22
0
require_once dirname(__DIR__) . DS . 'tables' . DS . 'password_rules.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'password_blacklist.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'quotas_classes.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'users_quotas.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'members');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'members';
}
$canDo = \Components\Members\Helpers\Permissions::getActions('component');
\Submenu::addEntry(\Lang::txt('COM_MEMBERS'), \Route::url('index.php?option=com_members'), $controllerName == 'members');
\Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_ONLINE'), \Route::url('index.php?option=com_members&controller=whosonline'), $controllerName == 'whosonline');
\Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_MESSAGING'), \Route::url('index.php?option=com_members&controller=messages'), $controllerName == 'messages');
if (\Component::params('com_members')->get('bankAccounts')) {
    \Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_POINTS'), \Route::url('index.php?option=com_members&controller=points'), $controllerName == 'points');
}
\Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_PLUGINS'), \Route::url('index.php?option=com_members&controller=plugins'), $controllerName == 'plugins');
if ($canDo->get('core.admin')) {
    \Submenu::addEntry(\Lang::txt('COM_MEMBERS_PASSWORDS'), \Route::url('index.php?option=com_members&controller=passwordrules'), $controllerName == 'passwordrules' || $controllerName == 'passwordblacklist');
}
\Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_QUOTAS'), \Route::url('index.php?option=com_members&controller=quotas'), $controllerName == 'quotas');
\Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_REGISTRATION'), \Route::url('index.php?option=com_members&controller=registration'), in_array($controllerName, array('registration', 'organizations', 'employers', 'incremental', 'premis')));
if ($canDo->get('core.admin')) {
    \Submenu::addEntry(\Lang::txt('COM_MEMBERS_MENU_IMPORT'), \Route::url('index.php?option=com_members&controller=import'), $controllerName == 'import' || $controllerName == 'importhooks');
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 23
0
 *
 * @package   hubzero-cms
 * @author    Alissa Nedossekina <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Store\Admin;

// Authorization check
if (!\User::authorise('core.manage', 'com_store')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'tables' . DS . 'store.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'order.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'orderitem.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'cart.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'imghandler.php';
$controllerName = \Request::getCmd('controller', 'orders');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'orders';
}
\Submenu::addEntry(\Lang::txt('Orders'), \Route::url('index.php?option=com_store&controller=orders'), $controllerName == 'orders');
\Submenu::addEntry(\Lang::txt('Store Items'), \Route::url('index.php?option=com_store&controller=items'), $controllerName == 'items');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 24
0
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Tags\Admin;

if (!\User::authorise('core.manage', 'com_tags')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'models' . DS . 'cloud.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'entries');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'entries';
}
$task = \Request::getCmd('task', '');
\Submenu::addEntry(\Lang::txt('COM_TAGS'), \Route::url('index.php?option=com_tags'), $controllerName == 'entries');
\Submenu::addEntry(\Lang::txt('COM_TAGS_RELATIONSHIPS'), \Route::url('index.php?option=com_tags&controller=relationships'), $controllerName == 'relationships' && $task != 'meta' && $task != 'updatefocusareas');
\Submenu::addEntry(\Lang::txt('COM_TAGS_FOCUS_AREAS'), \Route::url('index.php?option=com_tags&controller=relationships&task=meta'), $controllerName == 'relationships' && ($task == 'meta' || $task == 'updatefocusareas'));
require_once dirname(dirname(__DIR__)) . DS . 'com_plugins' . DS . 'admin' . DS . 'helpers' . DS . 'plugins.php';
if (\Components\Plugins\Admin\Helpers\Plugins::getActions()->get('core.manage')) {
    \Submenu::addEntry(\Lang::txt('COM_TAGS_PLUGINS'), \Route::url('index.php?option=com_plugins&view=plugins&filter_folder=tags&filter_type=tags'));
}
// Include scripts
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Initiate controller
$controller = new $controllerName();
$controller->execute();
Esempio n. 25
0
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Alissa Nedossekina <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Services\Admin;

if (!\User::authorise('core.manage', 'com_services')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'service.php';
require_once dirname(__DIR__) . DS . 'tables' . DS . 'subscription.php';
$controllerName = \Request::getCmd('controller', 'services');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'services';
}
\Submenu::addEntry(\Lang::txt('COM_SERVICES_SERVICES'), \Route::url('index.php?option=com_services&controller=services'), $controllerName == 'services');
\Submenu::addEntry(\Lang::txt('COM_SERVICES_SUBSCRIPTIONS'), \Route::url('index.php?option=com_services&controller=subscriptions'), $controllerName == 'subscriptions');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Initiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 26
0
 * GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2011 Purdue University. All rights reserved.
 * @license   http://www.gnu.org/licenses/lgpl-3.0.html LGPLv3
 */
namespace Components\Cart\Admin;

$option = 'com_cart';
if (!\User::authorise('core.manage', $option)) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once __DIR__ . DS . 'helpers' . DS . 'permissions.php';
$scope = \Request::getCmd('scope', 'site');
$controllerName = \Request::getCmd('controller', 'downloads');
\Submenu::addEntry(Lang::txt('COM_CART_SOFTWARE_DOWNLOADS'), \Route::url('index.php?option=com_storefront&controller=downloads'), $controllerName == 'downloads');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'downloads';
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 27
0
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 * THE SOFTWARE.
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Developer\Admin;

// permissions check
if (!\User::authorise('core.manage', 'com_developer')) {
    return \App::abort(403, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'models' . DS . 'application.php';
// Make extra sure that controller exists
$controllerName = \Request::getCmd('controller', 'applications');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'applications';
}
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
// Add some submenu items
\Submenu::addEntry(\Lang::txt('COM_DEVELOPER_APPLICATIONS'), \Route::url('index.php?option=com_developer&controller=applications'), $controllerName == 'applications');
// Build the class name
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst(strtolower($controllerName));
// Instantiate controller
$component = new $controllerName();
$component->execute();
Esempio n. 28
0
 *
 * HUBzero is a registered trademark of Purdue University.
 *
 * @package   hubzero-cms
 * @author    Shawn Rice <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Forum\Admin;

if (!\User::authorise('core.manage', 'com_forum')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
require_once dirname(__DIR__) . DS . 'models' . DS . 'manager.php';
require_once __DIR__ . DS . 'models' . DS . 'adminsection.php';
require_once __DIR__ . DS . 'models' . DS . 'admincategory.php';
require_once __DIR__ . DS . 'models' . DS . 'adminthread.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
$controllerName = \Request::getCmd('controller', 'sections');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'sections';
}
\Submenu::addEntry(\Lang::txt('COM_FORUM_SECTIONS'), \Route::url('index.php?option=com_forum&controller=sections'), $controllerName == 'sections');
\Submenu::addEntry(\Lang::txt('COM_FORUM_CATEGORIES'), \Route::url('index.php?option=com_forum&controller=categories&section_id=-1'), $controllerName == 'categories');
\Submenu::addEntry(\Lang::txt('COM_FORUM_THREADS'), \Route::url('index.php?option=com_forum&controller=threads&category_id=-1'), $controllerName == 'threads');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// initiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 29
0
require_once dirname(__DIR__) . DS . 'tables' . DS . 'contributor' . DS . 'roletype.php';
// include helpers
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'html.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'permissions.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'utilities.php';
require_once dirname(__DIR__) . DS . 'helpers' . DS . 'tags.php';
// include importer
require_once __DIR__ . DS . 'import' . DS . 'importer.php';
// get controller name
$controllerName = \Request::getCmd('controller', 'items');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'items';
}
\Submenu::addEntry(\Lang::txt('COM_RESOURCES'), \Route::url('index.php?option=' . $option), $controllerName == 'items' && $task != 'orphans');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_ORPHANS'), \Route::url('index.php?option=' . $option . '&controller=items&task=orphans'), $task == 'orphans');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_TYPES'), \Route::url('index.php?option=' . $option . '&controller=types'), $controllerName == 'types');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_LICENSES'), \Route::url('index.php?option=' . $option . '&controller=licenses'), $controllerName == 'licenses');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_AUTHORS'), \Route::url('index.php?option=' . $option . '&controller=authors'), $controllerName == 'authors');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_ROLES'), \Route::url('index.php?option=' . $option . '&controller=roles'), $controllerName == 'roles');
require_once dirname(dirname(__DIR__)) . DS . 'com_plugins' . DS . 'admin' . DS . 'helpers' . DS . 'plugins.php';
if (\Components\Plugins\Admin\Helpers\Plugins::getActions()->get('core.manage')) {
    \Submenu::addEntry(\Lang::txt('COM_RESOURCES_PLUGINS'), \Route::url('index.php?option=' . $option . '&controller=plugins'), $controllerName == 'plugins');
}
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_IMPORT'), \Route::url('index.php?option=' . $option . '&controller=import'), $controllerName == 'import');
\Submenu::addEntry(\Lang::txt('COM_RESOURCES_IMPORTHOOK'), \Route::url('index.php?option=' . $option . '&controller=importhooks'), $controllerName == 'importhooks');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();
Esempio n. 30
0
 *
 * @package   hubzero-cms
 * @author    Alissa Nedossekina <*****@*****.**>
 * @copyright Copyright 2005-2015 HUBzero Foundation, LLC.
 * @license   http://opensource.org/licenses/MIT MIT
 */
namespace Components\Publications\Admin;

$option = Request::getCmd('option', 'com_publications');
$task = Request::getWord('task', '');
if (!\User::authorise('core.manage', 'com_publications')) {
    return \App::abort(404, \Lang::txt('JERROR_ALERTNOAUTHOR'));
}
// Include scripts
require_once dirname(__DIR__) . DS . 'models' . DS . 'publication.php';
// get controller name
$controllerName = Request::getCmd('controller', 'items');
if (!file_exists(__DIR__ . DS . 'controllers' . DS . $controllerName . '.php')) {
    $controllerName = 'items';
}
\Submenu::addEntry(\Lang::txt('COM_PUBLICATIONS_PUBLICATIONS'), \Route::url('index.php?option=' . $option . '&controller=items'), $controllerName == 'items');
\Submenu::addEntry(\Lang::txt('COM_PUBLICATIONS_LICENSES'), \Route::url('index.php?option=' . $option . '&controller=licenses'), $controllerName == 'licenses');
\Submenu::addEntry(\Lang::txt('COM_PUBLICATIONS_CATEGORIES'), \Route::url('index.php?option=' . $option . '&controller=categories'), $controllerName == 'categories');
\Submenu::addEntry(\Lang::txt('COM_PUBLICATIONS_MASTER_TYPES'), \Route::url('index.php?option=' . $option . '&controller=types'), $controllerName == 'types');
\Submenu::addEntry(\Lang::txt('COM_PUBLICATIONS_BATCH_CREATE'), \Route::url('index.php?option=' . $option . '&controller=batchcreate'), $controllerName == 'batchcreate');
require_once __DIR__ . DS . 'controllers' . DS . $controllerName . '.php';
$controllerName = __NAMESPACE__ . '\\Controllers\\' . ucfirst($controllerName);
// Instantiate controller
$controller = new $controllerName();
$controller->execute();
$controller->redirect();