ADD: Belonging Transactions To Menu
FIX: Upload Document and Image system completely FIX: ImageGallery and ImageGallery components bugs FORCE: Dark Mode FIX: Minor bug in login page
This commit is contained in:
@@ -12,26 +12,30 @@ function formatCurrency(value) {
|
||||
onMounted(() => {
|
||||
BelongingService.getAllBelongings().then((data) => (products.value = data));
|
||||
});
|
||||
|
||||
function editBelonging(belongingId) {
|
||||
router.push('/belonging/edit-belonging/' + belongingId);
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="card">
|
||||
<div class="font-semibold text-xl mb-4">آخرین دارایی های افزوده شده</div>
|
||||
<DataTable :value="products" :rows="5" :paginator="true" responsiveLayout="scroll">
|
||||
<Column style="width: 15%" header="Image">
|
||||
<Column style="min-width: 15%" header="Image">
|
||||
<template #body="slotProps">
|
||||
<img :src="`${slotProps.data.mainImageUrl}`" :alt="slotProps.data.name" width="50" class="shadow" />
|
||||
</template>
|
||||
</Column>
|
||||
<Column field="name" header="نام" :sortable="true" style="width: 35%"></Column>
|
||||
<Column field="price" header="دسته بندی" :sortable="true" style="width: 35%">
|
||||
<Column field="name" header="نام" :sortable="true" style="min-width: 35%"></Column>
|
||||
<Column field="price" header="دسته بندی" :sortable="true" style="min-width: 30%">
|
||||
<template #body="slotProps">
|
||||
{{ slotProps.data.category.nativeName }}
|
||||
{{ slotProps.data.category?.nativeName }}
|
||||
</template>
|
||||
</Column>
|
||||
<Column style="width: 15%" header="نمایش">
|
||||
<Column style="min-width: 15%" header="نمایش">
|
||||
<template #body>
|
||||
<Button icon="pi pi-search" type="button" class="p-button-text"></Button>
|
||||
<Button icon="pi pi-search" type="button" class="p-button-text" @click="editBelonging(slotProps.data._id)"></Button>
|
||||
</template>
|
||||
</Column>
|
||||
</DataTable>
|
||||
|
||||
Reference in New Issue
Block a user