mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-08-09 10:22:51 +03:00
Adds code to delete the revision.
Signed-off-by: Abijeet <abijeetpatro@gmail.com>
This commit is contained in:
@@ -119,6 +119,11 @@ $button-border-radius: 2px;
|
||||
&.neg {
|
||||
color: $negative;
|
||||
}
|
||||
&.link {
|
||||
&:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.button-group {
|
||||
|
@@ -367,7 +367,7 @@ ul.pagination {
|
||||
padding: $-xs $-m;
|
||||
line-height: 1.2;
|
||||
}
|
||||
a {
|
||||
a, button {
|
||||
display: block;
|
||||
padding: $-xs $-m;
|
||||
color: #555;
|
||||
@@ -382,6 +382,10 @@ ul.pagination {
|
||||
width: 16px;
|
||||
}
|
||||
}
|
||||
button {
|
||||
width: 100%;
|
||||
text-align: left;
|
||||
}
|
||||
li.border-bottom {
|
||||
border-bottom: 1px solid #DDD;
|
||||
}
|
||||
|
@@ -41,6 +41,9 @@ table.table {
|
||||
.text-center {
|
||||
text-align: center;
|
||||
}
|
||||
td.actions {
|
||||
overflow: visible;
|
||||
}
|
||||
}
|
||||
|
||||
table.no-style {
|
||||
|
@@ -36,16 +36,31 @@
|
||||
<td> @if($revision->createdBy) {{ $revision->createdBy->name }} @else {{ trans('common.deleted_user') }} @endif</td>
|
||||
<td><small>{{ $revision->created_at->format('jS F, Y H:i:s') }} <br> ({{ $revision->created_at->diffForHumans() }})</small></td>
|
||||
<td>{{ $revision->summary }}</td>
|
||||
<td>
|
||||
<td class="actions">
|
||||
<a href="{{ $revision->getUrl('changes') }}" target="_blank">{{ trans('entities.pages_revisions_changes') }}</a>
|
||||
<span class="text-muted"> | </span>
|
||||
|
||||
|
||||
@if ($index === 0)
|
||||
<a target="_blank" href="{{ $page->getUrl() }}"><i>{{ trans('entities.pages_revisions_current') }}</i></a>
|
||||
@else
|
||||
<a href="{{ $revision->getUrl() }}" target="_blank">{{ trans('entities.pages_revisions_preview') }}</a>
|
||||
<span class="text-muted"> | </span>
|
||||
<a href="{{ $revision->getUrl('restore') }}">{{ trans('entities.pages_revisions_restore') }}</a>
|
||||
<span class="text-muted"> | </span>
|
||||
<div dropdown class="dropdown-container">
|
||||
<button type="button" dropdown-toggle class="text-button link">{{ trans('common.delete') }}</button>
|
||||
<ul>
|
||||
<li class="padded"><small class="text-muted">{{trans('entities.revision_delete_confirm')}}</small></li>
|
||||
<li>
|
||||
<form action="{{ $revision->getUrl('/delete/') }}" method="POST">
|
||||
{!! csrf_field() !!}
|
||||
<input type="hidden" name="_method" value="DELETE">
|
||||
<button type="submit" class="text-button neg">@icon('delete'){{ trans('common.delete') }}</button>
|
||||
</form>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
|
@@ -19,4 +19,4 @@
|
||||
color: {{ setting('app-color') }};
|
||||
fill: {{ setting('app-color') }};
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
Reference in New Issue
Block a user