update
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<h1 class="text-2xl font-bold mb-3">Danh sách sản phẩm ({{ page.total | format_number }})</h1>
|
||||
<div class="flex flex-wrap justify-between items-center">
|
||||
<div class="btn-left flex items-center mb-3 gap-3">
|
||||
<div class="form-control w-48">
|
||||
<div class="form-control w-30">
|
||||
<div class="dropdown dropdown-bottom w-full">
|
||||
<label tabindex="0" class="btn btn-view btn-sm btn-outline w-full flex justify-between">
|
||||
Chọn danh mục
|
||||
@@ -80,7 +80,7 @@
|
||||
{% assign counter = 0 %}
|
||||
{% for item in page.item_list %}
|
||||
{% increment counter %}
|
||||
<tr class="hover:bg-base-300">
|
||||
<tr>
|
||||
<td>{{ counter }}</td>
|
||||
<td>
|
||||
<img class="block mx-auto my-0 w-[70px] h-[50px]" src="{{item.image.thumb}}" alt="">
|
||||
@@ -143,7 +143,7 @@
|
||||
<label class="cursor-pointer flex items-center mb-2 gap-2"
|
||||
onclick="AdminFunction.update_product_hot('{{item.id}}')">
|
||||
<input type="checkbox" name="new" {% if item.hot_type=="new" %}checked="checked" {% endif %}
|
||||
class="checkbox checkbox-active checkbox-sm" />
|
||||
class="checkbox checkbox-active checkbox-sm rounded-sm" />
|
||||
<span class="label-text whitespace-nowrap">Mới Hot (Hỏi nhiều)</span>
|
||||
</label>
|
||||
|
||||
@@ -151,14 +151,14 @@
|
||||
<label class="cursor-pointer flex items-center mb-2 gap-2"
|
||||
onclick="AdminFunction.update_product_hot('{{item.id}}')">
|
||||
<input type="checkbox" name="hot" {% if item.hot_type=="hot" %}checked="checked" {% endif %}
|
||||
class="checkbox checkbox-active checkbox-sm" />
|
||||
class="checkbox checkbox-active checkbox-sm rounded-sm" />
|
||||
<span class="label-text whitespace-nowrap">Hot (Hỏi nhiều)</span>
|
||||
</label>
|
||||
|
||||
<label class="cursor-pointer flex items-center mb-2 gap-2"
|
||||
onclick="AdminFunction.update_product_hot('{{item.id}}')">
|
||||
<input type="checkbox" name="bestsale" {% if item.hot_type=="bestsale" %}checked="checked"
|
||||
{% endif %} class="checkbox checkbox-active checkbox-sm" />
|
||||
{% endif %} class="checkbox checkbox-active checkbox-sm rounded-sm" />
|
||||
<span class="label-text whitespace-nowrap">Bán
|
||||
chạy</span>
|
||||
</label>
|
||||
@@ -166,7 +166,7 @@
|
||||
<label class="cursor-pointer flex items-center mb-2 gap-2"
|
||||
onclick="AdminFunction.update_product_hot('{{item.id}}')">
|
||||
<input type="checkbox" name="saleoff" {% if item.hot_type=="saleoff" %}checked="checked" {%
|
||||
endif %} class="checkbox checkbox-active checkbox-sm" />
|
||||
endif %} class="checkbox checkbox-active checkbox-sm rounded-sm" />
|
||||
<span class="label-text whitespace-nowrap">Xả
|
||||
hàng (sale-off)</span>
|
||||
</label>
|
||||
@@ -174,7 +174,8 @@
|
||||
<label class="cursor-pointer flex items-center mb-2 gap-2"
|
||||
onclick="AdminFunction.update_product_hot('{{item.id}}')">
|
||||
<input type="checkbox" name="online-only" {% if item.hot_type=="online-only"
|
||||
%}checked="checked" {% endif %} class="checkbox checkbox-active checkbox-sm" />
|
||||
%}checked="checked" {% endif %}
|
||||
class="checkbox checkbox-active checkbox-sm rounded-sm" />
|
||||
<span class="label-text whitespace-nowrap">Chỉ bán online</span>
|
||||
</label>
|
||||
|
||||
@@ -184,23 +185,23 @@
|
||||
<div class="list-btn flex items-center gap-3">
|
||||
<a href="/admin/product/form?id={{item.id}}" title="Form sản phẩm"
|
||||
class="btn btn-soft btn-xs btn-square btn-outline btn-view">
|
||||
<i class="iconify lucide--pencil"></i>
|
||||
<i data-lucide="pencil" class="size-3"></i>
|
||||
</a>
|
||||
<a href="{{item.request_path}}" title="Xem tại web" target="_blank"
|
||||
class="btn btn-soft btn-xs btn-square btn-outline btn-view">
|
||||
<i class="iconify lucide--globe"></i>
|
||||
<i data-lucide="globe" class="size-3"></i>
|
||||
</a>
|
||||
{% if item.status == 0 %}
|
||||
<a href="" class="btn btn-soft btn-xs btn-square btn-outline btn-view">
|
||||
<i class="iconify lucide--eye-off"></i>
|
||||
<i data-lucide="eye-off" class="size-3"></i>
|
||||
</a>
|
||||
{% else %}
|
||||
<a href="" class="btn btn-soft btn-xs btn-square btn-outline btn-view">
|
||||
<i class="iconify lucide--eye"></i>
|
||||
<i data-lucide="eye" class="size-3"></i>
|
||||
</a>
|
||||
{% endif %}
|
||||
<a href="" class="btn btn-soft btn-xs btn-error btn-square">
|
||||
<i class="iconify lucide--trash"></i>
|
||||
<i data-lucide="trash-2" class="size-3 text-red-400"></i>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
@@ -210,23 +211,18 @@
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="join mt-5 justify-center flex items-center">
|
||||
{% for paging in page.pagination.collection %}
|
||||
{% if paging.name == 'next' %}
|
||||
<a href="{{paging.url}}" class="btn btn-square btn-sm btn-outline border-base-300 join-item"
|
||||
aria-label="Pagination controls">
|
||||
<span class="iconify lucide--arrow-right"></span>
|
||||
<div class="join mt-5 justify-end flex items-center gap-1">
|
||||
<a href="" class="btn btn-ghost btn-circle btn-sm" aria-label="Pagination controls">
|
||||
<i data-lucide="chevron-left" class="size-4"></i>
|
||||
</a>
|
||||
{% elsif paging.name == 'prev' %}
|
||||
<a href="{{paging.url}}" class="btn btn-square btn-sm btn-outline border-base-300 join-item"
|
||||
aria-label="Pagination controls">
|
||||
<span class="iconify lucide--arrow-left"></span>
|
||||
<a href="" class="btn btn-circle btn-sm btn-ghost">1</a>
|
||||
<a href="" class="btn btn-circle btn-sm btn-ghost btn-active">2</a>
|
||||
<a href="" class="btn btn-circle btn-sm btn-ghost">3</a>
|
||||
<a href="" class="btn btn-circle btn-sm btn-ghost">4</a>
|
||||
<a href="" class="btn btn-circle btn-sm btn-ghost">5</a>
|
||||
<a href="" class="btn btn-ghost btn-circle btn-sm" aria-label="Pagination controls">
|
||||
<i data-lucide="chevron-right" class="size-4"></i>
|
||||
</a>
|
||||
{% else %}
|
||||
<a href="{{paging.url}}"
|
||||
class="btn btn-square btn-sm btn-outline border-base-300 join-item {% if paging.is_active == 1 %}btn-active{% endif %}">{{paging.name}}</a>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user