You've already forked joomla_test
first commit
This commit is contained in:
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
@ -0,0 +1,86 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_installer
|
||||
*
|
||||
* @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;
|
||||
|
||||
?>
|
||||
|
||||
<div id="installer-database">
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_installer&view=database');?>" method="post" name="adminForm" id="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;?>
|
||||
<?php if ($this->errorCount === 0) : ?>
|
||||
<div class="alert alert-info">
|
||||
<a class="close" data-dismiss="alert" href="#">×</a>
|
||||
<?php echo JText::_('COM_INSTALLER_MSG_DATABASE_OK'); ?>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.startTabSet', 'myTab', array('active' => 'other')); ?>
|
||||
<?php else : ?>
|
||||
<div class="alert alert-error">
|
||||
<a class="close" data-dismiss="alert" href="#">×</a>
|
||||
<?php echo JText::_('COM_INSTALLER_MSG_DATABASE_ERRORS'); ?>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.startTabSet', 'myTab', array('active' => 'problems')); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'problems', JText::plural('COM_INSTALLER_MSG_N_DATABASE_ERROR_PANEL', $this->errorCount)); ?>
|
||||
<fieldset class="panelform">
|
||||
<ul>
|
||||
<?php if (!$this->filterParams) : ?>
|
||||
<li><?php echo JText::_('COM_INSTALLER_MSG_DATABASE_FILTER_ERROR'); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if (!(strncmp($this->schemaVersion, JVERSION, 5) === 0)) : ?>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_SCHEMA_ERROR', $this->schemaVersion, JVERSION); ?></li>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if (($this->updateVersion != JVERSION)) : ?>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_UPDATEVERSION_ERROR', $this->updateVersion, JVERSION); ?></li>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php foreach ($this->errors as $line => $error) : ?>
|
||||
<?php $key = 'COM_INSTALLER_MSG_DATABASE_' . $error->queryType;
|
||||
$msgs = $error->msgElements;
|
||||
$file = basename($error->file);
|
||||
$msg0 = (isset($msgs[0])) ? $msgs[0] : ' ';
|
||||
$msg1 = (isset($msgs[1])) ? $msgs[1] : ' ';
|
||||
$msg2 = (isset($msgs[2])) ? $msgs[2] : ' ';
|
||||
$message = JText::sprintf($key, $file, $msg0, $msg1, $msg2); ?>
|
||||
<li><?php echo $message; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php endif; ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'other', JText::_('COM_INSTALLER_MSG_DATABASE_INFO', true)); ?>
|
||||
<div class="control-group" >
|
||||
<fieldset class="panelform">
|
||||
<ul>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_SCHEMA_VERSION', $this->schemaVersion); ?></li>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_UPDATE_VERSION', $this->updateVersion); ?></li>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_DRIVER', JFactory::getDbo()->name); ?></li>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_CHECKED_OK', count($this->results['ok'])); ?></li>
|
||||
<li><?php echo JText::sprintf('COM_INSTALLER_MSG_DATABASE_SKIPPED', count($this->results['skipped'])); ?></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="boxchecked" value="0" />
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
@ -0,0 +1,80 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_installer
|
||||
*
|
||||
* @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;
|
||||
|
||||
include_once __DIR__ . '/../default/view.php';
|
||||
|
||||
/**
|
||||
* Extension Manager Manage View
|
||||
*
|
||||
* @package Joomla.Administrator
|
||||
* @subpackage com_installer
|
||||
* @since 1.6
|
||||
*/
|
||||
class InstallerViewDatabase extends InstallerViewDefault
|
||||
{
|
||||
/**
|
||||
* Display the view
|
||||
*
|
||||
* @param string $tpl Template
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @since 1.6
|
||||
*/
|
||||
public function display($tpl = null)
|
||||
{
|
||||
// Get data from the model
|
||||
$this->state = $this->get('State');
|
||||
$this->changeSet = $this->get('Items');
|
||||
$this->errors = $this->changeSet->check();
|
||||
$this->results = $this->changeSet->getStatus();
|
||||
$this->schemaVersion = $this->get('SchemaVersion');
|
||||
$this->updateVersion = $this->get('UpdateVersion');
|
||||
$this->filterParams = $this->get('DefaultTextFilters');
|
||||
$this->schemaVersion = ($this->schemaVersion) ? $this->schemaVersion : JText::_('JNONE');
|
||||
$this->updateVersion = ($this->updateVersion) ? $this->updateVersion : JText::_('JNONE');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->errorCount = count($this->errors);
|
||||
|
||||
if (!(strncmp($this->schemaVersion, JVERSION, 5) === 0))
|
||||
{
|
||||
$this->errorCount++;
|
||||
}
|
||||
if (!$this->filterParams)
|
||||
{
|
||||
$this->errorCount++;
|
||||
}
|
||||
if (($this->updateVersion != JVERSION))
|
||||
{
|
||||
$this->errorCount++;
|
||||
}
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @since 1.6
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
/*
|
||||
* Set toolbar items for the page
|
||||
*/
|
||||
JToolbarHelper::custom('database.fix', 'refresh', 'refresh', 'COM_INSTALLER_TOOLBAR_DATABASE_FIX', false, false);
|
||||
JToolbarHelper::divider();
|
||||
parent::addToolbar();
|
||||
JToolbarHelper::help('JHELP_EXTENSIONS_EXTENSION_MANAGER_DATABASE');
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user