mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2026-10-26 07:00:10 -05:00
Add flush page for local storage.
This commit is contained in:
1 parent
024ec17237
commit
dbd6725452
6 files changed
+81
-4
No files matched your search
@@ -106,7 +106,7 @@ final class DebugController extends Controller
|
||||
*
|
||||
* @throws FireflyException
|
||||
*/
|
||||
public function flush(Request $request): RedirectResponse
|
||||
public function flush(Request $request): View
|
||||
{
|
||||
if ($this->hasNoTables() || $this->isOldVersionInstalled()) {
|
||||
throw new FireflyException('This is not the moment.');
|
||||
@@ -128,8 +128,8 @@ final class DebugController extends Controller
|
||||
}
|
||||
|
||||
Artisan::call('view:clear');
|
||||
|
||||
return redirect(route('index'));
|
||||
return view('flush');
|
||||
//return redirect(route('index'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* dashboard.js
|
||||
* Copyright (c) 2026 james@firefly-iii.org
|
||||
*
|
||||
* This file is part of Firefly III (https://github.com/firefly-iii).
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Affero General Public License as
|
||||
* published by the Free Software Foundation, either version 3 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Affero General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
import '../boot/blank-bootstrap.js';
|
||||
window.onload = function(){
|
||||
localStorage.clear();
|
||||
window.location = document.getElementsByTagName('base')[0].href;
|
||||
}
|
||||
@@ -47,6 +47,7 @@ export default defineConfig(({command, mode, isSsrBuild, isPreview}) => {
|
||||
// generic
|
||||
'js/pages/generic.js',
|
||||
'js/pages/blank.js', // small bootstrap
|
||||
'js/pages/flush.js',
|
||||
|
||||
// accounts
|
||||
'js/pages/accounts/create.js',
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
@extends('layout.v3.flush')
|
||||
@section('content')
|
||||
@endsection
|
||||
@@ -31,8 +31,8 @@
|
||||
<body class="login-page bg-body-secondary">
|
||||
<div class="login-box">
|
||||
<div class="login-logo">
|
||||
<img src="images/logo-session.png" width="68" height="100" alt="Logo" title="Logo"/><br>
|
||||
@if(true===$IS_DEMO_SITE)
|
||||
<img src="images/logo-session.png" width="68" height="100" alt="Logo" title="Logo"/><br>
|
||||
<a href="{{ route('index', null, true) }}"><strong>Firefly</strong> III</a>
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
<!doctype html>
|
||||
<html lang="{{ __('config.html_language') }}">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
||||
<meta charset="UTF-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<meta name="csrf-token" content="{{ csrf_token() }}">
|
||||
<meta name="robots" content="noindex, nofollow, noarchive, noodp, NoImageIndex, noydir">
|
||||
<meta name="apple-mobile-web-app-capable" content="yes">
|
||||
<meta name="mobile-web-app-capable" content="yes">
|
||||
<!--
|
||||
(FLUSH)
|
||||
If the base href URL begins with "http://" but you are sure it should start with "https://",
|
||||
please visit the following page: https://bit.ly/FF3-broken-base-href
|
||||
-->
|
||||
<base href="{{ route('index', null, true) }}/">
|
||||
<title>@yield('status') - {{ $title ?? 'Firefly III' }}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes"/>
|
||||
<meta name="theme-color" content="#007bff" media="(prefers-color-scheme: light)"/>
|
||||
<meta name="theme-color" content="#1a1a1a" media="(prefers-color-scheme: dark)"/>
|
||||
<meta name="color-scheme" content="light dark">
|
||||
@vite(['sass/app.scss'])
|
||||
<x-layout.fav-icons/>
|
||||
<script nonce="{{ $JS_NONCE ?? '' }}">
|
||||
(() => {
|
||||
'use strict'
|
||||
document.documentElement.setAttribute('data-bs-theme', (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light'))
|
||||
})()
|
||||
</script>
|
||||
</head>
|
||||
<body class="bg-body-tertiary">
|
||||
<main class="align-items-center min-vh-100 py-5">
|
||||
<div class="container">
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-md-12 col-lg-8 col-xl-8">
|
||||
<p class="text-center">
|
||||
<img src="images/logo-session.png" width="68" height="100" alt="Firefly III Logo" title="Firefly III"/><br>
|
||||
</p>
|
||||
<h1 style="text-align:center;"><em class="bi bi-hourglass"></em></h1>
|
||||
@yield('content')
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
@vite(['js/pages/flush.js'])
|
||||
@yield('scripts')
|
||||
</body>
|
||||
</html>
|
||||
Reference in new issue
Block a user