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


PHP JToolbarHelper::addNew方法代码示例

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


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

示例1: addToolBar

 protected function addToolBar()
 {
     $state = $this->get('State');
     $canDo = JHelperContent::getActions('com_sppagebuilder');
     // return user permission status
     $user = JFactory::getUser();
     $bar = JToolBar::getInstance('toolbar');
     JToolBarHelper::title(JText::_('Page Builder'));
     // new page button
     if ($canDo->get('core.create')) {
         JToolbarHelper::addNew('page.add');
     }
     // edit button
     if ($canDo->get('core.edit')) {
         JToolbarHelper::editList('page.edit');
     }
     // publish and unpublish button
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::publish('pages.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('pages.unpublish', 'JTOOLBAR_UNPUBLISH', true);
     }
     // delete and trush button
     if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'pages.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('pages.trash');
     }
     JHtmlSidebar::setAction('index.php?option=com_sppagebuilder&view=pages');
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_published', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions', array('archived' => false)), 'value', 'text', $this->state->get('filter.published'), true));
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_ACCESS'), 'filter_access', JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access')));
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_LANGUAGE'), 'filter_language', JHtml::_('select.options', JHtml::_('contentlanguage.existing', true, true), 'value', 'text', $this->state->get('filter.language')));
 }
开发者ID:ranrolls,项目名称:ras-full-portal,代码行数:32,代码来源:view.html.php

示例2: addToolbar

 /**
  * Method to configure the toolbar for this view.
  *
  * @return  void
  *
  * @since   2.5
  */
 protected function addToolbar()
 {
     $canDo = FinderHelper::getActions();
     JToolbarHelper::title(JText::_('COM_FINDER_FILTERS_TOOLBAR_TITLE'), 'finder');
     $toolbar = JToolbar::getInstance('toolbar');
     if ($canDo->get('core.create')) {
         JToolbarHelper::addNew('filter.add');
         JToolbarHelper::editList('filter.edit');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::publishList('filters.publish');
         JToolbarHelper::unpublishList('filters.unpublish');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'filters.delete');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_finder');
     }
     JToolbarHelper::divider();
     $toolbar->appendButton('Popup', 'stats', 'COM_FINDER_STATISTICS', 'index.php?option=com_finder&view=statistics&tmpl=component', 550, 350);
     JToolbarHelper::divider();
     JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_SEARCH_FILTERS');
     JHtmlSidebar::setAction('index.php?option=com_finder&view=filters');
     JHtmlSidebar::addFilter(JText::_('COM_FINDER_INDEX_FILTER_BY_STATE'), 'filter_state', JHtml::_('select.options', JHtml::_('finder.statelist'), 'value', 'text', $this->state->get('filter.state')));
 }
开发者ID:interfaceslivres,项目名称:ccmd-ufpb,代码行数:36,代码来源:view.html.php

示例3: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @return  void
  *
  * @since   1.6
  */
 protected function addToolbar()
 {
     $state = $this->get('State');
     $canDo = JHelperContent::getActions('com_content', 'category', $this->state->get('filter.category_id'));
     JToolbarHelper::title(JText::_('COM_CONTENT_FEATURED_TITLE'), 'star featured');
     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::publish('articles.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('articles.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolbarHelper::custom('articles.unfeatured', 'unfeatured.png', 'featured_f2.png', 'JUNFEATURE', true);
         JToolbarHelper::archiveList('articles.archive');
         JToolbarHelper::checkin('articles.checkin');
     }
     if ($state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'articles.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('articles.trash');
     }
     if ($canDo->get('core.admin') || $canDo->get('core.options')) {
         JToolbarHelper::preferences('com_content');
     }
     JToolbarHelper::help('JHELP_CONTENT_FEATURED_ARTICLES');
 }
开发者ID:deenison,项目名称:joomla-cms,代码行数:35,代码来源:view.html.php

示例4: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @return  void
  *
  * @since   1.6
  */
 protected function addToolbar()
 {
     $state = $this->get('State');
     $canDo = JHelperContent::getActions('com_messages');
     JToolbarHelper::title(JText::_('COM_MESSAGES_MANAGER_MESSAGES'), 'envelope inbox');
     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', true);
         JToolbarHelper::unpublish('messages.unpublish', 'COM_MESSAGES_TOOLBAR_MARK_AS_UNREAD', true);
     }
     JToolbarHelper::divider();
     $bar = JToolBar::getInstance('toolbar');
     // Instantiate a new JLayoutFile instance and render the layout
     JHtml::_('behavior.modal', 'a.messagesSettings');
     $layout = new JLayoutFile('toolbar.mysettings');
     $bar->appendButton('Custom', $layout->render(array()), 'upload');
     if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::divider();
         JToolbarHelper::deleteList('', 'messages.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::divider();
         JToolbarHelper::trash('messages.trash');
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_messages');
     }
     JToolbarHelper::divider();
     JToolbarHelper::help('JHELP_COMPONENTS_MESSAGING_INBOX');
 }
