From 3a0204d27bde863207db6d8a621611cd7085dc18 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Wed, 24 Jul 2024 14:58:51 +0200 Subject: [PATCH 01/39] feat: vnLocation changes --- src/components/common/VnLocation.vue | 149 +++++++++++------- .../Customer/Card/CustomerFiscalData.vue | 6 +- .../Supplier/Card/SupplierFiscalData.vue | 10 +- .../vnComponent/vnLocation.spec.js | 2 +- 4 files changed, 98 insertions(+), 69 deletions(-) diff --git a/src/components/common/VnLocation.vue b/src/components/common/VnLocation.vue index 9ed48ca15..fc19e509f 100644 --- a/src/components/common/VnLocation.vue +++ b/src/components/common/VnLocation.vue @@ -1,18 +1,23 @@ diff --git a/src/pages/Entry/EntryStockBought.vue b/src/pages/Entry/EntryStockBought.vue index e0063bb62..12fc96214 100644 --- a/src/pages/Entry/EntryStockBought.vue +++ b/src/pages/Entry/EntryStockBought.vue @@ -5,6 +5,10 @@ import { useState } from 'src/composables/useState'; import { useQuasar } from 'quasar'; import VnTable from 'components/VnTable/VnTable.vue'; +import VnRow from 'src/components/ui/VnRow.vue'; +import VnInput from 'src/components/common/VnInput.vue'; +import VnLv from 'src/components/ui/VnLv.vue'; +import FetchData from 'src/components/FetchData.vue'; import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue'; import WorkerDescriptorProxy from 'src/pages/Worker/Card/WorkerDescriptorProxy.vue'; import EntryStockBoughtDetail from 'src/pages/Entry/EntryStockBoughtDetail.vue'; @@ -37,6 +41,7 @@ const columns = [ columnFilter: false, create: true, component: 'number', + summation: true, }, { align: 'left', @@ -61,6 +66,7 @@ const columns = [ label: t('Bought'), name: 'bought', columnFilter: false, + summation: true, }, { align: 'left', @@ -92,6 +98,21 @@ const columns = [ ], }, ]; +function getFilter(dated = Date.vnNow()) { + console.log('dated: ', new Date(dated * 1000)); + return { + fields: ['id', 'm3'], + where: { dated }, + include: [ + { + relation: 'warehouseIn', + where: { code: 'vnh' }, + }, + ], + }; +} +const travel = ref(); +const fetchDataRef = ref();