当前位置: 首页>>代码示例>>PHP>>正文


PHP JToolBarHelper::trash方法代码示例

本文整理汇总了PHP中JToolBarHelper::trash方法的典型用法代码示例。如果您正苦于以下问题:PHP JToolBarHelper::trash方法的具体用法?PHP JToolBarHelper::trash怎么用?PHP JToolBarHelper::trash使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在JToolBarHelper的用法示例。


在下文中一共展示了JToolBarHelper::trash方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     $state = $this->get('State');
     $canDo = MessagesHelper::getActions();
     JToolBarHelper::title(JText::_('COM_MESSAGES_MANAGER_MESSAGES'), 'inbox.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('message.add');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::publish('messages.publish', 'COM_MESSAGES_TOOLBAR_MARK_AS_READ');
         JToolBarHelper::unpublish('messages.unpublish', 'COM_MESSAGES_TOOLBAR_MARK_AS_UNREAD');
     }
     if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::divider();
         JToolBarHelper::deleteList('', 'messages.delete', 'JTOOLBAR_EMPTY_TRASH');
     } else {
         if ($canDo->get('core.edit.state')) {
             JToolBarHelper::divider();
             JToolBarHelper::trash('messages.trash');
         }
     }
     //JToolBarHelper::addNew('module.add');
     JToolBarHelper::divider();
     $bar = JToolBar::getInstance('toolbar');
     $bar->appendButton('Popup', 'options', 'COM_MESSAGES_TOOLBAR_MY_SETTINGS', 'index.php?option=com_messages&view=config&tmpl=component', 850, 400);
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_messages');
     }
     JToolBarHelper::divider();
     JToolBarHelper::help('JHELP_COMPONENTS_MESSAGING_INBOX');
 }
开发者ID:carmerin,项目名称:cesae-web,代码行数:37,代码来源:view.html.php

示例2: _setToolbar

 /**
  * Display the toolbar
  */
 protected function _setToolbar()
 {
     $state = $this->get('State');
     $canDo = ContentHelper::getActions($state->get('filter.category_id'));
     JToolBarHelper::title(JText::_('Content_Articles_Title'), 'article.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::custom('article.add', 'new.png', 'new_f2.png', 'New', false);
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::custom('article.edit', 'edit.png', 'edit_f2.png', 'Edit', true);
     }
     JToolBarHelper::divider();
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::custom('articles.publish', 'publish.png', 'publish_f2.png', 'Publish', true);
         JToolBarHelper::custom('articles.unpublish', 'unpublish.png', 'unpublish_f2.png', 'Unpublish', true);
         if ($state->get('filter.published') != -1) {
             JToolBarHelper::divider();
             JToolBarHelper::archiveList('articles.archive');
         }
     }
     if ($state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'articles.delete');
     } else {
         if ($canDo->get('core.edit.state')) {
             JToolBarHelper::trash('articles.trash');
         }
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::divider();
         JToolBarHelper::preferences('com_content');
     }
     JToolBarHelper::divider();
     JToolBarHelper::help('screen.content.articles');
 }
开发者ID:joebushi,项目名称:joomla,代码行数:37,代码来源:view.html.php

示例3: _setToolBar

 /**
  * Установки тулбара
  */
 protected function _setToolBar()
 {
     require_once JPATH_COMPONENT . '/helpers/smfaq.php';
     JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
     SmFaqHelper::addSubmenu($this->_name);
     $canDo = SmFaqHelper::getActions($this->state->get('filter.category_id'));
     // Выводим нужные кнопки и заголовок
     JToolBarHelper::title(JText::_('COM_SMFAQ_MANAGER_QUESTIONS'), 'smfaq');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNewX('smfaq.add', 'JTOOLBAR_NEW');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editListX('smfaq.edit', 'JTOOLBAR_EDIT');
     }
     JToolBarHelper::divider();
     JToolBarHelper::custom('smfaqlist.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_PUBLISH', true);
     JToolBarHelper::custom('smfaqlist.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_UNPUBLISH', true);
     JToolBarHelper::divider();
     JToolBarHelper::checkin('smfaqlist.checkin');
     // Замена тулбара карзины на удаление
     if ($this->state->get('filter.published') == -2) {
         JToolBarHelper::deleteList('COM_SMFAQ_YOU_WANT_DELETE_THIS', 'smfaqlist.delete', 'JTOOLBAR_EMPTY_TRASH');
     } else {
         JToolBarHelper::trash('smfaqlist.trash', 'JTOOLBAR_TRASH');
     }
     JToolBarHelper::divider();
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_smfaq');
     }
 }
