/** * Edit an team * * @param string $key key * @param string $urlVar urlvar * * @return bool */ public function edit($key = null, $urlVar = null) { if (!JFactory::getUser()->get('id')) { $this->setRedirect(JURI::base(), JText::_('COM_TRACKS_Please_login_to_be_able_to_edit'), 'error'); $this->redirect(); } return parent::edit($key, $urlVar); }
/** * Gets the URL arguments to append to an item redirect. * * @param integer $recordId The primary key id for the item. * @param string $urlVar The name of the URL variable for the id. * * @return string The arguments to append to the redirect URL. */ protected function getRedirectToItemAppend($recordId = null, $urlVar = 'id') { $append = parent::getRedirectToItemAppend($recordId, $urlVar); if (!($projectround_id = $this->input->getInt('projectround_id'))) { $fromForm = $this->input->get('jform', null, 'array'); $projectround_id = $fromForm['projectround_id']; } return $append . '&projectround_id=' . $projectround_id; }
/** * Gets the URL arguments to append to an item redirect. * * @param integer $recordId The primary key id for the item. * @param string $urlVar The name of the URL variable for the id. * * @return string The arguments to append to the redirect URL. */ protected function getRedirectToItemAppend($recordId = null, $urlVar = 'id') { $append = parent::getRedirectToItemAppend($recordId, $urlVar); $data = $this->input->get('jform', array(), 'array'); if (!empty($data['payment_name'])) { $append .= '&payment_name=' . $data['payment_name']; } return $append; }
public function save($key = null, $urlVar = null) { $task = $this->getTask(); switch ($task) { case 'save': $this->view_list = 'countries'; break; } parent::save($key, $urlVar); }
/** * Public constructor of the Controller class * * @param array $config Optional configuration parameters */ public function __construct($config = array()) { parent::__construct($config); $this->registerTask('assign', 'assign'); }
function __construct($config = array()) { parent::__construct($config); }
/** * Gets the URL arguments to append to an item redirect. * * @param integer $recordId The primary key id for the item. * @param string $urlVar The name of the URL variable for the id. * * @return string The arguments to append to the redirect URL. */ protected function getRedirectToItemAppend($recordId = null, $urlVar = 'id') { $append = parent::getRedirectToItemAppend($recordId, $urlVar); $component = $this->input->get('component'); $tab = $this->input->get('tab'); if ($component) { $append .= '&component=' . $component; } if ($tab) { $append .= '&tab=' . $tab; } return $append; }
/** * Gets the URL arguments to append to a list redirect. * * @return string The arguments to append to the redirect URL. */ protected function getRedirectToListAppend() { $append = parent::getRedirectToListAppend(); $append .= $this->getCommonRedirectAppend($append); return $append; }