mirror of
https://github.com/filegator/filegator.git
synced 2025-08-13 06:34:35 +02:00
Added chmod perm, modal to change, api with local/ftp/sftp (#399)
Read a fill current permissions for local driver Finished permissions for ftp driver, read and change Read permissions for sftp adapter Created FilegatorFtp for a cleaner permissions integration Implemented recursive chmod options for files/folders Modified tests to cover permissions Lint frontend permissions component
This commit is contained in:
@@ -23,7 +23,7 @@ class DirectoryCollection implements \JsonSerializable
|
||||
$this->location = $location;
|
||||
}
|
||||
|
||||
public function addFile(string $type, string $path, string $name, int $size, int $timestamp)
|
||||
public function addFile(string $type, string $path, string $name, int $size, int $timestamp, int $permissions)
|
||||
{
|
||||
if (! in_array($type, ['dir', 'file', 'back'])) {
|
||||
throw new \Exception('Invalid file type.');
|
||||
@@ -35,6 +35,7 @@ class DirectoryCollection implements \JsonSerializable
|
||||
'name' => $name,
|
||||
'size' => $size,
|
||||
'time' => $timestamp,
|
||||
'permissions' => $permissions,
|
||||
]);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user