Files
opensourcepos/app/Controllers/No_Access.php
objecttothis 8197e1918a - Refactor file name to match class name.
- Updated autoload in composer.json to reflect actual structure.
- Removed unneeded use statements

Signed-off-by: objecttothis <objecttothis@gmail.com>
2024-06-15 17:19:15 +02:00

33 lines
675 B
PHP

<?php
namespace App\Controllers;
use App\Models\Module;
/**
* Part of the grants mechanism to restrict access to modules that the user doesn't have permission for.
* Instantiated in the views.
*
* @property module module
*/
class No_Access extends BaseController
{
public function __construct()
{
$this->module = model('Module');
}
/**
* @param string $module_id
* @param string $permission_id
* @return void
*/
public function getIndex(string $module_id = '', string $permission_id = ''): void
{
$data['module_name'] = $this->module->get_module_name($module_id);
$data['permission_id'] = $permission_id;
echo view('no_access', $data);
}
}