コード例 #1
0
ファイル: users.php プロジェクト: ForAEdesWeb/AEW3
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = 'user.id', $direction = 'DESC')
 {
     $this->getFields();
     parent::populateState($ordering, $direction);
 }
コード例 #2
0
ファイル: users.php プロジェクト: ForAEdesWeb/AEW3
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = null, $direction = null)
 {
     $params = $this->getParams();
     $user = $this->container->get('user');
     $input = $this->container->get('input');
     $app = $this->container->get('app');
     // Order
     // =====================================================================================
     $orderCol = $params->get('orderby', 'a.ordering');
     $this->state->set('list.ordering', $orderCol);
     // Order Dir
     // =====================================================================================
     $listOrder = $params->get('order_dir', 'asc');
     $this->state->set('list.direction', $listOrder);
     // Limitstart
     // =====================================================================================
     $this->state->set('list.start', $input->getInt('limitstart', 0));
     // Max Level
     // =====================================================================================
     $maxLevel = $params->get('maxLevel');
     if ($maxLevel) {
         $this->state->set('filter.max_category_levels', $maxLevel);
     }
     // Edit Access
     // =====================================================================================
     if ($user->authorise('core.edit.state', 'com_userxtd') || $user->authorise('core.edit', 'com_userxtd')) {
         // Filter on published for those who do not have edit or edit.state rights.
         $this->state->set('filter.unpublished', 1);
     }
     // View Level
     // =====================================================================================
     if (!$params->get('show_noauth')) {
         $this->state->set('filter.access', true);
     } else {
         $this->state->set('filter.access', false);
     }
     // Language
     // =====================================================================================
     $this->state->set('filter.language', $app->getLanguageFilter());
     parent::populateState($ordering, 'ASC');
 }
コード例 #3
0
ファイル: lists.php プロジェクト: lyrasoft/lyrasoft.github.io
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = null, $direction = 'ASC')
 {
     // Build ordering prefix
     if (!$ordering) {
         $table = $this->getTable('List');
         $ordering = property_exists($table, 'ordering') ? 'list.ordering' : 'list.id';
         $ordering = property_exists($table, 'catid') ? 'list.catid, ' . $ordering : $ordering;
     }
     parent::populateState($ordering, $direction);
 }
コード例 #4
0
ファイル: items.php プロジェクト: beingsane/facebook-importer
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = null, $direction = 'ASC')
 {
     parent::populateState($ordering, $direction);
     $this->state->set('import_num', $this->getUserStateFromRequest('import_num', 'import_num', 50));
 }
コード例 #5
0
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = 'plugin.folder, plugin.extension_id', $direction = 'ASC')
 {
     parent::populateState($ordering, $direction);
 }
コード例 #6
0
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = null, $direction = 'ASC')
 {
     parent::populateState($ordering, $direction);
 }
コード例 #7
0
ファイル: profiles.php プロジェクト: ForAEdesWeb/AEW3
 /**
  * Method to auto-populate the model state.
  *
  * This method will only called in constructor. Using `ignore_request` to ignore this method.
  *
  * @param   string  $ordering   An optional ordering field.
  * @param   string  $direction  An optional direction (asc|desc).
  *
  * @return  void
  */
 protected function populateState($ordering = 'profile.id', $direction = 'DESC')
 {
     // Build ordering prefix
     if (!$ordering) {
         $table = $this->getTable('Profile');
         $ordering = property_exists($table, 'ordering') ? 'profile.ordering' : 'profile.id';
         $ordering = property_exists($table, 'catid') ? 'profile.catid, ' . $ordering : $ordering;
     }
     parent::populateState($ordering, $direction);
 }