mirror of
				https://github.com/pelican-dev/panel.git
				synced 2025-10-31 10:06:52 +01:00 
			
		
		
		
	 2046fa453a
			
		
	
	
		2046fa453a
		
			
		
	
	
	
	
		
			
			Co-authored-by: Lance Pioch <git@lance.sh> Co-authored-by: RMartinOscar <40749467+RMartinOscar@users.noreply.github.com>
		
			
				
	
	
		
			38 lines
		
	
	
		
			843 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			38 lines
		
	
	
		
			843 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
| <?php
 | |
| 
 | |
| namespace App\Enums;
 | |
| 
 | |
| enum RolePermissionModels: string
 | |
| {
 | |
|     case ApiKey = 'apiKey';
 | |
|     case DatabaseHost = 'databaseHost';
 | |
|     case Database = 'database';
 | |
|     case Egg = 'egg';
 | |
|     case Mount = 'mount';
 | |
|     case Node = 'node';
 | |
|     case Role = 'role';
 | |
|     case Server = 'server';
 | |
|     case User = 'user';
 | |
|     case Webhook = 'webhook';
 | |
| 
 | |
|     public function viewAny(): string
 | |
|     {
 | |
|         return RolePermissionPrefixes::ViewAny->value . ' ' . $this->value;
 | |
|     }
 | |
| 
 | |
|     public function view(): string
 | |
|     {
 | |
|         return RolePermissionPrefixes::View->value . ' ' . $this->value;
 | |
|     }
 | |
| 
 | |
|     public function create(): string
 | |
|     {
 | |
|         return RolePermissionPrefixes::Create->value . ' ' . $this->value;
 | |
|     }
 | |
| 
 | |
|     public function update(): string
 | |
|     {
 | |
|         return RolePermissionPrefixes::Update->value . ' ' . $this->value;
 | |
|     }
 | |
| }
 |