|
|
@ -1,5 +1,5 @@
|
|
|
|
<tr id="row-{{ article.id }}"
|
|
|
|
<tr id="row-{{ article.id }}"
|
|
|
|
x-data='{ title: "{{ article.title }}", created: "{{ full-timestamp article.created }}" }'
|
|
|
|
x-data='{ id: "{{ article.id }}", title: "{{ article.title }}", created: "{{ full-timestamp article.created }}" }'
|
|
|
|
class="border-b dark:border-gray-600 hover:bg-gray-100 dark:hover:bg-gray-700">
|
|
|
|
class="border-b dark:border-gray-600 hover:bg-gray-100 dark:hover:bg-gray-700">
|
|
|
|
<th scope="row" class="px-4 py-3 font-medium text-gray-900 whitespace-nowrap dark:text-white">
|
|
|
|
<th scope="row" class="px-4 py-3 font-medium text-gray-900 whitespace-nowrap dark:text-white">
|
|
|
|
<div class="flex items-center mr-3" x-text="title">
|
|
|
|
<div class="flex items-center mr-3" x-text="title">
|
|
|
@ -11,7 +11,14 @@
|
|
|
|
<td class="px-4 py-3" x-text="created"></td>
|
|
|
|
<td class="px-4 py-3" x-text="created"></td>
|
|
|
|
<td class="px-4 py-3 font-medium text-gray-900 whitespace-nowrap dark:text-white">
|
|
|
|
<td class="px-4 py-3 font-medium text-gray-900 whitespace-nowrap dark:text-white">
|
|
|
|
<div class="flex items-center space-x-4">
|
|
|
|
<div class="flex items-center space-x-4">
|
|
|
|
<button type="button" data-drawer-target="drawer-update-product" data-drawer-show="drawer-update-product" aria-controls="drawer-update-product" class="py-2 px-3 flex items-center text-sm font-medium text-center text-white bg-primary-700 rounded-lg hover:bg-primary-800 focus:ring-4 focus:outline-none focus:ring-primary-300 dark:bg-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800">
|
|
|
|
<button type="button"
|
|
|
|
|
|
|
|
@click="$dispatch('update_article', { id: id, title: title, created: created })"
|
|
|
|
|
|
|
|
hx-get="/htmx/admin/modals/article/edit-content/{{ article.id }}/"
|
|
|
|
|
|
|
|
hx-swap="outerHTML"
|
|
|
|
|
|
|
|
hx-target="#update-drawer-content"
|
|
|
|
|
|
|
|
data-drawer-target="drawer-update-article"
|
|
|
|
|
|
|
|
data-drawer-show="drawer-update-article"
|
|
|
|
|
|
|
|
class="py-2 px-3 flex items-center text-sm font-medium text-center text-white bg-primary-700 rounded-lg hover:bg-primary-800 focus:ring-4 focus:outline-none focus:ring-primary-300 dark:bg-primary-600 dark:hover:bg-primary-700 dark:focus:ring-primary-800">
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4 mr-2 -ml-0.5" viewbox="0 0 20 20" fill="currentColor" aria-hidden="true">
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4 mr-2 -ml-0.5" viewbox="0 0 20 20" fill="currentColor" aria-hidden="true">
|
|
|
|
<path d="M17.414 2.586a2 2 0 00-2.828 0L7 10.172V13h2.828l7.586-7.586a2 2 0 000-2.828z" />
|
|
|
|
<path d="M17.414 2.586a2 2 0 00-2.828 0L7 10.172V13h2.828l7.586-7.586a2 2 0 000-2.828z" />
|
|
|
|
<path fill-rule="evenodd" d="M2 6a2 2 0 012-2h4a1 1 0 010 2H4v10h10v-4a1 1 0 112 0v4a2 2 0 01-2 2H4a2 2 0 01-2-2V6z" clip-rule="evenodd" />
|
|
|
|
<path fill-rule="evenodd" d="M2 6a2 2 0 012-2h4a1 1 0 010 2H4v10h10v-4a1 1 0 112 0v4a2 2 0 01-2 2H4a2 2 0 01-2-2V6z" clip-rule="evenodd" />
|
|
|
@ -33,7 +40,7 @@
|
|
|
|
Preview
|
|
|
|
Preview
|
|
|
|
</button>
|
|
|
|
</button>
|
|
|
|
<button type="button"
|
|
|
|
<button type="button"
|
|
|
|
@click="$dispatch('show_delete_modal', { id: '{{ article.id }}'});"
|
|
|
|
@click="$dispatch('show_delete_modal', { id: id });"
|
|
|
|
data-modal-target="delete-modal"
|
|
|
|
data-modal-target="delete-modal"
|
|
|
|
data-modal-toggle="delete-modal"
|
|
|
|
data-modal-toggle="delete-modal"
|
|
|
|
class="flex items-center text-red-700 hover:text-white border border-red-700 hover:bg-red-800 focus:ring-4 focus:outline-none focus:ring-red-300 font-medium rounded-lg text-sm px-3 py-2 text-center dark:border-red-500 dark:text-red-500 dark:hover:text-white dark:hover:bg-red-600 dark:focus:ring-red-900">
|
|
|
|
class="flex items-center text-red-700 hover:text-white border border-red-700 hover:bg-red-800 focus:ring-4 focus:outline-none focus:ring-red-300 font-medium rounded-lg text-sm px-3 py-2 text-center dark:border-red-500 dark:text-red-500 dark:hover:text-white dark:hover:bg-red-600 dark:focus:ring-red-900">
|
|
|
|