Expand webhook code.

This commit is contained in:
James Cole
2022-09-17 07:08:30 +02:00
parent 10f2cf2481
commit ad9efde2d0
44 changed files with 1014 additions and 99 deletions

View File

@@ -1228,6 +1228,22 @@ try {
}
);
// webhooks
Breadcrumbs::for(
'webhooks.index',
static function (Generator $breadcrumbs): void {
$breadcrumbs->parent('index');
$breadcrumbs->push(trans('firefly.webhooks_breadcrumb'), route('webhooks.index'));
}
);
Breadcrumbs::for(
'webhooks.create',
static function (Generator $breadcrumbs): void {
$breadcrumbs->parent('index');
$breadcrumbs->push(trans('firefly.webhooks_create_breadcrumb'), route('webhooks.create'));
}
);
} catch (DuplicateBreadcrumbException $e) {
// @ignoreException
}

View File

@@ -1091,6 +1091,7 @@ Route::group(
['middleware' => 'user-full-auth', 'namespace' => 'FireflyIII\Http\Controllers\Webhooks', 'prefix' => 'webhooks', 'as' => 'webhooks.'],
static function () {
Route::get('index', ['uses' => 'IndexController@index', 'as' => 'index']);
Route::get('create', ['uses' => 'CreateController@index', 'as' => 'create']);
}
);