开发者ID:romuland,项目名称:khparts,代码行数:33,代码来源:view.html.php

示例4: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/faqs.php';
     $state = $this->get('State');
     $canDo = FaqsHelper::getActions($state->get('filter.category_id'));
     $user = JFactory::getUser();
     JToolBarHelper::title(JText::_('COM_FAQS_MANAGER_FAQS'), 'faqs.png');
     if (count($user->getAuthorisedCategories('com_faqs', 'core.create')) > 0) {
         JToolBarHelper::addNew('faq.add');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('faq.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::publish('faqs.publish', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::unpublish('faqs.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::divider();
         JToolBarHelper::archiveList('faqs.archive');
         JToolBarHelper::checkin('faqs.checkin');
     }
     if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'faqs.delete', 'JTOOLBAR_EMPTY_TRASH');
         JToolBarHelper::divider();
     } elseif ($canDo->get('core.edit.state')) {
         JToolBarHelper::trash('faqs.trash');
         JToolBarHelper::divider();
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_faqs');
         JToolBarHelper::divider();
     }
     JToolBarHelper::help('JHELP_COMPONENTS_FAQS_LINKS');
 }
开发者ID:bubujie,项目名称:xixia,代码行数:39,代码来源:view.html.php

示例5: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/fabrik.php';
     $canDo = FabrikHelper::getActions($this->state->get('filter.category_id'));
     JToolBarHelper::title(JText::_('COM_FABRIK_MANAGER_GROUPS'), 'groups.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('group.add', 'JTOOLBAR_NEW');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('group.edit', 'JTOOLBAR_EDIT');
     }
     if ($canDo->get('core.edit.state')) {
         if ($this->state->get('filter.state') != 2) {
             JToolBarHelper::divider();
             JToolBarHelper::custom('groups.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_PUBLISH', true);
             JToolBarHelper::custom('groups.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_UNPUBLISH', true);
         }
     }
     if (JFactory::getUser()->authorise('core.manage', 'com_checkin')) {
         JToolBarHelper::custom('groups.checkin', 'checkin.png', 'checkin_f2.png', 'JTOOLBAR_CHECKIN', true);
     }
     if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'groups.delete', 'JTOOLBAR_EMPTY_TRASH');
     } else {
         if ($canDo->get('core.edit.state')) {
             JToolBarHelper::trash('groups.trash', 'JTOOLBAR_TRASH');
         }
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::divider();
         JToolBarHelper::preferences('com_fabrik');
     }
     JToolBarHelper::divider();
     JToolBarHelper::help('JHELP_COMPONENTS_FABRIK_GROUPS', false, JText::_('JHELP_COMPONENTS_FABRIK_GROUPS'));
 }
开发者ID:romuland,项目名称:khparts,代码行数:40,代码来源:view.html.php

示例6: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     $state = $this->get('State');
     $canDo = ContentHelper::getActions($this->state->get('filter.category_id'));
     JToolBarHelper::title(JText::_('COM_CONTENT_FEATURED_TITLE'), 'featured.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('article.add');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('article.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::publish('articles.publish', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::unpublish('articles.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::divider();
         JToolBarHelper::archiveList('articles.archive');
         JToolBarHelper::checkin('articles.checkin');
         JToolBarHelper::custom('featured.delete', 'remove.png', 'remove_f2.png', 'JTOOLBAR_REMOVE', true);
     }
     if ($state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'articles.delete', 'JTOOLBAR_EMPTY_TRASH');
         JToolBarHelper::divider();
     } elseif ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::trash('articles.trash');
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_content');
         JToolBarHelper::divider();
     }
     JToolBarHelper::help('JHELP_CONTENT_FEATURED_ARTICLES');
 }
开发者ID:acculitx,项目名称:fleetmatrixsite,代码行数:38,代码来源:view.html.php

