[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/administrator/components/com_finder/src/Field/ -> BranchesField.php (source)

   1  <?php
   2  
   3  /**
   4   * @package     Joomla.Administrator
   5   * @subpackage  com_finder
   6   *
   7   * @copyright   (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
   8   * @license     GNU General Public License version 2 or later; see LICENSE.txt
   9   */
  10  
  11  namespace Joomla\Component\Finder\Administrator\Field;
  12  
  13  use Joomla\CMS\Factory;
  14  use Joomla\CMS\Form\Field\ListField;
  15  use Joomla\CMS\HTML\HTMLHelper;
  16  
  17  // phpcs:disable PSR1.Files.SideEffects
  18  \defined('_JEXEC') or die;
  19  // phpcs:enable PSR1.Files.SideEffects
  20  
  21  /**
  22   * Search Branches field for the Finder package.
  23   *
  24   * @since  3.5
  25   */
  26  class BranchesField extends ListField
  27  {
  28      /**
  29       * The form field type.
  30       *
  31       * @var    string
  32       * @since  3.5
  33       */
  34      protected $type = 'Branches';
  35  
  36      /**
  37       * Method to get the field options.
  38       *
  39       * @return  array  The field option objects.
  40       *
  41       * @since   3.5
  42       */
  43      public function getOptions()
  44      {
  45          Factory::getApplication()->bootComponent('com_finder');
  46  
  47          return HTMLHelper::_('finder.mapslist');
  48      }
  49  }


Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer