mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-29 19:25:57 +00:00
trash fixed
This commit is contained in:
@@ -184,6 +184,7 @@ class SetupDevEnvironment extends Command
|
|||||||
->create([
|
->create([
|
||||||
'type' => 'folder',
|
'type' => 'folder',
|
||||||
'item_id' => $shared_folder->id,
|
'item_id' => $shared_folder->id,
|
||||||
|
'user_id' => $user->id,
|
||||||
'permission' => 'editor',
|
'permission' => 'editor',
|
||||||
'is_protected' => false,
|
'is_protected' => false,
|
||||||
'password' => null,
|
'password' => null,
|
||||||
@@ -318,6 +319,7 @@ class SetupDevEnvironment extends Command
|
|||||||
->create([
|
->create([
|
||||||
'type' => 'folder',
|
'type' => 'folder',
|
||||||
'item_id' => $documents->id,
|
'item_id' => $documents->id,
|
||||||
|
'user_id' => $user->id,
|
||||||
'permission' => 'editor',
|
'permission' => 'editor',
|
||||||
'is_protected' => false,
|
'is_protected' => false,
|
||||||
'password' => null,
|
'password' => null,
|
||||||
@@ -722,7 +724,7 @@ class SetupDevEnvironment extends Command
|
|||||||
],
|
],
|
||||||
[
|
[
|
||||||
'name' => 'app_favicon',
|
'name' => 'app_favicon',
|
||||||
'value' => null,
|
'value' => 'system/favicon.png',
|
||||||
],
|
],
|
||||||
[
|
[
|
||||||
'name' => 'google_analytics',
|
'name' => 'google_analytics',
|
||||||
@@ -764,7 +766,7 @@ class SetupDevEnvironment extends Command
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Get system images
|
// Get system images
|
||||||
collect(['logo.svg', 'logo-horizontal.svg'])
|
collect(['logo.svg', 'logo-horizontal.svg', 'favicon.png'])
|
||||||
->each(function ($file) {
|
->each(function ($file) {
|
||||||
\File::copy(storage_path("demo/app/$file"), storage_path("app/system/$file"));
|
\File::copy(storage_path("demo/app/$file"), storage_path("app/system/$file"));
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -105,8 +105,10 @@ class BrowseController extends Controller
|
|||||||
$files_trashed = File::onlyTrashed()
|
$files_trashed = File::onlyTrashed()
|
||||||
->with(['parent'])
|
->with(['parent'])
|
||||||
->where('user_id', $user_id)
|
->where('user_id', $user_id)
|
||||||
->whereNull('folder_id')
|
->where(function($query) use ($folders_trashed) {
|
||||||
->orWhereNotIn('folder_id', array_values(array_unique(recursiveFind($folders_trashed->toArray(), 'id'))))
|
$query->whereNull('folder_id');
|
||||||
|
$query->orWhereNotIn('folder_id', array_values(array_unique(recursiveFind($folders_trashed->toArray(), 'id'))));
|
||||||
|
})
|
||||||
->sortable()
|
->sortable()
|
||||||
->get();
|
->get();
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 3.4 KiB |
@@ -338,8 +338,8 @@ class BrowseTest extends TestCase
|
|||||||
'parent_id' => null,
|
'parent_id' => null,
|
||||||
'name' => 'root',
|
'name' => 'root',
|
||||||
'user_id' => $user->id,
|
'user_id' => $user->id,
|
||||||
'deleted_at' => Carbon::now(),
|
|
||||||
"user_scope" => "master",
|
"user_scope" => "master",
|
||||||
|
'deleted_at' => Carbon::now(),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$file = File::factory(File::class)
|
$file = File::factory(File::class)
|
||||||
|
|||||||
Reference in New Issue
Block a user