BookStack/resources/views/settings/webhooks/index.blade.php
Dan Brown 8716b1922b
Completed webhook management interface
Got webhook CRUD actions in place within the interface.
Quick manual test pass done, Needs automated tests.
2021-12-08 17:35:58 +00:00

56 lines
1.8 KiB
PHP

@extends('layouts.simple')
@section('body')
<div class="container small">
<div class="py-m">
@include('settings.parts.navbar', ['selected' => 'webhooks'])
</div>
<div class="card content-wrap auto-height">
<div class="grid half v-center">
<h1 class="list-heading">{{ trans('settings.webhooks') }}</h1>
<div class="text-right">
<a href="{{ url("/settings/webhooks/create") }}"
class="button outline">{{ trans('settings.webhooks_create') }}</a>
</div>
</div>
@if(count($webhooks) > 0)
<table class="table">
<tr>
<th>{{ trans('common.name') }}</th>
<th>{{ trans('settings.webhook_events_table_header') }}</th>
</tr>
@foreach($webhooks as $webhook)
<tr>
<td>
<a href="{{ $webhook->getUrl() }}">{{ $webhook->name }}</a> <br>
<span class="small text-muted italic">{{ $webhook->endpoint }}</span>
</td>
<td>
@if($webhook->tracksEvent('all'))
{{ trans('settings.webhooks_events_all') }}
@else
{{ $webhook->trackedEvents->count() }}
@endif
</td>
</tr>
@endforeach
</table>
@else
<p class="text-muted empty-text">
{{ trans('common.no_items') }}
</p>
@endif
</div>
</div>
@stop