mirror of
https://github.com/Floriansylvain/RenewCMS.git
synced 2026-08-19 11:43:22 +02:00
feat: draft/online post field #26
This commit is contained in:
@@ -23,6 +23,9 @@
|
||||
</li>
|
||||
</ul>
|
||||
<ul class="navbar-nav">
|
||||
<li class="nav-item">
|
||||
<a class="nav-link text-body-tertiary text-decoration-underline" href="https://www.paypal.com/donate/?hosted_button_id=S6LUFUYK84CYY">support me!</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link disconnect-link" href="/logout">Log out</a>
|
||||
</li>
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
{{.Head}}
|
||||
|
||||
<style>
|
||||
.btn-outline-info:hover > *,
|
||||
.btn-outline-danger:hover > * {
|
||||
fill: #fff !important;
|
||||
transition: fill ease-in-out 50ms;
|
||||
@@ -22,12 +23,13 @@
|
||||
<th scope="col">Name</th>
|
||||
<th scope="col">Creation Date</th>
|
||||
<th scope="col">Edition Date</th>
|
||||
<th scope="col">Status</th>
|
||||
<th scope="col">Actions</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colspan="4" class="text-center">
|
||||
<td colspan="5" class="text-center">
|
||||
<form action="post/create" method="get">
|
||||
<button class="btn btn-sm btn-link w-100 h-100" type="submit">Create a new post...</button>
|
||||
</form>
|
||||
@@ -38,12 +40,26 @@
|
||||
<td>{{ $post.Title }}</td>
|
||||
<td class="date">{{ $post.CreatedAt }}</td>
|
||||
<td class="date">{{ $post.UpdatedAt }}</td>
|
||||
<td>{{ if $post.IsOnline }}🟢 Online{{ else }}🟠 Offline{{ end }}</td>
|
||||
<td>
|
||||
<a href="/post/{{ $post.ID }}/edit" class="btn btn-secondary btn-sm">
|
||||
<a href="/post/{{ $post.ID }}/edit" class="btn btn-outline-primary btn-sm">
|
||||
<svg width="12px" height="12px" fill="currentColor">
|
||||
<use xlink:href="/static/bootstrap-icons.svg#pen"/>
|
||||
</svg>
|
||||
</a>
|
||||
{{ if $post.IsOnline }}
|
||||
<a href="/post/{{ $post.ID }}/unpublish" class="btn btn-outline-info btn-sm">
|
||||
<svg width="12px" height="12px" fill="currentColor">
|
||||
<use xlink:href="/static/bootstrap-icons.svg#eye-slash"/>
|
||||
</svg>
|
||||
</a>
|
||||
{{ else }}
|
||||
<a href="/post/{{ $post.ID }}/publish" class="btn btn-outline-info btn-sm">
|
||||
<svg width="12px" height="12px" fill="currentColor">
|
||||
<use xlink:href="/static/bootstrap-icons.svg#eye"/>
|
||||
</svg>
|
||||
</a>
|
||||
{{ end }}
|
||||
<a href="/post/{{ $post.Title }}/delete" class="btn btn-outline-danger btn-sm" data-bs-toggle="modal"
|
||||
data-bs-target="#{{ $post.ID }}">
|
||||
<svg width=" 12px" height="12px" fill="currentColor">
|
||||
@@ -60,7 +76,8 @@
|
||||
aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<p>You are about to delete the post <b>« {{ $post.Title }} »</b>, this is definitive, are you sure?</p>
|
||||
<p>You are about to delete the post <b>« {{ $post.Title }} »</b>, this is definitive,
|
||||
are you sure?</p>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-outline-secondary" data-bs-dismiss="modal">Cancel
|
||||
|
||||
Reference in New Issue
Block a user