mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-05 18:23:48 +00:00
latest database backups included into the admin settings
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
<div class="mb-8 flex items-center">
|
||||
<edit-2-icon v-if="!icon" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<frown-icon v-if="icon === 'frown'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<info-icon v-if="icon === 'info'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<database-icon v-if="icon === 'database'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<file-text-icon v-if="icon === 'file-text'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<dollar-sign-icon v-if="icon === 'dollar'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
<credit-card-icon v-if="icon === 'credit-card'" size="22" class="vue-feather text-theme dark-text-theme mr-3" />
|
||||
@@ -21,6 +23,8 @@
|
||||
|
||||
<script>
|
||||
import {
|
||||
InfoIcon,
|
||||
DatabaseIcon,
|
||||
UsersIcon,
|
||||
ShieldIcon,
|
||||
CreditCardIcon,
|
||||
@@ -40,6 +44,8 @@ export default {
|
||||
name: 'FormLabel',
|
||||
props: ['icon'],
|
||||
components: {
|
||||
InfoIcon,
|
||||
DatabaseIcon,
|
||||
UsersIcon,
|
||||
CreditCardIcon,
|
||||
DollarSignIcon,
|
||||
|
||||
@@ -1,9 +1,64 @@
|
||||
<template>
|
||||
<PageTab v-if="! isLoading">
|
||||
<!--Cron check-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel icon="info">
|
||||
Cron
|
||||
</FormLabel>
|
||||
|
||||
<div class="flex items-center justify-between">
|
||||
<div class="text-left">
|
||||
<b class="text-sm font-bold block">Cron Jobs</b>
|
||||
<small v-if="!cron.running" class="text-xs text-gray-600">
|
||||
We detect, your cron jobs probably doesn't work correctly, please check it.
|
||||
</small>
|
||||
<small v-if="cron.running" class="text-xs text-gray-600">
|
||||
Latest Update: {{ cron.lastUpdate }}
|
||||
</small>
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
<check-icon v-if="cron.running" size="16" class="vue-feather text-theme"/>
|
||||
<x-icon v-if="!cron.running" size="16" class="vue-feather text-red-600" />
|
||||
|
||||
<span class="ml-3 text-sm font-bold" :class="cron.running ? 'text-green-600' : 'text-red-600'">
|
||||
{{ cron.running ? 'Working correctly' : "Doesn't work" }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--Database Backups check-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel icon="database">
|
||||
Latest Database Backups
|
||||
</FormLabel>
|
||||
|
||||
<InfoBox v-if="! backups.length" class="!mb-0">
|
||||
<p v-html="$t('There is not any database backup stored.')"></p>
|
||||
</InfoBox>
|
||||
|
||||
<InfoBox v-if="backups.length" class="!mb-3">
|
||||
<p v-html="$t('You can find your backups in <b>/storage/app/app-backups</b>.')"></p>
|
||||
</InfoBox>
|
||||
|
||||
<div v-if="backups.length" v-for="(filename, i) in backups" :key="i" class="py-3 flex items-center justify-between border-b border-dashed border-light dark:border-opacity-5">
|
||||
<div class="text-left">
|
||||
<b class="text-sm font-bold block">{{ filename }}</b>
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
<check-icon size="16" class="vue-feather text-theme"/>
|
||||
|
||||
<span class="ml-3 text-sm font-bold text-green-600">
|
||||
Stored Successfully
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--PHP version and ini check-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel>
|
||||
PHP Version & php.ini
|
||||
<FormLabel icon="info">
|
||||
PHP Settings
|
||||
</FormLabel>
|
||||
|
||||
<div class="py-3 flex items-center justify-between border-b border-dashed border-light dark:border-opacity-5">
|
||||
@@ -43,8 +98,8 @@
|
||||
|
||||
<!--PHP Extension info-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel>
|
||||
Required PHP Extensions
|
||||
<FormLabel icon="info">
|
||||
PHP Extensions
|
||||
</FormLabel>
|
||||
|
||||
<div v-if="modules" v-for="(value, module, i) in modules" :key="i" class="py-3 flex items-center justify-between border-b border-dashed border-light dark:border-opacity-5">
|
||||
@@ -61,58 +116,14 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--API check-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel>
|
||||
Others
|
||||
</FormLabel>
|
||||
|
||||
<div class="py-3 flex items-center justify-between border-b border-dashed border-light dark:border-opacity-5">
|
||||
<div class="text-left">
|
||||
<b class="text-sm font-bold block">API</b>
|
||||
<small v-if="isCheckedAPI && !apiRunning" class="text-xs text-gray-600">
|
||||
We detect, your domain root is not set correctly, please check it.
|
||||
</small>
|
||||
</div>
|
||||
<div v-if="isCheckedAPI" class="flex items-center">
|
||||
<check-icon v-if="apiRunning" size="16" class="vue-feather text-theme"/>
|
||||
<x-icon v-if="!apiRunning" size="16" class="vue-feather text-red-600" />
|
||||
|
||||
<span class="ml-3 text-sm font-bold" :class="apiRunning ? 'text-green-600' : 'text-red-600'">
|
||||
{{ apiRunning ? 'Working correctly' : "Doesn't work" }}
|
||||
</span>
|
||||
</div>
|
||||
<span v-if="!isCheckedAPI" class="ml-3 text-sm font-bold text-gray-600">Checking your API...</span>
|
||||
</div>
|
||||
|
||||
<div class="pt-3 flex items-center justify-between">
|
||||
<div class="text-left">
|
||||
<b class="text-sm font-bold block">Cron</b>
|
||||
<small v-if="!cron.running" class="text-xs text-gray-600">
|
||||
We detect, your cron jobs probably doesn't work correctly, please check it.
|
||||
</small>
|
||||
<small v-if="cron.running" class="text-xs text-gray-600">
|
||||
Latest Update: {{ cron.lastUpdate }}
|
||||
</small>
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
<check-icon v-if="cron.running" size="16" class="vue-feather text-theme"/>
|
||||
<x-icon v-if="!cron.running" size="16" class="vue-feather text-red-600" />
|
||||
|
||||
<span class="ml-3 text-sm font-bold" :class="cron.running ? 'text-green-600' : 'text-red-600'">
|
||||
{{ cron.running ? 'Working correctly' : "Doesn't work" }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</PageTab>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { CheckIcon, XIcon } from 'vue-feather-icons'
|
||||
import InfoBox from "../../../../components/Others/Forms/InfoBox"
|
||||
import FormLabel from '../../../../components/Others/Forms/FormLabel'
|
||||
import PageTab from '../../../../components/Others/Layout/PageTab'
|
||||
import { CheckIcon, XIcon } from 'vue-feather-icons'
|
||||
import { mapGetters } from 'vuex'
|
||||
import axios from "axios";
|
||||
|
||||
@@ -120,6 +131,7 @@ export default {
|
||||
name: 'Server',
|
||||
components: {
|
||||
FormLabel,
|
||||
InfoBox,
|
||||
PageTab,
|
||||
CheckIcon,
|
||||
XIcon,
|
||||
@@ -138,6 +150,7 @@ export default {
|
||||
modules: undefined,
|
||||
phpVersion: undefined,
|
||||
apiRunning: undefined,
|
||||
backups: undefined,
|
||||
}
|
||||
},
|
||||
created() {
|
||||
@@ -149,6 +162,7 @@ export default {
|
||||
this.cron = response.data.cron
|
||||
this.modules = response.data.modules
|
||||
this.phpVersion = response.data.php_version
|
||||
this.backups = response.data.backups
|
||||
})
|
||||
|
||||
// Ping API
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<!--PHP version and ini check-->
|
||||
<div class="card shadow-card">
|
||||
<FormLabel>
|
||||
PHP Version and php.ini
|
||||
PHP Setup
|
||||
</FormLabel>
|
||||
|
||||
<InfoBox class="!mb-2">
|
||||
|
||||
@@ -2,16 +2,16 @@
|
||||
|
||||
use Domain\Admin\Controllers\Users\UserController;
|
||||
use Domain\Pages\Controllers\AdminPagesController;
|
||||
use Domain\Settings\Controllers\GetServerStatusController;
|
||||
use Domain\Settings\Controllers\StoreEmailCredentialsController;
|
||||
use Domain\Settings\Controllers\FlushCacheController;
|
||||
use Domain\Localization\Controllers\LanguageController;
|
||||
use Domain\Admin\Controllers\Users\DeleteUserController;
|
||||
use Domain\Settings\Controllers\GetServerStatusController;
|
||||
use Domain\Settings\Controllers\GetSettingsValueController;
|
||||
use Domain\Admin\Controllers\Dashboard\GetNewbiesController;
|
||||
use Domain\Admin\Controllers\Users\ChangeUserRoleController;
|
||||
use Domain\Settings\Controllers\UpdateSettingValueController;
|
||||
use Domain\Admin\Controllers\Users\ResetUserPasswordController;
|
||||
use Domain\Settings\Controllers\StoreEmailCredentialsController;
|
||||
use Domain\Transactions\Controllers\GetAllTransactionsController;
|
||||
use Domain\Admin\Controllers\Dashboard\GetDashboardDataController;
|
||||
use Domain\Transactions\Controllers\GetUserTransactionsController;
|
||||
|
||||
@@ -1,15 +1,14 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
use App\Users\Models\User;
|
||||
use Illuminate\Console\Command;
|
||||
use Domain\Settings\Models\Setting;
|
||||
use Illuminate\Foundation\Testing\WithFaker;
|
||||
use Domain\Pages\Actions\SeedDefaultPagesAction;
|
||||
use Domain\Settings\Actions\SeedDefaultSettingsAction;
|
||||
use Domain\Localization\Actions\SeedDefaultLanguageAction;
|
||||
use Domain\SetupWizard\Actions\CreateDiskDirectoriesAction;
|
||||
use Illuminate\Foundation\Testing\WithFaker;
|
||||
|
||||
class SetupProdEnvironment extends Command
|
||||
{
|
||||
@@ -29,11 +28,10 @@ class SetupProdEnvironment extends Command
|
||||
|
||||
public function __construct(
|
||||
private CreateDiskDirectoriesAction $createDiskDirectories,
|
||||
private SeedDefaultSettingsAction $seedDefaultSettings,
|
||||
private SeedDefaultLanguageAction $seedDefaultLanguage,
|
||||
private SeedDefaultPagesAction $seedDefaultPages,
|
||||
)
|
||||
{
|
||||
private SeedDefaultSettingsAction $seedDefaultSettings,
|
||||
private SeedDefaultLanguageAction $seedDefaultLanguage,
|
||||
private SeedDefaultPagesAction $seedDefaultPages,
|
||||
) {
|
||||
parent::__construct();
|
||||
$this->setUpFaker();
|
||||
}
|
||||
@@ -199,16 +197,16 @@ class SetupProdEnvironment extends Command
|
||||
});
|
||||
|
||||
if ($this->argument('license') === 'extended') {
|
||||
$choice = $this->choice("Choose subscription type", [
|
||||
$choice = $this->choice('Choose subscription type', [
|
||||
'metered' => 'Metered',
|
||||
'fixed' => 'Fixed',
|
||||
'none' => 'None',
|
||||
]);
|
||||
|
||||
Setting::updateOrCreate([
|
||||
'name' => 'subscription_type'
|
||||
'name' => 'subscription_type',
|
||||
], [
|
||||
'value' => $choice
|
||||
'value' => $choice,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
<?php
|
||||
namespace App\Console;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Illuminate\Console\Scheduling\Schedule;
|
||||
use App\Console\Commands\SetupDevEnvironment;
|
||||
use App\Console\Commands\SetupProdEnvironment;
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
<?php
|
||||
|
||||
namespace App\Users\Actions;
|
||||
|
||||
use App\Users\Models\User;
|
||||
use App\Users\DTO\CreateUserData;
|
||||
use App\Http\Controllers\Controller;
|
||||
use Domain\Teams\Models\TeamFolderInvitation;
|
||||
use Domain\Teams\Models\TeamFolderMember;
|
||||
use Illuminate\Auth\Events\Registered;
|
||||
use Domain\Teams\Models\TeamFolderMember;
|
||||
use Domain\Teams\Models\TeamFolderInvitation;
|
||||
|
||||
class CreateNewUserAction extends Controller
|
||||
{
|
||||
public function __construct(
|
||||
protected AutoSubscribeForMeteredBillingAction $autoSubscribeForMeteredBilling,
|
||||
) {}
|
||||
) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Validate and create a new user.
|
||||
@@ -61,7 +61,7 @@ class CreateNewUserAction extends Controller
|
||||
}
|
||||
|
||||
// Mark as verified if verification is disabled
|
||||
if (!$data->password || !intval($settings['user_verification'])) {
|
||||
if (! $data->password || ! intval($settings['user_verification'])) {
|
||||
$user->markEmailAsVerified();
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,8 @@ class IndexController
|
||||
{
|
||||
public function __construct(
|
||||
public GetServerSetupStatusAction $getServerSetupStatus,
|
||||
) {}
|
||||
) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Show index page
|
||||
@@ -34,7 +35,8 @@ class IndexController
|
||||
|
||||
// Get all settings
|
||||
$settings = get_settings_in_json();
|
||||
} catch (PDOException $e) {}
|
||||
} catch (PDOException $e) {
|
||||
}
|
||||
|
||||
if ($setup_status === 'installation-needed') {
|
||||
$status_check = ($this->getServerSetupStatus)();
|
||||
|
||||
@@ -1,21 +1,28 @@
|
||||
<?php
|
||||
|
||||
namespace Domain\Settings\Controllers;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Storage;
|
||||
use Support\Status\Actions\GetServerSetupStatusAction;
|
||||
|
||||
class GetServerStatusController
|
||||
{
|
||||
public function __construct(
|
||||
public GetServerSetupStatusAction $getServerSetupStatus,
|
||||
) {}
|
||||
) {
|
||||
}
|
||||
|
||||
public function __invoke(): array
|
||||
{
|
||||
// Get server data
|
||||
$status = ($this->getServerSetupStatus)();
|
||||
|
||||
// Add latest database backups
|
||||
$status['backups'] = collect(Storage::allFiles('app-backup'))
|
||||
->map(fn ($path) => str_replace('app-backup/', '', $path))
|
||||
->reverse()
|
||||
->values()
|
||||
->take(5);
|
||||
|
||||
// Add cron info
|
||||
$status['cron'] = [
|
||||
'running' => isRunningCron(),
|
||||
@@ -24,4 +31,4 @@ class GetServerStatusController
|
||||
|
||||
return $status;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
<?php
|
||||
|
||||
namespace Domain\Settings\Controllers;
|
||||
|
||||
use Artisan;
|
||||
use Domain\Settings\Requests\StoreEmailCredentialsRequest;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Http\Response;
|
||||
use Domain\Settings\Requests\StoreEmailCredentialsRequest;
|
||||
|
||||
class StoreEmailCredentialsController
|
||||
{
|
||||
@@ -17,8 +15,7 @@ class StoreEmailCredentialsController
|
||||
// Abort in demo mode
|
||||
abort_if(is_demo(), 204, 'Done.');
|
||||
|
||||
if (!app()->runningUnitTests()) {
|
||||
|
||||
if (! app()->runningUnitTests()) {
|
||||
$mail = [
|
||||
'log' => [
|
||||
'MAIL_DRIVER' => 'log',
|
||||
|
||||
@@ -23,10 +23,10 @@ class StoreEmailCredentialsRequest extends FormRequest
|
||||
public function rules()
|
||||
{
|
||||
return [
|
||||
'mailDriver' => 'required|string',
|
||||
'smtp' => 'sometimes|array',
|
||||
'ses' => 'sometimes|array',
|
||||
'mailgun' => 'sometimes|array',
|
||||
'mailDriver' => 'required|string',
|
||||
'smtp' => 'sometimes|array',
|
||||
'ses' => 'sometimes|array',
|
||||
'mailgun' => 'sometimes|array',
|
||||
'postmark' => 'sometimes|array',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<?php
|
||||
namespace Domain\SetupWizard\Controllers;
|
||||
|
||||
use App\Users\Models\User;
|
||||
use Artisan;
|
||||
use App\Users\Models\User;
|
||||
use Illuminate\Http\Response;
|
||||
use Domain\Settings\Models\Setting;
|
||||
use App\Http\Controllers\Controller;
|
||||
@@ -61,9 +61,9 @@ class CreateAdminAccountController extends Controller
|
||||
],
|
||||
])->each(function ($col) {
|
||||
Setting::updateOrCreate([
|
||||
'name' => $col['name']
|
||||
'name' => $col['name'],
|
||||
], [
|
||||
'value' => $col['value']
|
||||
'value' => $col['value'],
|
||||
]);
|
||||
});
|
||||
|
||||
|
||||
@@ -82,9 +82,9 @@ class StoreAppSettingsController extends Controller
|
||||
],
|
||||
])->each(function ($col) {
|
||||
Setting::updateOrCreate([
|
||||
'name' => $col['name']
|
||||
'name' => $col['name'],
|
||||
], [
|
||||
'value' => $col['value']
|
||||
'value' => $col['value'],
|
||||
]);
|
||||
});
|
||||
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
<?php
|
||||
namespace Domain\SetupWizard\Controllers;
|
||||
|
||||
use Artisan;
|
||||
use DB;
|
||||
use Artisan;
|
||||
use Illuminate\Http\Response;
|
||||
use Domain\Settings\Models\Setting;
|
||||
use App\Http\Controllers\Controller;
|
||||
use Doctrine\DBAL\Driver\PDOException;
|
||||
use Symfony\Component\HttpKernel\Exception\HttpException;
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
namespace Domain\SetupWizard\Controllers;
|
||||
|
||||
use Artisan;
|
||||
@@ -14,9 +13,8 @@ class StoreEnvironmentSettingsController extends Controller
|
||||
*/
|
||||
public function __invoke(
|
||||
StoreEnvironmentSetupRequest $request,
|
||||
): Response
|
||||
{
|
||||
if (!app()->runningUnitTests()) {
|
||||
): Response {
|
||||
if (! app()->runningUnitTests()) {
|
||||
$drivers = [
|
||||
'local' => [
|
||||
'FILESYSTEM_DRIVER' => 'local',
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
namespace Domain\SetupWizard\Requests;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
@@ -2,10 +2,9 @@
|
||||
namespace Domain\Teams\Controllers;
|
||||
|
||||
use App\Users\Models\User;
|
||||
use Domain\Teams\Models\TeamFolderMember;
|
||||
use Illuminate\Http\Response;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use App\Http\Controllers\Controller;
|
||||
use Domain\Teams\Models\TeamFolderMember;
|
||||
use Domain\Teams\Models\TeamFolderInvitation;
|
||||
use Illuminate\Contracts\Routing\ResponseFactory;
|
||||
use Domain\Teams\Resources\TeamInvitationResource;
|
||||
|
||||
@@ -31,13 +31,15 @@ class TeamFolderInvitation extends Model
|
||||
|
||||
protected $keyType = 'string';
|
||||
|
||||
public function accept() {
|
||||
public function accept()
|
||||
{
|
||||
$this->update([
|
||||
'status' => 'accepted',
|
||||
]);
|
||||
}
|
||||
|
||||
public function reject() {
|
||||
public function reject()
|
||||
{
|
||||
$this->update([
|
||||
'status' => 'rejected',
|
||||
]);
|
||||
|
||||
@@ -13,11 +13,11 @@ class TeamInvitationResource extends JsonResource
|
||||
'id' => $this->id,
|
||||
'type' => 'invitation',
|
||||
'attributes' => [
|
||||
'parent_id' => $this->parent_id,
|
||||
'email' => $this->email,
|
||||
'color' => $this->color,
|
||||
'status' => $this->status,
|
||||
'permission' => $this->permission,
|
||||
'parent_id' => $this->parent_id,
|
||||
'email' => $this->email,
|
||||
'color' => $this->color,
|
||||
'status' => $this->status,
|
||||
'permission' => $this->permission,
|
||||
'isExistedUser' => User::where('email', $this->email)->exists(),
|
||||
],
|
||||
'relationships' => [
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
namespace Support\Status\Actions;
|
||||
|
||||
class GetServerSetupStatusAction
|
||||
@@ -58,4 +57,4 @@ class GetServerSetupStatusAction
|
||||
],
|
||||
];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ class AdminTest extends TestCase
|
||||
|
||||
$this
|
||||
->actingAs($admin)
|
||||
->getJson("/api/admin/status")
|
||||
->getJson('/api/admin/status')
|
||||
->assertOk();
|
||||
}
|
||||
|
||||
|
||||
@@ -190,7 +190,7 @@ class SettingsTest extends TestCase
|
||||
$this
|
||||
->actingAs($admin)
|
||||
->postJson('/api/admin/settings/email', [
|
||||
'mailDriver' => 'smtp',
|
||||
'mailDriver' => 'smtp',
|
||||
'smtp.host' => 'smtp.email.com',
|
||||
'smtp.port' => 25,
|
||||
'smtp.username' => 'john@doe.com',
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Domain\Sharing;
|
||||
|
||||
use Tests\TestCase;
|
||||
@@ -194,7 +193,7 @@ class VisitorBrowseTest extends TestCase
|
||||
}
|
||||
|
||||
// Check public shared item
|
||||
if (!$is_protected) {
|
||||
if (! $is_protected) {
|
||||
$this->getJson("/api/browse/folders/$root->id/$share->token")
|
||||
->assertStatus(200)
|
||||
->assertJsonFragment([
|
||||
@@ -310,7 +309,7 @@ class VisitorBrowseTest extends TestCase
|
||||
}
|
||||
|
||||
// Check public shared item
|
||||
if (!$is_protected) {
|
||||
if (! $is_protected) {
|
||||
$this->getJson("/api/browse/navigation/$share->token")
|
||||
->assertStatus(200)
|
||||
->assertExactJson($tree);
|
||||
@@ -362,7 +361,7 @@ class VisitorBrowseTest extends TestCase
|
||||
}
|
||||
|
||||
// Check public shared item
|
||||
if (!$is_protected) {
|
||||
if (! $is_protected) {
|
||||
$this->getJson("/api/browse/search/$share->token?query=doc")
|
||||
->assertStatus(200)
|
||||
->assertJsonFragment([
|
||||
@@ -413,7 +412,7 @@ class VisitorBrowseTest extends TestCase
|
||||
}
|
||||
|
||||
// Check public shared item
|
||||
if (!$is_protected) {
|
||||
if (! $is_protected) {
|
||||
$this->getJson("/api/browse/search/$share->token?query=doc")
|
||||
->assertStatus(200)
|
||||
->assertJsonFragment([]);
|
||||
@@ -460,7 +459,7 @@ class VisitorBrowseTest extends TestCase
|
||||
}
|
||||
|
||||
// Check public shared item
|
||||
if (!$is_protected) {
|
||||
if (! $is_protected) {
|
||||
$this->getJson("/api/browse/file/$share->token")
|
||||
->assertStatus(200)
|
||||
->assertJsonFragment([
|
||||
|
||||
Reference in New Issue
Block a user