示例7: display

 /**
  * The default method that will display the output of this view which is called by
  * Joomla
  * 
  * @param	string template	Template file name
  **/
 function display($tpl = null)
 {
     if ($this->getLayout() == 'edit') {
         $this->_displayEditLayout($tpl);
         return;
     }
     // Set the titlebar text
     JToolBarHelper::title(JText::_('CC USERS'), 'users');
     // Add the necessary buttons
     JToolBarHelper::back('Home', 'index.php?option=com_community');
     JToolBarHelper::divider();
     JToolBarHelper::custom('export', 'csv', 'csv', JText::_('CC EXPORT TO CSV'));
     JToolBarHelper::trash('delete', JText::_('CC DELETE'));
     $search = JRequest::getVar('search', '');
     $model =& $this->getModel('Users');
     $users =& $model->getAllUsers();
     $pagination =& $model->getPagination();
     $mainframe =& JFactory::getApplication();
     $filter_order = $mainframe->getUserStateFromRequest("com_community.users.filter_order", 'filter_order', 'a.name', 'cmd');
     $filter_order_Dir = $mainframe->getUserStateFromRequest("com_community.users.filter_order_Dir", 'filter_order_Dir', '', 'word');
     // table ordering
     $lists['order_Dir'] = $filter_order_Dir;
     $lists['order'] = $filter_order;
     // Load tooltips
     JHTML::_('behavior.tooltip', '.hasTip');
     $usertype = JRequest::getVar('usertype', 'all', 'POST');
     $this->assignRef('search', $search);
     $this->assignRef('usertype', $usertype);
     $this->assignRef('users', $users);
     $this->assignRef('lists', $lists);
     $this->assignRef('pagination', $pagination);
     parent::display($tpl);
 }
开发者ID:bizanto,项目名称:Hooked,代码行数:39,代码来源:view.html.php

示例8: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/banners.php';
     $canDo = BannersHelper::getActions();
     JToolBarHelper::title(JText::_('COM_BANNERS_MANAGER_CLIENTS'), 'banners-clients.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('client.add');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('client.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::publish('clients.publish', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::unpublish('clients.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::divider();
         JToolBarHelper::archiveList('clients.archive');
         JToolBarHelper::checkin('clients.checkin');
     }
     if ($this->state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'clients.delete', 'JTOOLBAR_EMPTY_TRASH');
         JToolBarHelper::divider();
     } elseif ($canDo->get('core.edit.state')) {
         JToolBarHelper::trash('clients.trash');
         JToolBarHelper::divider();
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_banners');
         JToolBarHelper::divider();
     }
     JToolBarHelper::help('JHELP_COMPONENTS_BANNERS_CLIENTS');
 }
开发者ID:acculitx,项目名称:fleetmatrixsite,代码行数:37,代码来源:view.html.php

示例9: 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)
 {
     $mainframe = JFactory::getApplication();
     $jinput = $mainframe->input;
     $search = $mainframe->getUserStateFromRequest("com_community.videos.search", 'search', '', 'string');
     // Set the titlebar text
     JToolBarHelper::title(JText::_('COM_COMMUNITY_PHOTOS'), 'photos');
     // Add the necessary buttons
     JToolBarHelper::trash('delete', JText::_('COM_COMMUNITY_DELETE'));
     JToolBarHelper::publishList('publish', JText::_('COM_COMMUNITY_PUBLISH'));
     JToolBarHelper::unpublishList('unpublish', JText::_('COM_COMMUNITY_UNPUBLISH'));
     $photos = $this->get('Photos');
     $pagination = $this->get('Pagination');
     foreach ($photos as $key => $val) {
         $pTable = JTable::getInstance('Photo', 'CTable');
         $pTable->load($val->pid);
         $photos[$key] = $pTable;
         $photos[$key]->albumName = $val->name;
     }
     $this->assignRef('photos', $photos);
     $this->assignRef('pagination', $pagination);
     $this->assignRef('search', $search);
     //var_dump($photos);
     parent::display($tpl);
 }
开发者ID:joshjim27,项目名称:jobsglobal,代码行数:31,代码来源:view.html.php

示例10: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/banners.php';
     $canDo = BannersHelper::getActions();
     JToolBarHelper::title(JText::_('COM_BANNERS_MANAGER_CLIENTS'), 'banners-clients.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('client.add', 'JTOOLBAR_NEW');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('client.edit', 'JTOOLBAR_EDIT');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::custom('clients.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::custom('clients.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::divider();
         JToolBarHelper::archiveList('clients.archive', 'JTOOLBAR_ARCHIVE');
         JToolBarHelper::custom('clients.checkin', 'checkin.png', 'checkin_f2.png', 'JTOOLBAR_CHECKIN', true);
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::trash('clients.trash', 'JTOOLBAR_TRASH');
     }
     if ($canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'clients.delete', 'JTOOLBAR_EMPTY_TRASH');
         JToolBarHelper::divider();
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_banners');
         JToolBarHelper::divider();
     }
     JToolBarHelper::help('JHELP_COMPONENTS_BANNERS_CLIENTS');
 }
