Added the [Run Expansion] button option for faster compile and install option of selected components.

This commit is contained in:
2018-09-20 21:17:07 +02:00
parent b208f4f616
commit e71ba204ca
26 changed files with 530 additions and 47 deletions

View File

@@ -85,6 +85,7 @@ if ($this->saveOrder)
</form>
<script type="text/javascript">
// joomla_components footer script
// waiting spinner
var outerDiv = jQuery('body');
jQuery('<div id="loading"></div>')
@@ -99,25 +100,26 @@ jQuery('<div id="loading"></div>')
.css("filter", "alpha(opacity = 80)")
.css("display", "none")
.appendTo(outerDiv);
// when the clone button is clicked
jQuery('#toolbar').on('click',"button.button-save-copy", function(e){
if (document.adminForm.boxchecked.value != 0){
jQuery('#loading').show();
}
});
// when the backup button is clicked
jQuery('#toolbar').on('click',"button.button-archive", function(e){
if (document.adminForm.boxchecked.value != 0){
jQuery('#loading').show();
}
});
// when the export button is clicked
jQuery('#toolbar').on('click',"button.button-download", function(e){
if (document.adminForm.boxchecked.value != 0){
jQuery('#loading').show();
}
});
// when the expand button is clicked
jQuery('#toolbar').on('click',"button.button-expand-2", function(e){
jQuery('#loading').show();
});
</script>

View File

@@ -147,11 +147,21 @@ class ComponentbuilderViewJoomla_components extends JViewLegacy
// add Import JCB Packages button.
JToolBarHelper::custom('joomla_components.smartImport', 'upload', '', 'COM_COMPONENTBUILDER_IMPORT_JCB_PACKAGES', false);
}
if ($this->user->authorise('joomla_component.run_expansion', 'com_componentbuilder'))
{
// add Run Expansion button.
JToolBarHelper::custom('joomla_components.runExpansion', 'expand-2', '', 'COM_COMPONENTBUILDER_RUN_EXPANSION', false);
}
if ($this->user->authorise('joomla_component.backup', 'com_componentbuilder'))
{
// add Backup button.
JToolBarHelper::custom('joomla_components.backup', 'archive', '', 'COM_COMPONENTBUILDER_BACKUP', false);
}
if ($this->user->authorise('joomla_component.clear_tmp', 'com_componentbuilder'))
{
// add Clear tmp button.
JToolBarHelper::custom('joomla_components.clearTmp', 'purge', '', 'COM_COMPONENTBUILDER_CLEAR_TMP', false);
}
if ($this->canDo->get('core.import') && $this->canDo->get('joomla_component.import'))
{