This commit is contained in:
William Buezas 2024-01-02 08:47:38 -03:00
parent c3dcf18596
commit 9b9ac4dfe1
8 changed files with 31 additions and 82 deletions

View File

@ -26,10 +26,6 @@ const closeButton = ref(null);
const countriesOptions = ref([]); const countriesOptions = ref([]);
const loading = ref(false); const loading = ref(false);
const setCountriesOptions = (data) => {
countriesOptions.value = data;
};
const onDataSaved = (data) => { const onDataSaved = (data) => {
emit('onDataSaved', data); emit('onDataSaved', data);
closeForm(); closeForm();
@ -43,9 +39,9 @@ const closeForm = () => {
<template> <template>
<FetchData <FetchData
url="Countries" url="Countries"
@on-fetch="(data) => setCountriesOptions(data)"
:filter="countriesFilter" :filter="countriesFilter"
auto-load auto-load
@on-fetch="(data) => (countriesOptions = data)"
/> />
<FormModel <FormModel
:form-initial-data="bankEntityFormData" :form-initial-data="bankEntityFormData"
@ -56,10 +52,10 @@ const closeForm = () => {
@on-data-saved="onDataSaved($event)" @on-data-saved="onDataSaved($event)"
> >
<template #form="{ data, validate }"> <template #form="{ data, validate }">
<span ref="closeButton" class="close-icon" v-close-popup> <span ref="closeButton" class="popup-form-close-button" v-close-popup>
<QIcon name="close" size="sm" /> <QIcon name="close" size="sm" />
</span> </span>
<h1 class="title">{{ t('title') }}</h1> <h1 class="popup-form-title">{{ t('title') }}</h1>
<p class="q-mb-md">{{ t('subtitle') }}</p> <p class="q-mb-md">{{ t('subtitle') }}</p>
<VnRow class="row q-gutter-md q-mb-md"> <VnRow class="row q-gutter-md q-mb-md">
<div class="col"> <div class="col">
@ -116,20 +112,6 @@ const closeForm = () => {
</FormModel> </FormModel>
</template> </template>
<style lang="scss" scoped>
.close-icon {
position: absolute;
top: 20px;
right: 20px;
cursor: pointer;
}
.title {
font-size: 17px;
font-weight: bold;
line-height: 20px;
}
</style>
<i18n> <i18n>
en: en:
title: New bank entity title: New bank entity

View File

@ -46,10 +46,10 @@ const closeForm = () => {
@on-data-saved="onDataSaved()" @on-data-saved="onDataSaved()"
> >
<template #form="{ data, validate }"> <template #form="{ data, validate }">
<span ref="closeButton" class="close-icon" v-close-popup> <span ref="closeButton" class="popup-form-close-button" v-close-popup>
<QIcon name="close" size="sm" /> <QIcon name="close" size="sm" />
</span> </span>
<h1 class="title">{{ t('New city') }}</h1> <h1 class="popup-form-title">{{ t('New city') }}</h1>
<p>{{ t('Please, ensure you put the correct data!') }}</p> <p>{{ t('Please, ensure you put the correct data!') }}</p>
<VnRow class="row q-gutter-md q-mb-md"> <VnRow class="row q-gutter-md q-mb-md">
<div class="col"> <div class="col">
@ -94,20 +94,6 @@ const closeForm = () => {
</FormModel> </FormModel>
</template> </template>
<style lang="scss" scoped>
.close-icon {
position: absolute;
top: 20px;
right: 20px;
cursor: pointer;
}
.title {
font-size: 17px;
font-weight: bold;
line-height: 20px;
}
</style>
<i18n> <i18n>
es: es:
New city: Nueva ciudad New city: Nueva ciudad

View File

@ -75,10 +75,10 @@ const closeForm = () => {
@on-data-saved="onDataSaved()" @on-data-saved="onDataSaved()"
> >
<template #form="{ data, validate }"> <template #form="{ data, validate }">
<span ref="closeButton" class="close-icon" v-close-popup> <span ref="closeButton" class="popup-form-close-button" v-close-popup>
<QIcon name="close" size="sm" /> <QIcon name="close" size="sm" />
</span> </span>
<h1 class="title">{{ t('New postcode') }}</h1> <h1 class="popup-form-title">{{ t('New postcode') }}</h1>
<p>{{ t('Please, ensure you put the correct data!') }}</p> <p>{{ t('Please, ensure you put the correct data!') }}</p>
<VnRow class="row q-gutter-md q-mb-md"> <VnRow class="row q-gutter-md q-mb-md">
<div class="col"> <div class="col">
@ -159,20 +159,6 @@ const closeForm = () => {
</FormModel> </FormModel>
</template> </template>
<style lang="scss" scoped>
.close-icon {
position: absolute;
top: 20px;
right: 20px;
cursor: pointer;
}
.title {
font-size: 17px;
font-weight: bold;
line-height: 20px;
}
</style>
<i18n> <i18n>
es: es:
New postcode: Nuevo código postal New postcode: Nuevo código postal

View File

@ -46,10 +46,10 @@ const closeForm = () => {
@on-data-saved="onDataSaved()" @on-data-saved="onDataSaved()"
> >
<template #form="{ data, validate }"> <template #form="{ data, validate }">
<span ref="closeButton" class="close-icon" v-close-popup> <span ref="closeButton" class="popup-form-close-button" v-close-popup>
<QIcon name="close" size="sm" /> <QIcon name="close" size="sm" />
</span> </span>
<h1 class="title">{{ t('New province') }}</h1> <h1 class="popup-form-title">{{ t('New province') }}</h1>
<p>{{ t('Please, ensure you put the correct data!') }}</p> <p>{{ t('Please, ensure you put the correct data!') }}</p>
<VnRow class="row q-gutter-md q-mb-md"> <VnRow class="row q-gutter-md q-mb-md">
<div class="col"> <div class="col">
@ -95,20 +95,6 @@ const closeForm = () => {
</FormModel> </FormModel>
</template> </template>
<style lang="scss" scoped>
.close-icon {
position: absolute;
top: 20px;
right: 20px;
cursor: pointer;
}
.title {
font-size: 17px;
font-weight: bold;
line-height: 20px;
}
</style>
<i18n> <i18n>
es: es:
New postcode: Nuevo código postal New postcode: Nuevo código postal

View File

@ -156,9 +156,7 @@ export function useArrayData(key, userOptions) {
delete store.userParams[param]; delete store.userParams[param];
delete params[param]; delete params[param];
if (store.filter?.where) { if (store.filter?.where) {
delete store.filter.where[ delete store.filter.where[Object.keys(exprBuilder ? exprBuilder(param) : param)[0]];
Object.keys(exprBuilder ? exprBuilder(param) : param)[0]
];
if (Object.keys(store.filter.where).length === 0) { if (Object.keys(store.filter.where).length === 0) {
delete store.filter.where; delete store.filter.where;
} }

View File

@ -53,3 +53,16 @@ body.body--dark {
color: var(--vn-text); color: var(--vn-text);
border-radius: 8px; border-radius: 8px;
} }
.popup-form-title {
font-size: 17px;
font-weight: bold;
line-height: 20px;
}
.popup-form-close-button {
position: absolute;
top: 20px;
right: 20px;
cursor: pointer;
}

View File

@ -49,7 +49,6 @@ export default {
microsip: 'Open in MicroSIP', microsip: 'Open in MicroSIP',
noSelectedRows: `You don't have any line selected`, noSelectedRows: `You don't have any line selected`,
downloadCSVSuccess: 'CSV downloaded successfully', downloadCSVSuccess: 'CSV downloaded successfully',
// labels compartidos entre vistas
reference: 'Reference', reference: 'Reference',
agency: 'Agency', agency: 'Agency',
wareHouseOut: 'Warehouse Out', wareHouseOut: 'Warehouse Out',
@ -566,7 +565,7 @@ export default {
landed: 'Landed', landed: 'Landed',
hour: 'Hour', hour: 'Hour',
agency: 'Agency', agency: 'Agency',
total: 'Total' total: 'Total',
}, },
form: { form: {
clientFk: 'Client', clientFk: 'Client',
@ -575,7 +574,7 @@ export default {
agencyModeFk: 'Agency', agencyModeFk: 'Agency',
}, },
list: { list: {
newOrder: 'New Order' newOrder: 'New Order',
}, },
summary: { summary: {
basket: 'Basket', basket: 'Basket',
@ -601,8 +600,8 @@ export default {
description: 'Description', description: 'Description',
quantity: 'Quantity', quantity: 'Quantity',
price: 'Price', price: 'Price',
amount: 'Amount' amount: 'Amount',
} },
}, },
worker: { worker: {
pageTitles: { pageTitles: {

View File

@ -48,7 +48,6 @@ export default {
dateFormat: 'es-ES', dateFormat: 'es-ES',
noSelectedRows: `No tienes ninguna línea seleccionada`, noSelectedRows: `No tienes ninguna línea seleccionada`,
microsip: 'Abrir en MicroSIP', microsip: 'Abrir en MicroSIP',
// labels compartidos entre vistas
downloadCSVSuccess: 'Descarga de CSV exitosa', downloadCSVSuccess: 'Descarga de CSV exitosa',
reference: 'Referencia', reference: 'Referencia',
agency: 'Agencia', agency: 'Agencia',
@ -475,7 +474,7 @@ export default {
landed: 'F. entrega', landed: 'F. entrega',
hour: 'Hora', hour: 'Hora',
agency: 'Agencia', agency: 'Agencia',
total: 'Total' total: 'Total',
}, },
form: { form: {
clientFk: 'Cliente', clientFk: 'Cliente',
@ -484,7 +483,7 @@ export default {
agencyModeFk: 'Agencia', agencyModeFk: 'Agencia',
}, },
list: { list: {
newOrder: 'Nuevo Pedido' newOrder: 'Nuevo Pedido',
}, },
summary: { summary: {
basket: 'Cesta', basket: 'Cesta',
@ -510,8 +509,8 @@ export default {
description: 'Descripción', description: 'Descripción',
quantity: 'Cantidad', quantity: 'Cantidad',
price: 'Precio', price: 'Precio',
amount: 'Monto' amount: 'Monto',
} },
}, },
shelving: { shelving: {
pageTitles: { pageTitles: {