开发者ID:akksi,项目名称:jcg,代码行数:37,代码来源:view.html.php

示例11: _setToolbar

 /**
  * Setup the Toolbar.
  */
 protected function _setToolbar()
 {
     $state = $this->get('State');
     $canDo = MessagesHelper::getActions();
     JToolBarHelper::title(JText::_('Messages_Manager_Messages'), 'inbox.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('message.add');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::custom('messages.publish', 'publish.png', 'publish_f2.png', 'Messages_Toolbar_Publish', true);
         JToolBarHelper::custom('messages.unpublish', 'unpublish.png', 'unpublish_f2.png', 'Messages_Toolbar_UnPublish', true);
     }
     if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'messages.delete');
     } else {
         if ($canDo->get('core.edit.state')) {
             JToolBarHelper::trash('messages.trash');
         }
     }
     //JToolBarHelper::addNew('module.add');
     $bar =& JToolBar::getInstance('toolbar');
     $bar->appendButton('Popup', 'config', 'Messages_Toolbar_My_Settings', 'index.php?option=com_messages&view=config&tmpl=component', 850, 400);
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_messages');
     }
     JToolBarHelper::help('screen.messages.inbox');
 }
开发者ID:joebushi,项目名称:joomla,代码行数:30,代码来源:view.html.php

示例12: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/localize_empresa.php';
     $state = $this->get('State');
     $canDo = Localize_empresaHelper::getActions($state->get('filter.category_id'));
     JToolBarHelper::title(JText::_('COM_LOCALIZE_EMPRESA_TITLE_CADASTRODEEMPRESAS'), 'cadastrodeempresas.png');
     //Check if the form exists before showing the add/edit buttons
     $formPath = JPATH_COMPONENT_ADMINISTRATOR . '/views/cadastrodeempresa';
     if (file_exists($formPath)) {
         if ($canDo->get('core.create')) {
             JToolBarHelper::addNew('cadastrodeempresa.add', 'JTOOLBAR_NEW');
         }
         if ($canDo->get('core.edit') && isset($this->items[0])) {
             JToolBarHelper::editList('cadastrodeempresa.edit', 'JTOOLBAR_EDIT');
         }
     }
     if ($canDo->get('core.edit.state')) {
         if (isset($this->items[0]->state)) {
             JToolBarHelper::divider();
             JToolBarHelper::custom('cadastrodeempresas.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_PUBLISH', true);
             JToolBarHelper::custom('cadastrodeempresas.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_UNPUBLISH', true);
         } else {
             if (isset($this->items[0])) {
                 //If this component does not use state then show a direct delete button as we can not trash
                 JToolBarHelper::deleteList('', 'cadastrodeempresas.delete', 'JTOOLBAR_DELETE');
             }
         }
         if (isset($this->items[0]->state)) {
             JToolBarHelper::divider();
             JToolBarHelper::archiveList('cadastrodeempresas.archive', 'JTOOLBAR_ARCHIVE');
         }
         if (isset($this->items[0]->checked_out)) {
             JToolBarHelper::custom('cadastrodeempresas.checkin', 'checkin.png', 'checkin_f2.png', 'JTOOLBAR_CHECKIN', true);
         }
     }
     //Show trash and delete for components that uses the state field
     if (isset($this->items[0]->state)) {
         if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
             JToolBarHelper::deleteList('', 'cadastrodeempresas.delete', 'JTOOLBAR_EMPTY_TRASH');
             JToolBarHelper::divider();
         } else {
             if ($canDo->get('core.edit.state')) {
                 JToolBarHelper::trash('cadastrodeempresas.trash', 'JTOOLBAR_TRASH');
                 JToolBarHelper::divider();
             }
         }
     }
     if ($canDo->get('core.admin')) {
         JToolBarHelper::preferences('com_localize_empresa');
     }
     //Set sidebar action - New in 3.0
     JHtmlSidebar::setAction('index.php?option=com_localize_empresa&view=cadastrodeempresas');
     $this->extra_sidebar = '';
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_published', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions'), "value", "text", $this->state->get('filter.state'), true));
     //Filter for the field corretores
     $this->extra_sidebar .= '<div class="other-filters">';
     $this->extra_sidebar .= '<small><label for="filter_corretores">Corretores</label></small>';
     $this->extra_sidebar .= JHtmlList::users('filter_corretores', $this->state->get('filter.corretores'), 1, 'onchange="this.form.submit();"');
     $this->extra_sidebar .= '</div>';
 }
