32
1
mirror of https://github.com/joomla-extensions/weblinks.git synced 2024-11-10 23:31:01 +00:00

Show Associations button on edit screen

This commit is contained in:
Tuan Pham Ngoc 2021-08-15 11:46:40 +07:00
parent 4372ed85aa
commit 4274af68e3

View File

@ -14,6 +14,7 @@ defined('_JEXEC') or die;
use Joomla\CMS\Component\ComponentHelper;
use Joomla\CMS\Factory;
use Joomla\CMS\Helper\ContentHelper;
use Joomla\CMS\Language\Associations;
use Joomla\CMS\Language\Text;
use Joomla\CMS\MVC\View\GenericDataException;
use Joomla\CMS\MVC\View\HtmlView as BaseHtmlView;
@ -163,6 +164,11 @@ class HtmlView extends BaseHtmlView
{
ToolbarHelper::versions('com_weblinks.weblink', $this->item->id);
}
if (Associations::isEnabled() && ComponentHelper::isEnabled('com_associations'))
{
ToolbarHelper::custom('weblink.editAssociations', 'contract', '', 'JTOOLBAR_ASSOCIATIONS', false, false);
}
}
}
}