2
0
mirror of https://github.com/acepanel/panel.git synced 2026-02-07 03:17:24 +08:00

特性:首次提交

This commit is contained in:
耗子
2022-11-17 00:18:56 +08:00
commit 9c63a56b14
8450 changed files with 1027165 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
<?php
namespace App\Http;
use Alexusmai\LaravelFileManager\Services\ACLService\ACLRepository;
class FilesACLRepository implements ACLRepository
{
/**
* Get user ID
*
* @return mixed
*/
public function getUserID()
{
return auth('sanctum')->id();
}
/**
* Get ACL rules list for user
*
* @return array
*/
public function getRules(): array
{
if (auth('sanctum')->check()) {
return [
['disk' => 'www', 'path' => '*', 'access' => 2],
];
} else {
return [
['disk' => 'www', 'path' => '*', 'access' => 0],
];
}
}
}