开发者ID:IFGO,项目名称:localize,代码行数:65,代码来源:view.html.php

示例13: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since	1.6
  */
 protected function addToolbar()
 {
     require_once JPATH_COMPONENT . '/helpers/j2xml.php';
     $canDo = J2XMLHelper::getActions();
     $doc = JFactory::getDocument();
     $icon_48_websites = " .icon-48-websites {background:url(../media/com_j2xml/images/icon-48-websites.png) no-repeat; }";
     $doc->addStyleDeclaration($icon_48_websites);
     JToolBarHelper::title(JText::_('COM_J2XML_MANAGER_WEBSITES'), 'websites.png');
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('website.add');
     }
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('website.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::divider();
         JToolBarHelper::publish('websites.publish', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::unpublish('websites.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::divider();
         JToolBarHelper::checkin('websites.checkin');
     }
     if ($this->state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('', 'websites.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolBarHelper::trash('websites.trash');
     }
 }
开发者ID:kleinhelmi,项目名称:tus03_j3_2015_01,代码行数:32,代码来源:view.html.php

示例14: _setToolbar

 /**
  * Display the toolbar
  */
 protected function _setToolbar()
 {
     $state = $this->get('State');
     $extension = $state->get('filter.extension');
     // Need to load the menu language file as mod_menu hasn't been loaded yet.
     $lang =& JFactory::getLanguage();
     $lang->load($extension . '.menu', JPATH_ADMINISTRATOR . '/components/' . $extension);
     $lang->load($extension . '.menu');
     JToolBarHelper::title(JText::sprintf('Categories_Categories_Title', $this->escape(JText::_($extension))), 'categories.png');
     JToolBarHelper::custom('category.edit', 'new.png', 'new_f2.png', 'New', false);
     JToolBarHelper::custom('category.edit', 'edit.png', 'edit_f2.png', 'Edit', true);
     JToolBarHelper::divider();
     JToolBarHelper::custom('categories.publish', 'publish.png', 'publish_f2.png', 'Publish', true);
     JToolBarHelper::custom('categories.unpublish', 'unpublish.png', 'unpublish_f2.png', 'Unpublish', true);
     if ($state->get('filter.published') != -1) {
         JToolBarHelper::divider();
         JToolBarHelper::archiveList('categories.archive');
     }
     if ($state->get('filter.published') == -2) {
         JToolBarHelper::deleteList('', 'categories.delete');
     } else {
         JToolBarHelper::trash('categories.trash');
     }
     JToolBarHelper::divider();
     JToolBarHelper::custom('categories.rebuild', 'refresh.png', 'refresh_f2.png', 'JToolbar_Rebuild', false);
     JToolBarHelper::divider();
     JToolBarHelper::help('screen.categories');
 }
开发者ID:joebushi,项目名称:joomla,代码行数:31,代码来源:view.html.php

示例15: addToolbar

 /**
  * Add Toolbar
  */
 protected function addToolbar()
 {
     JToolBarHelper::title(JText::_('COM_JEM_EVENTS'), 'events');
     /* retrieving the allowed actions for the user */
     $canDo = JEMHelperBackend::getActions(0);
     /* create */
     if ($canDo->get('core.create')) {
         JToolBarHelper::addNew('event.add');
     }
     /* edit */
     if ($canDo->get('core.edit')) {
         JToolBarHelper::editList('event.edit');
         JToolBarHelper::divider();
     }
     /* state */
     if ($canDo->get('core.edit.state')) {
         JToolBarHelper::publishList('events.publish', 'JTOOLBAR_PUBLISH', true);
         JToolBarHelper::unpublishList('events.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolBarHelper::custom('events.featured', 'featured.png', 'featured_f2.png', 'JFEATURED', true);
         JToolBarHelper::archiveList('events.archive');
         JToolBarHelper::checkin('events.checkin');
     }
     if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolBarHelper::deleteList('COM_JEM_CONFIRM_DELETE', 'events.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolBarHelper::trash('events.trash');
     }
     JToolBarHelper::divider();
     JToolBarHelper::help('listevents', true);
 }
开发者ID:JKoelman,项目名称:JEM-3,代码行数:33,代码来源:view.html.php


注:本文中的JToolBarHelper::trash方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。