开发者ID:grlf,项目名称:eyedock,代码行数:39,代码来源:view.html.php

示例5: addToolbar

 protected function addToolbar()
 {
     $canDo = JHelperContent::getActions('com_jvisualcontent');
     $user = JFactory::getUser();
     JToolbarHelper::title(JText::_('COM_JVISUALCONTENT_EXTRAFIELDS_MANAGER'));
     // Create new button
     if ($canDo->get('core.create')) {
         JToolbarHelper::addNew('extrafield.add');
         JToolbarHelper::divider();
     }
     // Create edit button
     if ($canDo->get('core.edit') || $canDo->get('core.edit.own')) {
         JToolbarHelper::editList('type.edit');
     }
     // Create publish, unpublish buttons
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::publish('extrafields.publish');
         JToolbarHelper::unpublish('extrafields.unpublish');
         JToolbarHelper::divider();
     }
     if ($this->state->get('filter.published') == -2 && $user->authorise('core.delete')) {
         JToolbarHelper::deleteList('', 'extrafields.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('extrafields.trash');
     }
     // Create options button
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_jvisualcontent');
     }
     if (version_compare(JVERSION, '3.0', '>=')) {
         $fieldsType = array('textfield' => JText::_('COM_JVISUALCONTENT_TEXT_FIELD'), 'textarea' => JText::_('COM_JVISUALCONTENT_TEXTAREA'), 'select' => JText::_('COM_JVISUALCONTENT_DROPDOWN_SELECT'), 'multiselect' => JText::_('COM_JVISUALCONTENT_DROPDOWN_LIST'), 'radio' => JText::_('COM_JVISUALCONTENT_RADIO'), 'checkbox' => JText::_('COM_JVISUALCONTENT_CHECKBOX'), 'editor' => JText::_('COM_JVISUALCONTENT_EDITOR'), 'calendar' => JText::_('COM_JVISUALCONTENT_CALENDAR'), 'file' => JText::_('COM_JVISUALCONTENT_FILE'));
         JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_published', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions', array('archived' => false)), 'value', 'text', $this->state->get('filter.published'), true));
         JHtmlSidebar::addFilter(JText::_('COM_JVISUALCONTENT_OPTION_SELECT_TYPE'), 'filter_type', JHtml::_('select.options', $fieldsType, 'value', 'text', $this->state->get('filter.type')));
     }
 }
开发者ID:Glonum,项目名称:tz_portfolio,代码行数:35,代码来源:view.html.php

示例6: addToolbar

 /**
  * Adds the page title and toolbar.
  *
  * @return  void
  *
  * @since   2.5
  */
 protected function addToolbar()
 {
     // Get the results for each action
     $canDo = JHelperContent::getActions('com_languages');
     JToolbarHelper::title(JText::_('COM_LANGUAGES_VIEW_OVERRIDES_TITLE'), 'comments-2 langmanager');
     if ($canDo->get('core.create')) {
         JToolbarHelper::addNew('override.add');
     }
     if ($canDo->get('core.edit') && $this->pagination->total) {
         JToolbarHelper::editList('override.edit');
     }
     if ($canDo->get('core.delete') && $this->pagination->total) {
         JToolbarHelper::deleteList('JGLOBAL_CONFIRM_DELETE', 'overrides.delete', 'JTOOLBAR_DELETE');
     }
     if (JFactory::getUser()->authorise('core.admin')) {
         JToolbarHelper::custom('overrides.purge', 'refresh.png', 'refresh_f2.png', 'COM_LANGUAGES_VIEW_OVERRIDES_PURGE', false);
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_languages');
     }
     JToolbarHelper::divider();
     JToolbarHelper::help('JHELP_EXTENSIONS_LANGUAGE_MANAGER_OVERRIDES');
     JHtmlSidebar::setAction('index.php?option=com_languages&view=overrides');
     JHtmlSidebar::addFilter('', 'filter_language_client', JHtml::_('select.options', $this->languages, null, 'text', $this->state->get('filter.language_client')), true);
     $this->sidebar = JHtmlSidebar::render();
 }
