Example #1
0
 /**
  * Method to cancel an element.
  *
  * @access	public
  * @return	void
  */
 public function cancel()
 {
     $this->_result = $result = parent::cancel();
     $model = $this->getModel();
     //Define the redirections
     switch ($this->getLayout() . '.' . $this->getTask()) {
         case 'changelog.cancel':
             $this->applyRedirection($result, array('stay', 'com_rtiprint.changelogs.changelogs'), array('cid[]' => null));
             break;
         case 'rochangelog.cancel':
             $this->applyRedirection($result, array('stay', 'com_rtiprint.changelogs.default'), array('cid[]' => null));
             break;
         default:
             $this->applyRedirection($result, array('stay', 'com_rtiprint.changelogs.default'));
             break;
     }
 }