0
0
Fork 0

Merge pull request 'Hotfix: fixed state column in TicketList and translation' (!944) from Hotfix-TicketList into master

Reviewed-on: verdnatura/salix-front#944
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
This commit is contained in:
Jon Elias 2024-11-15 11:11:14 +00:00
commit f03e5dc412
2 changed files with 7 additions and 22 deletions

View File

@ -17,21 +17,6 @@ const props = defineProps({
}); });
const itemTypeWorkersOptions = ref([]); const itemTypeWorkersOptions = ref([]);
const exprBuilder = (param, value) => {
switch (param) {
case 'name':
return { 'i.name': { like: `%${value}%` } };
case 'itemFk':
case 'warehouseFk':
case 'rate2':
case 'rate3':
param = `fp.${param}`;
return { [param]: value };
case 'minPrice':
param = `i.${param}`;
return { [param]: value };
}
};
</script> </script>
<template> <template>
@ -66,7 +51,7 @@ const exprBuilder = (param, value) => {
url="Warehouses" url="Warehouses"
auto-load auto-load
:filter="{ fields: ['id', 'name'], order: 'name ASC', limit: 30 }" :filter="{ fields: ['id', 'name'], order: 'name ASC', limit: 30 }"
:label="t('components.itemsFilterPanel.warehouseFk')" :label="t('globals.warehouse')"
v-model="params.warehouseFk" v-model="params.warehouseFk"
option-label="name" option-label="name"
option-value="id" option-value="id"

View File

@ -579,17 +579,17 @@ function setReference(data) {
</span> </span>
</template> </template>
<template #column-stateFk="{ row }"> <template #column-stateFk="{ row }">
<span v-if="getColor(row)"> <span v-if="row.refFk">
<QChip :class="getColor(row)" dense square>
{{ row.state }}
</QChip>
</span>
<span v-else-if="row.state === 'Entregado'">
<span class="link" @click.stop> <span class="link" @click.stop>
{{ row.refFk }} {{ row.refFk }}
<InvoiceOutDescriptorProxy :id="row.invoiceOutId" /> <InvoiceOutDescriptorProxy :id="row.invoiceOutId" />
</span> </span>
</span> </span>
<span v-else-if="getColor(row)">
<QChip :class="getColor(row)" dense square>
{{ row.state }}
</QChip>
</span>
<span v-else> <span v-else>
{{ row.state }} {{ row.state }}
</span> </span>