first commit

This commit is contained in:
alazhar
2020-01-02 22:20:31 +07:00
commit 10eb3340ad
5753 changed files with 631345 additions and 0 deletions

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,86 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JHtml::_('behavior.formvalidation');
JHtml::_('behavior.keepalive');
JHtml::_('formbehavior.chosen', 'select');
?>
<form action="<?php echo JRoute::_('index.php?option=com_finder&view=filter&layout=edit&filter_id=' . (int) $this->item->filter_id); ?>" method="post" name="adminForm" id="adminForm" class="form-validate form-horizontal">
<fieldset>
<?php echo JHtml::_('bootstrap.startTabSet', 'myTab', array('active' => 'basic')); ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'basic', JText::_('COM_FINDER_EDIT_FILTER', true)); ?>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('title'); ?></div>
<div class="controls"><?php echo $this->form->getInput('title'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('alias'); ?></div>
<div class="controls"><?php echo $this->form->getInput('alias'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('state'); ?></div>
<div class="controls"><?php echo $this->form->getInput('state'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('map_count'); ?></div>
<div class="controls"><?php echo $this->form->getInput('map_count'); ?></div>
</div>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'params', JText::_('COM_FINDER_FILTER_FIELDSET_PARAMS', true)); ?>
<?php foreach ($this->form->getGroup('params') as $field) : ?>
<div class="control-group">
<?php if (!$field->hidden) : ?>
<div class="control-label"><?php echo $field->label; ?></div>
<?php endif; ?>
<div class="controls"><?php echo $field->input; ?></div>
</div>
<?php endforeach; ?>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'details', JText::_('COM_FINDER_FILTER_FIELDSET_DETAILS', true)); ?>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('created_by'); ?></div>
<div class="controls"><?php echo $this->form->getInput('created_by'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('created_by_alias'); ?></div>
<div class="controls"><?php echo $this->form->getInput('created_by_alias'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('created'); ?></div>
<div class="controls"><?php echo $this->form->getInput('created'); ?></div>
</div>
<?php if ($this->item->modified_by) : ?>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('modified_by'); ?></div>
<div class="controls"><?php echo $this->form->getInput('modified_by'); ?></div>
</div>
<div class="control-group">
<div class="control-label"><?php echo $this->form->getLabel('modified'); ?></div>
<div class="controls"><?php echo $this->form->getInput('modified'); ?></div>
</div>
<?php endif; ?>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php echo JHtml::_('bootstrap.endTabSet'); ?>
</fieldset>
<div id="finder-filter-window">
<?php echo JHtml::_('filter.slider', array('selected_nodes' => $this->filter->data)); ?>
</div>
<input type="hidden" name="task" value="" />
<input type="hidden" name="return" value="<?php echo JFactory::getApplication()->input->get('return', '', 'cmd');?>" />
<?php echo JHtml::_('form.token'); ?>
</form>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,114 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
/**
* Filter view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewFilter extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return mixed A string if successful, otherwise a JError object.
*
* @since 2.5
*/
public function display($tpl = null)
{
// Load the view data.
$this->filter = $this->get('Filter');
$this->item = $this->get('Item');
$this->form = $this->get('Form');
$this->state = $this->get('State');
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseError(500, implode("\n", $errors));
return false;
}
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
JHtml::addIncludePath(JPATH_SITE . '/components/com_finder/helpers/html');
// Configure the toolbar.
$this->addToolbar();
parent::display($tpl);
}
/**
* Method to configure the toolbar for this view.
*
* @return void
*
* @since 2.5
*/
protected function addToolbar()
{
JFactory::getApplication()->input->set('hidemainmenu', true);
$user = JFactory::getUser();
$userId = $user->get('id');
$isNew = ($this->item->filter_id == 0);
$checkedOut = !($this->item->checked_out == 0 || $this->item->checked_out == $userId);
$canDo = FinderHelper::getActions();
// Configure the toolbar.
JToolbarHelper::title(JText::_('COM_FINDER_FILTER_EDIT_TOOLBAR_TITLE'), 'finder');
// Set the actions for new and existing records.
if ($isNew)
{
// For new records, check the create permission.
if ($canDo->get('core.create'))
{
JToolbarHelper::apply('filter.apply');
JToolbarHelper::save('filter.save');
JToolbarHelper::save2new('filter.save2new');
}
JToolbarHelper::cancel('filter.cancel');
}
else
{
// Can't save the record if it's checked out.
if (!$checkedOut)
{
// Since it's an existing record, check the edit permission.
if ($canDo->get('core.edit'))
{
JToolbarHelper::apply('filter.apply');
JToolbarHelper::save('filter.save');
// We can save this record, but check the create permission to see if we can return to make a new one.
if ($canDo->get('core.create'))
{
JToolbarHelper::save2new('filter.save2new');
}
}
}
// If an existing item, can save as a copy
if ($canDo->get('core.create'))
{
JToolbarHelper::save2copy('filter.save2copy');
}
JToolbarHelper::cancel('filter.cancel', 'JTOOLBAR_CLOSE');
}
JToolbarHelper::divider();
JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_SEARCH_FILTERS_EDIT');
}
}

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,161 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JHtml::_('formbehavior.chosen', 'select');
JHtml::_('bootstrap.tooltip');
$user = JFactory::getUser();
$userId = $user->get('id');
$listOrder = $this->escape($this->state->get('list.ordering'));
$listDirn = $this->escape($this->state->get('list.direction'));
JText::script('COM_FINDER_INDEX_CONFIRM_DELETE_PROMPT');
?>
<script type="text/javascript">
Joomla.submitbutton = function(pressbutton)
{
if (pressbutton == 'filters.delete')
{
if (confirm(Joomla.JText._('COM_FINDER_INDEX_CONFIRM_DELETE_PROMPT')))
{
Joomla.submitform(pressbutton);
}
else
{
return false;
}
}
Joomla.submitform(pressbutton);
}
</script>
<form action="<?php echo JRoute::_('index.php?option=com_finder&view=filters');?>" 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;?>
<div id="filter-bar" class="btn-toolbar">
<div class="filter-search btn-group pull-left">
<input type="text" name="filter_search" id="filter_search" placeholder="<?php echo JText::_('JSEARCH_FILTER'); ?>" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" class="hasTooltip" title="<?php echo JHtml::tooltipText('COM_FINDER_FILTER_SEARCH_DESCRIPTION'); ?>" />
</div>
<div class="btn-group pull-left">
<button type="submit" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_SUBMIT'); ?>"><i class="icon-search"></i></button>
<button type="button" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_CLEAR'); ?>" onclick="document.id('filter_search').value='';this.form.submit();"><i class="icon-remove"></i></button>
</div>
</div>
<div class="clearfix"> </div>
<table class="table table-striped">
<thead>
<tr>
<th width="1%">
<?php echo JHtml::_('grid.checkall'); ?>
</th>
<th class="nowrap">
<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'a.title', $listDirn, $listOrder); ?>
</th>
<th width="5%" class="nowrap">
<?php echo JHtml::_('grid.sort', 'JSTATUS', 'a.state', $listDirn, $listOrder); ?>
</th>
<th width="10%" class="center nowrap">
<?php echo JHtml::_('grid.sort', 'JGRID_HEADING_CREATED_BY', 'a.created_by_alias', $listDirn, $listOrder); ?>
</th>
<th width="10%" class="center nowrap">
<?php echo JHtml::_('grid.sort', 'COM_FINDER_FILTER_TIMESTAMP', 'a.created', $listDirn, $listOrder); ?>
</th>
<th width="5%" class="center nowrap">
<?php echo JHtml::_('grid.sort', 'COM_FINDER_FILTER_MAP_COUNT', 'a.map_count', $listDirn, $listOrder); ?>
</th>
<th width="1%" class="center nowrap">
<?php echo JHtml::_('grid.sort', 'JGRID_HEADING_ID', 'a.filter_id', $listDirn, $listOrder); ?>
</th>
</tr>
</thead>
<tbody>
<?php if (count($this->items) == 0) : ?>
<tr class="row0">
<td class="center" colspan="7">
<?php
if ($this->total == 0):
echo JText::_('COM_FINDER_NO_FILTERS');
?>
<a href="<?php echo JRoute::_('index.php?option=com_finder&task=filter.add'); ?>" title="<?php echo JText::_('COM_FINDER_CREATE_FILTER'); ?>">
<?php echo JText::_('COM_FINDER_CREATE_FILTER'); ?>
</a>
<?php
else:
echo JText::_('COM_FINDER_NO_RESULTS');
endif;
?>
</td>
</tr>
<?php endif; ?>
<?php foreach ($this->items as $i => $item):
$canCreate = $user->authorise('core.create', 'com_finder');
$canEdit = $user->authorise('core.edit', 'com_finder');
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $item->checked_out == $user->get('id') || $item->checked_out == 0;
$canChange = $user->authorise('core.edit.state', 'com_finder') && $canCheckin;
?>
<tr class="row<?php echo $i % 2; ?>">
<td class="center">
<?php echo JHtml::_('grid.id', $i, $item->filter_id); ?>
</td>
<td>
<?php if ($item->checked_out)
{
echo JHtml::_('jgrid.checkedout', $i, $item->editor, $item->checked_out_time, 'filters.', $canCheckin);
} ?>
<?php if ($canEdit) { ?>
<a href="<?php echo JRoute::_('index.php?option=com_finder&task=filter.edit&filter_id=' . (int) $item->filter_id); ?>">
<?php echo $this->escape($item->title); ?></a>
<?php } else {
echo $this->escape($item->title);
} ?>
</td>
<td class="center nowrap">
<?php echo JHtml::_('jgrid.published', $item->state, $i, 'filters.', $canChange); ?>
</td>
<td class="center nowrap">
<?php echo $item->created_by_alias ? $item->created_by_alias : $item->user_name; ?>
</td>
<td class="center nowrap">
<?php echo JHtml::_('date', $item->created, JText::_('DATE_FORMAT_LC4')); ?>
</td>
<td class="center nowrap">
<?php echo $item->map_count; ?>
</td>
<td class="center">
<?php echo (int) $item->filter_id; ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
<tfoot>
<tr>
<td colspan="7" class="nowrap">
<?php echo $this->pagination->getListFooter(); ?>
</td>
</tr>
</tfoot>
</table>
<input type="hidden" name="task" value="" />
<input type="hidden" name="boxchecked" value="0" />
<input type="hidden" name="filter_order" value="<?php echo $this->state->get('list.ordering'); ?>" />
<input type="hidden" name="filter_order_Dir" value="<?php echo $this->state->get('list.direction'); ?>" />
<?php echo JHtml::_('form.token'); ?>
</div>
</form>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,103 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
/**
* Filters view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewFilters extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return mixed A string if successful, otherwise a JError object.
*
* @since 2.5
*/
public function display($tpl = null)
{
// Load the view data.
$this->items = $this->get('Items');
$this->pagination = $this->get('Pagination');
$this->total = $this->get('Total');
$this->state = $this->get('State');
FinderHelper::addSubmenu('filters');
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseError(500, implode("\n", $errors));
return false;
}
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
// Configure the toolbar.
$this->addToolbar();
$this->sidebar = JHtmlSidebar::render();
parent::display($tpl);
}
/**
* Method to configure the toolbar for this view.
*
* @return void
*
* @since 2.5
*/
protected function addToolbar()
{
$canDo = FinderHelper::getActions();
JToolbarHelper::title(JText::_('COM_FINDER_FILTERS_TOOLBAR_TITLE'), 'finder');
$toolbar = JToolbar::getInstance('toolbar');
if ($canDo->get('core.create'))
{
JToolbarHelper::addNew('filter.add');
JToolbarHelper::editList('filter.edit');
JToolbarHelper::divider();
}
if ($canDo->get('core.edit.state'))
{
JToolbarHelper::publishList('filters.publish');
JToolbarHelper::unpublishList('filters.unpublish');
JToolbarHelper::divider();
}
if ($canDo->get('core.delete'))
{
JToolbarHelper::deleteList('', 'filters.delete');
JToolbarHelper::divider();
}
if ($canDo->get('core.admin'))
{
JToolbarHelper::preferences('com_finder');
}
JToolbarHelper::divider();
$toolbar->appendButton('Popup', 'stats', 'COM_FINDER_STATISTICS', 'index.php?option=com_finder&view=statistics&tmpl=component', 550, 350);
JToolbarHelper::divider();
JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_SEARCH_FILTERS');
JHtmlSidebar::setAction('index.php?option=com_finder&view=filters');
JHtmlSidebar::addFilter(
JText::_('COM_FINDER_INDEX_FILTER_BY_STATE'),
'filter_state',
JHtml::_('select.options', JHtml::_('finder.statelist'), 'value', 'text', $this->state->get('filter.state'))
);
}
}

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,173 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JHtml::_('bootstrap.tooltip');
JHtml::_('formbehavior.chosen', 'select');
JHtml::_('bootstrap.popover');
$listOrder = $this->escape($this->state->get('list.ordering'));
$listDirn = $this->escape($this->state->get('list.direction'));
$lang = JFactory::getLanguage();
JText::script('COM_FINDER_INDEX_CONFIRM_PURGE_PROMPT');
JText::script('COM_FINDER_INDEX_CONFIRM_DELETE_PROMPT');
?>
<script type="text/javascript">
Joomla.submitbutton = function(pressbutton)
{
if (pressbutton == 'index.purge')
{
if (confirm(Joomla.JText._('COM_FINDER_INDEX_CONFIRM_PURGE_PROMPT')))
{
Joomla.submitform(pressbutton);
}
else
{
return false;
}
}
if (pressbutton == 'index.delete')
{
if (confirm(Joomla.JText._('COM_FINDER_INDEX_CONFIRM_DELETE_PROMPT')))
{
Joomla.submitform(pressbutton);
}
else
{
return false;
}
}
Joomla.submitform(pressbutton);
}
</script>
<form action="<?php echo JRoute::_('index.php?option=com_finder&view=index');?>" 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;?>
<div id="filter-bar" class="btn-toolbar">
<div class="filter-search btn-group pull-left">
<input type="text" name="filter_search" id="filter_search" placeholder="<?php echo JText::_('JSEARCH_FILTER'); ?>" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" class="hasTooltip" title="<?php echo JHtml::tooltipText('COM_FINDER_FILTER_SEARCH_DESCRIPTION'); ?>" />
</div>
<div class="btn-group pull-left">
<button type="submit" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_SUBMIT'); ?>"><i class="icon-search"></i></button>
<button type="button" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_CLEAR'); ?>" onclick="document.id('filter_search').value='';this.form.submit();"><i class="icon-remove"></i></button>
</div>
</div>
<div class="clearfix"> </div>
<?php if (!$this->pluginState['plg_content_finder']->enabled) : ?>
<div class="alert fade in">
<button class="close" data-dismiss="alert">×</button>
<?php echo JText::_('COM_FINDER_INDEX_PLUGIN_CONTENT_NOT_ENABLED'); ?>
</div>
<?php endif; ?>
<table class="table table-striped">
<thead>
<tr>
<th width="1%" class="hidden-phone">
<?php echo JHtml::_('grid.checkall'); ?>
</th>
<th width="5%">
<?php echo JHtml::_('grid.sort', 'JSTATUS', 'l.published', $listDirn, $listOrder); ?>
</th>
<th>
<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'l.title', $listDirn, $listOrder); ?>
</th>
<th class="hidden-phone"></th>
<th width="5%" class="hidden-phone">
<?php echo JHtml::_('grid.sort', 'COM_FINDER_INDEX_HEADING_INDEX_TYPE', 'l.type_id', $listDirn, $listOrder); ?>
</th>
<th width="15%" class="hidden-phone">
<?php echo JHtml::_('grid.sort', 'COM_FINDER_INDEX_HEADING_INDEX_DATE', 'l.indexdate', $listDirn, $listOrder); ?>
</th>
</tr>
</thead>
<tbody>
<?php if (count($this->items) == 0) : ?>
<tr class="row0">
<td align="center" colspan="6">
<?php
if ($this->total == 0)
{
echo JText::_('COM_FINDER_INDEX_NO_DATA') . ' ' . JText::_('COM_FINDER_INDEX_TIP');
} else {
echo JText::_('COM_FINDER_INDEX_NO_CONTENT');
}
?>
</td>
</tr>
<?php endif; ?>
<?php $canChange = JFactory::getUser()->authorise('core.manage', 'com_finder'); ?>
<?php foreach ($this->items as $i => $item) : ?>
<tr class="row<?php echo $i % 2; ?>">
<td class="center hidden-phone">
<?php echo JHtml::_('grid.id', $i, $item->link_id); ?>
</td>
<td>
<?php echo JHtml::_('jgrid.published', $item->published, $i, 'index.', $canChange, 'cb'); ?>
</td>
<td>
<strong>
<?php echo $this->escape($item->title); ?>
</strong>
<small class="muted">
<?php
if (strlen($item->url) > 80)
{
echo substr($item->url, 0, 70) . '...';
} else {
echo $item->url;
}
?>
</small>
</td>
<td class="hidden-phone">
<?php if (intval($item->publish_start_date) or intval($item->publish_end_date) or intval($item->start_date) or intval($item->end_date)) : ?>
<i class="icon-calendar pull-right pop hasPopover" data-placement="left" title="<?php echo JText::_('JDETAILS');?>" data-content="<?php echo JText::sprintf('COM_FINDER_INDEX_DATE_INFO', $item->publish_start_date, $item->publish_end_date, $item->start_date, $item->end_date);?>"></i>
<?php endif; ?>
</td>
<td class="small nowrap hidden-phone">
<?php
$key = FinderHelperLanguage::branchSingular($item->t_title);
echo $lang->hasKey($key) ? JText::_($key) : $item->t_title;
?>
</td>
<td class="small nowrap hidden-phone">
<?php echo JHtml::_('date', $item->indexdate, JText::_('DATE_FORMAT_LC4')); ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
<tfoot>
<tr>
<td colspan="6" class="nowrap">
<?php echo $this->pagination->getListFooter(); ?>
</td>
</tr>
</tfoot>
</table>
<input type="hidden" name="task" value="display" />
<input type="hidden" name="boxchecked" value="0" />
<input type="hidden" name="filter_order" value="<?php echo $listOrder ?>" />
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn ?>" />
<?php echo JHtml::_('form.token'); ?>
</div>
</form>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,116 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JLoader::register('FinderHelperLanguage', JPATH_ADMINISTRATOR . '/components/com_finder/helpers/language.php');
/**
* Index view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewIndex extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return mixed A string if successful, otherwise a JError object.
*
* @since 2.5
*/
public function display($tpl = null)
{
// Load plug-in language files.
FinderHelperLanguage::loadPluginLanguage();
$this->items = $this->get('Items');
$this->total = $this->get('Total');
$this->pagination = $this->get('Pagination');
$this->state = $this->get('State');
$this->pluginState = $this->get('pluginState');
FinderHelper::addSubmenu('index');
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseError(500, implode("\n", $errors));
return false;
}
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
// Configure the toolbar.
$this->addToolbar();
$this->sidebar = JHtmlSidebar::render();
parent::display($tpl);
}
/**
* Method to configure the toolbar for this view.
*
* @return void
*
* @since 2.5
*/
protected function addToolbar()
{
$canDo = FinderHelper::getActions();
JToolbarHelper::title(JText::_('COM_FINDER_INDEX_TOOLBAR_TITLE'), 'finder');
$toolbar = JToolbar::getInstance('toolbar');
$toolbar->appendButton(
'Popup', 'archive', 'COM_FINDER_INDEX', 'index.php?option=com_finder&view=indexer&tmpl=component', 500, 210, 0, 0,
'window.parent.location.reload()', 'COM_FINDER_HEADING_INDEXER'
);
if ($canDo->get('core.edit.state'))
{
JToolbarHelper::publishList('index.publish');
JToolbarHelper::unpublishList('index.unpublish');
}
if ($canDo->get('core.delete'))
{
JToolbarHelper::deleteList('', 'index.delete');
}
if ($canDo->get('core.edit.state'))
{
JToolbarHelper::trash('index.purge', 'COM_FINDER_INDEX_TOOLBAR_PURGE', false);
}
if ($canDo->get('core.admin'))
{
JToolbarHelper::preferences('com_finder');
}
$toolbar->appendButton('Popup', 'stats', 'COM_FINDER_STATISTICS', 'index.php?option=com_finder&view=statistics&tmpl=component', 550, 350);
JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_INDEXED_CONTENT');
JHtmlSidebar::setAction('index.php?option=com_finder&view=index');
JHtmlSidebar::addFilter(
JText::_('COM_FINDER_INDEX_FILTER_BY_STATE'),
'filter_state',
JHtml::_('select.options', JHtml::_('finder.statelist'), 'value', 'text', $this->state->get('filter.state'))
);
JHtmlSidebar::addFilter(
JText::_('COM_FINDER_INDEX_TYPE_FILTER'),
'filter_type',
JHtml::_('select.options', JHtml::_('finder.typeslist'), 'value', 'text', $this->state->get('filter.type'))
);
}
}

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,27 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JHtml::_('behavior.framework');
JHtml::_('behavior.keepalive');
?>
<div id="finder-indexer-container">
<br /><br />
<h1 id="finder-progress-header"><?php echo JText::_('COM_FINDER_INDEXER_HEADER_INIT'); ?></h1>
<p id="finder-progress-message"><?php echo JText::_('COM_FINDER_INDEXER_MESSAGE_INIT'); ?></p>
<form id="finder-progress-form"></form>
<div id="finder-progress-container"></div>
<input id="finder-indexer-token" type="hidden" name="<?php echo JFactory::getSession()->getFormToken(); ?>" value="1" />
</div>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,39 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
/**
* Indexer view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewIndexer extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return void
*
* @since 2.5
*/
public function display($tpl = null)
{
JHtml::_('behavior.framework');
JHtml::_('stylesheet', 'com_finder/indexer.css', false, true, false);
JHtml::_('script', 'com_finder/indexer.js', false, true);
JHtml::_('script', 'system/progressbar.js', true, true);
parent::display();
}
}

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,137 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JHtml::_('formbehavior.chosen', 'select');
JHtml::_('bootstrap.tooltip');
$listOrder = $this->escape($this->state->get('list.ordering'));
$listDirn = $this->escape($this->state->get('list.direction'));
$lang = JFactory::getLanguage();
JText::script('COM_FINDER_MAPS_CONFIRM_DELETE_PROMPT');
?>
<script type="text/javascript">
Joomla.submitbutton = function(pressbutton)
{
if (pressbutton == 'map.delete')
{
if (confirm(Joomla.JText._('COM_FINDER_MAPS_CONFIRM_DELETE_PROMPT')))
{
Joomla.submitform(pressbutton);
}
else
{
return false;
}
}
Joomla.submitform(pressbutton);
}
</script>
<form action="<?php echo JRoute::_('index.php?option=com_finder&view=maps');?>" 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;?>
<div id="filter-bar" class="btn-toolbar">
<div class="filter-search btn-group pull-left">
<input type="text" name="filter_search" id="filter_search" placeholder="<?php echo JText::_('JSEARCH_FILTER'); ?>" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" class="hasTooltip" title="<?php echo JHtml::tooltipText('COM_FINDER_FILTER_SEARCH_DESCRIPTION'); ?>" />
</div>
<div class="btn-group pull-left">
<button type="submit" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_SUBMIT'); ?>"><i class="icon-search"></i></button>
<button type="button" class="btn hasTooltip" title="<?php echo JHtml::tooltipText('JSEARCH_FILTER_CLEAR'); ?>" onclick="document.id('filter_search').value='';this.form.submit();"><i class="icon-remove"></i></button>
</div>
</div>
<div class="clearfix"> </div>
<table class="table table-striped">
<thead>
<tr>
<th width="1%">
<?php echo JHtml::_('grid.checkall'); ?>
</th>
<th class="nowrap">
<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'a.title', $listDirn, $listOrder); ?>
</th>
<th class="nowrap" width="10%">
<?php echo JHtml::_('grid.sort', 'JSTATUS', 'a.state', $listDirn, $listOrder); ?>
</th>
</tr>
</thead>
<tbody>
<?php if (count($this->items) == 0) : ?>
<tr class="row0">
<td class="center" colspan="5">
<?php echo JText::_('COM_FINDER_MAPS_NO_CONTENT'); ?>
</td>
</tr>
<?php endif; ?>
<?php if ($this->state->get('filter.branch') != 1) : ?>
<tr class="row1">
<td colspan="5" class="center">
<a href="#" onclick="document.id('filter_branch').value='1';document.adminForm.submit();">
<?php echo JText::_('COM_FINDER_MAPS_RETURN_TO_BRANCHES'); ?></a>
</td>
</tr>
<?php endif; ?>
<?php $canChange = JFactory::getUser()->authorise('core.manage', 'com_finder'); ?>
<?php foreach ($this->items as $i => $item) : ?>
<tr class="row<?php echo $i % 2; ?>">
<td class="center">
<?php echo JHtml::_('grid.id', $i, $item->id); ?>
</td>
<td>
<?php
$key = FinderHelperLanguage::branchSingular($item->title);
$title = $lang->hasKey($key) ? JText::_($key) : $item->title;
?>
<?php if ($this->state->get('filter.branch') == 1 && $item->num_children) : ?>
<a href="#" onclick="document.id('filter_branch').value='<?php echo (int) $item->id;?>';document.adminForm.submit();" title="<?php echo JText::_('COM_FINDER_MAPS_BRANCH_LINK'); ?>">
<?php echo $this->escape($title); ?></a>
<?php else: ?>
<?php echo $this->escape(($title == '*') ? JText::_('JALL_LANGUAGE') : $title); ?>
<?php endif; ?>
<?php if ($item->num_children > 0) : ?>
<small>(<?php echo $item->num_children; ?>)</small>
<?php elseif ($item->num_nodes > 0) : ?>
<small>(<?php echo $item->num_nodes; ?>)</small>
<?php endif; ?>
<?php if ($this->escape(trim($title, '**')) == 'Language' && JLanguageMultilang::isEnabled()) : ?>
<strong><?php echo JText::_('COM_FINDER_MAPS_MULTILANG'); ?></strong>
<?php endif; ?>
</td>
<td class="center nowrap">
<?php echo JHtml::_('jgrid.published', $item->state, $i, 'maps.', $canChange, 'cb'); ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
<tfoot>
<tr>
<td colspan="9" class="nowrap">
<?php echo $this->pagination->getListFooter(); ?>
</td>
</tr>
</tfoot>
</table>
<input type="hidden" name="task" value="display" />
<input type="hidden" name="boxchecked" value="0" />
<input type="hidden" name="filter_order" value="<?php echo $listOrder ?>" />
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn ?>" />
</div>
<?php echo JHtml::_('form.token'); ?>
</form>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,111 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
JLoader::register('FinderHelperLanguage', JPATH_ADMINISTRATOR . '/components/com_finder/helpers/language.php');
/**
* Groups view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewMaps extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return mixed A string if successful, otherwise a JError object.
*
* @since 2.5
*/
public function display($tpl = null)
{
// Load plug-in language files.
FinderHelperLanguage::loadPluginLanguage();
// Load the view data.
$this->items = $this->get('Items');
$this->total = $this->get('Total');
$this->pagination = $this->get('Pagination');
$this->state = $this->get('State');
FinderHelper::addSubmenu('maps');
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseError(500, implode("\n", $errors));
return false;
}
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
// Prepare the view.
$this->addToolbar();
$this->sidebar = JHtmlSidebar::render();
parent::display($tpl);
}
/**
* Method to configure the toolbar for this view.
*
* @return void
*
* @since 2.5
*/
protected function addToolbar()
{
// For whatever reason, the helper isn't being found
include_once JPATH_COMPONENT . '/helpers/finder.php';
$canDo = FinderHelper::getActions();
JToolbarHelper::title(JText::_('COM_FINDER_MAPS_TOOLBAR_TITLE'), 'finder');
$toolbar = JToolbar::getInstance('toolbar');
if ($canDo->get('core.edit.state'))
{
JToolbarHelper::publishList('maps.publish');
JToolbarHelper::unpublishList('maps.unpublish');
JToolbarHelper::divider();
}
if ($canDo->get('core.delete'))
{
JToolbarHelper::deleteList('', 'maps.delete');
JToolbarHelper::divider();
}
if ($canDo->get('core.admin'))
{
JToolbarHelper::preferences('com_finder');
}
JToolbarHelper::divider();
$toolbar->appendButton('Popup', 'stats', 'COM_FINDER_STATISTICS', 'index.php?option=com_finder&view=statistics&tmpl=component', 550, 350);
JToolbarHelper::divider();
JToolbarHelper::help('JHELP_COMPONENTS_FINDER_MANAGE_CONTENT_MAPS');
JHtmlSidebar::setAction('index.php?option=com_finder&view=maps');
JHtmlSidebar::addFilter(
'',
'filter_branch',
JHtml::_('select.options', JHtml::_('finder.mapslist'), 'value', 'text', $this->state->get('filter.branch')),
true
);
JHtmlSidebar::addFilter(
JText::_('COM_FINDER_INDEX_FILTER_BY_STATE'),
'filter_state',
JHtml::_('select.options', JHtml::_('finder.statelist'), 'value', 'text', $this->state->get('filter.state'))
);
}
}

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,52 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
?>
<h3>
<?php echo JText::_('COM_FINDER_STATISTICS_TITLE') ?>
</h3>
<div class="row-fluid">
<div class="span6">
<p class="tab-description"><?php echo JText::sprintf('COM_FINDER_STATISTICS_STATS_DESCRIPTION', number_format($this->data->term_count), number_format($this->data->link_count), number_format($this->data->taxonomy_node_count), number_format($this->data->taxonomy_branch_count)); ?></p>
<table class="table table-striped table-condensed">
<thead>
<tr>
<th class="center">
<?php echo JText::_('COM_FINDER_STATISTICS_LINK_TYPE_HEADING');?>
</th>
<th class="center">
<?php echo JText::_('COM_FINDER_STATISTICS_LINK_TYPE_COUNT');?>
</th>
</tr>
</thead>
<tbody>
<?php foreach ($this->data->type_list as $type) :?>
<tr>
<td>
<?php echo $type->type_title;?>
</td>
<td>
<span class="badge badge-info"><?php echo number_format($type->link_count);?></span>
</td>
</tr>
<?php endforeach; ?>
<tr>
<td>
<strong><?php echo JText::_('COM_FINDER_STATISTICS_LINK_TYPE_TOTAL'); ?></strong>
</td>
<td>
<span class="badge badge-info"><?php echo number_format($this->data->link_count); ?></span>
</td>
</tr>
</tbody>
</table>
</div>
</div>

View File

@ -0,0 +1 @@
<!DOCTYPE html><title></title>

View File

@ -0,0 +1,44 @@
<?php
/**
* @package Joomla.Administrator
* @subpackage com_finder
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE
*/
defined('_JEXEC') or die;
/**
* Statistics view class for Finder.
*
* @package Joomla.Administrator
* @subpackage com_finder
* @since 2.5
*/
class FinderViewStatistics extends JViewLegacy
{
/**
* Method to display the view.
*
* @param string $tpl A template file to load. [optional]
*
* @return mixed A string if successful, otherwise a JError object.
*
* @since 2.5
*/
public function display($tpl = null)
{
// Load the view data.
$this->data = $this->get('Data');
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseError(500, implode("\n", $errors));
return false;
}
parent::display($tpl);
}
}