开发者ID:adjaika,项目名称:J3Base,代码行数:33,代码来源:view.html.php

示例7: addToolbar

 /**
  * Method to configure the toolbar for this view.
  *
  * @return  void
  *
  * @since   2.5
  */
 protected function addToolbar()
 {
     $canDo = JHelperContent::getActions('com_finder');
     JToolbarHelper::title(JText::_('COM_FINDER_FILTERS_TOOLBAR_TITLE'), 'zoom-in finder');
     $toolbar = JToolbar::getInstance('toolbar');
     if ($canDo->get('core.create')) {
         JToolbarHelper::addNew('filter.add');
         JToolbarHelper::editList('filter.edit');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::publishList('filters.publish');
         JToolbarHelper::unpublishList('filters.unpublish');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.admin') || $canDo->get('core.options')) {
         JToolbarHelper::preferences('com_finder');
     }
     JToolbarHelper::divider();
     $toolbar->appendButton('Popup', 'bars', 'COM_FINDER_STATISTICS', 'index.php?option=com_finder&view=statistics&tmpl=component', 550, 350);
     JToolbarHelper::divider();
     JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_SEARCH_FILTERS');
     if ($canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'filters.delete');
         JToolbarHelper::divider();
     }
 }
开发者ID:brenot,项目名称:forumdesenvolvimento,代码行数:34,代码来源:view.html.php

示例8: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @return  void
  *
  * @since   1.6
  */
 protected function addToolbar()
 {
     $canDo = JHelperContent::getActions('com_banners');
     JToolbarHelper::title(JText::_('COM_BANNERS_MANAGER_CLIENTS'), 'bookmark banners-clients');
     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::publish('clients.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('clients.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolbarHelper::archiveList('clients.archive');
         JToolbarHelper::checkin('clients.checkin');
     }
     if ($this->state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::deleteList('JGLOBAL_CONFIRM_DELETE', 'clients.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('clients.trash');
     }
     if ($canDo->get('core.admin') || $canDo->get('core.options')) {
         JToolbarHelper::preferences('com_banners');
     }
     JToolbarHelper::help('JHELP_COMPONENTS_BANNERS_CLIENTS');
 }
开发者ID:ITPrism,项目名称:GamificationDistribution,代码行数:33,代码来源:view.html.php

示例9: addToolbar

 /**
  * Add the toolbar and toolbar title.
  *
  * @access  protected
  * @return  void
  *
  * @since 2.0
  */
 protected function addToolbar()
 {
     // Get the results for each action
     $canDo = JoomHelper::getActions();
     JToolBarHelper::title(JText::_('COM_JOOMGALLERY_CATMAN_CATEGORY_MANAGER'), 'folder');
     if ($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.create') || count(JoomHelper::getAuthorisedCategories('core.create'))) {
         JToolbarHelper::addNew('new');
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.edit') || count(JoomHelper::getAuthorisedCategories('core.edit'))) && $this->pagination->total) {
         JToolbarHelper::editList('edit');
         JHtml::_('bootstrap.modal', 'collapseModal');
         $title = JText::_('JTOOLBAR_BATCH');
         $dhtml = "<button data-toggle=\"modal\" data-target=\"#collapseModal\" class=\"btn btn-small\">\n                  <i class=\"icon-checkbox-partial\" title=\"{$title}\"></i>\n                  {$title}</button>";
         JToolBar::getInstance('toolbar')->appendButton('Custom', $dhtml, 'batch');
         JToolbarHelper::divider();
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || count(JoomHelper::getAuthorisedCategories('core.edit.state'))) && $this->pagination->total) {
         JToolbarHelper::publishList('publish', JText::_('COM_JOOMGALLERY_COMMON_PUBLISH'));
         JToolbarHelper::unpublishList('unpublish', JText::_('COM_JOOMGALLERY_COMMON_UNPUBLISH'));
         JToolbarHelper::divider();
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.delete') || count(JoomHelper::getAuthorisedCategories('core.delete'))) && $this->pagination->total) {
         JToolbarHelper::deleteList('', 'remove');
         JToolbarHelper::divider();
     }
 }
开发者ID:pabloarias,项目名称:JoomGallery,代码行数:34,代码来源:view.html.php

