Merge branch 'dev' into 8449-vnLogFilter
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Alex Moreno 2025-03-26 08:23:29 +00:00
commit 4179219f15
10 changed files with 35 additions and 31 deletions

View File

@ -49,3 +49,9 @@ pnpm run test:e2e:summary
```bash ```bash
quasar build quasar build
``` ```
### Serve the app for production
```bash
quasar build quasar serve dist/spa --host 0.0.0.0 --proxy=./proxy-serve.js
```

View File

@ -1,15 +1,15 @@
<script setup> <script setup>
import {useDialogPluginComponent} from 'quasar'; import { useDialogPluginComponent } from 'quasar';
import {useI18n} from 'vue-i18n'; import { useI18n } from 'vue-i18n';
import {computed, ref} from 'vue'; import { computed, ref } from 'vue';
import VnInput from 'components/common/VnInput.vue'; import VnInput from 'components/common/VnInput.vue';
import axios from 'axios'; import axios from 'axios';
import useNotify from "composables/useNotify"; import useNotify from 'composables/useNotify';
const MESSAGE_MAX_LENGTH = 160; const MESSAGE_MAX_LENGTH = 160;
const {t} = useI18n(); const { t } = useI18n();
const {notify} = useNotify(); const { notify } = useNotify();
const props = defineProps({ const props = defineProps({
title: { title: {
type: String, type: String,
@ -34,7 +34,7 @@ const props = defineProps({
}); });
const emit = defineEmits([...useDialogPluginComponent.emits, 'sent']); const emit = defineEmits([...useDialogPluginComponent.emits, 'sent']);
const {dialogRef, onDialogHide} = useDialogPluginComponent(); const { dialogRef, onDialogHide } = useDialogPluginComponent();
const smsRules = [ const smsRules = [
(val) => (val && val.length > 0) || t("The message can't be empty"), (val) => (val && val.length > 0) || t("The message can't be empty"),
@ -43,10 +43,10 @@ const smsRules = [
t("The message it's too long"), t("The message it's too long"),
]; ];
const message = ref(''); const message = ref(t('routeDelay'));
const charactersRemaining = computed( const charactersRemaining = computed(
() => MESSAGE_MAX_LENGTH - new Blob([message.value]).size () => MESSAGE_MAX_LENGTH - new Blob([message.value]).size,
); );
const charactersChipColor = computed(() => { const charactersChipColor = computed(() => {
@ -114,7 +114,7 @@ const onSubmit = async () => {
<QTooltip> <QTooltip>
{{ {{
t( t(
'Special characters like accents counts as a multiple' 'Special characters like accents counts as a multiple',
) )
}} }}
</QTooltip> </QTooltip>
@ -144,7 +144,10 @@ const onSubmit = async () => {
max-width: 450px; max-width: 450px;
} }
</style> </style>
<i18n> <i18n>
en:
routeDelay: "Your order has been delayed in transit.\nDelivery will take place throughout the day.\nWe apologize for the inconvenience and appreciate your patience."
es: es:
Message: Mensaje Message: Mensaje
Send: Enviar Send: Enviar
@ -153,4 +156,5 @@ es:
The destination can't be empty: El destinatario no puede estar vacio The destination can't be empty: El destinatario no puede estar vacio
The message can't be empty: El mensaje no puede estar vacio The message can't be empty: El mensaje no puede estar vacio
The message it's too long: El mensaje es demasiado largo The message it's too long: El mensaje es demasiado largo
</i18n> routeDelay: "Retraso en ruta.\nInformamos que la ruta que lleva su pedido ha sufrido un retraso y la entrega se hará a lo largo del día.\nDisculpe las molestias."
</i18n>

View File

@ -15,7 +15,7 @@ const editDownloadDisabled = ref(false);
const $props = defineProps({ const $props = defineProps({
defaultDmsCode: { defaultDmsCode: {
type: String, type: String,
default: 'InvoiceIn', default: 'invoiceIn',
}, },
disable: { disable: {
type: Boolean, type: Boolean,

View File

@ -648,7 +648,7 @@ onMounted(() => {
:url="`Entries/${entityId}/getBuyList`" :url="`Entries/${entityId}/getBuyList`"
search-url="EntryBuys" search-url="EntryBuys"
save-url="Buys/crud" save-url="Buys/crud"
:filter="filter" :filter="editableMode ? filter : {}"
:disable-option="{ card: true }" :disable-option="{ card: true }"
v-model:selected="selectedRows" v-model:selected="selectedRows"
@on-fetch="() => footerFetchDataRef.fetch()" @on-fetch="() => footerFetchDataRef.fetch()"

View File

@ -147,7 +147,7 @@ async function deleteEntry() {
<template> <template>
<EntityDescriptor <EntityDescriptor
:url="`Entries/${entityId}`" :url="`Entries/${entityId}`"
:user-filter="entryFilter" :filter="entryFilter"
title="supplier.nickname" title="supplier.nickname"
data-key="Entry" data-key="Entry"
width="lg-width" width="lg-width"

View File

@ -116,6 +116,7 @@ const filter = computed(() => ({
hour: 0, hour: 0,
minute: 0, minute: 0,
second: 0, second: 0,
milliseconds: 0,
}), }),
m3: { neq: null }, m3: { neq: null },
}, },

View File

@ -198,20 +198,7 @@ const getLocale = (label) => {
<QItemSection> <QItemSection>
<VnSelect <VnSelect
dense dense
filled rounded
:label="t('globals.params.departmentFk')"
v-model="params.department"
option-label="name"
option-value="name"
url="Departments"
/>
</QItemSection>
</QItem>
<QItem>
<QItemSection>
<VnSelect
dense
filled
:label="t('globals.params.packing')" :label="t('globals.params.packing')"
v-model="params.packing" v-model="params.packing"
url="ItemPackingTypes" url="ItemPackingTypes"

View File

@ -197,7 +197,11 @@ const entriesTotals = computed(() => {
entriesTableRows.value.forEach((row) => { entriesTableRows.value.forEach((row) => {
for (const key in totals) { for (const key in totals) {
totals[key] += row[key] || 0; if (key === 'cc') {
totals[key] += Math.ceil(row[key] || 0);
} else {
totals[key] += row[key] || 0;
}
} }
}); });

View File

@ -80,7 +80,7 @@ defineExpose({ states });
/> />
<VnSelect <VnSelect
:label="t('travel.warehouseOut')" :label="t('travel.warehouseOut')"
v-model="params.warehouseOut" v-model="params.warehouseOutFk"
@update:model-value="searchFn()" @update:model-value="searchFn()"
url="warehouses" url="warehouses"
:use-like="false" :use-like="false"
@ -128,6 +128,7 @@ en:
ref: Reference ref: Reference
agency: Agency agency: Agency
warehouseInFk: Warehouse In warehouseInFk: Warehouse In
warehouseOutFk: Warehouse Out
shipped: Shipped shipped: Shipped
shipmentHour: Shipment Hour shipmentHour: Shipment Hour
warehouseOut: Warehouse Out warehouseOut: Warehouse Out
@ -141,6 +142,7 @@ es:
ref: Referencia ref: Referencia
agency: Agencia agency: Agencia
warehouseInFk: Alm.Entrada warehouseInFk: Alm.Entrada
warehouseOutFk: Alm.Salida
shipped: F.Envío shipped: F.Envío
shipmentHour: Hora de envío shipmentHour: Hora de envío
warehouseOut: Alm.Salida warehouseOut: Alm.Salida

View File

@ -1,4 +1,4 @@
describe('RouteAutonomous', () => { describe.skip('RouteAutonomous', () => {
const getLinkSelector = (colField) => const getLinkSelector = (colField) =>
`tr:first-child > [data-col-field="${colField}"] > .no-padding > .link`; `tr:first-child > [data-col-field="${colField}"] > .no-padding > .link`;