8627-devToTest #1421
|
@ -291,9 +291,9 @@ globals:
|
||||||
buyRequest: Peticiones de compra
|
buyRequest: Peticiones de compra
|
||||||
wasteBreakdown: Deglose de mermas
|
wasteBreakdown: Deglose de mermas
|
||||||
itemCreate: Nuevo artículo
|
itemCreate: Nuevo artículo
|
||||||
tax: 'IVA'
|
tax: IVA
|
||||||
botanical: 'Botánico'
|
botanical: Botánico
|
||||||
barcode: 'Código de barras'
|
barcode: Código de barras
|
||||||
itemTypeCreate: Nueva familia
|
itemTypeCreate: Nueva familia
|
||||||
family: Familia
|
family: Familia
|
||||||
lastEntries: Últimas entradas
|
lastEntries: Últimas entradas
|
||||||
|
@ -668,8 +668,8 @@ wagon:
|
||||||
volumeNotEmpty: El volumen no puede estar vacío
|
volumeNotEmpty: El volumen no puede estar vacío
|
||||||
typeNotEmpty: El tipo no puede estar vacío
|
typeNotEmpty: El tipo no puede estar vacío
|
||||||
maxTrays: Has alcanzado el número máximo de bandejas
|
maxTrays: Has alcanzado el número máximo de bandejas
|
||||||
minHeightBetweenTrays: 'La distancia mínima entre bandejas es '
|
minHeightBetweenTrays: La distancia mínima entre bandejas es
|
||||||
maxWagonHeight: 'La altura máxima del vagón es '
|
maxWagonHeight: La altura máxima del vagón es
|
||||||
uncompleteTrays: Hay bandejas sin completar
|
uncompleteTrays: Hay bandejas sin completar
|
||||||
params:
|
params:
|
||||||
label: Etiqueta
|
label: Etiqueta
|
||||||
|
@ -814,7 +814,7 @@ components:
|
||||||
cardDescriptor:
|
cardDescriptor:
|
||||||
mainList: Listado principal
|
mainList: Listado principal
|
||||||
summary: Resumen
|
summary: Resumen
|
||||||
moreOptions: 'Más opciones'
|
moreOptions: Más opciones
|
||||||
leftMenu:
|
leftMenu:
|
||||||
addToPinned: Añadir a fijados
|
addToPinned: Añadir a fijados
|
||||||
removeFromPinned: Eliminar de fijados
|
removeFromPinned: Eliminar de fijados
|
||||||
|
|
|
@ -46,7 +46,8 @@ const defaultColumnAttrs = {
|
||||||
};
|
};
|
||||||
const emit = defineEmits(['onDialogClosed', 'itemReplaced']);
|
const emit = defineEmits(['onDialogClosed', 'itemReplaced']);
|
||||||
|
|
||||||
const conditionalValuePrice = (price) => (price > 1.3 ? 'match' : 'not-match');
|
const conditionalValuePrice = (price) =>
|
||||||
|
price > 1 + ticketConfig.value.lackAlertPrice / 100 ? 'match' : 'not-match';
|
||||||
|
|
||||||
const columns = computed(() => [
|
const columns = computed(() => [
|
||||||
{
|
{
|
||||||
|
@ -189,7 +190,8 @@ const isSelectionAvailable = (itemProposal) => {
|
||||||
return byPrice;
|
return byPrice;
|
||||||
}
|
}
|
||||||
const byQuantity =
|
const byQuantity =
|
||||||
(100 * itemProposal.available) / Math.abs($props.itemLack.lack) < 30;
|
(100 * itemProposal.available) / Math.abs($props.itemLack.lack) <
|
||||||
|
ticketConfig.value.lackAlertPrice;
|
||||||
return byQuantity;
|
return byQuantity;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,13 @@ const reload = async () => {
|
||||||
tableRef.value.tableRef.reload();
|
tableRef.value.tableRef.reload();
|
||||||
};
|
};
|
||||||
defineExpose({ reload });
|
defineExpose({ reload });
|
||||||
|
const filter = computed(() => ({
|
||||||
|
scopeDays: route.query.days,
|
||||||
|
showType: true,
|
||||||
|
alertLevelCode: 'FREE',
|
||||||
|
date: Date.vnNew(),
|
||||||
|
warehouseFk: useState().getUser().value.warehouseFk,
|
||||||
|
}));
|
||||||
const itemProposalEvt = (data) => {
|
const itemProposalEvt = (data) => {
|
||||||
const { itemProposal } = data;
|
const { itemProposal } = data;
|
||||||
itemProposalSelected.value = itemProposal;
|
itemProposalSelected.value = itemProposal;
|
||||||
|
@ -54,7 +60,6 @@ function onBuysFetched(data) {
|
||||||
}
|
}
|
||||||
const showItemProposal = () => {
|
const showItemProposal = () => {
|
||||||
quasar
|
quasar
|
||||||
|
|
||||||
.dialog({
|
.dialog({
|
||||||
component: ItemProposalProxy,
|
component: ItemProposalProxy,
|
||||||
componentProps: {
|
componentProps: {
|
||||||
|
@ -65,13 +70,6 @@ const showItemProposal = () => {
|
||||||
})
|
})
|
||||||
.onOk(itemProposalEvt);
|
.onOk(itemProposalEvt);
|
||||||
};
|
};
|
||||||
const filter = computed(() => ({
|
|
||||||
scopeDays: 2,
|
|
||||||
showType: true,
|
|
||||||
alertLevelCode: 'FREE',
|
|
||||||
date: Date.vnNew(),
|
|
||||||
warehouseFk: useState().getUser().value.warehouseFk,
|
|
||||||
}));
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -89,7 +87,7 @@ const filter = computed(() => ({
|
||||||
<FetchData
|
<FetchData
|
||||||
:url="`Buys/latestBuysFilter`"
|
:url="`Buys/latestBuysFilter`"
|
||||||
:fields="['longName']"
|
:fields="['longName']"
|
||||||
:filter="{ where: { 'i.id': '2' } }"
|
:filter="{ where: { 'i.id': entityId } }"
|
||||||
@on-fetch="onBuysFetched"
|
@on-fetch="onBuysFetched"
|
||||||
auto-load
|
auto-load
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -38,6 +38,11 @@ const onCategoryChange = async (categoryFk, search) => {
|
||||||
search();
|
search();
|
||||||
await itemTypesRef.value.fetch();
|
await itemTypesRef.value.fetch();
|
||||||
};
|
};
|
||||||
|
const emit = defineEmits(['set-user-params']);
|
||||||
|
|
||||||
|
const setUserParams = (params) => {
|
||||||
|
emit('set-user-params', params);
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -57,7 +62,11 @@ const onCategoryChange = async (categoryFk, search) => {
|
||||||
auto-load
|
auto-load
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<VnFilterPanel :data-key="props.dataKey" :search-button="true">
|
<VnFilterPanel
|
||||||
|
:data-key="props.dataKey"
|
||||||
|
:search-button="true"
|
||||||
|
@set-user-params="setUserParams"
|
||||||
|
>
|
||||||
<template #tags="{ tag, formatFn }">
|
<template #tags="{ tag, formatFn }">
|
||||||
<div class="q-gutter-x-xs">
|
<div class="q-gutter-x-xs">
|
||||||
<strong>{{ t(`negative.${tag.label}`) }}</strong>
|
<strong>{{ t(`negative.${tag.label}`) }}</strong>
|
||||||
|
@ -74,6 +83,11 @@ const onCategoryChange = async (categoryFk, search) => {
|
||||||
dense
|
dense
|
||||||
is-outlined
|
is-outlined
|
||||||
type="number"
|
type="number"
|
||||||
|
@update:model-value="
|
||||||
|
(value) => {
|
||||||
|
setUserParams(params);
|
||||||
|
}
|
||||||
|
"
|
||||||
/>
|
/>
|
||||||
</QItemSection>
|
</QItemSection>
|
||||||
</QItem>
|
</QItem>
|
||||||
|
|
|
@ -11,18 +11,25 @@ import { useRole } from 'src/composables/useRole';
|
||||||
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
import ItemDescriptorProxy from 'src/pages/Item/Card/ItemDescriptorProxy.vue';
|
||||||
import RightMenu from 'src/components/common/RightMenu.vue';
|
import RightMenu from 'src/components/common/RightMenu.vue';
|
||||||
import TicketLackFilter from './TicketLackFilter.vue';
|
import TicketLackFilter from './TicketLackFilter.vue';
|
||||||
|
onBeforeMount(() => {
|
||||||
|
stateStore.$state.rightDrawer = true;
|
||||||
|
});
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const stateStore = useStateStore();
|
const stateStore = useStateStore();
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const selectedRows = ref([]);
|
const selectedRows = ref([]);
|
||||||
|
const tableRef = ref();
|
||||||
|
const filterParams = ref({});
|
||||||
const negativeParams = reactive({
|
const negativeParams = reactive({
|
||||||
days: useRole().likeAny('buyer') ? 2 : 0,
|
days: useRole().likeAny('buyer') ? 2 : 0,
|
||||||
warehouseFk: useState().getUser().value.warehouseFk,
|
warehouseFk: useState().getUser().value.warehouseFk,
|
||||||
});
|
});
|
||||||
const redirectToCreateView = ({ itemFk }) => {
|
const redirectToCreateView = ({ itemFk }) => {
|
||||||
router.push({ name: 'NegativeDetail', params: { id: itemFk } });
|
router.push({
|
||||||
|
name: 'NegativeDetail',
|
||||||
|
params: { id: itemFk },
|
||||||
|
query: { days: filterParams.value.days ?? negativeParams.days },
|
||||||
|
});
|
||||||
};
|
};
|
||||||
const columns = computed(() => [
|
const columns = computed(() => [
|
||||||
{
|
{
|
||||||
|
@ -136,18 +143,19 @@ const columns = computed(() => [
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
const tableRef = ref();
|
|
||||||
onBeforeMount(() => {
|
const setUserParams = (params) => {
|
||||||
stateStore.$state.rightDrawer = true;
|
filterParams.value = params;
|
||||||
});
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<RightMenu>
|
<RightMenu>
|
||||||
<template #right-panel>
|
<template #right-panel>
|
||||||
<TicketLackFilter data-key="NegativeList" />
|
<TicketLackFilter data-key="NegativeList" @set-user-params="setUserParams" />
|
||||||
</template>
|
</template>
|
||||||
</RightMenu>
|
</RightMenu>
|
||||||
|
{{ filterRef }}
|
||||||
<VnTable
|
<VnTable
|
||||||
ref="tableRef"
|
ref="tableRef"
|
||||||
data-key="NegativeList"
|
data-key="NegativeList"
|
||||||
|
|
|
@ -187,59 +187,59 @@ ticketList:
|
||||||
client: Customer
|
client: Customer
|
||||||
createTicket: Create ticket
|
createTicket: Create ticket
|
||||||
negative:
|
negative:
|
||||||
hour: 'Hour'
|
hour: Hour
|
||||||
id: 'Id Article'
|
id: Id Article
|
||||||
longName: 'Article'
|
longName: Article
|
||||||
supplier: 'Supplier'
|
supplier: Supplier
|
||||||
colour: 'Colour'
|
colour: Colour
|
||||||
size: 'Size'
|
size: Size
|
||||||
origen: 'Origin'
|
origen: Origin
|
||||||
value: 'Negative'
|
value: Negative
|
||||||
itemFk: 'Article'
|
itemFk: Article
|
||||||
producer: 'Producer'
|
producer: Producer
|
||||||
warehouse: 'Warehouse'
|
warehouse: Warehouse
|
||||||
warehouseFk: 'Warehouse'
|
warehouseFk: Warehouse
|
||||||
category: 'Category'
|
category: Category
|
||||||
categoryFk: 'Family'
|
categoryFk: Family
|
||||||
type: 'Type'
|
type: Type
|
||||||
typeFk: 'Type'
|
typeFk: Type
|
||||||
lack: 'Negative'
|
lack: Negative
|
||||||
inkFk: 'inkFk'
|
inkFk: inkFk
|
||||||
timed: 'timed'
|
timed: timed
|
||||||
date: 'Date'
|
date: Date
|
||||||
minTimed: 'minTimed'
|
minTimed: minTimed
|
||||||
negativeAction: 'Negative'
|
negativeAction: Negative
|
||||||
totalNegative: 'Total negatives'
|
totalNegative: Total negatives
|
||||||
days: Days
|
days: Days
|
||||||
buttonsUpdate:
|
buttonsUpdate:
|
||||||
item: Item
|
item: Item
|
||||||
state: State
|
state: State
|
||||||
quantity: Quantity
|
quantity: Quantity
|
||||||
modalOrigin:
|
modalOrigin:
|
||||||
title: 'Update negatives'
|
title: Update negatives
|
||||||
question: 'Select a state to update'
|
question: Select a state to update
|
||||||
modalSplit:
|
modalSplit:
|
||||||
title: Confirm split selected
|
title: Confirm split selected
|
||||||
question: 'Select a state to update'
|
question: Select a state to update
|
||||||
detail:
|
detail:
|
||||||
saleFk: 'Sale'
|
saleFk: Sale
|
||||||
itemFk: 'Article'
|
itemFk: Article
|
||||||
ticketFk: 'Ticket'
|
ticketFk: Ticket
|
||||||
code: 'Code'
|
code: Code
|
||||||
nickname: 'Alias'
|
nickname: Alias
|
||||||
name: 'Name'
|
name: Name
|
||||||
zoneName: 'Agency name'
|
zoneName: Agency name
|
||||||
shipped: 'Date'
|
shipped: Date
|
||||||
theoreticalhour: 'Theoretical hour'
|
theoreticalhour: Theoretical hour
|
||||||
agName: 'Agency'
|
agName: Agency
|
||||||
quantity: 'Quantity'
|
quantity: Quantity
|
||||||
alertLevelCode: 'Group state'
|
alertLevelCode: Group state
|
||||||
state: 'State'
|
state: State
|
||||||
peticionCompra: 'Ticket request'
|
peticionCompra: Ticket request
|
||||||
isRookie: 'Is rookie'
|
isRookie: Is rookie
|
||||||
turno: 'Turn line'
|
turno: Turn line
|
||||||
isBasket: 'Basket'
|
isBasket: Basket
|
||||||
hasObservation: 'Has substitution'
|
hasObservation: Has substitution
|
||||||
hasToIgnore: VIP
|
hasToIgnore: VIP
|
||||||
modal:
|
modal:
|
||||||
changeItem:
|
changeItem:
|
||||||
|
|
|
@ -216,58 +216,58 @@ ticketList:
|
||||||
addressNickname: Alias consignatario
|
addressNickname: Alias consignatario
|
||||||
ref: Referencia
|
ref: Referencia
|
||||||
negative:
|
negative:
|
||||||
hour: 'Hora'
|
hour: Hora
|
||||||
id: 'Id Articulo'
|
id: Id Articulo
|
||||||
longName: 'Articulo'
|
longName: Articulo
|
||||||
supplier: 'Productor'
|
supplier: Productor
|
||||||
colour: 'Color'
|
colour: Color
|
||||||
size: 'Medida'
|
size: Medida
|
||||||
origen: 'Origen'
|
origen: Origen
|
||||||
value: 'Negativo'
|
value: Negativo
|
||||||
warehouseFk: 'Almacen'
|
warehouseFk: Almacen
|
||||||
producer: 'Producer'
|
producer: Producer
|
||||||
category: 'Categoría'
|
category: Categoría
|
||||||
categoryFk: 'Familia'
|
categoryFk: Familia
|
||||||
typeFk: 'Familia'
|
typeFk: Familia
|
||||||
warehouse: 'Almacen'
|
warehouse: Almacen
|
||||||
lack: 'Negativo'
|
lack: Negativo
|
||||||
inkFk: 'Color'
|
inkFk: Color
|
||||||
timed: 'Hora'
|
timed: Hora
|
||||||
date: 'Fecha'
|
date: Fecha
|
||||||
minTimed: 'Hora'
|
minTimed: Hora
|
||||||
type: 'Tipo'
|
type: Tipo
|
||||||
negativeAction: 'Negativo'
|
negativeAction: Negativo
|
||||||
totalNegative: 'Total negativos'
|
totalNegative: Total negativos
|
||||||
days: Rango de dias
|
days: Rango de dias
|
||||||
buttonsUpdate:
|
buttonsUpdate:
|
||||||
item: artículo
|
item: artículo
|
||||||
state: Estado
|
state: Estado
|
||||||
quantity: Cantidad
|
quantity: Cantidad
|
||||||
modalOrigin:
|
modalOrigin:
|
||||||
title: 'Actualizar negativos'
|
title: Actualizar negativos
|
||||||
question: 'Seleccione un estado para guardar'
|
question: Seleccione un estado para guardar
|
||||||
modalSplit:
|
modalSplit:
|
||||||
title: Confirmar acción de split
|
title: Confirmar acción de split
|
||||||
question: 'Selecciona un estado'
|
question: Selecciona un estado
|
||||||
detail:
|
detail:
|
||||||
saleFk: 'Línea'
|
saleFk: Línea
|
||||||
itemFk: 'Artículo'
|
itemFk: Artículo
|
||||||
ticketFk: 'Ticket'
|
ticketFk: Ticket
|
||||||
code: 'code'
|
code: code
|
||||||
nickname: 'Alias'
|
nickname: Alias
|
||||||
name: 'Nombre'
|
name: Nombre
|
||||||
zoneName: 'Agencia'
|
zoneName: Agencia
|
||||||
shipped: 'F. envío'
|
shipped: F. envío
|
||||||
theoreticalhour: 'Hora teórica'
|
theoreticalhour: Hora teórica
|
||||||
agName: 'Agencia'
|
agName: Agencia
|
||||||
quantity: 'Cantidad'
|
quantity: Cantidad
|
||||||
alertLevelCode: 'Estado agrupado'
|
alertLevelCode: Estado agrupado
|
||||||
state: 'Estado'
|
state: Estado
|
||||||
peticionCompra: 'Petición compra'
|
peticionCompra: Petición compra
|
||||||
isRookie: 'Cliente nuevo'
|
isRookie: Cliente nuevo
|
||||||
turno: 'Linea turno'
|
turno: Linea turno
|
||||||
isBasket: 'Cesta'
|
isBasket: Cesta
|
||||||
hasObservation: 'Tiene sustitución'
|
hasObservation: Tiene sustitución
|
||||||
hasToIgnore: VIP
|
hasToIgnore: VIP
|
||||||
modal:
|
modal:
|
||||||
changeItem:
|
changeItem:
|
||||||
|
|
Loading…
Reference in New Issue