You've already forked joomla_test
first commit
This commit is contained in:
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
@ -0,0 +1,111 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_languages
|
||||
*
|
||||
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
// Add specific helper files for html generation
|
||||
JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
$user = JFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
$client = $this->state->get('filter.client_id', 0) ? JText::_('JADMINISTRATOR') : JText::_('JSITE');
|
||||
$clientId = $this->state->get('filter.client_id', 0);
|
||||
?>
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_languages&view=installed&client='.$clientId); ?>" method="post" id="adminForm" name="adminForm">
|
||||
<?php if (!empty( $this->sidebar)) : ?>
|
||||
<div id="j-sidebar-container" class="span2">
|
||||
<?php echo $this->sidebar; ?>
|
||||
</div>
|
||||
<div id="j-main-container" class="span10">
|
||||
<?php else : ?>
|
||||
<div id="j-main-container">
|
||||
<?php endif;?>
|
||||
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="20">
|
||||
 
|
||||
</th>
|
||||
<th width="25%" class="title">
|
||||
<?php echo JText::_('COM_LANGUAGES_HEADING_LANGUAGE'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('COM_LANGUAGES_FIELD_LANG_TAG_LABEL'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('JCLIENT'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('COM_LANGUAGES_HEADING_DEFAULT'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('JVERSION'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('JDATE'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('JAUTHOR'); ?>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo JText::_('COM_LANGUAGES_HEADING_AUTHOR_EMAIL'); ?>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="9">
|
||||
<?php echo $this->pagination->getListFooter(); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
<tbody>
|
||||
<?php foreach ($this->rows as $i => $row) :
|
||||
$canCreate = $user->authorise('core.create', 'com_languages');
|
||||
$canEdit = $user->authorise('core.edit', 'com_languages');
|
||||
$canChange = $user->authorise('core.edit.state', 'com_languages');
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td width="20">
|
||||
<?php echo JHtml::_('languages.id', $i, $row->language);?>
|
||||
</td>
|
||||
<td width="25%">
|
||||
<?php echo $this->escape($row->name); ?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo $this->escape($row->language); ?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo $client;?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo JHtml::_('jgrid.isdefault', $row->published, $i, 'installed.', !$row->published && $canChange);?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo $this->escape($row->version); ?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo $this->escape($row->creationDate); ?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo $this->escape($row->author); ?>
|
||||
</td>
|
||||
<td align="center">
|
||||
<?php echo JStringPunycode::emailToUTF8($this->escape($row->authorEmail)); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="boxchecked" value="0" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
@ -0,0 +1,103 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_languages
|
||||
*
|
||||
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
|
||||
* @license GNU General Public License version 2 or later; see LICENSE.txt
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
/**
|
||||
* Displays a list of the installed languages.
|
||||
*
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_languages
|
||||
* @since 1.6
|
||||
*/
|
||||
class LanguagesViewInstalled extends JViewLegacy
|
||||
{
|
||||
/**
|
||||
* @var object client object
|
||||
*/
|
||||
protected $client = null;
|
||||
|
||||
/**
|
||||
* @var boolean|JExeption True, if FTP settings should be shown, or an exeption
|
||||
*/
|
||||
protected $ftp = null;
|
||||
|
||||
/**
|
||||
* @var string option name
|
||||
*/
|
||||
protected $option = null;
|
||||
|
||||
/**
|
||||
* @var object pagination information
|
||||
*/
|
||||
protected $pagination = null;
|
||||
|
||||
/**
|
||||
* @var array languages information
|
||||
*/
|
||||
protected $rows = null;
|
||||
|
||||
/**
|
||||
* @var object user object
|
||||
*/
|
||||
protected $user = null;
|
||||
|
||||
/**
|
||||
* Display the view
|
||||
*/
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$this->ftp = $this->get('Ftp');
|
||||
$this->option = $this->get('Option');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->rows = $this->get('Data');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
$client = (int) $this->state->get('filter.client_id', 0);
|
||||
LanguagesHelper::addSubmenu('installed', $client);
|
||||
|
||||
$this->addToolbar();
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
* @since 1.6
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
require_once JPATH_COMPONENT.'/helpers/languages.php';
|
||||
|
||||
$canDo = LanguagesHelper::getActions();
|
||||
|
||||
JToolbarHelper::title(JText::_('COM_LANGUAGES_VIEW_INSTALLED_TITLE'), 'langmanager.png');
|
||||
|
||||
if ($canDo->get('core.edit.state'))
|
||||
{
|
||||
JToolbarHelper::makeDefault('installed.setDefault');
|
||||
JToolbarHelper::divider();
|
||||
}
|
||||
|
||||
if ($canDo->get('core.admin'))
|
||||
{
|
||||
// Add install languages link to the lang installer component
|
||||
$bar = JToolbar::getInstance('toolbar');
|
||||
$bar->appendButton('Link', 'upload', 'COM_LANGUAGES_INSTALL', 'index.php?option=com_installer&view=languages');
|
||||
JToolbarHelper::divider();
|
||||
|
||||
JToolbarHelper::preferences('com_languages');
|
||||
JToolbarHelper::divider();
|
||||
}
|
||||
|
||||
JToolbarHelper::help('JHELP_EXTENSIONS_LANGUAGE_MANAGER_INSTALLED');
|
||||
|
||||
$this->sidebar = JHtmlSidebar::render();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user