Source for file groups.php

Documentation is available at groups.php

  1. <?php
  2. /**
  3.  * @package     Joomla.Administrator
  4.  * @subpackage  com_users
  5.  *
  6.  * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
  7.  * @license     GNU General Public License version 2 or later; see LICENSE.txt
  8.  */
  9.  
  10. defined('_JEXEC'or die;
  11.  
  12. /**
  13.  * User groups list controller class.
  14.  *
  15.  * @package     Joomla.Administrator
  16.  * @subpackage  com_users
  17.  * @since       1.6
  18.  */
  19. {
  20.     /**
  21.      * @var        string    The prefix to use with controller messages.
  22.      * @since   1.6
  23.      */
  24.     protected $text_prefix = 'COM_USERS_GROUPS';
  25.  
  26.     /**
  27.      * Proxy for getModel.
  28.      *
  29.      * @since   1.6
  30.      */
  31.     public function getModel($name 'Group'$prefix 'UsersModel'$config array())
  32.     {
  33.         return parent::getModel($name$prefixarray('ignore_request' => true));
  34.     }
  35.  
  36.     /**
  37.      * Removes an item.
  38.      *
  39.      * Overrides JControllerAdmin::delete to check the core.admin permission.
  40.      *
  41.      * @since   1.6
  42.      */
  43.     public function delete()
  44.     {
  45.         if (!JFactory::getUser()->authorise('core.admin'$this->option))
  46.         {
  47.             JError::raiseError(500JText::_('JERROR_ALERTNOAUTHOR'));
  48.             jexit();
  49.         }
  50.  
  51.         return parent::delete();
  52.     }
  53.  
  54.     /**
  55.      * Method to publish a list of records.
  56.      *
  57.      * Overrides JControllerAdmin::publish to check the core.admin permission.
  58.      *
  59.      * @since   1.6
  60.      */
  61.     public function publish()
  62.     {
  63.         if (!JFactory::getUser()->authorise('core.admin'$this->option))
  64.         {
  65.             JError::raiseError(500JText::_('JERROR_ALERTNOAUTHOR'));
  66.             jexit();
  67.         }
  68.  
  69.         return parent::publish();
  70.     }
  71.  
  72.     /**
  73.      * Changes the order of one or more records.
  74.      *
  75.      * Overrides JControllerAdmin::reorder to check the core.admin permission.
  76.      *
  77.      * @since   1.6
  78.      */
  79.     public function reorder()
  80.     {
  81.         if (!JFactory::getUser()->authorise('core.admin'$this->option))
  82.         {
  83.             JError::raiseError(500JText::_('JERROR_ALERTNOAUTHOR'));
  84.             jexit();
  85.         }
  86.  
  87.         return parent::reorder();
  88.     }
  89.  
  90.     /**
  91.      * Method to save the submitted ordering values for records.
  92.      *
  93.      * Overrides JControllerAdmin::saveorder to check the core.admin permission.
  94.      *
  95.      * @since   1.6
  96.      */
  97.     public function saveorder()
  98.     {
  99.         if (!JFactory::getUser()->authorise('core.admin'$this->option))
  100.         {
  101.             JError::raiseError(500JText::_('JERROR_ALERTNOAUTHOR'));
  102.             jexit();
  103.         }
  104.  
  105.         return parent::saveorder();
  106.     }
  107.  
  108.     /**
  109.      * Check in of one or more records.
  110.      *
  111.      * Overrides JControllerAdmin::checkin to check the core.admin permission.
  112.      *
  113.      * @since   1.6
  114.      */
  115.     public function checkin()
  116.     {
  117.         if (!JFactory::getUser()->authorise('core.admin'$this->option))
  118.         {
  119.             JError::raiseError(500JText::_('JERROR_ALERTNOAUTHOR'));
  120.             jexit();
  121.         }
  122.  
  123.         return parent::checkin();
  124.     }
  125. }

Documentation generated on Tue, 19 Nov 2013 15:04:10 +0100 by phpDocumentor 1.4.3