示例10: addToolbar

 /**
  * Add the toolbar and toolbar title.
  *
  * @access  protected
  * @return  void
  *
  * @since 2.0
  */
 protected function addToolbar()
 {
     // Get the results for each action
     $canDo = JoomHelper::getActions();
     JToolBarHelper::title(JText::_('COM_JOOMGALLERY_CATMAN_CATEGORY_MANAGER'), 'folder');
     if ($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.create') || count(JoomHelper::getAuthorisedCategories('core.create'))) {
         JToolbarHelper::addNew('new');
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.edit') || count(JoomHelper::getAuthorisedCategories('core.edit'))) && $this->pagination->total) {
         JToolbarHelper::editList('edit');
         JHtml::_('bootstrap.modal', 'collapseModal');
         $title = JText::_('JTOOLBAR_BATCH');
         $dhtml = "<button data-toggle=\"modal\" data-target=\"#collapseModal\" class=\"btn btn-small\">\n                  <i class=\"icon-checkbox-partial\" title=\"{$title}\"></i>\n                  {$title}</button>";
         JToolBar::getInstance('toolbar')->appendButton('Custom', $dhtml, 'batch');
         JToolbarHelper::divider();
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || count(JoomHelper::getAuthorisedCategories('core.edit.state'))) && $this->pagination->total) {
         JToolbarHelper::publishList('publish', JText::_('COM_JOOMGALLERY_COMMON_PUBLISH'));
         JToolbarHelper::unpublishList('unpublish', JText::_('COM_JOOMGALLERY_COMMON_UNPUBLISH'));
         JToolbarHelper::divider();
     }
     if (($this->_config->get('jg_disableunrequiredchecks') || $canDo->get('core.delete') || count(JoomHelper::getAuthorisedCategories('core.delete'))) && $this->pagination->total) {
         JToolbarHelper::deleteList('', 'remove');
         JToolbarHelper::divider();
     }
     $options = array(JHtml::_('select.option', 1, JText::_('COM_JOOMGALLERY_COMMON_OPTION_PUBLISHED_ONLY')), JHtml::_('select.option', 0, JText::_('COM_JOOMGALLERY_COMMON_OPTION_NOT_PUBLISHED_ONLY')));
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_published', JHtml::_('select.options', $options, 'value', 'text', $this->state->get('filter.published'), true));
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_ACCESS'), 'filter_access', JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access')));
     $options = array(JHtml::_('select.option', 1, JText::_('COM_JOOMGALLERY_CATMAN_OPTION_USERCATEGORIES_ONLY')), JHtml::_('select.option', 2, JText::_('COM_JOOMGALLERY_CATMAN_OPTION_BACKENDCATEGORIES_ONLY')));
     JHtmlSidebar::addFilter(JText::_('COM_JOOMGALLERY_COMMON_OPTION_SELECT_TYPE'), 'filter_type', JHtml::_('select.options', $options, 'value', 'text', $this->state->get('filter.type'), true));
 }
开发者ID:naka211,项目名称:kkvn,代码行数:39,代码来源:view.html.php

示例11: addToolbar

 /**
  * Add the page title and toolbar.
  *
  * @since    1.7.0
  *
  * @return void
  */
 protected function addToolbar()
 {
     $canDo = ChurchDirectoryHelper::getActions('com_churchdirectory', 'familyunit');
     $user = JFactory::getUser();
     JToolbarHelper::title(JText::_('COM_CHURCHDIRECTORY_MANAGER_FAMILYUNITS'), 'churchdirectory');
     if ($canDo->get('core.create') || count($user->getAuthorisedCategories('com_churchdirectory', 'core.create')) > 0) {
         JToolbarHelper::addNew('familyunit.add');
     }
     if ($canDo->get('core.edit') || $canDo->get('core.edit.own')) {
         JToolbarHelper::editList('familyunit.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::divider();
         JToolbarHelper::publish('familyunits.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('familyunits.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolbarHelper::divider();
         JToolbarHelper::checkin('familyunits.checkin');
     }
     if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'familyunits.delete', 'JTOOLBAR_EMPTY_TRASH');
         JToolbarHelper::divider();
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('familyunits.trash');
         JToolbarHelper::divider();
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_churchdirectory');
         JToolbarHelper::divider();
     }
     JToolbarHelper::help('churchdirectory_familyunit', true);
     JHtmlSidebar::setAction('index.php?option=com_churchdirectory&amp;view=familyunits');
 }
开发者ID:Joomla-Bible-Study,项目名称:joomla_churchdirectory,代码行数:39,代码来源:view.html.php

示例12: 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::publish('clients.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('clients.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         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');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('clients.trash');
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_banners');
     }
     JToolbarHelper::help('JHELP_COMPONENTS_BANNERS_CLIENTS');
     JHtmlSidebar::setAction('index.php?option=com_banners&view=clients');
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_state', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter.state'), true));
 }
