feat: refs #8277 add Entry Control page and update localization files
This commit is contained in:
parent
f8b41101d3
commit
7a1eb9bec6
|
@ -334,6 +334,7 @@ globals:
|
|||
parking: Parking
|
||||
vehicleList: Vehicles
|
||||
vehicle: Vehicle
|
||||
entryControl: Entry control
|
||||
unsavedPopup:
|
||||
title: Unsaved changes will be lost
|
||||
subtitle: Are you sure exit without saving?
|
||||
|
|
|
@ -334,6 +334,7 @@ globals:
|
|||
parking: Parking
|
||||
vehicleList: Vehículos
|
||||
vehicle: Vehículo
|
||||
entryControl: Control de entradas
|
||||
unsavedPopup:
|
||||
title: Los cambios que no haya guardado se perderán
|
||||
subtitle: ¿Seguro que quiere salir sin guardar?
|
||||
|
@ -653,7 +654,7 @@ supplier:
|
|||
tableVisibleColumns:
|
||||
nif: NIF/CIF
|
||||
account: Cuenta
|
||||
|
||||
|
||||
summary:
|
||||
responsible: Responsable
|
||||
verified: Verificado
|
||||
|
|
|
@ -0,0 +1,146 @@
|
|||
<script setup>
|
||||
import { ref, computed, markRaw } from 'vue';
|
||||
import VnTable from 'src/components/VnTable/VnTable.vue';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
import FetchData from 'src/components/FetchData.vue';
|
||||
import VnSelectSupplier from 'src/components/common/VnSelectSupplier.vue';
|
||||
|
||||
const { t } = useI18n();
|
||||
const companies = ref([]);
|
||||
const countries = ref([]);
|
||||
const columns = computed(() => [
|
||||
{
|
||||
name: 'supplierFk',
|
||||
label: t('globals.supplier'),
|
||||
format: (row) => row.supplierFk,
|
||||
columnFilter: {
|
||||
component: markRaw(VnSelectSupplier),
|
||||
label: null,
|
||||
name: 'supplierFk',
|
||||
url: 'Suppliers',
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'companyFk',
|
||||
label: t('globals.company'),
|
||||
columnFilter: {
|
||||
component: 'select',
|
||||
name: 'companyFk',
|
||||
options: companies.value,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'gestDocFk',
|
||||
label: t('entry.gestDocFk'),
|
||||
},
|
||||
{
|
||||
name: 'dmsType',
|
||||
label: t('entry.dmsType'),
|
||||
format: (row) => row.dmsType,
|
||||
},
|
||||
{
|
||||
name: 'invoiceNumber',
|
||||
label: t('entry.invoiceNumber'),
|
||||
},
|
||||
{
|
||||
name: 'reference',
|
||||
label: t('entry.reference'),
|
||||
},
|
||||
{
|
||||
name: 'shipped',
|
||||
label: t('entry.shipped'),
|
||||
},
|
||||
{
|
||||
name: 'dated',
|
||||
label: t('entry.dated'),
|
||||
},
|
||||
{
|
||||
name: 'id',
|
||||
label: t('entry.id'),
|
||||
isId: true,
|
||||
chip: {
|
||||
condition: () => true,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'invoiceInFk',
|
||||
label: t('entry.invoiceInFk'),
|
||||
},
|
||||
{
|
||||
name: 'country',
|
||||
label: t('globals.country'),
|
||||
format: (row) => row.country,
|
||||
columnFilter: {
|
||||
component: 'select',
|
||||
name: 'country',
|
||||
options: countries.value,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'description',
|
||||
label: t('globals.description'),
|
||||
},
|
||||
{
|
||||
name: 'payDem',
|
||||
label: t('entry.payDem'),
|
||||
},
|
||||
{
|
||||
name: 'amount',
|
||||
label: t('amount'),
|
||||
},
|
||||
{
|
||||
name: 'isBooked',
|
||||
label: t('entry.isBooked'),
|
||||
},
|
||||
{
|
||||
name: 'received',
|
||||
label: t('entry.received'),
|
||||
},
|
||||
// {
|
||||
// name: 'travelFk',
|
||||
// label: t('entry.travelFk'),
|
||||
// },
|
||||
// {
|
||||
// name: 'landed',
|
||||
// label: t('entry.landed'),
|
||||
// },
|
||||
// {
|
||||
// name: 'agencyMode',
|
||||
// label: t('entry.agencyMode'),
|
||||
// format: (row) => row.agencyMode,
|
||||
// },
|
||||
// {
|
||||
// name: 'isAgricultural',
|
||||
// label: t('entry.isAgricultural'),
|
||||
// },
|
||||
// {
|
||||
// name: 'account',
|
||||
// label: t('globals.account'),
|
||||
// },
|
||||
// {
|
||||
// name: 'nickname',
|
||||
// label: t('globals.nickname'),
|
||||
// },
|
||||
]);
|
||||
</script>
|
||||
<template>
|
||||
<FetchData
|
||||
url="Countries"
|
||||
:filter="{ fields: ['id', 'name'] }"
|
||||
@on-fetch="(data) => (countries.value = data)"
|
||||
auto-load
|
||||
/>
|
||||
<FetchData
|
||||
url="Companies"
|
||||
:filter="{ fields: ['id', 'name'] }"
|
||||
@on-fetch="(data) => (companies.value = data)"
|
||||
auto-load
|
||||
/>
|
||||
<VnTable
|
||||
data-key="entryControl"
|
||||
url="Entries/control"
|
||||
:columns
|
||||
auto-load
|
||||
:right-search="false"
|
||||
/>
|
||||
</template>
|
|
@ -6,13 +6,7 @@ const entryCard = {
|
|||
component: () => import('src/pages/Entry/Card/EntryCard.vue'),
|
||||
redirect: { name: 'EntrySummary' },
|
||||
meta: {
|
||||
menu: [
|
||||
'EntryBasicData',
|
||||
'EntryBuys',
|
||||
'EntryNotes',
|
||||
'EntryDms',
|
||||
'EntryLog',
|
||||
],
|
||||
menu: ['EntryBasicData', 'EntryBuys', 'EntryNotes', 'EntryDms', 'EntryLog'],
|
||||
},
|
||||
children: [
|
||||
{
|
||||
|
@ -91,7 +85,8 @@ export default {
|
|||
'EntryLatestBuys',
|
||||
'EntryStockBought',
|
||||
'EntryWasteRecalc',
|
||||
]
|
||||
'EntryControl',
|
||||
],
|
||||
},
|
||||
component: RouterView,
|
||||
redirect: { name: 'EntryMain' },
|
||||
|
@ -103,7 +98,7 @@ export default {
|
|||
redirect: { name: 'EntryIndexMain' },
|
||||
children: [
|
||||
{
|
||||
path:'',
|
||||
path: '',
|
||||
name: 'EntryIndexMain',
|
||||
redirect: { name: 'EntryList' },
|
||||
component: () => import('src/pages/Entry/EntryList.vue'),
|
||||
|
@ -127,7 +122,7 @@ export default {
|
|||
icon: 'add',
|
||||
},
|
||||
component: () => import('src/pages/Entry/EntryCreate.vue'),
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'my',
|
||||
name: 'MyEntries',
|
||||
|
@ -164,7 +159,16 @@ export default {
|
|||
},
|
||||
component: () => import('src/pages/Entry/EntryWasteRecalc.vue'),
|
||||
},
|
||||
{
|
||||
path: 'control',
|
||||
name: 'EntryControl',
|
||||
meta: {
|
||||
title: 'entryControl',
|
||||
icon: 'help',
|
||||
},
|
||||
component: () => import('src/pages/Entry/EntryControl.vue'),
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue