本文整理汇总了PHP中JToolBarHelper::makeDefault方法的典型用法代码示例。如果您正苦于以下问题:PHP JToolBarHelper::makeDefault方法的具体用法?PHP JToolBarHelper::makeDefault怎么用?PHP JToolBarHelper::makeDefault使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类JToolBarHelper
的用法示例。
在下文中一共展示了JToolBarHelper::makeDefault方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: addToolbar
/**
* Add the page title and toolbar.
*
* @since 1.6
*/
protected function addToolbar()
{
$state = $this->get('State');
$canDo = TemplatesHelper::getActions();
$isSite = $state->get('filter.client_id') == 0;
JToolBarHelper::title(JText::_('COM_TEMPLATES_MANAGER_STYLES'), 'thememanager');
if ($canDo->get('core.edit.state')) {
JToolBarHelper::makeDefault('styles.setDefault', 'COM_TEMPLATES_TOOLBAR_SET_HOME');
JToolBarHelper::divider();
}
if ($canDo->get('core.edit')) {
JToolBarHelper::editList('style.edit');
}
if ($canDo->get('core.create')) {
JToolBarHelper::custom('styles.duplicate', 'copy.png', 'copy_f2.png', 'JTOOLBAR_DUPLICATE', true);
JToolBarHelper::divider();
}
if ($canDo->get('core.delete')) {
JToolBarHelper::deleteList('', 'styles.delete');
JToolBarHelper::divider();
}
if ($canDo->get('core.admin')) {
JToolBarHelper::preferences('com_templates');
JToolBarHelper::divider();
}
JToolBarHelper::help('JHELP_EXTENSIONS_TEMPLATE_MANAGER_STYLES');
}
示例2: display
function display($tpl = null)
{
$cid = JRequest::getVar('cid', array(0), 'get', 'array');
$edit = JRequest::getVar('edit', true);
$me = JFactory::getUser();
JArrayHelper::toInteger($cid, array(0));
$db = JFactory::getDBO();
$user = JTable::getInstance('ExtUser', 'KunenaImporterTable');
$user->load($cid[0]);
$importer = $this->getModel('import');
$items = $importer->findPotentialUsers($user, true);
$myuser = JFactory::getUser();
$acl = JFactory::getACL();
// Check for post data in the event that we are returning
// from a unsuccessful attempt to save data
/* $post = JRequest::get('post');
if ( $post ) {
$user->bind($post);
}*/
// build the html select list
$lists['block'] = JHTML::_('select.booleanlist', 'block', 'class="inputbox" size="1"', $user->get('block'));
// build the html select list
$lists['sendEmail'] = JHTML::_('select.booleanlist', 'sendEmail', 'class="inputbox" size="1"', $user->get('sendEmail'));
$this->assignRef('me', $me);
$this->assignRef('lists', $lists);
$this->assignRef('user', $user);
$this->assignRef('items', $items);
JToolBarHelper::makeDefault('select', 'Select');
JToolBarHelper::back();
parent::display($tpl);
}
示例3: __construct
function __construct($default = array())
{
parent::__construct($default);
$task = JRequest::getWord('task', '');
switch ($task) {
case 'add':
case 'save':
case 'apply':
case 'edit':
JToolBarHelper::apply();
JToolBarHelper::save();
JToolBarHelper::cancel();
break;
default:
JToolBarHelper::addNew();
JToolBarHelper::deleteList();
JToolBarHelper::makeDefault('publish');
break;
}
// Register Extra tasks
JRequest::setVar('view', 'services');
$this->registerTask('add', 'edit');
$this->registerTask('apply', 'save');
$this->registerTask('publish', 'setDefault');
}
示例4: display
function display($tpl = null)
{
// Load the helper(s)
if (!class_exists('VmHTML')) {
require JPATH_VM_ADMINISTRATOR . DS . 'helpers' . DS . 'html.php';
}
// $this->assignRef('perms', Permissions::getInstance());
$model = VmModel::getModel();
$layoutName = JRequest::getWord('layout', 'default');
if ($layoutName == 'edit') {
$shoppergroup = $model->getShopperGroup();
$this->SetViewTitle('SHOPPERGROUP', $shoppergroup->shopper_group_name);
$vendors = ShopFunctions::renderVendorList($shoppergroup->virtuemart_vendor_id);
$this->assignRef('vendorList', $vendors);
$this->assignRef('shoppergroup', $shoppergroup);
$this->addStandardEditViewCommands();
} else {
$this->SetViewTitle();
JToolBarHelper::makeDefault();
$this->loadHelper('permissions');
$showVendors = Permissions::getInstance()->check('admin');
$this->assignRef('showVendors', $showVendors);
$this->addStandardDefaultViewCommands();
$this->addStandardDefaultViewLists($model);
$shoppergroups = $model->getShopperGroups(false, true);
$this->assignRef('shoppergroups', $shoppergroups);
$pagination = $model->getPagination();
$this->assignRef('pagination', $pagination);
}
parent::display($tpl);
}
示例5: display
/**
* Control Panel display function
*
* @param template $tpl
*/
public function display($tpl = null)
{
$document = JFactory::getDocument();
$document->setTitle(JText::_('JOOMFISH_TITLE') . ' :: ' . JText::_('LANGUAGE_TITLE'));
// Set toolbar items for the page
JToolBarHelper::apply('languages.apply');
JToolBarHelper::save('languages.save');
JToolBarHelper::title(JText::_('LANGUAGE_TITLE'), 'language');
JToolBarHelper::makeDefault('languages.setDefault');
JToolBarHelper::deleteList('ARE_YOU_SURE_YOU_WANT_TO_DELETE_THE_SELCTED_ITEMS', 'languages.remove');
JToolBarHelper::addNew('languages.add');
JToolBarHelper::cancel('languages.cancel', 'JTOOLBAR_CLOSE');
JToolBarHelper::divider();
JToolBarHelper::help('screen.languages', true);
JSubMenuHelper::addEntry(JText::_('COM_JOOMFISH_CONTROL_PANEL'), 'index.php?option=com_joomfish');
JSubMenuHelper::addEntry(JText::_('TRANSLATION'), 'index.php?option=com_joomfish&task=translate.overview');
if (JOOMFISH_DEVMODE == true) {
JSubMenuHelper::addEntry(JText::_('ORPHANS'), 'index.php?option=com_joomfish&task=translate.orphans');
}
if (JOOMFISH_DEVMODE == true) {
JSubMenuHelper::addEntry(JText::_('MANAGE_TRANSLATIONS'), 'index.php?option=com_joomfish&task=manage.overview');
}
if (JOOMFISH_DEVMODE == true) {
JSubMenuHelper::addEntry(JText::_('STATISTICS'), 'index.php?option=com_joomfish&task=statistics.overview');
}
JSubMenuHelper::addEntry(JText::_('LANGUAGE_CONFIGURATION'), 'index.php?option=com_joomfish&task=languages.show', true);
JSubMenuHelper::addEntry(JText::_('CONTENT_ELEMENTS'), 'index.php?option=com_joomfish&task=elements.show');
JSubMenuHelper::addEntry(JText::_('HELP_AND_HOWTO'), 'index.php?option=com_joomfish&task=help.show');
$option = JRequest::getCmd('option', 'com_joomfish');
$filter_state = JFactory::getApplication()->getUserStateFromRequest($option . 'filter_state', 'filter_state', '', 'word');
$filter_catid = JFactory::getApplication()->getUserStateFromRequest($option . 'filter_catid', 'filter_catid', 0, 'int');
$filter_order = JFactory::getApplication()->getUserStateFromRequest($option . 'filter_order', 'filter_order', 'l.ordering', 'cmd');
$filter_order_Dir = JFactory::getApplication()->getUserStateFromRequest($option . 'filter_order_Dir', 'filter_order_Dir', '', 'word');
$search = JFactory::getApplication()->getUserStateFromRequest($option . 'search', 'search', '', 'string');
$search = JString::strtolower($search);
$languages = $this->get('data');
$defaultLanguage = $this->get('defaultLanguage');
$this->assignRef('items', $languages);
$this->assignRef('defaultLanguage', $defaultLanguage);
$jfManager = JoomFishManager::getInstance();
$overwriteGlobalConfig = $jfManager->getCfg('overwriteGlobalConfig');
$this->assignRef('overwriteGlobalConfig', $overwriteGlobalConfig);
$directory_flags = $jfManager->getCfg('directory_flags');
$this->assignRef('directory_flags', $directory_flags);
// state filter
$lists['state'] = JHTML::_('grid.state', $filter_state);
// table ordering
$lists['order_Dir'] = $filter_order_Dir;
$lists['order'] = $filter_order;
// search filter
$lists['search'] = $search;
$user = JFactory::getUser();
$this->assignRef('user', $user);
$this->assignRef('lists', $lists);
JHTML::_('behavior.tooltip');
parent::display($tpl);
}
示例6: _setToolBar
/**
* Setup the Toolbar
*
* @since 1.6
*/
protected function _setToolBar()
{
JToolBarHelper::title(JText::_('Langs_View_Installed_Title'), 'langmanager.png');
JToolBarHelper::makeDefault('installed.publish');
JToolBarHelper::divider();
JToolBarHelper::preferences('com_languages');
JToolBarHelper::divider();
JToolBarHelper::help('screen.languages');
}
示例7: displayList
function displayList($tpl = null)
{
JToolBarHelper::title(_JSHOP_LIST_CURRENCY, 'generic.png');
JToolBarHelper::makeDefault("setdefault");
JToolBarHelper::addNew();
JToolBarHelper::publishList();
JToolBarHelper::unpublishList();
JToolBarHelper::deleteList();
parent::display($tpl);
}
示例8: display
function display($tpl = null)
{
// Create the form
$this->form =& ComJea::getParams();
$this->form->loadSetupFile(JPATH_COMPONENT . DS . 'models' . DS . 'Config.xml');
JHTML::_('behavior.tooltip');
JToolBarHelper::title('JEA : ' . JText::_('Configuration'), 'config.png');
JToolBarHelper::save();
JToolBarHelper::makeDefault();
parent::display($tpl);
}
示例9: display
function display($tpl = null)
{
global $mainframe;
$this->_layout = 'default';
/*
* Set toolbar items for the page
*/
$menutype = $mainframe->getUserStateFromRequest('com_menus.menutype', 'menutype', 'mainmenu', 'menutype');
JToolBarHelper::title(JText::_('MENU ITEM MANAGER'), 'menu.png');
JToolBarHelper::addNewX('newItem');
JToolBarHelper::spacer();
JToolBarHelper::trash();
JToolBarHelper::spacer();
JToolBarHelper::customX('move', 'move.png', 'move_f2.png', 'Move', true);
JToolBarHelper::customX('copy', 'copy.png', 'copy_f2.png', 'Copy', true);
JToolBarHelper::spacer();
JToolBarHelper::publishList();
JToolBarHelper::unpublishList();
JToolBarHelper::spacer();
JToolBarHelper::makeDefault('setdefault');
JSubMenuHelper::addEntry(JText::_('Items'), 'index.php?option=com_menus&task=view', true);
JSubMenuHelper::addEntry(JText::_('Menus'), 'index.php?option=com_menus');
if (JFactory::getUser()->authorize('com_trash', 'manage')) {
JSubMenuHelper::addEntry(JText::_('Trash'), 'index.php?option=com_trash&task=viewMenu');
}
$document =& JFactory::getDocument();
$document->setTitle(JText::_('View Menu Items'));
$limitstart = JRequest::getVar('limitstart', '0', '', 'int');
$items =& $this->get('Items');
$pagination =& $this->get('Pagination');
$lists =& $this->_getViewLists();
$user =& JFactory::getUser();
require_once JPATH_COMPONENT . DS . 'helpers' . DS . 'helper.php';
$menus = MenusHelper::getMenuTypelist();
// Ensure ampersands and double quotes are encoded in item titles
foreach ($items as $i => $item) {
$treename = $item->treename;
$treename = JFilterOutput::ampReplace($treename);
$treename = str_replace('"', '"', $treename);
$items[$i]->treename = $treename;
}
//Ordering allowed ?
$ordering = $lists['order'] == 'm.ordering';
JHTML::_('behavior.tooltip');
$this->assignRef('items', $items);
$this->assignRef('pagination', $pagination);
$this->assignRef('lists', $lists);
$this->assignRef('user', $user);
$this->assignRef('menutype', $menutype);
$this->assignRef('ordering', $ordering);
$this->assignRef('limitstart', $limitstart);
$this->assignRef('menus', $menus);
parent::display($tpl);
}
示例10: setConnectionsToolbar
/**
* set up the menu when viewing the list of connections
*/
function setConnectionsToolbar()
{
JToolBarHelper::title(JText::_('CONNECTIONS'), 'fabrik-connection.png');
JToolBarHelper::makeDefault('setdefault');
JToolBarHelper::publishList();
JToolBarHelper::unpublishList();
JToolBarHelper::customX('copy', 'copy.png', 'copy_f2.png', 'Copy');
JToolBarHelper::deleteList();
JToolBarHelper::editListX();
JToolBarHelper::addNewX();
}
示例11: _DEFAULT
function _DEFAULT(&$client)
{
JToolBarHelper::title(JText::_('Template Manager'), 'thememanager');
if ($client->id == '1') {
JToolBarHelper::makeDefault('publish');
} else {
JToolBarHelper::makeDefault();
}
JToolBarHelper::editListX('edit', 'Edit');
//JToolBarHelper::addNew();
JToolBarHelper::help('screen.templates');
}
示例12: display
/**
* Hellos view display method
* @return void
**/
function display($tpl = null)
{
JToolBarHelper::title(JText::_('Saisonliste'), 'generic.png');
JToolBarHelper::makeDefault('setdefault');
JToolBarHelper::deleteList();
JToolBarHelper::editListX();
JToolBarHelper::addNewX();
// Get data from the model
$items =& $this->get('Data');
$this->assignRef('items', $items);
parent::display($tpl);
}
示例13: registerToolbar
public function registerToolbar()
{
JToolBarHelper::title(JText::_('COM_EASYDISCUSS_CATEGORIES_TITLE'), 'category');
JToolBarHelper::custom('home', 'arrow-left', '', JText::_('COM_EASYDISCUSS_TOOLBAR_HOME'), false);
JToolBarHelper::divider();
JToolBarHelper::makeDefault('makeDefault');
JToolBarHelper::divider();
JToolbarHelper::publishList();
JToolbarHelper::unpublishList();
JToolBarHelper::divider();
JToolbarHelper::addNew();
JToolbarHelper::deleteList();
}
示例14: addToolbar
function addToolbar()
{
$group = JRequest::getWord('group', '');
JToolBarHelper::title(JText::_('CONFIGURATION_MANAGER'));
if ($group == 'integrate') {
JToolBarHelper::makeDefault('makedefault');
} elseif ($group == 'permissions') {
JToolBarHelper::addNew('add', 'Add User');
JToolBarHelper::deleteList();
} else {
JToolBarHelper::save();
}
}
示例15: display
/**
* The default method that will display the output of this view which is called by
* Joomla
*
* @param string template Template file name
**/
public function display($tpl = null)
{
if ($this->getLayout() == 'edit') {
$this->_displayEditLayout($tpl);
return;
}
// Set the titlebar text
JToolBarHelper::title(JText::_('COM_COMMUNITY_TEMPLATES'), 'templates');
// Add the necessary buttons
JToolBarHelper::makeDefault('publish');
$this->assign('config', CFactory::getConfig());
$this->assign('templates', $this->getTemplates());
parent::display($tpl);
}