+
@@ -103,18 +107,18 @@ function viewSummary(id) {
+
+
+
+ {{ t('New client') }}
+
+
-
-
es:
Search customer: Buscar cliente
You can search by customer id or name: Puedes buscar por id o nombre del cliente
+ New client: Nuevo cliente
diff --git a/src/pages/Customer/CustomerPaymentsFilter.vue b/src/pages/Customer/CustomerPaymentsFilter.vue
deleted file mode 100644
index 7ee584d7f..000000000
--- a/src/pages/Customer/CustomerPaymentsFilter.vue
+++ /dev/null
@@ -1,118 +0,0 @@
-
-
-
-
-
-
- {{ t(`params.${tag.label}`) }}:
- {{ formatFn(tag.value) }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {
- if (value.includes(','))
- params.amount = params.amount.replace(',', '.');
- }
- "
- :rules="[
- (val) =>
- isValidNumber(val) || !val || 'Please type a number',
- ]"
- >
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-en:
- params:
- orderFk: Order
- clientFk: Customer
- amount: Amount
- from: From
- to: To
-es:
- params:
- orderFk: Pedido
- clientFk: Cliente
- amount: Importe
- from: Desde
- to: Hasta
- Order ID: ID pedido
- Customer ID: ID cliente
- Amount: Importe
- Please type a number: Por favor, escriba un número
- From: Desde
- To: Hasta
-
diff --git a/src/pages/Customer/Defaulter/CustomerBalanceDueTotal.vue b/src/pages/Customer/Defaulter/CustomerBalanceDueTotal.vue
new file mode 100644
index 000000000..c4a50a10f
--- /dev/null
+++ b/src/pages/Customer/Defaulter/CustomerBalanceDueTotal.vue
@@ -0,0 +1,51 @@
+
+
+
+
+
{{ t('Total') }}
+
+
{{ t('Balance due') }}:
+
+ {{ toCurrency($props.amount) }}
+
+
+
+
+
+
+
+
+es:
+ Total: Total
+ Balance due: Saldo vencido
+
diff --git a/src/pages/Customer/Defaulter/CustomerDefaulter.vue b/src/pages/Customer/Defaulter/CustomerDefaulter.vue
new file mode 100644
index 000000000..1dfd331e2
--- /dev/null
+++ b/src/pages/Customer/Defaulter/CustomerDefaulter.vue
@@ -0,0 +1,276 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ props.value }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Client: Cliente
+ Is worker: Es trabajador
+ Salesperson: Comercial
+ Country: País
+ P. Method: F. Pago
+ Balance D.: Saldo V.
+ Author: Autor
+ Last observation: Última observación
+ L. O. Date: Fecha Ú. O.
+ Credit I.: Crédito A.
+ From: Desde
+
diff --git a/src/pages/Customer/Defaulter/CustomerDefaulterAddObservation.vue b/src/pages/Customer/Defaulter/CustomerDefaulterAddObservation.vue
new file mode 100644
index 000000000..b150f4d8b
--- /dev/null
+++ b/src/pages/Customer/Defaulter/CustomerDefaulterAddObservation.vue
@@ -0,0 +1,100 @@
+
+
+
+
+
+
+
+
+ {{
+ t('Add observation to all selected clients', {
+ numberClients: t($props.clients.length),
+ })
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ es:
+ Add observation to all selected clients: Añadir observación a { numberClients } cliente(s) seleccionado(s)
+ Message: Mensaje
+
diff --git a/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue b/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue
new file mode 100644
index 000000000..f26af5975
--- /dev/null
+++ b/src/pages/Customer/Defaulter/CustomerDefaulterFilter.vue
@@ -0,0 +1,223 @@
+
+
+
+ (clients = data)" auto-load url="Clients" />
+ (salespersons = data)"
+ auto-load
+ url="Workers/activeWithInheritedRole"
+ />
+ (countries = data)" auto-load url="Countries" />
+ (authors = data)"
+ auto-load
+ url="Workers/activeWithInheritedRole"
+ />
+
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ clientFk: Client
+ salesPersonFk: Salesperson
+ countryFk: Country
+ paymentMethod: P. Method
+ balance: Balance D.
+ workerFk: Author
+ date: L. O. Date
+ credit: Credit I.
+ defaulterSinced: From
+es:
+ params:
+ clientFk: Cliente
+ salesPersonFk: Comercial
+ countryFk: País
+ paymentMethod: F. Pago
+ balance: Saldo V.
+ workerFk: Autor
+ date: Fecha Ú. O.
+ credit: Crédito A.
+ defaulterSinced: Desde
+ Client: Cliente
+ Salesperson: Comercial
+ Country: País
+ P. Method: F. Pago
+ Balance D.: Saldo V.
+ Author: Autor
+ L. O. Date: Fecha Ú. O.
+ Credit I.: Crédito A.
+ From: Desde
+
diff --git a/src/pages/Customer/ExtendedList/CustomerExtendedList.vue b/src/pages/Customer/ExtendedList/CustomerExtendedList.vue
new file mode 100644
index 000000000..69effe88e
--- /dev/null
+++ b/src/pages/Customer/ExtendedList/CustomerExtendedList.vue
@@ -0,0 +1,565 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ dashIfEmpty(col.value) }}
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Customer/ExtendedList/CustomerExtendedListActions.vue b/src/pages/Customer/ExtendedList/CustomerExtendedListActions.vue
new file mode 100644
index 000000000..a7c51d714
--- /dev/null
+++ b/src/pages/Customer/ExtendedList/CustomerExtendedListActions.vue
@@ -0,0 +1,71 @@
+
+
+
+
+
+
+ {{ t('Client ticket list') }}
+
+
+
+
+ {{ t('Preview') }}
+
+
+
+
+
+
+es:
+ Client ticket list: Listado de tickets del cliente
+ Preview: Vista previa
+
diff --git a/src/pages/Customer/ExtendedList/CustomerExtendedListFilter.vue b/src/pages/Customer/ExtendedList/CustomerExtendedListFilter.vue
new file mode 100644
index 000000000..df898e7c1
--- /dev/null
+++ b/src/pages/Customer/ExtendedList/CustomerExtendedListFilter.vue
@@ -0,0 +1,571 @@
+
+
+
+ (clients = data)"
+ auto-load
+ />
+ (workers = data)"
+ auto-load
+ />
+ (workers = data)"
+ auto-load
+ />
+ (countriesOptions = data)"
+ auto-load
+ />
+ (provincesOptions = data)"
+ auto-load
+ url="Provinces"
+ />
+ (paymethodsOptions = data)"
+ auto-load
+ />
+ (businessTypesOptions = data)"
+ auto-load
+ />
+ (sageTaxTypesOptions = data)"
+ />
+ (sageTransactionTypesOptions = data)"
+ />
+
+
+
+ {{ t(`customer.extendedList.tableVisibleColumns.${tag.label}`) }}:
+
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Social name: Razón social
+
diff --git a/src/pages/Customer/Notifications/CustomerNotifications.vue b/src/pages/Customer/Notifications/CustomerNotifications.vue
new file mode 100644
index 000000000..cf66443b9
--- /dev/null
+++ b/src/pages/Customer/Notifications/CustomerNotifications.vue
@@ -0,0 +1,153 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ props.value }}
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Identifier: Identificador
+ Social name: Razón social
+ Salesperson: Comercial
+ Phone: Teléfono
+ City: Población
+ Email: Email
+
diff --git a/src/pages/Customer/Notifications/CustomerNotificationsFilter.vue b/src/pages/Customer/Notifications/CustomerNotificationsFilter.vue
new file mode 100644
index 000000000..957abb7a3
--- /dev/null
+++ b/src/pages/Customer/Notifications/CustomerNotificationsFilter.vue
@@ -0,0 +1,133 @@
+
+
+
+ (clients = data)"
+ auto-load
+ url="Clients"
+ />
+ (cities = data)" auto-load url="Towns" />
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ identifier: Identifier
+ socialName: Social name
+ city: City
+ phone: Phone
+ email: Email
+es:
+ params:
+ identifier: Identificador
+ socialName: Razón social
+ city: Población
+ phone: Teléfono
+ email: Email
+ Identifier: Identificador
+ Social name: Razón social
+ City: Población
+ Phone: Teléfono
+ Email: Email
+
diff --git a/src/pages/Customer/CustomerPayments.vue b/src/pages/Customer/Payments/CustomerPayments.vue
similarity index 95%
rename from src/pages/Customer/CustomerPayments.vue
rename to src/pages/Customer/Payments/CustomerPayments.vue
index 24e5efa39..eedaaf137 100644
--- a/src/pages/Customer/CustomerPayments.vue
+++ b/src/pages/Customer/Payments/CustomerPayments.vue
@@ -7,7 +7,7 @@ import { useStateStore } from 'stores/useStateStore';
import { useArrayData } from 'composables/useArrayData';
import VnPaginate from 'components/ui/VnPaginate.vue';
import VnConfirm from 'components/ui/VnConfirm.vue';
-import CustomerDescriptorProxy from './Card/CustomerDescriptorProxy.vue';
+import CustomerDescriptorProxy from '../Card/CustomerDescriptorProxy.vue';
import { toDate, toCurrency } from 'filters/index';
import CustomerPaymentsFilter from './CustomerPaymentsFilter.vue';
@@ -122,9 +122,8 @@ function stateColor(row) {
-
-
- {{ t('Web Payments') }}
+
+
+ />
{{ t('Change view') }}
@@ -279,18 +278,13 @@ function stateColor(row) {
diff --git a/src/pages/Customer/Payments/CustomerPaymentsFilter.vue b/src/pages/Customer/Payments/CustomerPaymentsFilter.vue
new file mode 100644
index 000000000..74ea2c203
--- /dev/null
+++ b/src/pages/Customer/Payments/CustomerPaymentsFilter.vue
@@ -0,0 +1,109 @@
+
+
+
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {
+ if (value.includes(','))
+ params.amount = params.amount.replace(',', '.');
+ }
+ "
+ :rules="[
+ (val) => isValidNumber(val) || !val || 'Please type a number',
+ ]"
+ lazy-rules
+ >
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ orderFk: Order
+ clientFk: Customer
+ amount: Amount
+ from: From
+ to: To
+es:
+ params:
+ orderFk: Pedido
+ clientFk: Cliente
+ amount: Importe
+ from: Desde
+ to: Hasta
+ Order ID: ID pedido
+ Customer ID: ID cliente
+ Amount: Importe
+ Please type a number: Por favor, escriba un número
+ From: Desde
+ To: Hasta
+
diff --git a/src/pages/Customer/components/CustomerConsigneeCreate.vue b/src/pages/Customer/components/CustomerConsigneeCreate.vue
new file mode 100644
index 000000000..92ce47bf2
--- /dev/null
+++ b/src/pages/Customer/components/CustomerConsigneeCreate.vue
@@ -0,0 +1,265 @@
+
+
+
+ (postcodesOptions = data)"
+ auto-load
+ ref="postcodeFetchDataRef"
+ url="Postcodes/location"
+ />
+ (citiesLocationOptions = data)"
+ auto-load
+ ref="townsFetchDataRef"
+ url="Towns/location"
+ />
+ (provincesLocationOptions = data)"
+ auto-load
+ url="Provinces/location"
+ />
+ (agencyModes = data)"
+ auto-load
+ url="AgencyModes/isActive"
+ />
+ (incoterms = data)" auto-load url="Incoterms" />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.code }}
+
+ {{ scope.opt.code }} -
+ {{ scope.opt.town.name }}
+ ({{ scope.opt.town.province.name }},
+ {{ scope.opt.town.province.country.country }})
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.name }}
+
+ {{
+ `${scope.opt.name}, ${scope.opt.province.name} (${scope.opt.province.country.country})`
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ `${scope.opt.name} (${scope.opt.country.country})`
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Default: Predeterminado
+ Consignee: Consignatario
+ Street address: Dirección postal
+ Postcode: Código postal
+ City: Población
+ Province: Provincia
+ Agency: Agencia
+ Phone: Teléfono
+ Mobile: Movíl
+ Incoterms: Incoterms
+ Customs agent: Agente de aduanas
+
diff --git a/src/pages/Customer/components/CustomerConsigneeEdit.vue b/src/pages/Customer/components/CustomerConsigneeEdit.vue
new file mode 100644
index 000000000..43649c58e
--- /dev/null
+++ b/src/pages/Customer/components/CustomerConsigneeEdit.vue
@@ -0,0 +1,371 @@
+
+
+
+ (postcodesOptions = data)"
+ auto-load
+ url="Postcodes/location"
+ />
+ (citiesLocationOptions = data)"
+ auto-load
+ url="Towns/location"
+ />
+ (provincesLocationOptions = data)"
+ auto-load
+ url="Provinces/location"
+ />
+ (agencyModes = data)"
+ auto-load
+ url="AgencyModes/isActive"
+ />
+ (incoterms = data)" auto-load url="Incoterms" />
+ (customsAgents = data)"
+ auto-load
+ url="CustomsAgents"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.code }}
+
+ {{ scope.opt.code }} -
+ {{ scope.opt.town.name }}
+ ({{ scope.opt.town.province.name }},
+ {{ scope.opt.town.province.country.country }})
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.name }}
+
+ {{
+ `${scope.opt.name}, ${scope.opt.province.name} (${scope.opt.province.country.country})`
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ `${scope.opt.name} (${scope.opt.country.country})`
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Notes') }}
+
+
+
+
+
+
+
+
+
+
+ {{ t('Remove') }}
+
+
+
+
+
+
+
+ {{ t('Add note') }}
+
+
+
+
+
+
+
+
+
+es:
+ Enabled: Activo
+ Is equalizated: Recargo de equivalencia
+ Is Loginflora allowed: Compra directa en Holanda
+ Consignee: Consignatario
+ Street address: Dirección postal
+ Postcode: Código postal
+ City: Población
+ Province: Provincia
+ Agency: Agencia
+ Phone: Teléfono
+ Mobile: Movíl
+ Incoterms: Incoterms
+ Customs agent: Agente de aduanas
+ Notes: Notas
+ Observation type: Tipo de observación
+ Description: Descripción
+ Add note: Añadir nota
+ Remove note: Eliminar nota
+
diff --git a/src/pages/Customer/components/CustomerCreditCreate.vue b/src/pages/Customer/components/CustomerCreditCreate.vue
new file mode 100644
index 000000000..053f0d18a
--- /dev/null
+++ b/src/pages/Customer/components/CustomerCreditCreate.vue
@@ -0,0 +1,51 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Credit: Crédito
+
diff --git a/src/pages/Customer/components/CustomerNewCustomsAgent.vue b/src/pages/Customer/components/CustomerNewCustomsAgent.vue
new file mode 100644
index 000000000..b8b83e763
--- /dev/null
+++ b/src/pages/Customer/components/CustomerNewCustomsAgent.vue
@@ -0,0 +1,65 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ New customs agent: Nuevo agente de aduanas
+ NIF: NIF
+ Fiscal name: Nombre fiscal
+ Street: Dirección fiscal
+ Phone: Teléfono
+
diff --git a/src/pages/Customer/components/CustomerNoteCreate.vue b/src/pages/Customer/components/CustomerNoteCreate.vue
new file mode 100644
index 000000000..cea90f975
--- /dev/null
+++ b/src/pages/Customer/components/CustomerNoteCreate.vue
@@ -0,0 +1,51 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Note: Nota
+
diff --git a/src/pages/Department/Card/DepartmentBasicData.vue b/src/pages/Department/Card/DepartmentBasicData.vue
new file mode 100644
index 000000000..3b30a97e6
--- /dev/null
+++ b/src/pages/Department/Card/DepartmentBasicData.vue
@@ -0,0 +1,135 @@
+
+
+ (workersOptions = data)"
+ auto-load
+ />
+ (clientsOptions = data)" auto-load />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Department/Card/DepartmentCard.vue b/src/pages/Department/Card/DepartmentCard.vue
new file mode 100644
index 000000000..da9accee1
--- /dev/null
+++ b/src/pages/Department/Card/DepartmentCard.vue
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Department/Card/DepartmentDescriptor.vue b/src/pages/Department/Card/DepartmentDescriptor.vue
new file mode 100644
index 000000000..bd96812c9
--- /dev/null
+++ b/src/pages/Department/Card/DepartmentDescriptor.vue
@@ -0,0 +1,127 @@
+
+
+ {
+ department = data;
+ setData(data);
+ }
+ "
+ >
+
+
+ {{ t('Delete') }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Department workers') }}
+
+
+
+
+
+
+
+ es:
+ Department workers: Trabajadores del departamento
+
diff --git a/src/pages/Department/Card/DepartmentSummary.vue b/src/pages/Department/Card/DepartmentSummary.vue
new file mode 100644
index 000000000..40bb4c83d
--- /dev/null
+++ b/src/pages/Department/Card/DepartmentSummary.vue
@@ -0,0 +1,107 @@
+
+
+
+
+
+ {{ entity.name }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Entry/Card/EntryBasicData.vue b/src/pages/Entry/Card/EntryBasicData.vue
new file mode 100644
index 000000000..a5565fbf6
--- /dev/null
+++ b/src/pages/Entry/Card/EntryBasicData.vue
@@ -0,0 +1,202 @@
+
+
+ (suppliersOptions = data)"
+ auto-load
+ />
+ (travelsOptions = data)"
+ auto-load
+ />
+ (companiesOptions = data)"
+ auto-load
+ />
+ (currenciesOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+ {{ scope.opt?.name }}
+
+ {{ scope.opt?.nickname }}, {{ scope.opt?.id }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt?.agencyModeName }} -
+ {{ scope.opt?.warehouseInName }} ({{
+ toDate(scope.opt?.shipped)
+ }}) → {{ scope.opt?.warehouseOutName }} ({{
+ toDate(scope.opt?.landed)
+ }})
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Entry/Card/EntryBuys.vue b/src/pages/Entry/Card/EntryBuys.vue
new file mode 100644
index 000000000..5eee14d29
--- /dev/null
+++ b/src/pages/Entry/Card/EntryBuys.vue
@@ -0,0 +1,409 @@
+
+
+
+ (packagingsOptions = data)"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ col.value }}
+
+
+
+
+
+
+
+ {{ props.row.item.itemType.code }}
+
+
+ {{ props.row.item.id }}
+
+
+ {{ props.row.item.size }}
+
+
+ {{ toCurrency(props.row.item.minPrice) }}
+
+
+ {{ props.row.item.concept }}
+
+ {{ props.row.item.subName }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ col.label + ': ' + col.value }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Import buys') }}
+
+
+
+
+
+
+
+es:
+ Import buys: Importar compras
+ Buy deleted: Compra eliminada
+ Buys deleted: Compras eliminadas
+ Confirm deletion: Confirmar eliminación
+ Are you sure you want to delete this buy?: Seguro que quieres eliminar esta compra?
+ Are you sure you want to delete this buys?: Seguro que quieres eliminar estas compras?
+
diff --git a/src/pages/Entry/Card/EntryBuysImport.vue b/src/pages/Entry/Card/EntryBuysImport.vue
new file mode 100644
index 000000000..50f5aeae8
--- /dev/null
+++ b/src/pages/Entry/Card/EntryBuysImport.vue
@@ -0,0 +1,282 @@
+
+
+ (lastItemBuysOptions = data)"
+ auto-load
+ />
+ (packagingsOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Select a file') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt?.id }} -
+ {{ scope.opt?.name }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Select a file: Selecciona un fichero
+ Some of the imported buys does not have an item: Algunas de las compras importadas no tienen un artículo
+
diff --git a/src/pages/Entry/Card/EntryCard.vue b/src/pages/Entry/Card/EntryCard.vue
new file mode 100644
index 000000000..f6399cc0b
--- /dev/null
+++ b/src/pages/Entry/Card/EntryCard.vue
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Search entries: Buscar entradas
+ You can search by entry reference: Puedes buscar por referencia de la entrada
+
diff --git a/src/pages/Entry/Card/EntryDescriptor.vue b/src/pages/Entry/Card/EntryDescriptor.vue
new file mode 100644
index 000000000..b1658ccd3
--- /dev/null
+++ b/src/pages/Entry/Card/EntryDescriptor.vue
@@ -0,0 +1,202 @@
+
+
+
+
+
+
+ {{ t('Show entry report') }}
+
+
+
+
+ {{ t('Go to module index') }}
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Inventory entry') }}
+
+
+ {{ t('Virtual entry') }}
+
+
+
+
+
+
+ {{ t('Supplier card') }}
+
+
+ {{ t('All travels with current agency') }}
+
+
+ {{ t('All entries with current supplier') }}
+
+
+
+
+
+
+es:
+ Supplier card: Ficha del proveedor
+ All travels with current agency: Todos los envíos con la agencia actual
+ All entries with current supplier: Todas las entradas con el proveedor actual
+ Show entry report: Ver informe del pedido
+ Go to module index: Ir al índice del modulo
+ Inventory entry: Es inventario
+ Virtual entry: Es una redada
+
diff --git a/src/pages/Entry/Card/EntryDescriptorProxy.vue b/src/pages/Entry/Card/EntryDescriptorProxy.vue
new file mode 100644
index 000000000..e1c05f1ac
--- /dev/null
+++ b/src/pages/Entry/Card/EntryDescriptorProxy.vue
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
diff --git a/src/pages/Entry/Card/EntryLog.vue b/src/pages/Entry/Card/EntryLog.vue
new file mode 100644
index 000000000..930f7dd40
--- /dev/null
+++ b/src/pages/Entry/Card/EntryLog.vue
@@ -0,0 +1,6 @@
+
+
+
+
diff --git a/src/pages/Entry/Card/EntryNotes.vue b/src/pages/Entry/Card/EntryNotes.vue
new file mode 100644
index 000000000..c78d6c842
--- /dev/null
+++ b/src/pages/Entry/Card/EntryNotes.vue
@@ -0,0 +1,99 @@
+
+
+ (entryObservationsOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Remove note') }}
+
+
+
+
+
+
+
+ {{ t('Add note') }}
+
+
+
+
+
+
+
+
+
+ es:
+ Add note: Añadir nota
+ Remove note: Quitar nota
+
diff --git a/src/pages/Entry/Card/EntrySummary.vue b/src/pages/Entry/Card/EntrySummary.vue
new file mode 100644
index 000000000..3861e0321
--- /dev/null
+++ b/src/pages/Entry/Card/EntrySummary.vue
@@ -0,0 +1,359 @@
+
+
+
+ setEntryData(data)"
+ >
+
+
+
+
+ {{ entry.id }} - {{ entry.supplier.nickname }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ entry.travel.ref }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ col.value }}
+ {{
+ col.toolTip
+ }}
+
+
+
+
+
+ {{ row.item.itemType.code }}
+
+
+ {{ row.item.id }}
+
+
+ {{ row.item.size }}
+
+
+ {{ toCurrency(row.item.minPrice) }}
+
+
+ {{ row.item.concept }}
+
+ {{ row.item.subName }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Travel data: 'Datos envío'
+
diff --git a/src/pages/Entry/Card/EntrySummaryDialog.vue b/src/pages/Entry/Card/EntrySummaryDialog.vue
new file mode 100644
index 000000000..527421ce2
--- /dev/null
+++ b/src/pages/Entry/Card/EntrySummaryDialog.vue
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Entry/EntryCreate.vue b/src/pages/Entry/EntryCreate.vue
new file mode 100644
index 000000000..d4eb8a3ef
--- /dev/null
+++ b/src/pages/Entry/EntryCreate.vue
@@ -0,0 +1,135 @@
+
+
+
+ (suppliersOptions = data)"
+ auto-load
+ />
+ (travelsOptionsOptions = data)"
+ auto-load
+ />
+ (companiesOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt?.nickname }}
+
+ #{{ scope.opt?.id }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt?.agencyModeName }} -
+ {{ scope.opt?.warehouseInName }} ({{
+ toDate(scope.opt?.shipped)
+ }}) → {{ scope.opt?.warehouseOutName }} ({{
+ toDate(scope.opt?.landed)
+ }})
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ es:
+ Supplier: Proveedor
+ Travel: Envío
+ Company: Empresa
+
diff --git a/src/pages/Entry/EntryFilter.vue b/src/pages/Entry/EntryFilter.vue
new file mode 100644
index 000000000..f137b05e8
--- /dev/null
+++ b/src/pages/Entry/EntryFilter.vue
@@ -0,0 +1,235 @@
+
+
+
+ (companiesOptions = data)"
+ auto-load
+ />
+ (currenciesOptions = data)"
+ auto-load
+ />
+ (suppliersOptions = data)"
+ auto-load
+ />
+
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ scope.opt?.name + ': ' + scope.opt?.nickname
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ search: General search
+ reference: Reference
+ invoiceNumber: Invoice number
+ travelFk: Travel
+ companyFk: Company
+ currencyFk: Currency
+ supplierFk: Supplier
+ from: From
+ to: To
+ created: Created
+ isBooked: Booked
+ isConfirmed: Confirmed
+ isOrdered: Ordered
+es:
+ params:
+ search: Búsqueda general
+ reference: Referencia
+ invoiceNumber: Núm. factura
+ travelFk: Envío
+ companyFk: Empresa
+ currencyFk: Moneda
+ supplierFk: Proveedor
+ from: Desde
+ to: Hasta
+ created: Fecha creación
+ isBooked: Asentado
+ isConfirmed: Confirmado
+ isOrdered: Pedida
+
diff --git a/src/pages/Entry/EntryList.vue b/src/pages/Entry/EntryList.vue
new file mode 100644
index 000000000..0cf707efa
--- /dev/null
+++ b/src/pages/Entry/EntryList.vue
@@ -0,0 +1,137 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Inventory entry') }}
+
+
+ {{ t('Virtual entry') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('entry.list.newEntry') }}
+
+
+
+
+
+es:
+ Search entries: Buscar entradas
+ You can search by entry reference: Puedes buscar por referencia de la entrada
+ Inventory entry: Es inventario
+ Virtual entry: Es una redada
+
diff --git a/src/pages/Entry/EntryMain.vue b/src/pages/Entry/EntryMain.vue
new file mode 100644
index 000000000..8fa17a899
--- /dev/null
+++ b/src/pages/Entry/EntryMain.vue
@@ -0,0 +1,36 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Search entries: Buscar entradas
+ You can search by entry reference: Puedes buscar por referencia de la entrada
+
diff --git a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue
index 6c79d0dc7..c969c9b27 100644
--- a/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue
+++ b/src/pages/InvoiceIn/Card/InvoiceInBasicData.vue
@@ -4,11 +4,12 @@ import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import { useQuasar } from 'quasar';
import { useArrayData } from 'src/composables/useArrayData';
-
import { downloadFile } from 'src/composables/downloadFile';
-import FetchData from 'src/components/FetchData.vue';
+
import FormModel from 'components/FormModel.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
+import FetchData from 'src/components/FetchData.vue';
+
import axios from 'axios';
const quasar = useQuasar();
@@ -21,8 +22,6 @@ const arrayData = useArrayData('InvoiceIn');
const invoiceIn = computed(() => arrayData.store.data);
const userConfig = ref(null);
-const suppliers = ref([]);
-const suppliersRef = ref();
const currencies = ref([]);
const currenciesRef = ref();
const companies = ref([]);
@@ -132,45 +131,43 @@ async function upsert() {
}
- (suppliers = data)"
- />
(currencies = data)"
+ auto-load
/>
(companies = data)"
+ auto-load
/>
(dmsTypes = data)"
+ auto-load
/>
(warehouses = data)"
+ auto-load
/>
(allowedContentTypes = data)"
+ auto-load
/>
@@ -400,13 +396,11 @@ async function upsert() {
@@ -417,7 +411,6 @@ async function upsert() {
:options="companies"
option-value="id"
option-label="code"
- @input-value="companiesRef.fetch()"
/>
@@ -459,7 +452,6 @@ async function upsert() {
:options="companies"
option-value="id"
option-label="code"
- @input-value="companiesRef.fetch()"
:rules="[requiredFieldRule]"
/>
@@ -471,7 +463,6 @@ async function upsert() {
:options="warehouses"
option-value="id"
option-label="name"
- @input-value="warehousesRef.fetch()"
:rules="[requiredFieldRule]"
/>
@@ -571,7 +561,6 @@ async function upsert() {
:options="companies"
option-value="id"
option-label="code"
- @input-value="companiesRef.fetch()"
:rules="[requiredFieldRule]"
/>
@@ -583,7 +572,6 @@ async function upsert() {
:options="warehouses"
option-value="id"
option-label="name"
- @input-value="warehousesRef.fetch()"
:rules="[requiredFieldRule]"
/>
diff --git a/src/pages/InvoiceIn/Card/InvoiceInCard.vue b/src/pages/InvoiceIn/Card/InvoiceInCard.vue
index 7af22f9c7..f11a39110 100644
--- a/src/pages/InvoiceIn/Card/InvoiceInCard.vue
+++ b/src/pages/InvoiceIn/Card/InvoiceInCard.vue
@@ -4,6 +4,7 @@ import { useStateStore } from 'stores/useStateStore';
import InvoiceInDescriptor from './InvoiceInDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'components/ui/VnSearchbar.vue';
+import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import { useArrayData } from 'src/composables/useArrayData';
import { onMounted, watch } from 'vue';
import { useRoute } from 'vue-router';
@@ -72,11 +73,7 @@ watch(
-
-
-
-
-
+
diff --git a/src/pages/InvoiceIn/InvoiceInFilter.vue b/src/pages/InvoiceIn/InvoiceInFilter.vue
index 6348d4167..dec798906 100644
--- a/src/pages/InvoiceIn/InvoiceInFilter.vue
+++ b/src/pages/InvoiceIn/InvoiceInFilter.vue
@@ -1,9 +1,12 @@
- onFetchCompanies(data)" auto-load />
- onFetchPrinters(data)" auto-load />
- onFetchClients(data)" auto-load />
+ (companiesOptions = data)"
+ auto-load
+ />
+ (printersOptions = data)" auto-load />
+ (clientsOptions = data)" auto-load />
{
class="form-container q-pa-md"
style="max-width: 256px"
>
-
+
{
val="one"
:label="t('oneClient')"
:dark="true"
+ class="q-mb-sm"
/>
{
+ is-outlined
+ />
+ is-outlined
+ />
{
url="InvoiceOuts/filter"
>
-
-
+
+
{
:model-value="selectedCards.size === rows.length"
class="q-mr-md"
/>
-
-
+
+
-
+
{
-
-
en:
searchInvoice: Search issued invoice
diff --git a/src/pages/InvoiceOut/InvoiceOutNegativeBases.vue b/src/pages/InvoiceOut/InvoiceOutNegativeBases.vue
index 7d07b8217..c832d577c 100644
--- a/src/pages/InvoiceOut/InvoiceOutNegativeBases.vue
+++ b/src/pages/InvoiceOut/InvoiceOutNegativeBases.vue
@@ -1,41 +1,55 @@
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
- {{ rows.length }} {{ t('results') }}
-
-
-
-
-
-
-
-
-
- {{ t(`invoiceOut.negativeBases.${col.label}`) }}
-
-
-
-
-
refresh());
v-if="props.col.name === 'clientId'"
:id="selectedCustomerId"
/>
-
@@ -359,11 +270,7 @@ onMounted(() => refresh());
diff --git a/src/pages/InvoiceOut/InvoiceOutNegativeBasesFilter.vue b/src/pages/InvoiceOut/InvoiceOutNegativeBasesFilter.vue
new file mode 100644
index 000000000..3adfa1d13
--- /dev/null
+++ b/src/pages/InvoiceOut/InvoiceOutNegativeBasesFilter.vue
@@ -0,0 +1,130 @@
+
+
+
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ from: From
+ to: To
+ company: Company
+ country: Country
+ clientId: Client Id
+ clientSocialName: Client
+ amount: Amount
+ comercialName: Comercial
+es:
+ params:
+ from: Desde
+ to: Hasta
+ company: Empresa
+ country: País
+ clientId: Id cliente
+ clientSocialName: Cliente
+ amount: Importe
+ comercialName: Comercial
+ Date is required: La fecha es requerida
+
+
diff --git a/src/pages/Item/Card/ItemCard.vue b/src/pages/Item/Card/ItemCard.vue
new file mode 100644
index 000000000..57c3a434d
--- /dev/null
+++ b/src/pages/Item/Card/ItemCard.vue
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Item/Card/ItemDescriptor.vue b/src/pages/Item/Card/ItemDescriptor.vue
new file mode 100644
index 000000000..362fcfc67
--- /dev/null
+++ b/src/pages/Item/Card/ItemDescriptor.vue
@@ -0,0 +1,316 @@
+
+
+
+ {
+ item = data;
+ setData(data);
+ }
+ "
+ >
+
+
+
+ {{ t('Regularize stock') }}
+
+
+
+
+
+
+
+ {{ t('Clone') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('item.descriptor.item') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('item.descriptor.visible') }}
+
+ {{
+ visible
+ }}
+
+
+
+ {{ t('item.descriptor.available') }}
+
+ {{
+ available
+ }}
+
+
+
+ {{ warehouseText }}
+
+
+
+
+
+
+
+
+ {{ t('item.descriptor.buyer') }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('item.descriptor.itemDiary') }}
+
+
+
+
+
+
+
+es:
+ Regularize stock: Regularizar stock
+ Clone: Clonar
+ All it's properties will be copied: Todas sus propiedades serán copiadas
+ Do you want to clone this item?: ¿Desea clonar este artículo?
+
+
+
diff --git a/src/pages/Item/Card/ItemDescriptorProxy.vue b/src/pages/Item/Card/ItemDescriptorProxy.vue
new file mode 100644
index 000000000..58471dc83
--- /dev/null
+++ b/src/pages/Item/Card/ItemDescriptorProxy.vue
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
diff --git a/src/pages/Item/Card/ItemDiary.vue b/src/pages/Item/Card/ItemDiary.vue
new file mode 100644
index 000000000..21249349f
--- /dev/null
+++ b/src/pages/Item/Card/ItemDiary.vue
@@ -0,0 +1 @@
+Item diary (CREAR CUANDO SE DESARROLLE EL MODULO DE ITEMS)
diff --git a/src/pages/Item/Card/ItemSummary.vue b/src/pages/Item/Card/ItemSummary.vue
new file mode 100644
index 000000000..567fbf32b
--- /dev/null
+++ b/src/pages/Item/Card/ItemSummary.vue
@@ -0,0 +1 @@
+Item summary
diff --git a/src/pages/Item/Card/ItemSummaryDialog.vue b/src/pages/Item/Card/ItemSummaryDialog.vue
new file mode 100644
index 000000000..4af617fd9
--- /dev/null
+++ b/src/pages/Item/Card/ItemSummaryDialog.vue
@@ -0,0 +1,5 @@
+
+ Item summary dialog (A DESARROLLAR CUANDO SE CREE EL MODULO DE ITEMS)
+
diff --git a/src/pages/Item/Card/ItemTags.vue b/src/pages/Item/Card/ItemTags.vue
new file mode 100644
index 000000000..95f4380e4
--- /dev/null
+++ b/src/pages/Item/Card/ItemTags.vue
@@ -0,0 +1 @@
+Item tags (CREAR CUANDO SE DESARROLLE EL MODULO DE ITEMS)
diff --git a/src/pages/Item/ItemList.vue b/src/pages/Item/ItemList.vue
new file mode 100644
index 000000000..49a5dbb64
--- /dev/null
+++ b/src/pages/Item/ItemList.vue
@@ -0,0 +1 @@
+Item list
diff --git a/src/pages/Item/ItemMain.vue b/src/pages/Item/ItemMain.vue
new file mode 100644
index 000000000..c1f2a31db
--- /dev/null
+++ b/src/pages/Item/ItemMain.vue
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Login/LoginMain.vue b/src/pages/Login/LoginMain.vue
index 2e4fd91ca..e2ccdac16 100644
--- a/src/pages/Login/LoginMain.vue
+++ b/src/pages/Login/LoginMain.vue
@@ -3,12 +3,13 @@ import { ref } from 'vue';
import { Notify, useQuasar } from 'quasar';
import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
-import axios from 'axios';
import { useSession } from 'src/composables/useSession';
import { useLogin } from 'src/composables/useLogin';
import VnLogo from 'components/ui/VnLogo.vue';
+import VnInput from 'src/components/common/VnInput.vue';
+import axios from 'axios';
const quasar = useQuasar();
const session = useSession();
@@ -68,13 +69,14 @@ async function onSubmit() {
-
-
{{ t('twoFactor.insert') }}
-
-
+
+import LeftMenu from 'components/LeftMenu.vue';
+import { useStateStore } from 'stores/useStateStore';
+import OrderDescriptor from 'pages/Order/Card/OrderDescriptor.vue';
+import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
+
+const stateStore = useStateStore();
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/Card/OrderCatalogFilter.vue b/src/pages/Order/Card/OrderCatalogFilter.vue
new file mode 100644
index 000000000..760c48726
--- /dev/null
+++ b/src/pages/Order/Card/OrderCatalogFilter.vue
@@ -0,0 +1,469 @@
+
+
+
+
+
+
+
+ {{ t(selectedCategory?.name || '') }}
+
+
+ {{ t(selectedType?.name || '') }}
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+ {{ JSON.parse(chip).tagSelection?.name }}:
+ {{
+ (JSON.parse(chip).values || [])
+ .map((item) => item.value)
+ .join(' | ')
+ }}
+
+
+
+
+
+
+
+
+
+ {{ t(category.name) }}
+
+
+
+
+
+
+ {
+ selectedTypeFk = value;
+ searchFn();
+ }
+ "
+ >
+
+
+
+ {{ opt.name }}
+
+ {{ opt.categoryName }}
+
+
+
+
+
+
+
+
+
+
+ onOrderChange(value, params, searchFn)
+ "
+ />
+
+
+
+
+ onOrderFieldChange(value, params, searchFn)
+ "
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+ (tagOptions = data)"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ type: Type
+ orderBy: Order By
+ tag: Tag
+ value: Value
+ order: Order
+es:
+ params:
+ type: Tipo
+ orderBy: Ordenar por
+ tag: Etiqueta
+ value: Valor
+ order: Orden
+ Plant: Planta
+ Flower: Flor
+ Handmade: Confección
+ Green: Verde
+ Accessories: Complemento
+ Fruit: Fruta
+
diff --git a/src/pages/Order/Card/OrderCatalogItem.vue b/src/pages/Order/Card/OrderCatalogItem.vue
new file mode 100644
index 000000000..ee73bcffb
--- /dev/null
+++ b/src/pages/Order/Card/OrderCatalogItem.vue
@@ -0,0 +1,186 @@
+
+
+
+
+
+
+
+
+ {{ item.name }}
+
+
+
{{ item.subName }}
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ to: to
+ price-kg: Precio por Kg
+en:
+ to: hasta
+ price-kg: Price per Kg
+
diff --git a/src/pages/Order/Card/OrderCatalogItemDialog.vue b/src/pages/Order/Card/OrderCatalogItemDialog.vue
new file mode 100644
index 000000000..d5464ed1a
--- /dev/null
+++ b/src/pages/Order/Card/OrderCatalogItemDialog.vue
@@ -0,0 +1,82 @@
+
+
+
+
+
+
+
+
+
+ {{ item.warehouse }}
+ |
+
+ {
+ item.quantity += item.grouping;
+ }
+ "
+ >
+ {{ item.grouping }}
+
+ x {{ toCurrency(item.price) }}
+ |
+
+
+ |
+
+
+
+
+
+ {{ t('globals.add') }}
+
+
+
+
+
+
+
diff --git a/src/pages/Order/Card/OrderDescriptor.vue b/src/pages/Order/Card/OrderDescriptor.vue
new file mode 100644
index 000000000..1c770194a
--- /dev/null
+++ b/src/pages/Order/Card/OrderDescriptor.vue
@@ -0,0 +1,139 @@
+
+
+
+ (total = response)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+ {{ entity?.client?.salesPersonUser?.name || '-' }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('order.summary.orderTicketList') }}
+
+
+ {{ t('claim.card.customerSummary') }}
+
+
+
+
+
diff --git a/src/pages/Order/Card/OrderDescriptorMenu.vue b/src/pages/Order/Card/OrderDescriptorMenu.vue
new file mode 100644
index 000000000..2e36aa3c5
--- /dev/null
+++ b/src/pages/Order/Card/OrderDescriptorMenu.vue
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+ {{ t('deleteOrder') }}
+
+
+
+
+en:
+ deleteOrder: Delete order
+ confirmDeletion: Confirm deletion
+ confirmDeletionMessage: Are you sure you want to delete this order?
+
+es:
+ deleteOrder: Eliminar pedido
+ confirmDeletion: Confirmar eliminación
+ confirmDeletionMessage: Seguro que quieres eliminar este pedido?
+
+
diff --git a/src/pages/Order/Card/OrderFilter.vue b/src/pages/Order/Card/OrderFilter.vue
new file mode 100644
index 000000000..62bfe0e02
--- /dev/null
+++ b/src/pages/Order/Card/OrderFilter.vue
@@ -0,0 +1,255 @@
+
+
+
+ (agencyList = data)"
+ />
+ (salesPersonList = data)"
+ :params="{ departmentCodes: ['VT'] }"
+ auto-load
+ />
+ (sourceList = data)"
+ auto-load
+ />
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ opt.name }}
+
+ {{ opt.nickname }},{{ opt.code }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ search: Includes
+ clientFk: Client
+ agencyModeFk: Agency
+ salesPersonFk: Sales Person
+ from: From
+ to: To
+ orderFk: Order
+ sourceApp: Application
+ myTeam: My Team
+ isConfirmed: Is Confirmed
+ showEmpty: Show Empty
+ customerId: Customer ID
+ agency: Agency
+ salesPerson: Sales Person
+ fromLanded: From Landed
+ toLanded: To Landed
+ orderId: Order ID
+ application: Application
+ myTeam: My Team
+ isConfirmed: Order Confirmed
+ showEmpty: Show Empty
+es:
+ params:
+ search: Búsqueda
+ clientFk: Cliente
+ agencyModeFk: Agencia
+ salesPersonFk: Comercial
+ from: Desde
+ to: Hasta
+ orderFk: Cesta
+ sourceApp: Aplicación
+ myTeam: Mi Equipo
+ isConfirmed: Confirmado
+ showEmpty: Mostrar vacías
+ customerId: ID Cliente
+ agency: Agencia
+ salesPerson: Comercial
+ fromLanded: Desde F. entrega
+ toLanded: Hasta F. entrega
+ orderId: ID Cesta
+ application: Aplicación
+ myTeam: Mi Equipo
+ isConfirmed: Confirmado
+ showEmpty: Mostrar vacías
+
diff --git a/src/pages/Order/Card/OrderForm.vue b/src/pages/Order/Card/OrderForm.vue
new file mode 100644
index 000000000..42aee7640
--- /dev/null
+++ b/src/pages/Order/Card/OrderForm.vue
@@ -0,0 +1,208 @@
+
+
+
+ (clientList = data)"
+ :filter="{ fields: ['id', 'name', 'defaultAddressFk'] }"
+ auto-load
+ />
+
+
+
+
+
+
+ fetchAddressList(client.defaultAddressFk)
+ "
+ >
+
+
+
+
+ {{ `${scope.opt.id}: ${scope.opt.name}` }}
+
+
+
+
+
+
+
+ fetchAgencyList(data.landed, data.addressFk)
+ "
+ >
+
+
+
+
+ {{
+ `${scope.opt.nickname}: ${scope.opt.street},${scope.opt.city}`
+ }}
+
+
+
+
+
+
+
+
+
+ fetchAgencyList(data.landed, data.addressFk)
+ "
+ />
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/Card/OrderSearchbar.vue b/src/pages/Order/Card/OrderSearchbar.vue
new file mode 100644
index 000000000..a768768a5
--- /dev/null
+++ b/src/pages/Order/Card/OrderSearchbar.vue
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+es:
+ Search order: Buscar orden
+ You can search orders by reference: Puedes buscar por referencia de la orden
+
diff --git a/src/pages/Order/Card/OrderSummary.vue b/src/pages/Order/Card/OrderSummary.vue
new file mode 100644
index 000000000..9b26891a1
--- /dev/null
+++ b/src/pages/Order/Card/OrderSummary.vue
@@ -0,0 +1,255 @@
+
+
+
+
+
+
+
+
+
+
+ {{ t('order.summary.basket') }} #{{ entity?.id }} -
+ {{ entity?.client?.name }} ({{ entity?.clientFk }})
+
+
+
+
+
+
+
+ {{ dashIfEmpty(entity?.address?.nickname) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ dashIfEmpty(entity?.address?.phone) }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ entity?.note }}
+
+
+
+
+
+ {{ t('order.summary.subtotal') }}
+
+
+ {{
+ toCurrency(entity?.subTotal)
+ }}
+
+
+
+
+ {{ t('order.summary.vat') }}
+
+
+ {{ toCurrency(entity?.VAT) }}
+
+
+
+
+ {{ t('order.summary.total') }}
+
+
+ {{ toCurrency(entity?.total) }}
+
+
+
+
+
+
+
+
+ {{ t('order.summary.item') }}
+ {{ t('order.summary.description') }}
+ {{ t('order.summary.quantity') }}
+ {{ t('order.summary.price') }}
+ {{ t('order.summary.amount') }}
+
+
+
+
+
+ {{ props.row.item?.id }}
+
+
+
+ {{ props.row.item.name }}
+
+ {{ props.row.item.subName }}
+
+
+
+
+
+ {{ props.row.quantity }}
+
+
+ {{ props.row.price }}
+
+
+ {{
+ toCurrency(props.row?.quantity * props.row?.price)
+ }}
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/Card/OrderSummaryDialog.vue b/src/pages/Order/Card/OrderSummaryDialog.vue
new file mode 100644
index 000000000..ebe891f4a
--- /dev/null
+++ b/src/pages/Order/Card/OrderSummaryDialog.vue
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/OrderCatalog.vue b/src/pages/Order/OrderCatalog.vue
new file mode 100644
index 000000000..21442d10d
--- /dev/null
+++ b/src/pages/Order/OrderCatalog.vue
@@ -0,0 +1,110 @@
+
+
+
+
+
+
+
+
+
+
+ {{ t('globals.collapseMenu') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('globals.noResults') }}
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/OrderLines.vue b/src/pages/Order/OrderLines.vue
new file mode 100644
index 000000000..a2ee42481
--- /dev/null
+++ b/src/pages/Order/OrderLines.vue
@@ -0,0 +1,290 @@
+
+
+
+ (order = data)"
+ auto-load
+ />
+ (orderSummary.total = data)"
+ auto-load
+ />
+ (orderSummary.vat = data)"
+ auto-load
+ />
+
+
+
+ {{ t('globals.noResults') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ row?.item?.name }}
+
+
+ {{ t('ID') }}: {{ row.id }}
+
+
+
+
+
+
+ {{ row.item.subName }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('confirm') }}
+
+
+
+
+
+
+
+en:
+ summary: Summary
+ subtotal: Subtotal
+ VAT: VAT
+ total: Total
+ item: Item
+ warehouse: Warehouse
+ shipped: Shipped
+ quantity: Quantity
+ price: Price
+ amount: Amount
+ remove: Remove
+ confirmDeletion: Confirm deletion,
+ confirmDeletionMessage: Are you sure you want to delete this item?
+ confirm: Confirm
+es:
+ summary: Resumen
+ subtotal: Subtotal
+ VAT: IVA
+ total: Total
+ item: Artículo
+ warehouse: Almacén
+ shipped: F. envío
+ quantity: Cantidad
+ price: Precio
+ amount: Importe
+ remove: Eliminar
+ confirmDeletion: Confirmar eliminación,
+ confirmDeletionMessage: Seguro que quieres eliminar este artículo?
+ confirm: Confirmar
+
diff --git a/src/pages/Order/OrderList.vue b/src/pages/Order/OrderList.vue
new file mode 100644
index 000000000..8b6b53fbe
--- /dev/null
+++ b/src/pages/Order/OrderList.vue
@@ -0,0 +1,155 @@
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('globals.collapseMenu') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ row?.name || '-' }}
+
+
+
+
+
+
+
+ {{ row?.clientName || '-' }}
+
+
+
+
+
+
+
+
+
+ {{ toDate(row?.landed) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('order.list.newOrder') }}
+
+
+
+
+
diff --git a/src/pages/Order/OrderMain.vue b/src/pages/Order/OrderMain.vue
new file mode 100644
index 000000000..66ce78f23
--- /dev/null
+++ b/src/pages/Order/OrderMain.vue
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Order/OrderVolume.vue b/src/pages/Order/OrderVolume.vue
new file mode 100644
index 000000000..5bb106edc
--- /dev/null
+++ b/src/pages/Order/OrderVolume.vue
@@ -0,0 +1,156 @@
+
+
+
+ (volumeSummary = data)"
+ auto-load
+ />
+
+
+
+ {{ t('globals.noResults') }}
+
+
+
+
+
+
+
loadVolumes(data)"
+ >
+
+
+
+
+
+
+
+
+
+
+
+ {{ row.item.subName }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ summary: Summary
+ total: Total
+ boxes: Boxes
+ item: Item
+ subName: Subname
+ quantity: Quantity
+ volume: m³ per quantity
+es:
+ summary: Resumen
+ total: Total
+ boxes: Cajas
+ item: Artículo
+ subName: Subname
+ quantity: Cantidad
+ volume: m³ por cantidad
+
diff --git a/src/pages/Route/Card/RouteCard.vue b/src/pages/Route/Card/RouteCard.vue
new file mode 100644
index 000000000..46b997b65
--- /dev/null
+++ b/src/pages/Route/Card/RouteCard.vue
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Route/Card/RouteDescriptor.vue b/src/pages/Route/Card/RouteDescriptor.vue
new file mode 100644
index 000000000..218764277
--- /dev/null
+++ b/src/pages/Route/Card/RouteDescriptor.vue
@@ -0,0 +1,104 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Date: Fecha
+ Agency: Agencia
+ Zone: Zona
+ Volume: Volumen
+ Description: Descripción
+
diff --git a/src/pages/Route/Card/RouteDescriptorMenu.vue b/src/pages/Route/Card/RouteDescriptorMenu.vue
new file mode 100644
index 000000000..b661d1cd7
--- /dev/null
+++ b/src/pages/Route/Card/RouteDescriptorMenu.vue
@@ -0,0 +1,63 @@
+
+
+
+
+
+
+ {{ t('deleteRoute') }}
+
+
+
+
+en:
+ confirmDeletion: Confirm deletion
+ confirmDeletionMessage: Are you sure you want to delete this route?
+ deleteRoute: Delete route
+es:
+ confirmDeletion: Confirmar eliminación,
+ confirmDeletionMessage: Seguro que quieres eliminar esta ruta?
+ deleteRoute: Eliminar ruta
+
diff --git a/src/pages/Route/Card/RouteDescriptorProxy.vue b/src/pages/Route/Card/RouteDescriptorProxy.vue
new file mode 100644
index 000000000..541f9716a
--- /dev/null
+++ b/src/pages/Route/Card/RouteDescriptorProxy.vue
@@ -0,0 +1,15 @@
+
+
+
+
+
+
diff --git a/src/pages/Route/Card/RouteFilter.vue b/src/pages/Route/Card/RouteFilter.vue
new file mode 100644
index 000000000..4be1981ab
--- /dev/null
+++ b/src/pages/Route/Card/RouteFilter.vue
@@ -0,0 +1,232 @@
+
+
+
+ (workerList = data)"
+ auto-load
+ />
+ (agencyList = data)"
+ auto-load
+ />
+ (vehicleList = data)"
+ auto-load
+ />
+ (warehouseList = data)" auto-load />
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+ {{ opt.name }}
+
+ {{ opt.nickname }},{{ opt.code }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ warehouseFk: Warehouse
+ description: Description
+ m3: m³
+ vehicleFk: Vehicle
+ agencyModeFk: Agency
+ workerFk: Worker
+ from: From
+ to: To
+es:
+ params:
+ warehouseFk: Almacén
+ description: Descripción
+ m3: m³
+ vehicleFk: Vehículo
+ agencyModeFk: Agencia
+ workerFk: Trabajador
+ from: Desde
+ to: Hasta
+ Warehouse: Almacén
+ Description: Descripción
+ Vehicle: Vehículo
+ Agency: Agencia
+ Worker: Trabajador
+ From: Desde
+ To: Hasta
+
diff --git a/src/pages/Route/Card/RouteForm.vue b/src/pages/Route/Card/RouteForm.vue
new file mode 100644
index 000000000..604f04357
--- /dev/null
+++ b/src/pages/Route/Card/RouteForm.vue
@@ -0,0 +1,233 @@
+
+
+
+ (workerList = data)"
+ auto-load
+ />
+ (agencyList = data)"
+ auto-load
+ />
+ (vehicleList = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+ {{ opt.name }}
+
+ {{ opt.nickname }},{{ opt.code }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Worker: Trabajador
+ Vehicle: Vehículo
+ Agency: Agencia
+ Km Start: Km de inicio
+ Km End: Km de fin
+ Hour started: Hora inicio
+ Hour finished: Hora fin
+ Description: Descripción
+ Is served: Se ha servido
+
diff --git a/src/pages/Route/Card/RouteSearchbar.vue b/src/pages/Route/Card/RouteSearchbar.vue
new file mode 100644
index 000000000..9ee4a602f
--- /dev/null
+++ b/src/pages/Route/Card/RouteSearchbar.vue
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+es:
+ Search route: Buscar rutas
+ You can search by route reference: Puedes buscar por referencia de la ruta
+
diff --git a/src/pages/Route/Card/RouteSummary.vue b/src/pages/Route/Card/RouteSummary.vue
new file mode 100644
index 000000000..a10ca088e
--- /dev/null
+++ b/src/pages/Route/Card/RouteSummary.vue
@@ -0,0 +1,314 @@
+
+
+
+
+
+
+
+
+
+
+
+ {{ `${entity?.route.id} - ${entity?.route?.description}` }}
+
+
+
+
+
+
+
+
+
+
+ {{ dashIfEmpty(entity?.route?.worker?.user?.name) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ dashIfEmpty(entity?.route?.description) }}
+
+
+
+
+
+
+
+
+
+ {{ value }}
+
+
+
+
+
+
+ {{ value }}
+
+
+
+
+
+
+
+ {{ value }}
+
+
+
+
+
+
+
+ {{ value }}
+
+
+
+
+
+
+
+
+
+
+en:
+ route:
+ summary:
+ date: Date
+ agency: Agency
+ vehicle: Vehicle
+ driver: Driver
+ cost: Cost
+ started: Started time
+ finished: Finished time
+ kmStart: Km start
+ kmEnd: Km end
+ volume: Volume
+ packages: Packages
+ description: Description
+ tickets: Tickets
+ order: Order
+ street: Street
+ city: City
+ pc: PC
+ client: Client
+ warehouse: Warehouse
+ m3: m³
+ packaging: Packaging
+ ticket: Ticket
+es:
+ route:
+ summary:
+ date: Fecha
+ agency: Agencia
+ vehicle: Vehículo
+ driver: Conductor
+ cost: Costo
+ started: Hora inicio
+ finished: Hora fin
+ kmStart: Km inicio
+ kmEnd: Km fin
+ volume: Volumen
+ packages: Bultos
+ description: Descripción
+ tickets: Tickets
+ order: Orden
+ street: Dirección fiscal
+ city: Población
+ pc: CP
+ client: Cliente
+ warehouse: Almacén
+ packaging: Encajado
+
diff --git a/src/pages/Route/Card/RouteSummaryDialog.vue b/src/pages/Route/Card/RouteSummaryDialog.vue
new file mode 100644
index 000000000..4a943a93a
--- /dev/null
+++ b/src/pages/Route/Card/RouteSummaryDialog.vue
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Route/Cmr/CmrFilter.vue b/src/pages/Route/Cmr/CmrFilter.vue
index bab300672..553f19431 100644
--- a/src/pages/Route/Cmr/CmrFilter.vue
+++ b/src/pages/Route/Cmr/CmrFilter.vue
@@ -1,9 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+ {{ t('globals.collapseMenu') }}
+
+
+
+
+
+
+
+
+ {{ t('Select the starting date') }}
+
+
+
+
+
+
+
+
+
+ {{ t('Clone') }}
+
+
+
+
+
+
+
+
+
+ (workers = data)"
+ auto-load
+ />
+ (agencyList = data)" auto-load />
+ (vehicleList = data)" auto-load />
+
+
+
+
+ {{ t('Clone Selected Routes') }}
+
+
+
+ {{ t('Mark as served') }}
+
+
+
+
+
+
+
+
+
+
+ {{ props.row?.workerUserName }}
+ updateWorker(props.row, worker)
+ "
+ >
+ $event.target.select()"
+ >
+
+
+
+ {{ opt.name }}
+ {{
+ opt.nickname
+ }}
+
+
+
+
+
+
+
+
+
+ {{ props.row?.agencyName }}
+ updateAgency(props.row, agency)
+ "
+ >
+ $event.target.select()"
+ />
+
+
+
+
+
+ {{ props.row?.vehiclePlateNumber }}
+ updateVehicle(props.row, vehicle)
+ "
+ >
+ $event.target.select()"
+ />
+
+
+
+
+
+ {{ toDate(props.row?.created) }}
+
+ $event.target.select()"
+ />
+
+
+
+
+
+ {{ props.row?.description }}
+
+ $event.target.select()"
+ />
+
+
+
+
+
+ {{ toHour(props.row.started) }}
+
+ $event.target.select()"
+ />
+
+
+
+
+
+ {{ toHour(props.row.finished) }}
+
+ $event.target.select()"
+ />
+
+
+
+
+
+
+
+ {{ t('Add ticket') }}
+
+
+ {{ t('Preview') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('newRoute') }}
+
+
+
+
+
+
+
+
+en:
+ newRoute: New Route
+es:
+ ID: ID
+ Worker: Trabajador
+ Agency: Agencia
+ Vehicle: Vehículo
+ Date: Fecha
+ Description: Descripción
+ Hour started: Hora inicio
+ Hour finished: Hora fin
+ newRoute: Nueva Ruta
+ Clone Selected Routes: Clonar rutas seleccionadas
+ Select the starting date: Seleccione la fecha de inicio
+ Stating date: Fecha de inicio
+ Cancel: Cancelar
+ Clone: Clonar
+ Mark as served: Marcar como servidas
+ Add ticket: Añadir tickets
+ Preview: Vista previa
+
diff --git a/src/pages/Shelving/Card/ShelvingDescriptor.vue b/src/pages/Shelving/Card/ShelvingDescriptor.vue
index 34c374117..6beca6d88 100644
--- a/src/pages/Shelving/Card/ShelvingDescriptor.vue
+++ b/src/pages/Shelving/Card/ShelvingDescriptor.vue
@@ -5,8 +5,8 @@ import { useI18n } from 'vue-i18n';
import CardDescriptor from 'components/ui/CardDescriptor.vue';
import VnLv from 'components/ui/VnLv.vue';
import useCardDescription from 'composables/useCardDescription';
-import WorkerDescriptorProxy from "pages/Worker/Card/WorkerDescriptorProxy.vue";
-import ShelvingDescriptorMenu from "pages/Shelving/Card/ShelvingDescriptorMenu.vue";
+import ShelvingDescriptorMenu from 'pages/Shelving/Card/ShelvingDescriptorMenu.vue';
+import VnUserLink from 'src/components/ui/VnUserLink.vue';
const $props = defineProps({
id: {
@@ -57,14 +57,14 @@ const setData = (entity) => (data.value = useCardDescription(entity.code, entity
-
- {{ entity.worker?.user?.nickname }}
-
-
+
-
+
diff --git a/src/pages/Shelving/Card/ShelvingFilter.vue b/src/pages/Shelving/Card/ShelvingFilter.vue
index 423402f89..6767f6d97 100644
--- a/src/pages/Shelving/Card/ShelvingFilter.vue
+++ b/src/pages/Shelving/Card/ShelvingFilter.vue
@@ -41,7 +41,11 @@ function setParkings(data) {
@on-fetch="setWorkers"
auto-load
/>
-
+
{{ t(`params.${tag.label}`) }}:
@@ -49,59 +53,57 @@ function setParkings(data) {
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Shelving/Card/ShelvingForm.vue b/src/pages/Shelving/Card/ShelvingForm.vue
index e30ac1939..e9e5e68c3 100644
--- a/src/pages/Shelving/Card/ShelvingForm.vue
+++ b/src/pages/Shelving/Card/ShelvingForm.vue
@@ -5,6 +5,8 @@ import { useRoute } from 'vue-router';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
import FormModel from 'components/FormModel.vue';
+import VnInput from 'src/components/common/VnInput.vue';
+import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
const { t } = useI18n();
const route = useRoute();
@@ -15,7 +17,7 @@ const defaultInitialData = {
priority: 0,
code: null,
isRecyclable: false,
-}
+};
const parkingFilter = { fields: ['id', 'code'] };
const parkingList = ref([]);
@@ -58,11 +60,7 @@ const shelvingFilter = {
};
-
-
-
-
-
+
-
-
-
+
-
-
diff --git a/src/pages/Supplier/Card/SupplierAccounts.vue b/src/pages/Supplier/Card/SupplierAccounts.vue
new file mode 100644
index 000000000..b4aac8c38
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierAccounts.vue
@@ -0,0 +1,193 @@
+
+
+ (bankEntitiesOptions = data)"
+ auto-load
+ />
+ (wireTransferFk = data.id)"
+ :filter="{ where: { code: 'wireTransfer' } }"
+ auto-load
+ />
+ (supplier = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+ {{
+ t('components.iban_tooltip')
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.bic }}
+ {{ scope.opt.name }}
+
+
+
+
+
+
+
+
+
+ {{
+ t(
+ 'Name of the bank account holder if different from the provider'
+ )
+ }}
+
+
+
+
+
+
+
+ {{ t('Remove account') }}
+
+
+
+
+
+
+
+ {{ t('Add account') }}
+
+
+
+
+
+
+
+
+
+ es:
+ Do you want to change the pay method to wire transfer?: ¿Quieres modificar la forma de pago a transferencia?
+ Add account: Añadir cuenta
+ Remove account: Remover cuenta
+ Name of the bank account holder if different from the provider: Nombre del titular de la cuenta bancaria en caso de ser diferente del proveedor
+
diff --git a/src/pages/Supplier/Card/SupplierAddresses.vue b/src/pages/Supplier/Card/SupplierAddresses.vue
new file mode 100644
index 000000000..c6b08075f
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierAddresses.vue
@@ -0,0 +1,90 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('supplier.list.newSupplier') }}
+
+
+
+
diff --git a/src/pages/Supplier/Card/SupplierAddressesCreate.vue b/src/pages/Supplier/Card/SupplierAddressesCreate.vue
new file mode 100644
index 000000000..60a803ee1
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierAddressesCreate.vue
@@ -0,0 +1,179 @@
+
+
+
+ (postcodesOptions = data)"
+ auto-load
+ />
+ (provincesOptions = data)"
+ auto-load
+ url="Provinces"
+ />
+ (townsLocationOptions = data)"
+ auto-load
+ url="Towns/location"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.code }}
+ {{ scope.opt.code }} -
+ {{ scope.opt.town.name }} ({{
+ scope.opt.town.province.name
+ }},
+ {{
+ scope.opt.town.province.country.country
+ }})
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Supplier/Card/SupplierAgencyTerm.vue b/src/pages/Supplier/Card/SupplierAgencyTerm.vue
new file mode 100644
index 000000000..769ff4dad
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierAgencyTerm.vue
@@ -0,0 +1,139 @@
+
+
+ (agenciesOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+ {{ row.agency?.name }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Remove row') }}
+
+
+
+
+
+
+
+
+
+
+ {{ t('supplier.agencyTerms.addRow') }}
+
+
+
+
+
+ es:
+ Remove row: Eliminar fila
+
diff --git a/src/pages/Supplier/Card/SupplierAgencyTermCreate.vue b/src/pages/Supplier/Card/SupplierAgencyTermCreate.vue
new file mode 100644
index 000000000..17786c1ea
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierAgencyTermCreate.vue
@@ -0,0 +1,110 @@
+
+
+
+ (agenciesOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Supplier/Card/SupplierBasicData.vue b/src/pages/Supplier/Card/SupplierBasicData.vue
new file mode 100644
index 000000000..bc50deb9b
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierBasicData.vue
@@ -0,0 +1,108 @@
+
+
+ (workersOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+ {{
+ t('Responsible for approving invoices')
+ }}
+
+
+
+
+
+ {{ scope.opt?.name }}
+
+ {{ scope.opt?.nickname }}, {{ scope.opt?.id }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+es:
+ Responsible for approving invoices: Responsable de aprobar las facturas
+
diff --git a/src/pages/Supplier/Card/SupplierBillingData.vue b/src/pages/Supplier/Card/SupplierBillingData.vue
new file mode 100644
index 000000000..bf5ccb115
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierBillingData.vue
@@ -0,0 +1,73 @@
+
+
+ (paymethodsOptions = data)"
+ auto-load
+ />
+ formatPayDems(data)" auto-load />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Supplier/Card/SupplierCard.vue b/src/pages/Supplier/Card/SupplierCard.vue
index cf94c9e8d..ddac988e7 100644
--- a/src/pages/Supplier/Card/SupplierCard.vue
+++ b/src/pages/Supplier/Card/SupplierCard.vue
@@ -2,6 +2,9 @@
import { useI18n } from 'vue-i18n';
import { useStateStore } from 'stores/useStateStore';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
+import LeftMenu from 'components/LeftMenu.vue';
+import SupplierDescriptor from './SupplierDescriptor.vue';
+import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -11,6 +14,7 @@ const { t } = useI18n();
@@ -18,16 +22,14 @@ const { t } = useI18n();
-
+
+
+
-
-
-
-
-
+
@@ -61,3 +63,8 @@ const { t } = useI18n();
}
}
+
+
+ es:
+ Search suppliers: Buscar proveedores
+
diff --git a/src/pages/Supplier/Card/SupplierConsumption.vue b/src/pages/Supplier/Card/SupplierConsumption.vue
new file mode 100644
index 000000000..59dd2281c
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierConsumption.vue
@@ -0,0 +1,208 @@
+
+
+
+
+
+
+ {{ t('Open as PDF') }}
+
+
+
+
+ {{ t('Send to email') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ t('supplier.consumption.entry')
+ }}
+ {{ row.id }}
+ {{ t('supplier.consumption.date') }}
+ {{ toDate(row.shipped) }}
+ {{
+ t('supplier.consumption.reference')
+ }}
+ {{ row.invoiceNumber }}
+
+
+
+ {{ buy.itemName }}
+
+
+
+
+ {{ buy.subName }}
+
+
+ {{ dashIfEmpty(buy.quantity) }}
+ {{ dashIfEmpty(buy.price) }}
+ {{ dashIfEmpty(buy.total) }}
+
+
+
+ {{ t('Total entry') }}:
+ {{ calculateTotal(row.buys) }}
+
+
+
+
+
+
+
+
+
+
+es:
+ Total entry: Total entrada
+ Open as PDF: Abrir como PDF
+ Send to email: Enviar por email
+ This supplier does not have a contact with an email address: Este proveedor no tiene un email de contacto
+
diff --git a/src/pages/Supplier/Card/SupplierConsumptionFilter.vue b/src/pages/Supplier/Card/SupplierConsumptionFilter.vue
new file mode 100644
index 000000000..339a9d0d9
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierConsumptionFilter.vue
@@ -0,0 +1,181 @@
+
+
+
+ (buyersOptions = data)"
+ auto-load
+ />
+ (itemTypesOptions = data)"
+ auto-load
+ />
+ (itemCategoriesOptions = data)"
+ auto-load
+ />
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt?.name }}
+ {{
+ scope.opt?.category?.name
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ search: General search
+ itemId: Item id
+ buyerId: Buyer
+ typeId: Type
+ categoryId: Category
+ from: From
+ to: To
+es:
+ params:
+ search: Búsqueda general
+ itemId: Id Artículo
+ buyerId: Comprador
+ typeId: Tipo
+ categoryId: Reino
+ from: Desde
+ to: Hasta
+
diff --git a/src/pages/Supplier/Card/SupplierContacts.vue b/src/pages/Supplier/Card/SupplierContacts.vue
new file mode 100644
index 000000000..d69b74a4c
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierContacts.vue
@@ -0,0 +1,118 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ t('Remove contact') }}
+
+
+
+
+
+
+
+
+ {{ t('Add contact') }}
+
+
+
+
+
+
+
+
+
+
+
+ es:
+ Add contact: Añadir contacto
+ Remove contact: Remover contacto
+
diff --git a/src/pages/Supplier/Card/SupplierDescriptor.vue b/src/pages/Supplier/Card/SupplierDescriptor.vue
index 910d36489..83bad87d2 100644
--- a/src/pages/Supplier/Card/SupplierDescriptor.vue
+++ b/src/pages/Supplier/Card/SupplierDescriptor.vue
@@ -1,10 +1,14 @@
@@ -73,22 +103,99 @@ const setData = (entity) => {
@on-fetch="setData"
data-key="Supplier"
>
+
+
+
+ {{ t('Go to module index') }}
+
+
+
+
+
+
+ {{ t('Inactive supplier') }}
+
+
+ {{ t('Unverified supplier') }}
+
+
+
+
+
+
+ {{ t('All entries with current supplier') }}
+
+
+ {{ t('Go to client') }}
+
+
+ {{ t('Create invoiceIn') }}
+
+
+
-
+
+es:
+ All entries with current supplier: Todas las entradas con proveedor actual
+ Go to client: Ir a cliente
+ Create invoiceIn: Crear factura recibida
+ Go to module index: Ir al índice del módulo
+ Inactive supplier: Proveedor inactivo
+ Unverified supplier: Proveedor no verificado
diff --git a/src/pages/Supplier/Card/SupplierFiscalData.vue b/src/pages/Supplier/Card/SupplierFiscalData.vue
new file mode 100644
index 000000000..d481d6205
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierFiscalData.vue
@@ -0,0 +1,298 @@
+
+
+ (sageTaxTypesOptions = data)"
+ />
+ (sageWithholdingsOptions = data)"
+ />
+ (sageTransactionTypesOptions = data)"
+ />
+ (supplierActivitiesOptions = data)"
+ />
+ (postcodesOptions = data)"
+ auto-load
+ />
+ (townsLocationOptions = data)"
+ auto-load
+ url="Towns/location"
+ />
+ (provincesLocationOptions = data)"
+ auto-load
+ url="Provinces/location"
+ />
+ (countriesOptions = data)"
+ auto-load
+ url="Countries"
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.code }}
+ {{ scope.opt.code }} -
+ {{ scope.opt.town.name }} ({{
+ scope.opt.town.province.name
+ }},
+ {{
+ scope.opt.town.province.country.country
+ }})
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.name }}
+ {{ scope.opt.name }},
+ {{ scope.opt.province.name }} ({{
+ scope.opt.province.country.country
+ }})
+
+
+
+
+
+
+
+
+
+
+ {{
+ `${scope.opt.name} (${scope.opt.country.country})`
+ }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ t(
+ 'When activating it, do not enter the country code in the ID field.'
+ )
+ }}
+
+
+
+
+
+
+
+
+
+
+es:
+ When activating it, do not enter the country code in the ID field.: Al activarlo, no informar el código del país en el campo nif
+
diff --git a/src/pages/Supplier/Card/SupplierLog.vue b/src/pages/Supplier/Card/SupplierLog.vue
new file mode 100644
index 000000000..86ee15fce
--- /dev/null
+++ b/src/pages/Supplier/Card/SupplierLog.vue
@@ -0,0 +1,6 @@
+
+
+
+
diff --git a/src/pages/Supplier/Card/SupplierSummary.vue b/src/pages/Supplier/Card/SupplierSummary.vue
index e9fbffe96..d734e21a5 100644
--- a/src/pages/Supplier/Card/SupplierSummary.vue
+++ b/src/pages/Supplier/Card/SupplierSummary.vue
@@ -3,11 +3,11 @@ import { onMounted, ref, computed, onUpdated } from 'vue';
import { useRoute } from 'vue-router';
import { useI18n } from 'vue-i18n';
import CardSummary from 'components/ui/CardSummary.vue';
-import WorkerDescriptorProxy from 'pages/Worker/Card/WorkerDescriptorProxy.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import { getUrl } from 'src/composables/getUrl';
import { useRole } from 'src/composables/useRole';
import { dashIfEmpty } from 'src/filters';
+import VnUserLink from 'src/components/ui/VnUserLink.vue';
onUpdated(() => summaryRef.value.fetch());
@@ -53,7 +53,7 @@ const isAdministrative = computed(() => {
>
@@ -71,13 +71,10 @@ const isAdministrative = computed(() => {
-
- {{ dashIfEmpty(supplier.worker?.user?.nickname) }}
-
-
+
@@ -185,4 +182,3 @@ const isAdministrative = computed(() => {
-
diff --git a/src/pages/Supplier/SupplierCreate.vue b/src/pages/Supplier/SupplierCreate.vue
index 9b792483b..8424ae68c 100644
--- a/src/pages/Supplier/SupplierCreate.vue
+++ b/src/pages/Supplier/SupplierCreate.vue
@@ -1,17 +1,27 @@
@@ -26,20 +36,17 @@ const newSupplierForm = reactive({
-
-
-
-
-
+
-
@@ -49,13 +56,3 @@ const newSupplierForm = reactive({
-
-
diff --git a/src/pages/Supplier/SupplierList.vue b/src/pages/Supplier/SupplierList.vue
index ea7bc3cb0..f4875fc99 100644
--- a/src/pages/Supplier/SupplierList.vue
+++ b/src/pages/Supplier/SupplierList.vue
@@ -1,13 +1,16 @@
+
+
+ (provincesOptions = data)"
+ auto-load
+ />
+ (countriesOptions = data)"
+ auto-load
+ />
+
+
+
+ {{ t(`params.${tag.label}`) }}:
+ {{ formatFn(tag.value) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+en:
+ params:
+ search: General search
+ nickname: Alias
+ nif: Tax number
+ provinceFk: Province
+ countryFk: Country
+es:
+ params:
+ search: Búsqueda general
+ nickname: Alias
+ nif: NIF/CIF
+ provinceFk: Provincia
+ countryFk: País
+
diff --git a/src/pages/Ticket/Card/TicketCard.vue b/src/pages/Ticket/Card/TicketCard.vue
index 91921f827..35870946a 100644
--- a/src/pages/Ticket/Card/TicketCard.vue
+++ b/src/pages/Ticket/Card/TicketCard.vue
@@ -4,6 +4,7 @@ import { useStateStore } from 'stores/useStateStore';
import TicketDescriptor from './TicketDescriptor.vue';
import LeftMenu from 'components/LeftMenu.vue';
import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
+import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
const stateStore = useStateStore();
const { t } = useI18n();
@@ -26,11 +27,8 @@ const { t } = useI18n();
-
-
-
-
-
+
+
diff --git a/src/pages/Ticket/Card/TicketDescriptor.vue b/src/pages/Ticket/Card/TicketDescriptor.vue
index d2a407874..37ed13c2e 100644
--- a/src/pages/Ticket/Card/TicketDescriptor.vue
+++ b/src/pages/Ticket/Card/TicketDescriptor.vue
@@ -8,7 +8,7 @@ import CardDescriptor from 'components/ui/CardDescriptor.vue';
import TicketDescriptorMenu from './TicketDescriptorMenu.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import useCardDescription from 'src/composables/useCardDescription';
-import WorkerDescriptorProxy from 'src/pages/Worker/Card/WorkerDescriptorProxy.vue';
+import VnUserLink from 'src/components/ui/VnUserLink.vue';
const $props = defineProps({
id: {
@@ -106,13 +106,10 @@ const setData = (entity) =>
-
- {{ entity.client.salesPersonUser.name }}
-
-
+
diff --git a/src/pages/Ticket/Card/TicketSms.vue b/src/pages/Ticket/Card/TicketSms.vue
index b145be50e..ff7de6611 100644
--- a/src/pages/Ticket/Card/TicketSms.vue
+++ b/src/pages/Ticket/Card/TicketSms.vue
@@ -1,118 +1,16 @@
-
-
-
-
-
-
-
-
-
-
-
-
- {{ row.sms.sender.name }}
-
-
-
-
-
-
- {{
- formatNumer(row.sms.destination)
- }}
- {{ row.sms.message }}
-
-
- {{
- date.formatDate(
- row.sms.created,
- 'YYYY-MM-DD HH:mm:ss'
- )
- }}
-
-
- {{ row.sms.status }}
-
-
-
-
-
-
-
-
+
diff --git a/src/pages/Ticket/Card/TicketSummary.vue b/src/pages/Ticket/Card/TicketSummary.vue
index 4114b0c8e..fe7dcee9a 100644
--- a/src/pages/Ticket/Card/TicketSummary.vue
+++ b/src/pages/Ticket/Card/TicketSummary.vue
@@ -8,10 +8,10 @@ import CardSummary from 'components/ui/CardSummary.vue';
import FetchData from 'components/FetchData.vue';
import FetchedTags from 'components/ui/FetchedTags.vue';
import InvoiceOutDescriptorProxy from 'pages/InvoiceOut/Card/InvoiceOutDescriptorProxy.vue';
-import WorkerDescriptorProxy from 'pages/Worker/Card/WorkerDescriptorProxy.vue';
import VnLv from 'src/components/ui/VnLv.vue';
import VnLinkPhone from 'src/components/ui/VnLinkPhone.vue';
import { getUrl } from 'src/composables/getUrl';
+import VnUserLink from 'src/components/ui/VnUserLink.vue';
onUpdated(() => summaryRef.value.fetch());
@@ -58,7 +58,7 @@ function formattedAddress() {
function isEditable() {
try {
- return !ticket.value.ticketState.state.alertLevel;
+ return !ticket.value.ticketState?.state?.alertLevel;
} catch (e) {
console.error(e);
}
@@ -153,20 +153,17 @@ async function changeState(value) {
-
- {{ ticket.ticketState.state.name }}
+
+ {{ ticket.ticketState?.state?.name }}
-
- {{ ticket.client?.salesPersonUser?.name }}
-
-
+
import { ref } from 'vue';
import { useI18n } from 'vue-i18n';
+
import FetchData from 'components/FetchData.vue';
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
+import VnInput from 'src/components/common/VnInput.vue';
+
import toDateString from 'filters/toDateString';
-import VnInputDate from "components/common/VnInputDate.vue";
+import VnInputDate from 'components/common/VnInputDate.vue';
const { t } = useI18n();
const props = defineProps({
@@ -53,176 +56,189 @@ const warehouses = ref();
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
-
+
-
+
-
-
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -232,7 +248,7 @@ en:
params:
search: Contains
clientFk: Customer
- orderFK: Order
+ orderFk: Order
from: From
to: To
salesPersonFk: Salesperson
@@ -249,7 +265,7 @@ es:
params:
search: Contiene
clientFk: Cliente
- orderFK: Pedido
+ orderFk: Pedido
from: Desde
to: Hasta
salesPersonFk: Comercial
diff --git a/src/pages/Ticket/TicketList.vue b/src/pages/Ticket/TicketList.vue
index 7d7429630..6f57ad0b9 100644
--- a/src/pages/Ticket/TicketList.vue
+++ b/src/pages/Ticket/TicketList.vue
@@ -74,7 +74,7 @@ function viewSummary(id) {
-
+
@@ -134,13 +134,6 @@ function viewSummary(id) {
-
-
es:
Search ticket: Buscar ticket
diff --git a/src/pages/Travel/Card/TravelCard.vue b/src/pages/Travel/Card/TravelCard.vue
index 6309c14ab..34ecc25ee 100644
--- a/src/pages/Travel/Card/TravelCard.vue
+++ b/src/pages/Travel/Card/TravelCard.vue
@@ -1,21 +1,23 @@
-
+
+
+
-
-
-
-
-
+
+
diff --git a/src/pages/Travel/Card/TravelSummary.vue b/src/pages/Travel/Card/TravelSummary.vue
index ad4659b11..4f0e8860a 100644
--- a/src/pages/Travel/Card/TravelSummary.vue
+++ b/src/pages/Travel/Card/TravelSummary.vue
@@ -2,14 +2,15 @@
import { onMounted, ref, computed, onUpdated } from 'vue';
import { useRoute, useRouter } from 'vue-router';
import { useI18n } from 'vue-i18n';
+
+import { QCheckbox, QIcon } from 'quasar';
import CardSummary from 'components/ui/CardSummary.vue';
import VnLv from 'src/components/ui/VnLv.vue';
-import { getUrl } from 'src/composables/getUrl';
-import { toDate } from 'src/filters';
+
import travelService from 'src/services/travel.service';
-import { QCheckbox, QIcon } from 'quasar';
-import { toCurrency } from 'filters/index';
-import VnRow from 'components/ui/VnRow.vue';
+import { toDate, toCurrency } from 'src/filters';
+import { getUrl } from 'src/composables/getUrl';
+import axios from 'axios';
onUpdated(() => summaryRef.value.fetch());
@@ -40,9 +41,17 @@ const cloneTravel = () => {
redirectToCreateView(stringifiedTravelData);
};
+const cloneTravelWithEntries = () => {
+ try {
+ axios.post(`Travels/${$props.id}/cloneWithEntries`);
+ } catch (err) {
+ console.err('Error cloning travel with entries');
+ }
+};
+
const headerMenuOptions = [
{ name: t('travel.summary.cloneShipping'), action: cloneTravel },
- { name: t('travel.summary.CloneTravelAndEntries'), action: null },
+ { name: t('travel.summary.CloneTravelAndEntries'), action: cloneTravelWithEntries },
{ name: t('travel.summary.AddEntry'), action: null },
];
@@ -185,7 +194,7 @@ const openEntryDescriptor = () => {};
>
@@ -208,75 +217,47 @@ const openEntryDescriptor = () => {};
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+ {{ t('Open as PDF') }}
+
+
+
+
@@ -314,7 +322,7 @@ onMounted(async () => {
label-set="Save"
label-cancel="Close"
>
- {
:props="props"
class="secondary-row"
>
- {{ entry.id }}
-
-
+
+ {{ entry.id }}
+
{{
@@ -394,7 +401,7 @@ onMounted(async () => {
diff --git a/src/pages/Travel/TravelFilter.vue b/src/pages/Travel/TravelFilter.vue
index 2c2d80488..62439a2e4 100644
--- a/src/pages/Travel/TravelFilter.vue
+++ b/src/pages/Travel/TravelFilter.vue
@@ -1,9 +1,12 @@
+
+
+ onFetchWorkerConfig(data)"
+ :filter="workerConfigFilter"
+ auto-load
+ />
+
+ (companiesOptions = data)"
+ auto-load
+ />
+ (workersOptions = data)"
+ auto-load
+ />
+ (payMethodsOptions = data)"
+ auto-load
+ />
+ (bankEntitiesOptions = data)"
+ auto-load
+ />
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ handleLocation(data, location)
+ "
+ >
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.name }}
+ {{ scope.opt.nickname }},
+ {{ scope.opt.code }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{
+ t('components.iban_tooltip')
+ }}
+
+
+
+
+
+
+
+
+
+
+
+ {{ scope.opt.bic }}
+ {{ scope.opt.name }}
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/Worker/WorkerDepartment.vue b/src/pages/Worker/WorkerDepartment.vue
new file mode 100644
index 000000000..3c0e5fdd0
--- /dev/null
+++ b/src/pages/Worker/WorkerDepartment.vue
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+es:
+ Search worker: Buscar trabajador
+ You can search by worker id or name: Puedes buscar por id o nombre del trabajador
+
diff --git a/src/pages/Worker/WorkerFilter.vue b/src/pages/Worker/WorkerFilter.vue
index 079905c4f..0853791ef 100644
--- a/src/pages/Worker/WorkerFilter.vue
+++ b/src/pages/Worker/WorkerFilter.vue
@@ -1,8 +1,10 @@
@@ -60,7 +64,7 @@ function viewSummary(id) {
-
+
+
+
+
+ {{ t('worker.list.newWorker') }}
+
+
-
-
es:
Search worker: Buscar trabajador
diff --git a/src/router/modules/Supplier.js b/src/router/modules/Supplier.js
index 198a9581e..d341ddc25 100644
--- a/src/router/modules/Supplier.js
+++ b/src/router/modules/Supplier.js
@@ -11,7 +11,17 @@ export default {
redirect: { name: 'SupplierMain' },
menus: {
main: ['SupplierList'],
- card: [],
+ card: [
+ 'SupplierBasicData',
+ 'SupplierFiscalData',
+ 'SupplierBillingData',
+ 'SupplierLog',
+ 'SupplierAccounts',
+ 'SupplierContacts',
+ 'SupplierAddresses',
+ 'SupplierConsumption',
+ 'SupplierAgencyTerm',
+ ],
},
children: [
{
@@ -55,6 +65,107 @@ export default {
component: () =>
import('src/pages/Supplier/Card/SupplierSummary.vue'),
},
+ {
+ path: 'basic-data',
+ name: 'SupplierBasicData',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierBasicData.vue'),
+ },
+ {
+ path: 'fiscal-data',
+ name: 'SupplierFiscalData',
+ meta: {
+ title: 'fiscalData',
+ icon: 'vn:dfiscales',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierFiscalData.vue'),
+ },
+ {
+ path: 'billing-data',
+ name: 'SupplierBillingData',
+ meta: {
+ title: 'billingData',
+ icon: 'vn:payment',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierBillingData.vue'),
+ },
+ {
+ path: 'log',
+ name: 'SupplierLog',
+ meta: {
+ title: 'log',
+ icon: 'vn:History',
+ },
+ component: () => import('src/pages/Supplier/Card/SupplierLog.vue'),
+ },
+ {
+ path: 'account',
+ name: 'SupplierAccounts',
+ meta: {
+ title: 'accounts',
+ icon: 'vn:account',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierAccounts.vue'),
+ },
+ {
+ path: 'contact',
+ name: 'SupplierContacts',
+ meta: {
+ title: 'contacts',
+ icon: 'contact_phone',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierContacts.vue'),
+ },
+ {
+ path: 'address',
+ name: 'SupplierAddresses',
+ meta: {
+ title: 'addresses',
+ icon: 'vn:delivery',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierAddresses.vue'),
+ },
+ {
+ path: 'address/create',
+ name: 'SupplierAddressesCreate',
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierAddressesCreate.vue'),
+ },
+ {
+ path: 'consumption',
+ name: 'SupplierConsumption',
+ meta: {
+ title: 'consumption',
+ icon: 'show_chart',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierConsumption.vue'),
+ },
+ {
+ path: 'agency-term',
+ name: 'SupplierAgencyTerm',
+ meta: {
+ title: 'agencyTerm',
+ icon: 'vn:agency-term',
+ },
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierAgencyTerm.vue'),
+ },
+ {
+ path: 'agency-term/create',
+ name: 'SupplierAgencyTermCreate',
+ component: () =>
+ import('src/pages/Supplier/Card/SupplierAgencyTermCreate.vue'),
+ },
],
},
],
diff --git a/src/router/modules/customer.js b/src/router/modules/customer.js
index 832a1e0fd..fa57682af 100644
--- a/src/router/modules/customer.js
+++ b/src/router/modules/customer.js
@@ -10,8 +10,29 @@ export default {
component: RouterView,
redirect: { name: 'CustomerMain' },
menus: {
- main: ['CustomerList', 'CustomerPayments'],
- card: ['CustomerBasicData'],
+ main: [
+ 'CustomerList',
+ 'CustomerPayments',
+ 'CustomerExtendedList',
+ 'CustomerNotifications',
+ 'CustomerDefaulter',
+ ],
+ card: [
+ 'CustomerBasicData',
+ 'CustomerFiscalData',
+ 'CustomerBillingData',
+ 'CustomerConsignees',
+ 'CustomerNotes',
+ 'CustomerCredits',
+ 'CustomerGreuges',
+ 'CustomerBalance',
+ 'CustomerRecoveries',
+ 'CustomerWebAccess',
+ 'CustomerLog',
+ 'CustomerSms',
+ 'CustomerCreditManagement',
+ 'CustomerOthers',
+ ],
},
children: [
{
@@ -29,6 +50,14 @@ export default {
},
component: () => import('src/pages/Customer/CustomerList.vue'),
},
+ {
+ path: 'create',
+ name: 'CustomerCreate',
+ meta: {
+ title: 'create',
+ },
+ component: () => import('src/pages/Customer/CustomerCreate.vue'),
+ },
{
path: 'payments',
name: 'CustomerPayments',
@@ -36,7 +65,42 @@ export default {
title: 'webPayments',
icon: 'vn:onlinepayment',
},
- component: () => import('src/pages/Customer/CustomerPayments.vue'),
+ component: () =>
+ import('src/pages/Customer/Payments/CustomerPayments.vue'),
+ },
+ {
+ path: 'extendedList',
+ name: 'CustomerExtendedList',
+ meta: {
+ title: 'extendedList',
+ icon: 'vn:client',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/ExtendedList/CustomerExtendedList.vue'
+ ),
+ },
+ {
+ path: 'notifications',
+ name: 'CustomerNotifications',
+ meta: {
+ title: 'notifications',
+ icon: 'notifications',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/Notifications/CustomerNotifications.vue'
+ ),
+ },
+ {
+ path: 'defaulter',
+ name: 'CustomerDefaulter',
+ meta: {
+ title: 'defaulter',
+ icon: 'vn:risk',
+ },
+ component: () =>
+ import('src/pages/Customer/Defaulter/CustomerDefaulter.vue'),
},
],
},
@@ -66,6 +130,205 @@ export default {
component: () =>
import('src/pages/Customer/Card/CustomerBasicData.vue'),
},
+ {
+ path: 'fiscal-data',
+ name: 'CustomerFiscalData',
+ meta: {
+ title: 'fiscalData',
+ icon: 'vn:dfiscales',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerFiscalData.vue'),
+ },
+ {
+ path: 'billing-data',
+ name: 'CustomerBillingData',
+ meta: {
+ title: 'billingData',
+ icon: 'vn:payment',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerBillingData.vue'),
+ },
+ {
+ path: 'consignees',
+ name: 'ConsigneesCard',
+ redirect: { name: 'CustomerConsignees' },
+ children: [
+ {
+ path: '',
+ name: 'CustomerConsignees',
+ meta: {
+ icon: 'vn:delivery',
+ title: 'consignees',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerConsignees.vue'),
+ },
+ {
+ path: 'create',
+ name: 'CustomerConsigneeCreate',
+ meta: {
+ title: 'consignee-create',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/components/CustomerConsigneeCreate.vue'
+ ),
+ },
+ {
+ path: ':consigneeId',
+ name: 'CustomerConsigneeEditCard',
+ redirect: { name: 'CustomerConsigneeEdit' },
+ children: [
+ {
+ path: 'edit',
+ name: 'CustomerConsigneeEdit',
+ meta: {
+ title: 'consignee-edit',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/components/CustomerConsigneeEdit.vue'
+ ),
+ },
+ ],
+ },
+ ],
+ },
+ {
+ path: 'notes',
+ name: 'NotesCard',
+ redirect: { name: 'CustomerNotes' },
+ children: [
+ {
+ path: '',
+ name: 'CustomerNotes',
+ meta: {
+ title: 'notes',
+ icon: 'vn:notes',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerNotes.vue'),
+ },
+ {
+ path: 'create',
+ name: 'CustomerNoteCreate',
+ meta: {
+ title: 'note-create',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/components/CustomerNoteCreate.vue'
+ ),
+ },
+ ],
+ },
+ {
+ path: 'credits',
+ name: 'CreditsCard',
+ redirect: { name: 'CustomerCredits' },
+ children: [
+ {
+ path: '',
+ name: 'CustomerCredits',
+ meta: {
+ title: 'credits',
+ icon: 'vn:credit',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerCredits.vue'),
+ },
+ {
+ path: 'create',
+ name: 'CustomerCreditCreate',
+ meta: {
+ title: 'credit-create',
+ },
+ component: () =>
+ import(
+ 'src/pages/Customer/components/CustomerCreditCreate.vue'
+ ),
+ },
+ ],
+ },
+ {
+ path: 'greuges',
+ name: 'CustomerGreuges',
+ meta: {
+ title: 'greuges',
+ icon: 'vn:greuge',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerGreuges.vue'),
+ },
+ {
+ path: 'balance',
+ name: 'CustomerBalance',
+ meta: {
+ title: 'balance',
+ icon: 'vn:invoice',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerBalance.vue'),
+ },
+ {
+ path: 'recoveries',
+ name: 'CustomerRecoveries',
+ meta: {
+ title: 'recoveries',
+ icon: 'vn:recovery',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerRecoveries.vue'),
+ },
+ {
+ path: 'web-access',
+ name: 'CustomerWebAccess',
+ meta: {
+ title: 'webAccess',
+ icon: 'vn:web',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerWebAccess.vue'),
+ },
+ {
+ path: 'log',
+ name: 'CustomerLog',
+ meta: {
+ title: 'log',
+ icon: 'vn:History',
+ },
+ component: () => import('src/pages/Customer/Card/CustomerLog.vue'),
+ },
+ {
+ path: 'sms',
+ name: 'CustomerSms',
+ meta: {
+ title: 'sms',
+ icon: 'sms',
+ },
+ component: () => import('src/pages/Customer/Card/CustomerSms.vue'),
+ },
+ {
+ path: 'credit-management',
+ name: 'CustomerCreditManagement',
+ meta: {
+ title: 'creditManagement',
+ icon: 'paid',
+ },
+ component: () =>
+ import('src/pages/Customer/Card/CustomerCreditManagement.vue'),
+ },
+ {
+ path: 'others',
+ name: 'CustomerOthers',
+ meta: {
+ title: 'others',
+ icon: 'pending',
+ },
+ component: () => import('src/pages/Customer/Card/CustomerOthers.vue'),
+ },
],
},
],
diff --git a/src/router/modules/department.js b/src/router/modules/department.js
new file mode 100644
index 000000000..aaffc3460
--- /dev/null
+++ b/src/router/modules/department.js
@@ -0,0 +1,46 @@
+import { RouterView } from 'vue-router';
+
+export default {
+ path: '/department',
+ name: 'Department',
+ meta: {
+ title: 'department',
+ icon: 'vn:greuge',
+ },
+ component: RouterView,
+ redirect: { name: 'DepartmentCard' },
+ menus: {
+ main: [],
+ card: ['DepartmentBasicData'],
+ },
+ children: [
+ {
+ name: 'DepartmentCard',
+ path: 'department/:id',
+ component: () => import('src/pages/Department/Card/DepartmentCard.vue'),
+ redirect: { name: 'DepartmentSummary' },
+ children: [
+ {
+ name: 'DepartmentSummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'launch',
+ },
+ component: () =>
+ import('src/pages/Department/Card/DepartmentSummary.vue'),
+ },
+ {
+ name: 'DepartmentBasicData',
+ path: 'basic-data',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () =>
+ import('src/pages/Department/Card/DepartmentBasicData.vue'),
+ },
+ ],
+ },
+ ],
+};
diff --git a/src/router/modules/entry.js b/src/router/modules/entry.js
new file mode 100644
index 000000000..8d25a8e0c
--- /dev/null
+++ b/src/router/modules/entry.js
@@ -0,0 +1,101 @@
+import { RouterView } from 'vue-router';
+
+export default {
+ path: '/entry',
+ name: 'Entry',
+ meta: {
+ title: 'entries',
+ icon: 'vn:entry',
+ },
+ component: RouterView,
+ redirect: { name: 'EntryMain' },
+ menus: {
+ main: ['EntryList'],
+ card: ['EntryBasicData', 'EntryBuys', 'EntryNotes', 'EntryLog'],
+ },
+ children: [
+ {
+ path: '',
+ name: 'EntryMain',
+ component: () => import('src/pages/Entry/EntryMain.vue'),
+ redirect: { name: 'EntryList' },
+ children: [
+ {
+ path: 'list',
+ name: 'EntryList',
+ meta: {
+ title: 'list',
+ icon: 'view_list',
+ },
+ component: () => import('src/pages/Entry/EntryList.vue'),
+ },
+ {
+ path: 'create',
+ name: 'EntryCreate',
+ meta: {
+ title: 'create',
+ },
+ component: () => import('src/pages/Entry/EntryCreate.vue'),
+ },
+ ],
+ },
+ {
+ name: 'EntryCard',
+ path: ':id',
+ component: () => import('src/pages/Entry/Card/EntryCard.vue'),
+ redirect: { name: 'EntrySummary' },
+ children: [
+ {
+ name: 'EntrySummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'launch',
+ },
+ component: () => import('src/pages/Entry/Card/EntrySummary.vue'),
+ },
+ {
+ path: 'basic-data',
+ name: 'EntryBasicData',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () => import('src/pages/Entry/Card/EntryBasicData.vue'),
+ },
+ {
+ path: 'buys',
+ name: 'EntryBuys',
+ meta: {
+ title: 'buys',
+ icon: 'vn:lines',
+ },
+ component: () => import('src/pages/Entry/Card/EntryBuys.vue'),
+ },
+ {
+ path: 'buys/import',
+ name: 'EntryBuysImport',
+ component: () => import('src/pages/Entry/Card/EntryBuysImport.vue'),
+ },
+ {
+ path: 'notes',
+ name: 'EntryNotes',
+ meta: {
+ title: 'notes',
+ icon: 'vn:notes',
+ },
+ component: () => import('src/pages/Entry/Card/EntryNotes.vue'),
+ },
+ {
+ path: 'log',
+ name: 'EntryLog',
+ meta: {
+ title: 'log',
+ icon: 'vn:History',
+ },
+ component: () => import('src/pages/Entry/Card/EntryLog.vue'),
+ },
+ ],
+ },
+ ],
+};
diff --git a/src/router/modules/index.js b/src/router/modules/index.js
index 0ab5bf2b2..84a26798d 100644
--- a/src/router/modules/index.js
+++ b/src/router/modules/index.js
@@ -1,3 +1,4 @@
+import Item from './item';
import Customer from './customer';
import Ticket from './ticket';
import Claim from './claim';
@@ -9,8 +10,12 @@ import Wagon from './wagon';
import Route from './route';
import Supplier from './Supplier';
import Travel from './travel';
+import Order from './order';
+import Department from './department';
+import Entry from './entry';
export default [
+ Item,
Customer,
Ticket,
Claim,
@@ -21,5 +26,8 @@ export default [
Route,
Supplier,
Travel,
+ Order,
invoiceIn,
+ Department,
+ Entry,
];
diff --git a/src/router/modules/item.js b/src/router/modules/item.js
new file mode 100644
index 000000000..d3462e15c
--- /dev/null
+++ b/src/router/modules/item.js
@@ -0,0 +1,70 @@
+import { RouterView } from 'vue-router';
+
+export default {
+ path: '/item',
+ name: 'Item',
+ meta: {
+ title: 'items',
+ icon: 'vn:item',
+ },
+ component: RouterView,
+ redirect: { name: 'ItemMain' },
+ menus: {
+ main: [],
+ card: [],
+ },
+ children: [
+ {
+ path: '',
+ name: 'ItemMain',
+ component: () => import('src/pages/Item/ItemMain.vue'),
+ redirect: { name: 'Itemlist' },
+ children: [
+ {
+ path: 'list',
+ name: 'ItemList',
+ meta: {
+ title: 'list',
+ icon: 'view_list',
+ },
+ component: () => import('src/pages/Item/ItemList.vue'),
+ },
+ ],
+ },
+ {
+ name: 'ItemCard',
+ path: ':id',
+ component: () => import('src/pages/Item/Card/ItemCard.vue'),
+ redirect: { name: 'ItemSummary' },
+ children: [
+ {
+ name: 'ItemSummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'launch',
+ },
+ component: () => import('src/pages/Item/Card/ItemSummary.vue'),
+ },
+ {
+ path: 'diary',
+ name: 'ItemDiary',
+ meta: {
+ title: 'diary',
+ icon: 'vn:transaction',
+ },
+ component: () => import('src/pages/Item/Card/ItemDiary.vue'),
+ },
+ {
+ path: 'tags',
+ name: 'ItemTags',
+ meta: {
+ title: 'Tags',
+ icon: 'vn:tags',
+ },
+ component: () => import('src/pages/Item/Card/ItemTags.vue'),
+ },
+ ],
+ },
+ ],
+};
diff --git a/src/router/modules/order.js b/src/router/modules/order.js
new file mode 100644
index 000000000..4599394cd
--- /dev/null
+++ b/src/router/modules/order.js
@@ -0,0 +1,96 @@
+import { RouterView } from 'vue-router';
+
+export default {
+ path: '/order',
+ name: 'Order',
+ meta: {
+ title: 'order',
+ icon: 'vn:basket',
+ },
+ component: RouterView,
+ redirect: { name: 'OrderMain' },
+ menus: {
+ main: ['OrderList'],
+ card: ['OrderBasicData', 'OrderCatalog', 'OrderVolume', 'OrderLines'],
+ },
+ children: [
+ {
+ path: '',
+ name: 'OrderMain',
+ component: () => import('src/pages/Order/OrderMain.vue'),
+ redirect: { name: 'OrderList' },
+ children: [
+ {
+ path: 'list',
+ name: 'OrderList',
+ meta: {
+ title: 'orderList',
+ icon: 'view_list',
+ },
+ component: () => import('src/pages/Order/OrderList.vue'),
+ },
+ {
+ path: 'create',
+ name: 'OrderCreate',
+ meta: {
+ title: 'create',
+ },
+ component: () => import('src/pages/Order/Card/OrderForm.vue'),
+ },
+ ],
+ },
+ {
+ name: 'OrderCard',
+ path: ':id',
+ component: () => import('src/pages/Order/Card/OrderCard.vue'),
+ redirect: { name: 'OrderSummary' },
+ children: [
+ {
+ name: 'OrderSummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'launch',
+ },
+ component: () => import('src/pages/Order/Card/OrderSummary.vue'),
+ },
+ {
+ name: 'OrderBasicData',
+ path: 'basic-data',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () => import('src/pages/Order/Card/OrderForm.vue'),
+ },
+ {
+ name: 'OrderCatalog',
+ path: 'catalog',
+ meta: {
+ title: 'catalog',
+ icon: 'vn:basket',
+ },
+ component: () => import('src/pages/Order/OrderCatalog.vue'),
+ },
+ {
+ name: 'OrderVolume',
+ path: 'volume',
+ meta: {
+ title: 'volume',
+ icon: 'vn:volume',
+ },
+ component: () => import('src/pages/Order/OrderVolume.vue'),
+ },
+ {
+ name: 'OrderLines',
+ path: 'line',
+ meta: {
+ title: 'lines',
+ icon: 'vn:lines',
+ },
+ component: () => import('src/pages/Order/OrderLines.vue'),
+ },
+ ],
+ },
+ ],
+};
diff --git a/src/router/modules/route.js b/src/router/modules/route.js
index acda898de..614345913 100644
--- a/src/router/modules/route.js
+++ b/src/router/modules/route.js
@@ -10,15 +10,15 @@ export default {
component: RouterView,
redirect: { name: 'RouteMain' },
menus: {
- main: ['CmrList'],
- card: [],
+ main: ['RouteList', 'CmrList'],
+ card: ['RouteBasicData'],
},
children: [
{
path: '/route',
name: 'RouteMain',
component: () => import('src/pages/Route/RouteMain.vue'),
- redirect: { name: 'CmrList' },
+ redirect: { name: 'RouteList' },
children: [
{
path: 'cmr',
@@ -29,6 +29,49 @@ export default {
},
component: () => import('src/pages/Route/Cmr/CmrList.vue'),
},
+ {
+ path: 'list',
+ name: 'RouteList',
+ meta: {
+ title: 'RouteList',
+ icon: 'view_list',
+ },
+ component: () => import('src/pages/Route/RouteList.vue'),
+ },
+ {
+ path: 'create',
+ name: 'RouteCreate',
+ meta: {
+ title: 'create',
+ },
+ component: () => import('src/pages/Route/Card/RouteForm.vue'),
+ },
+ ],
+ },
+ {
+ name: 'RouteCard',
+ path: ':id',
+ component: () => import('src/pages/Route/Card/RouteCard.vue'),
+ redirect: { name: 'RouteSummary' },
+ children: [
+ {
+ name: 'RouteBasicData',
+ path: 'basic-data',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ },
+ component: () => import('pages/Route/Card/RouteForm.vue'),
+ },
+ {
+ name: 'RouteSummary',
+ path: 'summary',
+ meta: {
+ title: 'summary',
+ icon: 'open_in_new',
+ },
+ component: () => import('pages/Route/Card/RouteSummary.vue'),
+ },
],
},
],
diff --git a/src/router/modules/travel.js b/src/router/modules/travel.js
index bd0a2067d..43c444ae2 100644
--- a/src/router/modules/travel.js
+++ b/src/router/modules/travel.js
@@ -11,7 +11,7 @@ export default {
redirect: { name: 'TravelMain' },
menus: {
main: ['TravelList', 'ExtraCommunity'],
- card: [],
+ card: ['TravelBasicData', 'TravelHistory', 'TravelThermographs'],
},
children: [
{
@@ -42,7 +42,7 @@ export default {
path: 'create',
name: 'TravelCreate',
meta: {
- title: 'extraCommunity',
+ title: 'travelCreate',
icon: '',
},
component: () => import('src/pages/Travel/TravelCreate.vue'),
@@ -63,6 +63,36 @@ export default {
},
component: () => import('src/pages/Travel/Card/TravelSummary.vue'),
},
+ {
+ name: 'TravelBasicData',
+ path: 'basic-data',
+ meta: {
+ title: 'basicData',
+ icon: 'vn:settings',
+ // roles: [],
+ },
+ // component: () => import(),
+ },
+ {
+ name: 'TravelHistory',
+ path: 'history',
+ meta: {
+ title: 'history',
+ icon: 'history',
+ // roles: [],
+ },
+ // component: () => import(),
+ },
+ {
+ name: 'TravelThermographs',
+ path: 'thermographs',
+ meta: {
+ title: 'thermographs',
+ icon: 'vn:thermometer',
+ // roles: [],
+ },
+ // component: () => import(),
+ },
],
},
],
diff --git a/src/router/modules/worker.js b/src/router/modules/worker.js
index e5ee7c1a2..27a6f19a9 100644
--- a/src/router/modules/worker.js
+++ b/src/router/modules/worker.js
@@ -10,8 +10,9 @@ export default {
component: RouterView,
redirect: { name: 'WorkerMain' },
menus: {
- main: ['WorkerList'],
+ main: ['WorkerList', 'WorkerDepartment'],
card: ['WorkerNotificationsManager'],
+ departmentCard: ['BasicData'],
},
children: [
{
@@ -29,6 +30,24 @@ export default {
},
component: () => import('src/pages/Worker/WorkerList.vue'),
},
+ {
+ path: 'department',
+ name: 'WorkerDepartment',
+ meta: {
+ title: 'department',
+ icon: 'vn:greuge',
+ },
+ component: () => import('src/pages/Worker/WorkerDepartment.vue'),
+ },
+ {
+ path: 'create',
+ name: 'WorkerCreate',
+ meta: {
+ title: 'workerCreate',
+ icon: '',
+ },
+ component: () => import('src/pages/Worker/WorkerCreate.vue'),
+ },
],
},
{
diff --git a/src/router/routes.js b/src/router/routes.js
index 550fcf64e..d1027955f 100644
--- a/src/router/routes.js
+++ b/src/router/routes.js
@@ -1,3 +1,4 @@
+import item from './modules/item';
import customer from './modules/customer';
import ticket from './modules/ticket';
import claim from './modules/claim';
@@ -8,7 +9,10 @@ import wagon from './modules/wagon';
import supplier from './modules/Supplier';
import route from './modules/route';
import travel from './modules/travel';
+import department from './modules/department';
import shelving from 'src/router/modules/shelving';
+import order from 'src/router/modules/order';
+import entry from 'src/router/modules/entry';
const routes = [
{
@@ -48,6 +52,7 @@ const routes = [
component: () => import('../pages/Dashboard/DashboardMain.vue'),
},
// Module routes
+ item,
customer,
ticket,
claim,
@@ -56,9 +61,12 @@ const routes = [
invoiceOut,
invoiceIn,
wagon,
+ order,
route,
supplier,
travel,
+ department,
+ entry,
{
path: '/:catchAll(.*)*',
name: 'NotFound',
diff --git a/src/services/invoiceOut.service.js b/src/services/invoiceOut.service.js
deleted file mode 100644
index 6232f319d..000000000
--- a/src/services/invoiceOut.service.js
+++ /dev/null
@@ -1,49 +0,0 @@
-import axios from 'axios';
-
-const request = async (method, url, params = {}) => {
- try {
- let response;
-
- if (method === 'GET') {
- response = await axios.get(url, { params });
- } else if (method === 'POST') {
- response = await axios.post(url, params);
- }
- return response.data;
- } catch (err) {
- console.error(`Error with ${method} request to ${url}`, err);
- return err.response;
- }
-};
-
-const invoiceOutService = {
- getNegativeBases: async (params) => {
- return await request('GET', 'InvoiceOuts/negativeBases', params);
- },
-
- getNegativeBasesCsv: async (params) => {
- return await request('GET', 'InvoiceOuts/negativeBasesCsv', params);
- },
-
- getInvoiceDate: async (params) => {
- return await request('GET', 'InvoiceOuts/getInvoiceDate', params);
- },
-
- getFindOne: async (params) => {
- return await request('GET', 'InvoiceOutConfigs/findOne', params);
- },
-
- getClientsToInvoice: async (params) => {
- return await request('POST', 'InvoiceOuts/clientsToInvoice', params);
- },
-
- invoiceClient: async (params) => {
- return await request('POST', 'InvoiceOuts/invoiceClient', params);
- },
-
- makePdfAndNotify: async (invoiceId, params) => {
- return await request('POST', `InvoiceOuts/${invoiceId}/makePdfAndNotify`, params);
- },
-};
-
-export default invoiceOutService;
diff --git a/src/stores/invoiceOutGlobal.js b/src/stores/invoiceOutGlobal.js
index 71e4c3537..7151aac5f 100644
--- a/src/stores/invoiceOutGlobal.js
+++ b/src/stores/invoiceOutGlobal.js
@@ -1,8 +1,10 @@
import { defineStore } from 'pinia';
import { useUserConfig } from 'src/composables/useUserConfig';
-import invoiceOutService from 'src/services/invoiceOut.service';
-import useNotify from 'src/composables/useNotify.js';
import { exportFile } from 'quasar';
+import { useArrayData } from 'composables/useArrayData';
+import useNotify from 'src/composables/useNotify.js';
+
+import axios from 'axios';
const { notify } = useNotify();
@@ -60,18 +62,29 @@ export const useInvoiceOutGlobalStore = defineStore({
},
async fetchInvoiceOutConfig(companyFk) {
- this.formInitialData.companyFk = companyFk;
- const params = { companyFk: companyFk };
- const { issued } = await invoiceOutService.getInvoiceDate(params);
- const stringDate = issued.substring(0, 10);
- this.minInvoicingDate = stringDate;
- this.formInitialData.invoiceDate = stringDate;
+ try {
+ this.formInitialData.companyFk = companyFk;
+ const params = { companyFk: companyFk };
+
+ const { data } = await axios.get('InvoiceOuts/getInvoiceDate', {
+ params,
+ });
+
+ const stringDate = data.issued.substring(0, 10);
+ this.minInvoicingDate = stringDate;
+ this.formInitialData.invoiceDate = stringDate;
+ } catch (err) {
+ console.error('Error fetching invoice out global initial data');
+ throw new Error();
+ }
},
async fetchParallelism() {
const filter = { fields: ['parallelism'] };
- const { parallelism } = await invoiceOutService.getFindOne(filter);
- this.parallelism = parallelism;
+ const { data } = await axios.get('InvoiceOutConfigs/findOne', {
+ filter,
+ });
+ this.parallelism = data.parallelism;
},
async makeInvoice(formData, clientsToInvoice) {
@@ -90,11 +103,12 @@ export const useInvoiceOutGlobalStore = defineStore({
if (clientsToInvoice == 'all') params.clientId = undefined;
- const addressesResponse = await invoiceOutService.getClientsToInvoice(
+ const addressesResponse = await await axios.post(
+ 'InvoiceOuts/clientsToInvoice',
params
);
- this.addresses = addressesResponse;
+ this.addresses = addressesResponse.data;
if (!this.addresses || !this.addresses.length > 0) {
notify(
@@ -151,31 +165,45 @@ export const useInvoiceOutGlobalStore = defineStore({
},
async invoiceClient(address, formData) {
- if (this.nRequests === this.parallelism || this.isInvoicing) return;
+ try {
+ if (this.nRequests === this.parallelism || this.isInvoicing) return;
- if (this.status === 'stopping') {
- if (this.nRequests) return;
- this.invoicing = false;
- this.status = 'done';
- return;
- }
+ if (this.status === 'stopping') {
+ if (this.nRequests) return;
+ this.invoicing = false;
+ this.status = 'done';
+ return;
+ }
- const params = {
- clientId: address.clientId,
- addressId: address.id,
- invoiceDate: new Date(formData.invoiceDate),
- maxShipped: new Date(formData.maxShipped),
- companyFk: formData.companyFk,
- };
+ const params = {
+ clientId: address.clientId,
+ addressId: address.id,
+ invoiceDate: new Date(formData.invoiceDate),
+ maxShipped: new Date(formData.maxShipped),
+ companyFk: formData.companyFk,
+ };
- this.status = 'invoicing';
- this.invoicing = true;
+ this.status = 'invoicing';
+ this.invoicing = true;
- const invoiceResponse = await invoiceOutService.invoiceClient(params);
+ const invoiceResponse = await axios.post(
+ 'InvoiceOuts/invoiceClient',
+ params
+ );
- if (invoiceResponse.data.error) {
- if (invoiceResponse.status >= 400 && invoiceResponse.status < 500) {
- this.invoiceClientError(address, invoiceResponse);
+ if (invoiceResponse.data) {
+ this.makePdfAndNotify(invoiceResponse.data, address);
+ }
+
+ this.isInvoicing = false;
+ } catch (err) {
+ if (
+ err &&
+ err.response &&
+ err.response.status >= 400 &&
+ err.response.status < 500
+ ) {
+ this.invoiceClientError(address, err.response);
this.addressIndex++;
return;
} else {
@@ -187,11 +215,6 @@ export const useInvoiceOutGlobalStore = defineStore({
);
throw new Error('Critical invoicing error, process stopped');
}
- } else {
- this.isInvoicing = false;
- if (invoiceResponse.data) {
- this.makePdfAndNotify(invoiceResponse.data, address);
- }
}
},
@@ -200,7 +223,7 @@ export const useInvoiceOutGlobalStore = defineStore({
this.nRequests++;
this.totalPdfs++;
const params = { printerFk: this.printer };
- await invoiceOutService.makePdfAndNotify(invoiceId, params);
+ await axios.post(`InvoiceOuts/${invoiceId}/makePdfAndNotify`, params);
this.nPdfs++;
this.nRequests--;
} catch (err) {
@@ -219,14 +242,18 @@ export const useInvoiceOutGlobalStore = defineStore({
throw err;
},
- async getNegativeBasesCsv(from, to, filter = {}) {
+ async getNegativeBasesCsv() {
try {
- const params = { from: from, to: to, filter };
- const CSVResponse = await invoiceOutService.getNegativeBasesCsv(params);
+ const arrayData = useArrayData('InvoiceOutNegative');
+ const params = arrayData.store.currentFilter;
- if (CSVResponse.data && CSVResponse.data.error) throw new Error();
+ const { data } = await axios.get('InvoiceOuts/negativeBasesCsv', {
+ params,
+ });
- const status = exportFile('negativeBases.csv', CSVResponse, {
+ if (data.data && data.data.error) throw new Error();
+
+ const status = exportFile('negativeBases.csv', data, {
encoding: 'windows-1252',
mimeType: 'text/csv;charset=windows-1252;',
});
@@ -236,6 +263,7 @@ export const useInvoiceOutGlobalStore = defineStore({
}
} catch (err) {
notify('invoiceOut.negativeBases.errors.downloadCsvFailed', 'negative');
+ throw new Error();
}
},
diff --git a/src/stores/useArrayDataStore.js b/src/stores/useArrayDataStore.js
index 223406a33..115c161dd 100644
--- a/src/stores/useArrayDataStore.js
+++ b/src/stores/useArrayDataStore.js
@@ -19,6 +19,7 @@ export const useArrayDataStore = defineStore('arrayDataStore', () => {
order: '',
data: ref(),
isLoading: false,
+ userParamsChanged: false,
exprBuilder: null,
};
}
diff --git a/src/stores/useNavigationStore.js b/src/stores/useNavigationStore.js
index 5daa618d5..568063d1d 100644
--- a/src/stores/useNavigationStore.js
+++ b/src/stores/useNavigationStore.js
@@ -7,17 +7,19 @@ import routes from 'src/router/modules';
export const useNavigationStore = defineStore('navigationStore', () => {
const modules = [
+ 'shelving',
+ 'order',
'customer',
- 'claim',
- 'ticket',
+ 'entry',
+ 'travel',
'invoiceOut',
'invoiceIn',
- 'worker',
- 'shelving',
- 'wagon',
- 'route',
'supplier',
- 'travel',
+ 'claim',
+ 'route',
+ 'ticket',
+ 'worker',
+ 'wagon',
];
const pinnedModules = ref([]);
const role = useRole();
diff --git a/src/stores/useStateStore.js b/src/stores/useStateStore.js
index 74b65e71f..328df9978 100644
--- a/src/stores/useStateStore.js
+++ b/src/stores/useStateStore.js
@@ -5,6 +5,7 @@ export const useStateStore = defineStore('stateStore', () => {
const isMounted = ref(false);
const leftDrawer = ref(false);
const rightDrawer = ref(false);
+ const subToolbar = ref(false);
function toggleLeftDrawer() {
leftDrawer.value = !leftDrawer.value;
@@ -14,6 +15,10 @@ export const useStateStore = defineStore('stateStore', () => {
rightDrawer.value = !rightDrawer.value;
}
+ function toggleSubToolbar() {
+ subToolbar.value = !subToolbar.value;
+ }
+
function setMounted() {
isMounted.value = true;
}
@@ -31,10 +36,7 @@ export const useStateStore = defineStore('stateStore', () => {
}
function isSubToolbarShown() {
- return (
- !!document.querySelector('#st-data') &&
- !!document.querySelector('#st-actions')
- );
+ return subToolbar.value;
}
return {
@@ -47,5 +49,6 @@ export const useStateStore = defineStore('stateStore', () => {
isLeftDrawerShown,
isRightDrawerShown,
isSubToolbarShown,
+ toggleSubToolbar,
};
});
diff --git a/test/cypress/integration/VnLocation.spec.js b/test/cypress/integration/VnLocation.spec.js
new file mode 100644
index 000000000..fe0ecee68
--- /dev/null
+++ b/test/cypress/integration/VnLocation.spec.js
@@ -0,0 +1,31 @@
+const inputLocation = ':nth-child(3) > :nth-child(1) > .q-field > .q-field__inner > .q-field__control';
+const locationOptions ='[role="listbox"] > div.q-virtual-scroll__content > .q-item'
+describe('VnLocation', () => {
+ beforeEach(() => {
+ cy.viewport(1280, 720);
+ cy.login('developer');
+ cy.visit('/#/worker/create');
+ cy.waitForElement('.q-card');
+ });
+
+ it('Show all options', function() {
+ cy.get(inputLocation).click();
+ cy.get(locationOptions).should('have.length',5);
+ });
+
+ it('input filter location as "al"', function() {
+ cy.get(inputLocation).click();
+ cy.get(inputLocation).clear();
+ cy.get(inputLocation).type('al');
+ cy.get(locationOptions).should('have.length',3);
+ });
+ it('input filter location as "ecuador"', function() {
+ cy.get(inputLocation).click();
+ cy.get(inputLocation).clear();
+ cy.get(inputLocation).type('ecuador');
+ cy.get(locationOptions).should('have.length',1);
+ cy.get(`${locationOptions}:nth-child(1)`).click();
+ cy.get(':nth-child(3) > :nth-child(1) > .q-field > .q-field__inner > .q-field__control > :nth-child(2) > .q-icon').click();
+
+ });
+})
diff --git a/test/cypress/integration/claim/claimAction.spec.js b/test/cypress/integration/claim/claimAction.spec.js
index f181722fa..685e120ce 100644
--- a/test/cypress/integration/claim/claimAction.spec.js
+++ b/test/cypress/integration/claim/claimAction.spec.js
@@ -31,7 +31,6 @@ describe('ClaimAction', () => {
it('should regularize', () => {
cy.get('[title="Regularize"]').click();
- cy.clickConfirm();
});
it('should remove the line', () => {
diff --git a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
index 0013df343..7617a69d1 100644
--- a/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
+++ b/test/cypress/integration/invoiceIn/invoiceInBasicData.spec.js
@@ -16,11 +16,12 @@ describe('InvoiceInBasicData', () => {
cy.get(selects).eq(0).type('Bros');
cy.get(selects).eq(0).type('{enter}');
+ cy.get('[title="Reset"]').click();
cy.get(appendBtns).eq(0).click();
cy.get('input').eq(2).type(4739);
cy.saveCard();
- cy.get(`${selects} input`).eq(0).invoke('val').should('eq', 'Bros nick');
+ cy.get(`${selects} input`).eq(0).invoke('val').should('eq', 'Plants nick');
cy.get('input').eq(2).invoke('val').should('eq', '4739');
});
diff --git a/test/cypress/integration/invoiceIn/invoiceInList.spec.js b/test/cypress/integration/invoiceIn/invoiceInList.spec.js
index 60d8c5be1..9d3adbc73 100644
--- a/test/cypress/integration/invoiceIn/invoiceInList.spec.js
+++ b/test/cypress/integration/invoiceIn/invoiceInList.spec.js
@@ -9,6 +9,7 @@ describe('InvoiceInList', () => {
beforeEach(() => {
cy.login('developer');
cy.visit(`/#/invoice-in`);
+ cy.clickFilterSearchBtn();
});
it('should redirect on clicking a invoice', () => {
diff --git a/test/cypress/integration/vnSearchBar.spec.js b/test/cypress/integration/vnSearchBar.spec.js
new file mode 100644
index 000000000..d6dea0780
--- /dev/null
+++ b/test/cypress/integration/vnSearchBar.spec.js
@@ -0,0 +1,19 @@
+///
+describe('VnSearchBar', () => {
+ beforeEach(() => {
+ cy.login('developer');
+ cy.visit('/');
+ });
+
+ it('should redirect to new customer', () => {
+ cy.visit('#/customer/1112/basic-data')
+ cy.openLeftMenu();
+ cy.get('.q-item > .q-item__label').should('have.text',' #1112')
+ cy.closeLeftMenu();
+ cy.clearSearchbar();
+ cy.writeSearchbar('1{enter}');
+ cy.openLeftMenu();
+ cy.get('.q-item > .q-item__label').should('have.text',' #1')
+ cy.closeLeftMenu();
+ });
+});
diff --git a/test/cypress/support/commands.js b/test/cypress/support/commands.js
index 4dfde6e21..e4d1cebe1 100755
--- a/test/cypress/support/commands.js
+++ b/test/cypress/support/commands.js
@@ -138,23 +138,20 @@ Cypress.Commands.add('validateRow', (rowSelector, expectedValues) => {
Cypress.Commands.add('removeRow', (rowIndex) => {
let rowsBefore;
- let rowsAfter;
-
- cy.get('tr')
+ cy.get('tbody > tr:visible')
.its('length')
.then((length) => {
- rowsBefore = length;
cy.get('.q-checkbox').eq(rowIndex).click();
cy.removeCard();
cy.get('.q-dialog button').eq(2).click();
+ rowsBefore = length;
})
.then(() => {
- cy.get('tr')
- .its('length')
- .then((length) => {
- rowsAfter = length;
- expect(rowsBefore).to.eq(rowsAfter + 1);
- });
+ // Check the existence of tbody before performing the second assertion.
+ cy.get('tbody').then(($tbody) => {
+ if ($tbody.length > 0)
+ cy.get('tbody > tr:visible').should('have.length', rowsBefore - 1);
+ });
});
});
Cypress.Commands.add('openListSummary', (row) => {
@@ -166,7 +163,28 @@ Cypress.Commands.add('openRightMenu', (element) => {
cy.get('#actions-append').click();
});
+Cypress.Commands.add('openLeftMenu', (element) => {
+ if (element) cy.waitForElement(element);
+ cy.get('.q-toolbar > .q-btn--round.q-btn--dense > .q-btn__content > .q-icon').click();
+});
+Cypress.Commands.add('closeLeftMenu', (element) => {
+ if (element) cy.waitForElement(element);
+ cy.get('.fullscreen').click();
+});
+
+Cypress.Commands.add('clearSearchbar', (element) => {
+ if (element) cy.waitForElement(element);
+ cy.get('#searchbar > form > label > div:nth-child(1) input').clear();
+});
+
+Cypress.Commands.add('writeSearchbar', (value) => {
+ cy.get('#searchbar > form > label > div:nth-child(1) input').type(value);
+});
Cypress.Commands.add('validateContent', (selector, expectedValue) => {
cy.get(selector).should('have.text', expectedValue);
});
+
+Cypress.Commands.add('clickFilterSearchBtn', () => {
+ cy.get('.q-item__section > .q-btn > .q-btn__content > .q-icon').click();
+});
// registerCommands();
diff --git a/test/vitest/__tests__/components/Paginate.spec.js b/test/vitest/__tests__/components/Paginate.spec.js
index af9fb41a1..2a22ce438 100644
--- a/test/vitest/__tests__/components/Paginate.spec.js
+++ b/test/vitest/__tests__/components/Paginate.spec.js
@@ -119,7 +119,7 @@ describe('VnPaginate', () => {
await vm.onLoad(index, done);
expect(vm.pagination.page).toEqual(2);
- expect(done).toHaveBeenCalledWith(true);
+ expect(done).toHaveBeenCalledWith(false);
});
});
});
diff --git a/test/vitest/__tests__/components/common/VnSearchBar.spec.js b/test/vitest/__tests__/components/common/VnSearchBar.spec.js
new file mode 100644
index 000000000..fd0a026ef
--- /dev/null
+++ b/test/vitest/__tests__/components/common/VnSearchBar.spec.js
@@ -0,0 +1,53 @@
+import { vi, describe, expect, it, beforeAll, beforeEach, afterEach } from 'vitest';
+import { createWrapper, axios } from 'app/test/vitest/helper';
+import VnSearchbar from 'components/ui/VnSearchbar.vue';
+
+
+describe('VnSearchBar', () => {
+ let vm;
+ let wrapper;
+
+ beforeAll(() => {
+ wrapper = createWrapper(VnSearchbar, {
+ propsData: {
+ dataKey: 'CustomerList',
+ label: 'Search customer',
+ info: 'Info customer',
+ },
+ });
+ vm = wrapper.vm;
+ vm.route.matched = [
+ {
+ path: '/',
+ },
+ {
+ path: '/customer',
+ },
+ {
+ path: '/customer/:id',
+ },
+ {
+ path: '/customer/:id/basic-data',
+ },
+ ];
+ });
+
+ afterEach(() => {
+ vi.clearAllMocks();
+ });
+ it('should be defined', async () => {
+ expect(vm.searchText).toBeDefined();
+ expect(vm.searchText).toEqual('');
+ });
+ it('should redirect', async () => {
+ vi.spyOn(vm.router,'push');
+ vm.searchText = '1';
+ await vm.search();
+ expect(vm.router.push).toHaveBeenCalledWith('/customer/1/basic-data');
+ vm.searchText = '1112';
+ expect(vm.searchText).toEqual('1112');
+ vi.spyOn(vm.router,'push');
+ await vm.search();
+ expect(vm.router.push).toHaveBeenCalledWith('/customer/1112/basic-data');
+ });
+});
diff --git a/test/vitest/__tests__/components/common/VnSms.spec.js b/test/vitest/__tests__/components/common/VnSms.spec.js
new file mode 100644
index 000000000..e0f8c1868
--- /dev/null
+++ b/test/vitest/__tests__/components/common/VnSms.spec.js
@@ -0,0 +1,25 @@
+import { vi, describe, expect, it, beforeAll, afterEach } from 'vitest';
+import { createWrapper, axios } from 'app/test/vitest/helper';
+import VnSms from 'src/components/ui/VnSms.vue';
+
+describe('VnSms', () => {
+ let vm;
+
+ beforeAll(() => {
+ vm = createWrapper(VnSms, {
+ global: {
+ stubs: ['VnPaginate'],
+ mocks: {},
+ },
+ }).vm;
+ });
+
+ afterEach(() => {
+ vi.clearAllMocks();
+ });
+
+ it('should format number correctly', () => {
+ const formattedNumber = vm.formatNumber('123456789012');
+ expect(formattedNumber).toBe('1234 56789012');
+ });
+});
diff --git a/test/vitest/__tests__/pages/Customer/CustomerPayments.spec.js b/test/vitest/__tests__/pages/Customer/CustomerPayments.spec.js
index 5d096f113..13293f596 100644
--- a/test/vitest/__tests__/pages/Customer/CustomerPayments.spec.js
+++ b/test/vitest/__tests__/pages/Customer/CustomerPayments.spec.js
@@ -1,11 +1,10 @@
import { vi, describe, expect, it, beforeAll, afterEach } from 'vitest';
import { createWrapper, axios } from 'app/test/vitest/helper';
-import CustomerPayments from 'pages/Customer/CustomerPayments.vue';
+import CustomerPayments from 'src/pages/Customer/Payments/CustomerPayments.vue';
describe('CustomerPayments', () => {
let vm;
-
beforeAll(() => {
vm = createWrapper(CustomerPayments, {
global: {
@@ -13,7 +12,7 @@ describe('CustomerPayments', () => {
mocks: {
fetch: vi.fn(),
},
- }
+ },
}).vm;
});
@@ -28,11 +27,10 @@ describe('CustomerPayments', () => {
await vm.confirmTransaction({ id: 1 });
-
expect(vm.quasar.notify).toHaveBeenCalledWith(
expect.objectContaining({
message: 'Payment confirmed',
- type: 'positive'
+ type: 'positive',
})
);
});