mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Add lots of audit logs.
This commit is contained in:
@@ -26,6 +26,7 @@ namespace FireflyIII\Http\Controllers\Webhooks;
|
||||
|
||||
use FireflyIII\Http\Controllers\Controller;
|
||||
use Illuminate\Contracts\View\Factory;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
use Illuminate\View\View;
|
||||
|
||||
/**
|
||||
@@ -57,6 +58,7 @@ class CreateController extends Controller
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
Log::channel('audit')->info('User visits webhook create page.');
|
||||
$previousUrl = $this->rememberPreviousUrl('webhooks.create.url');
|
||||
|
||||
return view('webhooks.create', compact('previousUrl'));
|
||||
|
@@ -28,6 +28,7 @@ use FireflyIII\Models\Webhook;
|
||||
use Illuminate\Contracts\Foundation\Application;
|
||||
use Illuminate\Contracts\View\Factory;
|
||||
use Illuminate\Contracts\View\View;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
/**
|
||||
* Class DeleteController
|
||||
@@ -61,6 +62,7 @@ class DeleteController extends Controller
|
||||
*/
|
||||
public function index(Webhook $webhook)
|
||||
{
|
||||
Log::channel('audit')->info('User visits webhook delete page.');
|
||||
$subTitle = (string)trans('firefly.delete_webhook', ['title' => $webhook->title]);
|
||||
$this->rememberPreviousUrl('webhooks.delete.url');
|
||||
|
||||
|
@@ -28,6 +28,7 @@ use FireflyIII\Models\Webhook;
|
||||
use Illuminate\Contracts\Foundation\Application;
|
||||
use Illuminate\Contracts\View\Factory;
|
||||
use Illuminate\Contracts\View\View;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
/**
|
||||
* Class EditController
|
||||
@@ -60,8 +61,9 @@ class EditController extends Controller
|
||||
*/
|
||||
public function index(Webhook $webhook)
|
||||
{
|
||||
Log::channel('audit')->info('User visits webhook edit page.');
|
||||
$subTitle = (string)trans('firefly.edit_webhook', ['title' => $webhook->title]);
|
||||
$this->rememberPreviousUrl('webhooks.delete.url');
|
||||
$this->rememberPreviousUrl('webhooks.edit.url');
|
||||
|
||||
return view('webhooks.edit', compact('webhook', 'subTitle'));
|
||||
}
|
||||
|
@@ -26,6 +26,7 @@ namespace FireflyIII\Http\Controllers\Webhooks;
|
||||
|
||||
use FireflyIII\Http\Controllers\Controller;
|
||||
use Illuminate\Contracts\View\Factory;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
use Illuminate\View\View;
|
||||
|
||||
/**
|
||||
@@ -53,6 +54,7 @@ class IndexController extends Controller
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
Log::channel('audit')->info('User visits webhook index page.');
|
||||
return view('webhooks.index');
|
||||
}
|
||||
}
|
||||
|
@@ -28,6 +28,7 @@ use FireflyIII\Models\Webhook;
|
||||
use Illuminate\Contracts\Foundation\Application;
|
||||
use Illuminate\Contracts\View\Factory;
|
||||
use Illuminate\Contracts\View\View;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
/**
|
||||
* Class ShowController
|
||||
@@ -60,6 +61,7 @@ class ShowController extends Controller
|
||||
*/
|
||||
public function index(Webhook $webhook)
|
||||
{
|
||||
Log::channel('audit')->info(sprintf('User visits webhook #%d page.', $webhook->id));
|
||||
$subTitle = (string)trans('firefly.show_webhook', ['title' => $webhook->title]);
|
||||
|
||||
return view('webhooks.show', compact('webhook', 'subTitle'));
|
||||
|
Reference in New Issue
Block a user