Example #1
0
 /**
  * Display the view
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  *
  */
 public function render()
 {
     $form = null;
     $component = null;
     try {
         $form = $this->model->getForm();
         $component = $this->model->getComponent();
         $user = JFactory::getUser();
     } catch (Exception $e) {
         JFactory::getApplication()->enqueueMessage($e->getMessage(), 'error');
         return false;
     }
     // Bind the form to the data.
     if ($form && $component->params) {
         $form->bind($component->params);
     }
     $this->form =& $form;
     $this->component =& $component;
     $this->components = ConfigHelperConfig::getComponentsWithConfig();
     ConfigHelperConfig::loadLanguageForComponents($this->components);
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     $this->currentComponent = JFactory::getApplication()->input->get('component');
     $this->return = JFactory::getApplication()->input->get('return', '', 'base64');
     $this->addToolbar();
     JFactory::getApplication()->input->set('hidemainmenu', true);
     return parent::render();
 }
Example #2
0
 /**
  * Display the view
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  */
 public function render()
 {
     $lang = JFactory::getApplication()->getLanguage();
     $lang->load('', JPATH_ADMINISTRATOR, $lang->getTag());
     $lang->load('com_modules', JPATH_ADMINISTRATOR, $lang->getTag());
     return parent::render();
 }
Example #3
0
 /**
  * Method to display the view.
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  */
 public function render()
 {
     $form = null;
     $data = null;
     try {
         // Load Form and Data
         $form = $this->model->getForm();
         $data = $this->model->getData();
         $user = JFactory::getUser();
     } catch (Exception $e) {
         JFactory::getApplication()->enqueueMessage($e->getMessage(), 'error');
         return false;
     }
     // Bind data
     if ($form && $data) {
         $form->bind($data);
     }
     // Get the params for com_users.
     $usersParams = JComponentHelper::getParams('com_users');
     // Get the params for com_media.
     $mediaParams = JComponentHelper::getParams('com_media');
     // Load settings for the FTP layer.
     $ftp = JClientHelper::setCredentialsFromRequest('ftp');
     $this->form =& $form;
     $this->data =& $data;
     $this->ftp =& $ftp;
     $this->usersParams =& $usersParams;
     $this->mediaParams =& $mediaParams;
     $this->components = ConfigHelperConfig::getComponentsWithConfig();
     ConfigHelperConfig::loadLanguageForComponents($this->components);
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     $this->addToolbar();
     return parent::render();
 }
Example #4
0
 /**
  * Display the view
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  *
  */
 public function render()
 {
     $form = null;
     $component = null;
     try {
         $form = $this->model->getForm();
         $component = $this->model->getComponent();
         $user = JFactory::getUser();
     } catch (Exception $e) {
         JFactory::getApplication()->enqueueMessage($e->getMessage(), 'error');
         return false;
     }
     // Bind the form to the data.
     if ($form && $component->params) {
         $form->bind($component->params);
     }
     $this->fieldsets = $form->getFieldsets();
     // Don't show permissions fieldset if not authorised.
     if (!$user->authorise('core.admin', $component->option) && isset($this->fieldsets['permissions'])) {
         unset($this->fieldsets['permissions']);
     }
     $this->form =& $form;
     $this->component =& $component;
     $this->components = ConfigHelperConfig::getComponentsWithConfig();
     ConfigHelperConfig::loadLanguageForComponents($this->components);
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     $this->currentComponent = JFactory::getApplication()->input->get('component');
     $this->return = JFactory::getApplication()->input->get('return', '', 'base64');
     $this->addToolbar();
     return parent::render();
 }
 /**
  * Method to display the view.
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  */
 public function render()
 {
     $form = null;
     $data = null;
     try {
         // Load Form and Data
         $form = $this->model->getForm();
         $data = $this->model->getData();
         $user = JFactory::getUser();
     } catch (Exception $e) {
         JFactory::getApplication()->enqueueMessage($e->getMessage(), 'error');
         return false;
     }
     // Bind data
     if ($form && $data) {
         $form->bind($data);
     }
     $this->form =& $form;
     $this->data =& $data;
     $this->components = ConfigHelperConfig::getComponentsWithConfig();
     ConfigHelperConfig::loadLanguageForComponents($this->components);
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     $this->addToolbar();
     return parent::render();
 }
Example #6
0
 /**
  * Method to display the view.
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  */
 public function render()
 {
     $form = null;
     $data = null;
     try {
         // Load Form and Data
         $form = $this->model->getForm();
         $data = $this->model->getData();
         $user = JFactory::getUser();
     } catch (Exception $e) {
         JFactory::getApplication()->enqueueMessage($e->getMessage(), 'error');
         return false;
     }
     // Bind data
     if ($form && $data) {
         $form->bind($data);
     }
     // Get the params for com_users.
     $usersParams = JComponentHelper::getParams('com_users');
     // Get the params for com_media.
     $mediaParams = JComponentHelper::getParams('com_media');
     // Load settings for the FTP layer.
     $ftp = JClientHelper::setCredentialsFromRequest('ftp');
     $this->form =& $form;
     $this->data =& $data;
     $this->ftp =& $ftp;
     $this->usersParams =& $usersParams;
     $this->mediaParams =& $mediaParams;
     $this->components = ConfigHelperConfig::getComponentsWithConfig();
     ConfigHelperConfig::loadLanguageForComponents($this->components);
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     // Add strings for translations in Javascript.
     JText::script('COM_CONFIG_SENDMAIL_JS_ERROR_CONNECTION_ABORT');
     JText::script('COM_CONFIG_SENDMAIL_JS_ERROR_NO_CONTENT');
     JText::script('COM_CONFIG_SENDMAIL_JS_ERROR_OTHER');
     JText::script('COM_CONFIG_SENDMAIL_JS_ERROR_PARSE');
     JText::script('COM_CONFIG_SENDMAIL_JS_ERROR_TIMEOUT');
     $this->addToolbar();
     return parent::render();
 }
Example #7
0
 /**
  * Method to render the view.
  *
  * @return  string  The rendered view.
  *
  * @since   3.2
  */
 public function render()
 {
     $user = JFactory::getUser();
     $this->userIsSuperAdmin = $user->authorise('core.admin');
     return parent::render();
 }