forked from joomla/Component-Builder
Fixed tab line-up so the linked component in the admin_view will show again
This commit is contained in:
parent
dfd98aeacf
commit
f7b168d762
@ -114,8 +114,8 @@ Component Builder is mapped as a component in itself on my local development env
|
||||
+ *Version*: 2.5.8
|
||||
+ *Copyright*: Copyright (C) 2015. All Rights Reserved
|
||||
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
|
||||
+ *Line count*: **123911**
|
||||
+ *File count*: **741**
|
||||
+ *Line count*: **123978**
|
||||
+ *File count*: **742**
|
||||
+ *Folder count*: **129**
|
||||
|
||||
> This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder).
|
||||
|
@ -114,8 +114,8 @@ Component Builder is mapped as a component in itself on my local development env
|
||||
+ *Version*: 2.5.8
|
||||
+ *Copyright*: Copyright (C) 2015. All Rights Reserved
|
||||
+ *License*: GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
|
||||
+ *Line count*: **123911**
|
||||
+ *File count*: **741**
|
||||
+ *Line count*: **123978**
|
||||
+ *File count*: **742**
|
||||
+ *Folder count*: **129**
|
||||
|
||||
> This **component** was build with a Joomla [Automated Component Builder](http://vdm.bz/component-builder).
|
||||
|
@ -532,6 +532,7 @@ COM_COMPONENTBUILDER_ADMIN_VIEW_KEY_LABEL="Child Key"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LAMP="Lamp"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LAST="Last"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LINK="Link"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LINKED_COMPONENTS="Linked - Components"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LIST="List"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LIST_TWO="List 2"
|
||||
COM_COMPONENTBUILDER_ADMIN_VIEW_LOCATION="Location"
|
||||
|
@ -27,112 +27,30 @@
|
||||
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
// set the defaults
|
||||
$items = $displayData->vxzcustom_import;
|
||||
$user = JFactory::getUser();
|
||||
$id = $displayData->item->id;
|
||||
$edit = "index.php?option=com_componentbuilder&view=joomla_components&task=joomla_component.edit";
|
||||
$form = $displayData->getForm();
|
||||
|
||||
$fields = $displayData->get('fields') ?: array(
|
||||
'note_beginner_import',
|
||||
'note_advanced_import',
|
||||
'add_custom_import',
|
||||
'php_import_display',
|
||||
'html_import_view',
|
||||
'php_import',
|
||||
'php_import_setdata',
|
||||
'php_import_save',
|
||||
'php_import_ext'
|
||||
);
|
||||
|
||||
?>
|
||||
<div class="form-vertical">
|
||||
<?php if (ComponentbuilderHelper::checkArray($items)): ?>
|
||||
<table class="footable table data joomla_components" data-show-toggle="true" data-toggle-column="first" data-sorting="true" data-paging="true" data-paging-size="20" data-filtering="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_SYSTEM_NAME_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_NAME_CODE_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_COMPONENT_VERSION_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_SHORT_DESCRIPTION_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_COMPANYNAME_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_AUTHOR_LABEL'); ?>
|
||||
</th>
|
||||
<th width="10" data-breakpoints="xs sm md">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_STATUS'); ?>
|
||||
</th>
|
||||
<th width="5" data-type="number" data-breakpoints="xs sm md">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_ID'); ?>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($items as $i => $item): ?>
|
||||
<?php
|
||||
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $item->checked_out == $user->id || $item->checked_out == 0;
|
||||
$userChkOut = JFactory::getUser($item->checked_out);
|
||||
$canDo = ComponentbuilderHelper::getActions('joomla_component',$item,'joomla_components');
|
||||
?>
|
||||
<tr>
|
||||
<td class="nowrap">
|
||||
<?php if ($canDo->get('core.edit')): ?>
|
||||
<a href="<?php echo $edit; ?>&id=<?php echo $item->id; ?>&ref=admin_view&refid=<?php echo $id; ?>"><?php echo $displayData->escape($item->system_name); ?></a>
|
||||
<?php if ($item->checked_out): ?>
|
||||
<?php echo JHtml::_('jgrid.checkedout', $i, $userChkOut->name, $item->checked_out_time, 'joomla_components.', $canCheckin); ?>
|
||||
<?php endif; ?>
|
||||
<?php else: ?>
|
||||
<div class="name"><?php echo $displayData->escape($item->system_name); ?></div>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->name_code); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->component_version); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->short_description); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->companyname); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->author); ?>
|
||||
</td>
|
||||
<?php if ($item->published == 1):?>
|
||||
<td class="center" data-sort-value="1">
|
||||
<span class="status-metro status-published" title="<?php echo JText::_('PUBLISHED'); ?>">
|
||||
<?php echo JText::_('PUBLISHED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == 0):?>
|
||||
<td class="center" data-sort-value="2">
|
||||
<span class="status-metro status-inactive" title="<?php echo JText::_('INACTIVE'); ?>">
|
||||
<?php echo JText::_('INACTIVE'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == 2):?>
|
||||
<td class="center" data-sort-value="3">
|
||||
<span class="status-metro status-archived" title="<?php echo JText::_('ARCHIVED'); ?>">
|
||||
<?php echo JText::_('ARCHIVED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == -2):?>
|
||||
<td class="center" data-sort-value="4">
|
||||
<span class="status-metro status-trashed" title="<?php echo JText::_('ARCHIVED'); ?>">
|
||||
<?php echo JText::_('ARCHIVED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
<td class="nowrap center hidden-phone">
|
||||
<?php echo $item->id; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php else: ?>
|
||||
<div class="alert alert-no-items">
|
||||
<?php echo JText::_('JGLOBAL_NO_MATCHING_RESULTS'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php foreach($fields as $field): ?>
|
||||
<div class="control-group">
|
||||
<div class="control-label">
|
||||
<?php echo $form->getLabel($field); ?>
|
||||
</div>
|
||||
<div class="controls">
|
||||
<?php echo $form->getInput($field); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
|
138
admin/layouts/admin_view/linked_components_fullwidth.php
Normal file
138
admin/layouts/admin_view/linked_components_fullwidth.php
Normal file
@ -0,0 +1,138 @@
|
||||
<?php
|
||||
/*--------------------------------------------------------------------------------------------------------| www.vdm.io |------/
|
||||
__ __ _ _____ _ _ __ __ _ _ _
|
||||
\ \ / / | | | __ \ | | | | | \/ | | | | | | |
|
||||
\ \ / /_ _ ___| |_ | | | | _____ _____| | ___ _ __ _ __ ___ ___ _ __ | |_ | \ / | ___| |_| |__ ___ __| |
|
||||
\ \/ / _` / __| __| | | | |/ _ \ \ / / _ \ |/ _ \| '_ \| '_ ` _ \ / _ \ '_ \| __| | |\/| |/ _ \ __| '_ \ / _ \ / _` |
|
||||
\ / (_| \__ \ |_ | |__| | __/\ V / __/ | (_) | |_) | | | | | | __/ | | | |_ | | | | __/ |_| | | | (_) | (_| |
|
||||
\/ \__,_|___/\__| |_____/ \___| \_/ \___|_|\___/| .__/|_| |_| |_|\___|_| |_|\__| |_| |_|\___|\__|_| |_|\___/ \__,_|
|
||||
| |
|
||||
|_|
|
||||
/-------------------------------------------------------------------------------------------------------------------------------/
|
||||
|
||||
@version 2.5.8
|
||||
@build 13th October, 2017
|
||||
@created 30th April, 2015
|
||||
@package Component Builder
|
||||
@subpackage linked_components_fullwidth.php
|
||||
@author Llewellyn van der Merwe <http://vdm.bz/component-builder>
|
||||
@copyright Copyright (C) 2015. All Rights Reserved
|
||||
@license GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
||||
Builds Complex Joomla Components
|
||||
|
||||
/-----------------------------------------------------------------------------------------------------------------------------*/
|
||||
|
||||
// No direct access to this file
|
||||
|
||||
defined('_JEXEC') or die('Restricted access');
|
||||
|
||||
// set the defaults
|
||||
$items = $displayData->vxzlinked_components;
|
||||
$user = JFactory::getUser();
|
||||
$id = $displayData->item->id;
|
||||
$edit = "index.php?option=com_componentbuilder&view=joomla_components&task=joomla_component.edit";
|
||||
|
||||
?>
|
||||
<div class="form-vertical">
|
||||
<?php if (ComponentbuilderHelper::checkArray($items)): ?>
|
||||
<table class="footable table data joomla_components" data-show-toggle="true" data-toggle-column="first" data-sorting="true" data-paging="true" data-paging-size="20" data-filtering="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_SYSTEM_NAME_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_NAME_CODE_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_COMPONENT_VERSION_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_SHORT_DESCRIPTION_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_COMPANYNAME_LABEL'); ?>
|
||||
</th>
|
||||
<th data-breakpoints="xs sm md" data-type="html" data-sort-use="text">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_AUTHOR_LABEL'); ?>
|
||||
</th>
|
||||
<th width="10" data-breakpoints="xs sm md">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_STATUS'); ?>
|
||||
</th>
|
||||
<th width="5" data-type="number" data-breakpoints="xs sm md">
|
||||
<?php echo JText::_('COM_COMPONENTBUILDER_JOOMLA_COMPONENT_ID'); ?>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php foreach ($items as $i => $item): ?>
|
||||
<?php
|
||||
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $item->checked_out == $user->id || $item->checked_out == 0;
|
||||
$userChkOut = JFactory::getUser($item->checked_out);
|
||||
$canDo = ComponentbuilderHelper::getActions('joomla_component',$item,'joomla_components');
|
||||
?>
|
||||
<tr>
|
||||
<td class="nowrap">
|
||||
<?php if ($canDo->get('core.edit')): ?>
|
||||
<a href="<?php echo $edit; ?>&id=<?php echo $item->id; ?>&ref=admin_view&refid=<?php echo $id; ?>"><?php echo $displayData->escape($item->system_name); ?></a>
|
||||
<?php if ($item->checked_out): ?>
|
||||
<?php echo JHtml::_('jgrid.checkedout', $i, $userChkOut->name, $item->checked_out_time, 'joomla_components.', $canCheckin); ?>
|
||||
<?php endif; ?>
|
||||
<?php else: ?>
|
||||
<div class="name"><?php echo $displayData->escape($item->system_name); ?></div>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->name_code); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->component_version); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->short_description); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->companyname); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo $displayData->escape($item->author); ?>
|
||||
</td>
|
||||
<?php if ($item->published == 1):?>
|
||||
<td class="center" data-sort-value="1">
|
||||
<span class="status-metro status-published" title="<?php echo JText::_('PUBLISHED'); ?>">
|
||||
<?php echo JText::_('PUBLISHED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == 0):?>
|
||||
<td class="center" data-sort-value="2">
|
||||
<span class="status-metro status-inactive" title="<?php echo JText::_('INACTIVE'); ?>">
|
||||
<?php echo JText::_('INACTIVE'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == 2):?>
|
||||
<td class="center" data-sort-value="3">
|
||||
<span class="status-metro status-archived" title="<?php echo JText::_('ARCHIVED'); ?>">
|
||||
<?php echo JText::_('ARCHIVED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php elseif ($item->published == -2):?>
|
||||
<td class="center" data-sort-value="4">
|
||||
<span class="status-metro status-trashed" title="<?php echo JText::_('ARCHIVED'); ?>">
|
||||
<?php echo JText::_('ARCHIVED'); ?>
|
||||
</span>
|
||||
</td>
|
||||
<?php endif; ?>
|
||||
<td class="nowrap center hidden-phone">
|
||||
<?php echo $item->id; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php else: ?>
|
||||
<div class="alert alert-no-items">
|
||||
<?php echo JText::_('JGLOBAL_NO_MATCHING_RESULTS'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
@ -383,7 +383,7 @@ class ComponentbuilderModelAdmin_view extends JModelAdmin
|
||||
*
|
||||
* @return mixed An array of data items on success, false on failure.
|
||||
*/
|
||||
public function getVxzcustom_import()
|
||||
public function getVxzlinked_components()
|
||||
{
|
||||
// Get the user object.
|
||||
$user = JFactory::getUser();
|
||||
|
@ -157,6 +157,17 @@ $componentParams = JComponentHelper::getParams('com_componentbuilder');
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
|
||||
<?php if ($this->canDo->get('joomla_component.access')) : ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'admin_viewTab', 'linked_components', JText::_('COM_COMPONENTBUILDER_ADMIN_VIEW_LINKED_COMPONENTS', true)); ?>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
</div>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
<div class="span12">
|
||||
<?php echo JLayoutHelper::render('admin_view.linked_components_fullwidth', $this); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'admin_viewTab', 'custom_import', JText::_('COM_COMPONENTBUILDER_ADMIN_VIEW_CUSTOM_IMPORT', true)); ?>
|
||||
<div class="row-fluid form-horizontal-desktop">
|
||||
</div>
|
||||
@ -166,7 +177,6 @@ $componentParams = JComponentHelper::getParams('com_componentbuilder');
|
||||
</div>
|
||||
</div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ($this->canDo->get('admin_view.delete') || $this->canDo->get('admin_view.edit.created_by') || $this->canDo->get('admin_view.edit.state') || $this->canDo->get('admin_view.edit.created')) : ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'admin_viewTab', 'publishing', JText::_('COM_COMPONENTBUILDER_ADMIN_VIEW_PUBLISHING', true)); ?>
|
||||
|
@ -71,7 +71,7 @@ class ComponentbuilderViewAdmin_view extends JViewLegacy
|
||||
}
|
||||
|
||||
// Get Linked view data
|
||||
$this->vxzcustom_import = $this->get('Vxzcustom_import');
|
||||
$this->vxzlinked_components = $this->get('Vxzlinked_components');
|
||||
|
||||
// Set the toolbar
|
||||
$this->addToolBar();
|
||||
|
Loading…
Reference in New Issue
Block a user