@extends('admin.layouts.master-soyuz') @section('title', __('Backup Manager')) @section('body') @component('admin.component.breadcumb',['secondaryactive' => 'active']) @slot('heading'){{ __('Backup Manager') }}@endslot @slot('menu1'){{ __('Backup Manager') }}@endslot @endcomponent @php $dir17 = storage_path() . '/app/' . config('app.name'); $backups = collect(array_reverse(glob("$dir17/*") ?: [])) ->filter(function ($f) { return is_file($f) && pathinfo($f, PATHINFO_EXTENSION) === 'zip'; }) ->values(); $latest = $backups->first(); $dumpPath = env('SQL_DUMP_PATH'); @endphp
@if ($errors->any()) @endif @if(session('success')) @endif {{-- Hero status --}}

{{ __('Database Backup Manager') }}

{{ $backups->count() ? trans_choice('{1} :count backup file stored|[2,*] :count backup files stored', $backups->count(), ['count' => $backups->count()]) : __('No backups yet — generate your first one.') }}

{{-- LEFT: dump path config --}}
{{ __('MySQL Dump Configuration') }}
@csrf
{{ __('Important Notes') }}
  • {{ __('Usually MySQL dump path is') }} /usr/bin/
  • {{ __('Contact your hosting provider asking') }} "What is my MySQL DUMP Binary path?"
  • {{ __('Enter the path without') }} mysqldump
  • {{ __('Backup download links expire after 1 minute') }}
{{-- Schedule UI placeholder if any --}} @if(!empty($html))
{{ __('Backup Schedule') }}
{!! $html !!}
@endif
{{-- RIGHT: backup list --}}
{{ __('Available Backups') }}
@if($backups->isEmpty())

{{ __('No backup files yet.') }}

@else
@foreach($backups as $i => $file) @php $name = basename($file); $size = is_file($file) ? round(filesize($file) / 1024 / 1024, 2) : 0; $time = is_file($file) ? \Carbon\Carbon::createFromTimestamp(filemtime($file))->diffForHumans() : ''; @endphp
{{ $name }} @if($i === 0) {{ __('Latest') }} @endif
{{ $size }} MB · {{ $time }}
@endforeach
@endif
@endsection