开发者ID:fur81,项目名称:zofaxiopeu,代码行数:34,代码来源:view.html.php

示例13: addToolbar

 protected function addToolbar()
 {
     $canDo = ReservaHelper::getActions();
     $bar = JToolBar::getInstance('toolbar');
     JToolbarHelper::title(JText::_('COM_RESERVA_MANAGER_EVENTOS'), '');
     JToolbarHelper::addNew('evento.add');
     if ($canDo->get('core.edit')) {
         JToolbarHelper::editList('evento.edit');
     }
     if ($canDo->get('core.edit.state')) {
         JToolbarHelper::publish('eventos.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('eventos.unpublish', 'JTOOLBAR_UNPUBLISH', true);
         JToolbarHelper::archiveList('eventos.archive');
         JToolbarHelper::checkin('eventos.checkin');
     }
     //agregar filtro a la vista para busqueda
     JHtmlSidebar::setAction('index.php?option=com_reserva&view=eventos');
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_state', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter.state'), true));
     /*
     if ($canDo->get('core.delete'))
     {
     	JToolBarHelper::deleteList('', 'eventos.delete', 'JTOOLBAR_DELETE');
     }
     se replaza el boton de borrado por envio a la papelera en vez de borrado completamente
     */
     $state = $this->get('State');
     if ($state->get('filter.state') == -2 && $canDo->get('core.delete')) {
         JToolbarHelper::deleteList('', 'eventos.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($canDo->get('core.edit.state')) {
         JToolbarHelper::trash('eventos.trash');
     }
     if ($canDo->get('core.admin')) {
         JToolbarHelper::preferences('com_reserva');
     }
 }
开发者ID:sebarigonatto,项目名称:j3reserva,代码行数:35,代码来源:view.html.php

示例14: addToolBar

 /**
  * Setting the toolbar
  */
 public function addToolBar()
 {
     $user = JFactory::getUser();
     JToolbarHelper::title(JText::_('COM_ALFCONTACT_MANAGER_ALFCONTACTS'), 'alfcontact');
     if ($user->authorise('core.create')) {
         JToolbarHelper::addNew('alfcontact.add');
     }
     if ($user->authorise('core.edit') || $user->authorise('core.edit.own')) {
         JToolbarHelper::editList('alfcontact.edit');
     }
     if ($user->authorise('core.edit.state')) {
         JToolbarHelper::publish('alfcontacts.publish', 'JTOOLBAR_PUBLISH', true);
         JToolbarHelper::unpublish('alfcontacts.unpublish', 'JTOOLBAR_UNPUBLISH', true);
     }
     if ($this->state->get('filter.published') == -2 && $user->authorise('core.delete')) {
         JToolbarHelper::deleteList('', 'alfcontacts.delete', 'JTOOLBAR_EMPTY_TRASH');
     } elseif ($user->authorise('core.edit.state')) {
         JToolbarHelper::trash('alfcontacts.trash');
     }
     // Options button.
     if ($user->authorise('core.admin')) {
         JToolBarHelper::preferences('com_alfcontact');
     }
     JToolbarHelper::help('JHELP_COMPONENTS_ALFCONTACT_CONTACTS');
     JHtmlSidebar::setAction('index.php?option=com_alfcontact&view=alfcontacts');
     JHtmlSideBar::addFilter(JText::_('JOPTION_SELECT_PUBLISHED'), 'filter_published', JHtml::_('select.options', JHtml::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter.published'), true));
     JHtmlSideBar::addFilter(JText::_('JOPTION_SELECT_ACCESS'), 'filter_access', JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access')));
     JHtmlSidebar::addFilter(JText::_('JOPTION_SELECT_LANGUAGE'), 'filter_language', JHtml::_('select.options', JHtml::_('contentlanguage.existing', true, true), 'value', 'text', $this->state->get('filter.language')));
 }
开发者ID:grlf,项目名称:eyedock,代码行数:32,代码来源:view.html.php

示例15: addToolBar

 public function addToolBar()
 {
     JToolbarHelper::title(JText::_('COM_JOOMLAHAXE_JOOMLAHAXE_VIEW_DEFAULT_TITLE'), null);
     JToolbarHelper::deleteList("", "joomlahaxes.delete", "Delete");
     JToolbarHelper::editList("joomlahaxe.edit", "Edit");
     JToolbarHelper::addNew("joomlahaxe.add", "New", null);
 }
开发者ID:ConfidantCommunications,项目名称:JoomlaHaxe,代码行数:7,代码来源:JoomlahaxeViewJoomlahaxes.class.php


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