/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @return void * */ protected function populateState() { // Load the parameters - this will only load those from config.xml $params = JComponentHelper::getParams('com_componentarchitect'); $this->setState('params', $params); parent::populateState(); }
function populateState() { parent::populateState(); $this->setState('template.id', JRequest::getInt('id')); $this->setState('content.id', null); $this->setState('category.id', null); }
function populateState() { parent::populateState(); $this->setState('template.id', JFactory::getApplication()->input->getInt('id')); $this->setState('content.id', null); $this->setState('category.id', null); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @return void * * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication('administrator'); $this->setState('message', $app->getUserState('com_installer.message')); $this->setState('extension_message', $app->getUserState('com_installer.extension_message')); $app->setUserState('com_installer.message', ''); $app->setUserState('com_installer.extension_message', ''); parent::populateState(); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @return void * * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication('administrator'); $this->setState('message', $app->getUserState('com_installer.message')); $this->setState('extension_message', $app->getUserState('com_installer.extension_message')); $app->setUserState('com_installer.message', ''); $app->setUserState('com_installer.extension_message', ''); // Recall the 'Install from Directory' path. $path = $app->getUserStateFromRequest($this->_context . '.install_directory', 'install_directory', $app->getCfg('tmp_path')); $this->setState('install.directory', $path); parent::populateState(); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 */ protected function populateState() { parent::populateState(); $app = JFactory::getApplication("Site"); /** @var $app JApplicationSite */ // Get the pk of the record from the request. $value = $app->input->getInt("id"); $this->setState($this->getName() . '.project_id', $value); // Load the parameters. $value = $app->getParams($this->option); $this->setState('params', $value); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 */ protected function populateState() { // Initialise variables. $this->setState('message', User::getState('com_installer.message')); $this->setState('extension_message', User::getState('com_installer.extension_message')); User::setState('com_installer.message', ''); User::setState('com_installer.extension_message', ''); // Recall the 'Install from Directory' path. $path = Request::getState($this->_context . '.install_directory', 'install_directory', Config::get('tmp_path')); $this->setState('install.directory', $path); parent::populateState(); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @return void * */ protected function populateState() { $app = JFactory::getApplication('administrator'); $this->setState('message', $app->getUserState('com_demo.message')); $app->setUserState('com_demo.message', ''); // Recall the 'Import from Directory' path. $path = $app->getUserStateFromRequest($this->_context . '.import_directory', 'import_directory', $app->get('tmp_path')); $this->setState('import.directory', $path); // set uploading values $this->use_streams = false; $this->allow_unsafe = false; $this->safeFileOptions = array(); parent::populateState(); }
protected function populateState($ordering = null, $direction = null) { parent::populateState('lastname', 'ASC'); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 */ protected function populateState() { // Initialise variables. $app = JFactory::getApplication(); $filters = JRequest::getVar('filters'); if (empty($filters)) { $data = $app->getUserState($this->_context . '.data'); $filters = $data['filters']; } else { $app->setUserState($this->_context . '.data', array('filters' => $filters)); } $this->setState('message', $app->getUserState('com_installer.message')); $this->setState('extension_message', $app->getUserState('com_installer.extension_message')); $app->setUserState('com_installer.message', ''); $app->setUserState('com_installer.extension_message', ''); // Recall the 'Install from Directory' path. $path = $app->getUserStateFromRequest($this->_context . '.install_directory', 'install_directory', $app->getCfg('tmp_path')); $this->setState('install.directory', $path); $this->setState('filter.type', isset($filters['type']) ? $filters['type'] : ''); if (!isset($filters['update_site_id'])) { JRequest::setVar('update_site_id', '1'); } $this->setState('filter.update_site_id', isset($filters['update_site_id']) ? $filters['update_site_id'] : '1'); $this->setState('filter.folder', isset($filters['folder']) ? $filters['folder'] : ''); $this->setState('filter.search', isset($filters['search']) ? $filters['search'] : ''); parent::populateState('a.name', 'asc'); }