2024-03-03 00:21:51 +03:00
|
|
|
<?php
|
2024-03-09 18:58:35 +03:00
|
|
|
/**
|
|
|
|
* @package Joomla.Administrator
|
|
|
|
* @subpackage com_oauthserver
|
|
|
|
*
|
|
|
|
* @copyright (c) 2024. Webmasterskaya. <https://webmasterskaya.xyz>
|
|
|
|
* @license MIT; see LICENSE.txt
|
|
|
|
**/
|
2024-03-03 00:21:51 +03:00
|
|
|
|
|
|
|
use Joomla\CMS\Layout\LayoutHelper;
|
|
|
|
|
|
|
|
\defined('_JEXEC') or die;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @var \Webmasterskaya\Component\OauthServer\Administrator\View\Clients\HtmlView $this
|
|
|
|
*/
|
|
|
|
|
|
|
|
$displayData = [
|
|
|
|
'textPrefix' => 'COM_OAUTHSERVER_ORDERS',
|
2024-03-09 18:58:35 +03:00
|
|
|
'icon' => 'icon-copy',
|
2024-03-03 00:21:51 +03:00
|
|
|
];
|
|
|
|
|
|
|
|
$user = $this->getCurrentUser();
|
|
|
|
|
|
|
|
if ($user->authorise('core.create', 'com_oauthserver')
|
|
|
|
|| count($user->getAuthorisedCategories('com_oauthserver', 'core.create')) > 0
|
|
|
|
|| $user->authorise('product.create', 'com_oauthserver')
|
|
|
|
|| count($user->getAuthorisedCategories('com_oauthserver', 'client.create')) > 0
|
2024-03-09 18:58:35 +03:00
|
|
|
)
|
|
|
|
{
|
2024-03-03 00:21:51 +03:00
|
|
|
$displayData['createURL'] = 'index.php?option=com_oauthserver&task=client.add';
|
|
|
|
}
|
|
|
|
|
2024-03-09 18:58:35 +03:00
|
|
|
echo LayoutHelper::render('joomla.content.emptystate', $displayData);
|