parent
f01eb6c49c
commit
2cbbd92021
|
@ -162,7 +162,6 @@ async function fetch() {
|
||||||
align-items: start;
|
align-items: start;
|
||||||
.label {
|
.label {
|
||||||
color: var(--vn-label-color);
|
color: var(--vn-label-color);
|
||||||
width: 9em;
|
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
white-space: wrap;
|
white-space: wrap;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
|
|
@ -247,10 +247,6 @@ const toModule = computed(() => {
|
||||||
.label {
|
.label {
|
||||||
color: var(--vn-label-color);
|
color: var(--vn-label-color);
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
|
|
||||||
&:not(:has(a))::after {
|
|
||||||
content: ':';
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
.value {
|
.value {
|
||||||
color: var(--vn-text-color);
|
color: var(--vn-text-color);
|
||||||
|
|
|
@ -63,7 +63,6 @@ defineExpose({
|
||||||
spinner-color="primary"
|
spinner-color="primary"
|
||||||
:error-src="`/no_image${getDarkSuffix()}.png`"
|
:error-src="`/no_image${getDarkSuffix()}.png`"
|
||||||
/>
|
/>
|
||||||
{{ console.log(getDarkSuffix()) }}
|
|
||||||
<QDialog v-if="$props.zoom" v-model="show">
|
<QDialog v-if="$props.zoom" v-model="show">
|
||||||
<QImg
|
<QImg
|
||||||
:draggable="true"
|
:draggable="true"
|
||||||
|
|
|
@ -40,10 +40,10 @@ const val = computed(() => $props.value);
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<div v-if="label || $slots.label" class="label">
|
<div v-if="label || $slots.label" class="label">
|
||||||
<slot name="label">
|
<slot name="label">
|
||||||
<span style="color: var(--vn-label-color)">{{ label }}</span>
|
<span style="color: var(--vn-label-color)">{{ label }}:</span>
|
||||||
</slot>
|
</slot>
|
||||||
</div>
|
</div>
|
||||||
<div class="value" v-if="value || $slots.value">
|
<div class="value">
|
||||||
<slot name="value">
|
<slot name="value">
|
||||||
<span :title="value" style="text-overflow: ellipsis">
|
<span :title="value" style="text-overflow: ellipsis">
|
||||||
{{ dash ? dashIfEmpty(value) : value }}
|
{{ dash ? dashIfEmpty(value) : value }}
|
||||||
|
@ -71,21 +71,13 @@ const val = computed(() => $props.value);
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
.label,
|
|
||||||
.value {
|
|
||||||
white-space: pre-line;
|
|
||||||
word-wrap: break-word;
|
|
||||||
}
|
|
||||||
.copy {
|
.copy {
|
||||||
visibility: hidden;
|
visibility: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.info {
|
.info {
|
||||||
margin-left: 5px;
|
margin-left: 5px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
:deep(.q-checkbox.disabled) {
|
:deep(.q-checkbox.disabled) {
|
||||||
opacity: 1 !important;
|
opacity: 1 !important;
|
||||||
}
|
}
|
||||||
|
|
|
@ -498,26 +498,6 @@ entry:
|
||||||
isRaid: Raid
|
isRaid: Raid
|
||||||
invoiceNumber: Invoice
|
invoiceNumber: Invoice
|
||||||
reference: Ref/Alb/Guide
|
reference: Ref/Alb/Guide
|
||||||
params:
|
|
||||||
isExcludedFromAvailable: Excluir del inventario
|
|
||||||
isOrdered: Pedida
|
|
||||||
isConfirmed: Lista para etiquetar
|
|
||||||
isReceived: Recibida
|
|
||||||
isRaid: Redada
|
|
||||||
landed: Fecha
|
|
||||||
supplierFk: Proveedor
|
|
||||||
invoiceNumber: Nº Factura
|
|
||||||
reference: Ref/Alb/Guía
|
|
||||||
agencyModeId: Agencia
|
|
||||||
isBooked: Asentado
|
|
||||||
companyFk: Empresa
|
|
||||||
travelFk: Envio
|
|
||||||
evaNotes: Notas
|
|
||||||
warehouseOutFk: Origen
|
|
||||||
warehouseInFk: Destino
|
|
||||||
entryTypeDescription: Tipo entrada
|
|
||||||
invoiceAmount: Importe
|
|
||||||
dated: Fecha
|
|
||||||
ticket:
|
ticket:
|
||||||
params:
|
params:
|
||||||
ticketFk: Ticket ID
|
ticketFk: Ticket ID
|
||||||
|
|
|
@ -230,7 +230,7 @@ const onIntrastatCreated = (response, formData) => {
|
||||||
/>
|
/>
|
||||||
<VnInput
|
<VnInput
|
||||||
type="textarea"
|
type="textarea"
|
||||||
:label="t('globals.comment')"
|
:label="t('item.basicData.photoMotivation')"
|
||||||
v-model="data.photoMotivation"
|
v-model="data.photoMotivation"
|
||||||
fill-input
|
fill-input
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -102,20 +102,21 @@ const columns = computed(() => [
|
||||||
label: t('itemDiary.in'),
|
label: t('itemDiary.in'),
|
||||||
field: 'invalue',
|
field: 'invalue',
|
||||||
name: 'in',
|
name: 'in',
|
||||||
align: 'left',
|
align: 'right',
|
||||||
format: (val) => dashIfEmpty(val),
|
format: (val) => dashIfEmpty(val),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('itemDiary.out'),
|
label: t('itemDiary.out'),
|
||||||
field: 'out',
|
field: 'out',
|
||||||
name: 'out',
|
name: 'out',
|
||||||
align: 'left',
|
align: 'right',
|
||||||
format: (val) => dashIfEmpty(val),
|
format: (val) => dashIfEmpty(val),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('itemDiary.balance'),
|
label: t('itemDiary.balance'),
|
||||||
name: 'balance',
|
name: 'balance',
|
||||||
align: 'left',
|
align: 'right',
|
||||||
|
class: 'q-px-sm',
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
@ -217,7 +218,8 @@ async function updateWarehouse(warehouseFk) {
|
||||||
<QTable
|
<QTable
|
||||||
:rows="itemBalances"
|
:rows="itemBalances"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
class="full-width q-mt-md"
|
class="full-width q-mt-md q-px-md"
|
||||||
|
style="background-color: var(--vn-section-color)"
|
||||||
:no-data-label="t('globals.noResults')"
|
:no-data-label="t('globals.noResults')"
|
||||||
>
|
>
|
||||||
<template #body-cell-claim="{ row }">
|
<template #body-cell-claim="{ row }">
|
||||||
|
@ -294,14 +296,14 @@ async function updateWarehouse(warehouseFk) {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-in="{ row }">
|
<template #body-cell-in="{ row }">
|
||||||
<QTd @click.stop>
|
<QTd @click.stop class="text-right">
|
||||||
<span :class="{ 'is-in': row.invalue }">
|
<span :class="{ 'is-in': row.invalue }">
|
||||||
{{ dashIfEmpty(row.invalue) }}
|
{{ dashIfEmpty(row.invalue) }}
|
||||||
</span>
|
</span>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-balance="{ row }">
|
<template #body-cell-balance="{ row }">
|
||||||
<QTd @click.stop>
|
<QTd @click.stop class="text-right">
|
||||||
<QBadge
|
<QBadge
|
||||||
class="balance-negative"
|
class="balance-negative"
|
||||||
:color="
|
:color="
|
||||||
|
|
|
@ -48,7 +48,7 @@ const columns = computed(() => [
|
||||||
label: t('itemDiary.warehouse'),
|
label: t('itemDiary.warehouse'),
|
||||||
name: 'warehouse',
|
name: 'warehouse',
|
||||||
field: 'warehouse',
|
field: 'warehouse',
|
||||||
align: 'center',
|
align: 'left',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('lastEntries.landed'),
|
label: t('lastEntries.landed'),
|
||||||
|
@ -60,7 +60,7 @@ const columns = computed(() => [
|
||||||
label: t('lastEntries.entry'),
|
label: t('lastEntries.entry'),
|
||||||
name: 'entry',
|
name: 'entry',
|
||||||
field: 'stateName',
|
field: 'stateName',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
format: (val) => dashIfEmpty(val),
|
format: (val) => dashIfEmpty(val),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -75,14 +75,14 @@ const columns = computed(() => [
|
||||||
label: t('lastEntries.printedStickers'),
|
label: t('lastEntries.printedStickers'),
|
||||||
name: 'printedStickers',
|
name: 'printedStickers',
|
||||||
field: 'printedStickers',
|
field: 'printedStickers',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
format: (val) => dashIfEmpty(val),
|
format: (val) => dashIfEmpty(val),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('lastEntries.label'),
|
label: t('lastEntries.label'),
|
||||||
name: 'stickers',
|
name: 'stickers',
|
||||||
field: 'stickers',
|
field: 'stickers',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
format: (val) => dashIfEmpty(val),
|
format: (val) => dashIfEmpty(val),
|
||||||
style: (row) => highlightedRow(row),
|
style: (row) => highlightedRow(row),
|
||||||
},
|
},
|
||||||
|
@ -90,39 +90,39 @@ const columns = computed(() => [
|
||||||
label: 'Packing',
|
label: 'Packing',
|
||||||
name: 'packing',
|
name: 'packing',
|
||||||
field: 'packing',
|
field: 'packing',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('lastEntries.grouping'),
|
label: t('lastEntries.grouping'),
|
||||||
name: 'grouping',
|
name: 'grouping',
|
||||||
field: 'grouping',
|
field: 'grouping',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('itemBasicData.stems'),
|
label: t('itemBasicData.stems'),
|
||||||
name: 'stems',
|
name: 'stems',
|
||||||
field: 'stems',
|
field: 'stems',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
style: (row) => highlightedRow(row),
|
style: (row) => highlightedRow(row),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('lastEntries.quantity'),
|
label: t('lastEntries.quantity'),
|
||||||
name: 'quantity',
|
name: 'quantity',
|
||||||
field: 'quantity',
|
field: 'quantity',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
style: (row) => highlightedRow(row),
|
style: (row) => highlightedRow(row),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('lastEntries.cost'),
|
label: t('lastEntries.cost'),
|
||||||
name: 'cost',
|
name: 'cost',
|
||||||
field: 'cost',
|
field: 'right',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: 'Kg',
|
label: 'Kg',
|
||||||
name: 'weight',
|
name: 'weight',
|
||||||
field: 'weight',
|
field: 'weight',
|
||||||
align: 'center',
|
align: 'right',
|
||||||
style: (row) => highlightedRow(row),
|
style: (row) => highlightedRow(row),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -136,7 +136,7 @@ const columns = computed(() => [
|
||||||
label: t('lastEntries.supplier'),
|
label: t('lastEntries.supplier'),
|
||||||
name: 'supplier',
|
name: 'supplier',
|
||||||
field: 'supplier',
|
field: 'supplier',
|
||||||
align: 'center',
|
align: 'left',
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
@ -269,7 +269,7 @@ function highlightedRow(row) {
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-entry="{ row }">
|
<template #body-cell-entry="{ row }">
|
||||||
<QTd @click.stop :style="highlightedRow(row)">
|
<QTd @click.stop :style="highlightedRow(row)">
|
||||||
<div class="full-width flex justify-center">
|
<div class="full-width text-right">
|
||||||
<EntryDescriptorProxy :id="row.entryFk" class="q-ma-none" dense />
|
<EntryDescriptorProxy :id="row.entryFk" class="q-ma-none" dense />
|
||||||
<span class="link">{{ row.entryFk }}</span>
|
<span class="link">{{ row.entryFk }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
@ -282,16 +282,16 @@ function highlightedRow(row) {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-printedStickers="{ row }">
|
<template #body-cell-printedStickers="{ row }">
|
||||||
<QTd @click.stop class="text-center" :style="highlightedRow(row)">
|
<QTd @click.stop class="text-right" :style="highlightedRow(row)">
|
||||||
<span style="color: var(--vn-label-color)">
|
<span style="color: var(--vn-label-color)">
|
||||||
{{ row.printedStickers }}</span
|
{{ row.printedStickers }}</span
|
||||||
>
|
>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-packing="{ row }">
|
<template #body-cell-packing="{ row }">
|
||||||
<QTd @click.stop :style="highlightedRow(row)">
|
<QTd @click.stop :style="highlightedRow(row)" class="text-right">
|
||||||
<QBadge
|
<QBadge
|
||||||
class="center-content"
|
class="grouping-badge"
|
||||||
:class="getBadgeClass(row.groupingMode, 'packing')"
|
:class="getBadgeClass(row.groupingMode, 'packing')"
|
||||||
rounded
|
rounded
|
||||||
>
|
>
|
||||||
|
@ -301,9 +301,9 @@ function highlightedRow(row) {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-grouping="{ row }">
|
<template #body-cell-grouping="{ row }">
|
||||||
<QTd @click.stop :style="highlightedRow(row)">
|
<QTd @click.stop :style="highlightedRow(row)" class="text-right">
|
||||||
<QBadge
|
<QBadge
|
||||||
class="center-content"
|
class="grouping-badge"
|
||||||
:class="getBadgeClass(row.groupingMode, 'grouping')"
|
:class="getBadgeClass(row.groupingMode, 'grouping')"
|
||||||
rounded
|
rounded
|
||||||
>
|
>
|
||||||
|
@ -313,7 +313,7 @@ function highlightedRow(row) {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-cost="{ row }">
|
<template #body-cell-cost="{ row }">
|
||||||
<QTd @click.stop class="text-center" :style="highlightedRow(row)">
|
<QTd @click.stop class="text-right" :style="highlightedRow(row)">
|
||||||
<span>
|
<span>
|
||||||
{{ toCurrency(row.cost, 'EUR', 3) }}
|
{{ toCurrency(row.cost, 'EUR', 3) }}
|
||||||
<QTooltip>
|
<QTooltip>
|
||||||
|
@ -357,10 +357,7 @@ function highlightedRow(row) {
|
||||||
.q-badge--rounded {
|
.q-badge--rounded {
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
}
|
}
|
||||||
.center-content {
|
.grouping-badge {
|
||||||
display: flex;
|
|
||||||
max-width: max-content;
|
|
||||||
margin: auto;
|
|
||||||
padding: 0 11px;
|
padding: 0 11px;
|
||||||
height: 28px;
|
height: 28px;
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,7 +58,7 @@ const columns = computed(() => [
|
||||||
{
|
{
|
||||||
label: t('shelvings.item'),
|
label: t('shelvings.item'),
|
||||||
name: 'itemFk',
|
name: 'itemFk',
|
||||||
align: 'left',
|
align: 'right',
|
||||||
columnFilter: false,
|
columnFilter: false,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -102,19 +102,20 @@ const columns = computed(() => [
|
||||||
name: 'label',
|
name: 'label',
|
||||||
align: 'left',
|
align: 'left',
|
||||||
columnFilter: { inWhere: true },
|
columnFilter: { inWhere: true },
|
||||||
|
component: 'number',
|
||||||
format: (row) => (row.stock / row.packing).toFixed(2),
|
format: (row) => (row.stock / row.packing).toFixed(2),
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('shelvings.packing'),
|
label: t('shelvings.packing'),
|
||||||
name: 'packing',
|
name: 'packing',
|
||||||
attrs: { inWhere: true },
|
attrs: { inWhere: true },
|
||||||
align: 'left',
|
component: 'number',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: t('globals.visible'),
|
label: t('globals.visible'),
|
||||||
name: 'stock',
|
name: 'stock',
|
||||||
attrs: { inWhere: true },
|
attrs: { inWhere: true },
|
||||||
align: 'left',
|
component: 'number',
|
||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
@ -138,21 +139,12 @@ watchEffect(selectedRows);
|
||||||
<template>
|
<template>
|
||||||
<template v-if="stateStore.isHeaderMounted()">
|
<template v-if="stateStore.isHeaderMounted()">
|
||||||
<Teleport to="#st-data">
|
<Teleport to="#st-data">
|
||||||
<div class="q-pa-md q-mr-lg q-ma-xs" style="border: 2px solid #222">
|
|
||||||
<QCardSection horizontal>
|
|
||||||
<span class="text-weight-bold text-subtitle1 text-center full-width">
|
|
||||||
{{ t('shelvings.total') }}
|
|
||||||
</span>
|
|
||||||
</QCardSection>
|
|
||||||
<QCardSection class="column items-center" horizontal>
|
<QCardSection class="column items-center" horizontal>
|
||||||
<div>
|
<div>
|
||||||
<span class="details-label"
|
<span class="details-label">{{ t('shelvings.totalLabels') }} </span>
|
||||||
>{{ t('shelvings.totalLabels') }}
|
|
||||||
</span>
|
|
||||||
<span>: {{ totalLabels }}</span>
|
<span>: {{ totalLabels }}</span>
|
||||||
</div></QCardSection
|
|
||||||
>
|
|
||||||
</div>
|
</div>
|
||||||
|
</QCardSection>
|
||||||
</Teleport>
|
</Teleport>
|
||||||
<Teleport to="#st-actions">
|
<Teleport to="#st-actions">
|
||||||
<QBtn
|
<QBtn
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
import { computed } from 'vue';
|
import { computed } from 'vue';
|
||||||
import { useRoute } from 'vue-router';
|
import { useRoute } from 'vue-router';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
|
import { dashIfEmpty } from 'src/filters';
|
||||||
|
|
||||||
import CardSummary from 'components/ui/CardSummary.vue';
|
import CardSummary from 'components/ui/CardSummary.vue';
|
||||||
import VnLv from 'src/components/ui/VnLv.vue';
|
import VnLv from 'src/components/ui/VnLv.vue';
|
||||||
|
@ -48,7 +49,7 @@ const getUrl = (id, param) => `#/Item/${id}/${param}`;
|
||||||
<ItemDescriptorMenu :entity-id="entityId" :warehouse-fk="warehouseFk" />
|
<ItemDescriptorMenu :entity-id="entityId" :warehouse-fk="warehouseFk" />
|
||||||
</template>
|
</template>
|
||||||
<template #body="{ entity: { item, tags, visible, available, botanical } }">
|
<template #body="{ entity: { item, tags, visible, available, botanical } }">
|
||||||
<QCard class="vn-one photo">
|
<QCard class="vn-one photo" v-if="$route.name != 'ItemSummary'">
|
||||||
<ItemDescriptorImage
|
<ItemDescriptorImage
|
||||||
:entity-id="entityId"
|
:entity-id="entityId"
|
||||||
:visible="visible"
|
:visible="visible"
|
||||||
|
@ -56,14 +57,22 @@ const getUrl = (id, param) => `#/Item/${id}/${param}`;
|
||||||
:show-edit-button="false"
|
:show-edit-button="false"
|
||||||
/>
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-one">
|
<QCard class="vn-three">
|
||||||
<VnTitle
|
<VnTitle
|
||||||
:url="getUrl(entityId, 'basic-data')"
|
:url="getUrl(entityId, 'basic-data')"
|
||||||
:text="t('globals.summary.basicData')"
|
:text="t('globals.summary.basicData')"
|
||||||
/>
|
/>
|
||||||
|
<div class="vn-card-group">
|
||||||
|
<div class="vn-card-content">
|
||||||
<VnLv :label="t('globals.name')" :value="item.name" />
|
<VnLv :label="t('globals.name')" :value="item.name" />
|
||||||
<VnLv :label="t('item.summary.completeName')" :value="item.longName" />
|
<VnLv
|
||||||
<VnLv :label="t('item.summary.family')" :value="item.itemType.name" />
|
:label="t('item.summary.completeName')"
|
||||||
|
:value="item.longName"
|
||||||
|
/>
|
||||||
|
<VnLv
|
||||||
|
:label="t('item.summary.family')"
|
||||||
|
:value="item.itemType.name"
|
||||||
|
/>
|
||||||
<VnLv :label="t('globals.size')" :value="item.size" />
|
<VnLv :label="t('globals.size')" :value="item.size" />
|
||||||
<VnLv :label="t('globals.origin')" :value="item.origin.name" />
|
<VnLv :label="t('globals.origin')" :value="item.origin.name" />
|
||||||
<VnLv :label="t('item.summary.stems')" :value="item.stems" />
|
<VnLv :label="t('item.summary.stems')" :value="item.stems" />
|
||||||
|
@ -86,15 +95,24 @@ const getUrl = (id, param) => `#/Item/${id}/${param}`;
|
||||||
:label="t('item.summary.doPhoto')"
|
:label="t('item.summary.doPhoto')"
|
||||||
v-model="item.isPhotoRequested"
|
v-model="item.isPhotoRequested"
|
||||||
:disable="true"
|
:disable="true"
|
||||||
|
size="xs"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</VnLv>
|
</VnLv>
|
||||||
</QCard>
|
<VnLv :label="t('globals.description')">
|
||||||
<QCard class="vn-one">
|
<template #value>
|
||||||
<VnTitle
|
<span
|
||||||
:url="getUrl(entityId, 'basic-data')"
|
style="
|
||||||
:text="t('item.summary.otherData')"
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
"
|
||||||
|
v-text="dashIfEmpty(item.description)"
|
||||||
/>
|
/>
|
||||||
|
</template>
|
||||||
|
</VnLv>
|
||||||
|
</div>
|
||||||
|
<div class="vn-card-content">
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('item.summary.intrastatCode')"
|
:label="t('item.summary.intrastatCode')"
|
||||||
:value="item.intrastat.id"
|
:value="item.intrastat.id"
|
||||||
|
@ -104,11 +122,23 @@ const getUrl = (id, param) => `#/Item/${id}/${param}`;
|
||||||
:value="item.intrastat.description"
|
:value="item.intrastat.description"
|
||||||
/>
|
/>
|
||||||
<VnLv :label="t('item.summary.ref')" :value="item.comment" />
|
<VnLv :label="t('item.summary.ref')" :value="item.comment" />
|
||||||
<VnLv :label="t('item.summary.relevance')" :value="item.relevancy" />
|
<VnLv
|
||||||
<VnLv :label="t('item.summary.weight')" :value="item.weightByPiece" />
|
:label="t('item.summary.relevance')"
|
||||||
|
:value="item.relevancy"
|
||||||
|
/>
|
||||||
|
<VnLv
|
||||||
|
:label="t('item.summary.weight')"
|
||||||
|
:value="item.weightByPiece"
|
||||||
|
/>
|
||||||
<VnLv :label="t('item.summary.units')" :value="item.packingOut" />
|
<VnLv :label="t('item.summary.units')" :value="item.packingOut" />
|
||||||
<VnLv :label="t('item.summary.expense')" :value="item.expense.name" />
|
<VnLv
|
||||||
<VnLv :label="t('item.summary.generic')" :value="item.genericFk" />
|
:label="t('item.summary.expense')"
|
||||||
|
:value="item.expense.name"
|
||||||
|
/>
|
||||||
|
<VnLv
|
||||||
|
:label="t('item.summary.generic')"
|
||||||
|
:value="item.genericFk"
|
||||||
|
/>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('item.summary.recycledPlastic')"
|
:label="t('item.summary.recycledPlastic')"
|
||||||
:value="item.recycledPlastic"
|
:value="item.recycledPlastic"
|
||||||
|
@ -117,23 +147,18 @@ const getUrl = (id, param) => `#/Item/${id}/${param}`;
|
||||||
:label="t('item.summary.nonRecycledPlastic')"
|
:label="t('item.summary.nonRecycledPlastic')"
|
||||||
:value="item.nonRecycledPlastic"
|
:value="item.nonRecycledPlastic"
|
||||||
/>
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-one">
|
<QCard class="vn-one">
|
||||||
<VnTitle :url="getUrl(entityId, 'tags')" :text="t('globals.tags')" />
|
<VnTitle :url="getUrl(entityId, 'tags')" :text="t('globals.tags')" />
|
||||||
<VnLv
|
<VnLv
|
||||||
v-for="(tag, index) in tags"
|
v-for="(tag, index) in tags"
|
||||||
:key="index"
|
:key="index"
|
||||||
:label="`${tag.priority} ${tag.tag.name}:`"
|
:label="`${tag.priority} ${tag.tag.name}`"
|
||||||
:value="tag.value"
|
:value="tag.value"
|
||||||
/>
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-one" v-if="item.description">
|
|
||||||
<VnTitle
|
|
||||||
:url="getUrl(entityId, 'basic-data')"
|
|
||||||
:text="t('globals.description')"
|
|
||||||
/>
|
|
||||||
<p v-text="item.description" />
|
|
||||||
</QCard>
|
|
||||||
<QCard class="vn-one">
|
<QCard class="vn-one">
|
||||||
<VnTitle :url="getUrl(entityId, 'tax')" :text="t('item.summary.tax')" />
|
<VnTitle :url="getUrl(entityId, 'tax')" :text="t('item.summary.tax')" />
|
||||||
<VnLv
|
<VnLv
|
||||||
|
|
|
@ -76,15 +76,7 @@ const insertTag = (rows) => {
|
||||||
model="ItemTags"
|
model="ItemTags"
|
||||||
url="ItemTags"
|
url="ItemTags"
|
||||||
:data-required="{
|
:data-required="{
|
||||||
$index: undefined,
|
|
||||||
itemFk: route.params.id,
|
itemFk: route.params.id,
|
||||||
priority: undefined,
|
|
||||||
tag: {
|
|
||||||
isFree: undefined,
|
|
||||||
value: undefined,
|
|
||||||
name: undefined,
|
|
||||||
},
|
|
||||||
tagFk: undefined,
|
|
||||||
}"
|
}"
|
||||||
:default-remove="false"
|
:default-remove="false"
|
||||||
:user-filter="{
|
:user-filter="{
|
||||||
|
@ -106,7 +98,7 @@ const insertTag = (rows) => {
|
||||||
<VnRow
|
<VnRow
|
||||||
v-for="(row, index) in rows"
|
v-for="(row, index) in rows"
|
||||||
:key="index"
|
:key="index"
|
||||||
class="items-center"
|
class="items-center q-py-sm"
|
||||||
>
|
>
|
||||||
<VnSelect
|
<VnSelect
|
||||||
:label="t('itemTags.tag')"
|
:label="t('itemTags.tag')"
|
||||||
|
@ -132,9 +124,7 @@ const insertTag = (rows) => {
|
||||||
emit-value
|
emit-value
|
||||||
use-input
|
use-input
|
||||||
class="col"
|
class="col"
|
||||||
:is-clearable="false"
|
|
||||||
:required="false"
|
:required="false"
|
||||||
:rules="validate('itemTag.tagFk')"
|
|
||||||
:use-like="false"
|
:use-like="false"
|
||||||
sort-by="value"
|
sort-by="value"
|
||||||
/>
|
/>
|
||||||
|
@ -145,7 +135,6 @@ const insertTag = (rows) => {
|
||||||
v-model="row.value"
|
v-model="row.value"
|
||||||
:label="t('itemTags.value')"
|
:label="t('itemTags.value')"
|
||||||
:is-clearable="false"
|
:is-clearable="false"
|
||||||
@keyup.enter.stop="(data) => itemTagsRef.onSubmit(data)"
|
|
||||||
:data-cy="`tag${row?.tag?.name}Value`"
|
:data-cy="`tag${row?.tag?.name}Value`"
|
||||||
/>
|
/>
|
||||||
<VnInput
|
<VnInput
|
||||||
|
@ -154,7 +143,7 @@ const insertTag = (rows) => {
|
||||||
v-model="row.priority"
|
v-model="row.priority"
|
||||||
:required="true"
|
:required="true"
|
||||||
:rules="validate('itemTag.priority')"
|
:rules="validate('itemTag.priority')"
|
||||||
@keyup.enter.stop="(data) => itemTagsRef.onSubmit(data)"
|
style="max-width: 60%"
|
||||||
/>
|
/>
|
||||||
<div class="row justify-center" style="flex: 0">
|
<div class="row justify-center" style="flex: 0">
|
||||||
<QIcon
|
<QIcon
|
||||||
|
@ -181,11 +170,8 @@ const insertTag = (rows) => {
|
||||||
v-shortcut="'+'"
|
v-shortcut="'+'"
|
||||||
fab
|
fab
|
||||||
data-cy="createNewTag"
|
data-cy="createNewTag"
|
||||||
>
|
:title="t('globals.add')"
|
||||||
<QTooltip>
|
/>
|
||||||
{{ t('itemTags.addTag') }}
|
|
||||||
</QTooltip>
|
|
||||||
</QBtn>
|
|
||||||
</QPageSticky>
|
</QPageSticky>
|
||||||
</template>
|
</template>
|
||||||
</CrudModel>
|
</CrudModel>
|
||||||
|
|
|
@ -64,6 +64,7 @@ const submitTaxes = async (data) => {
|
||||||
auto-load
|
auto-load
|
||||||
>
|
>
|
||||||
<template #body="{ rows }">
|
<template #body="{ rows }">
|
||||||
|
<div style="display: flex; justify-content: center">
|
||||||
<QCard class="q-px-lg q-py-md">
|
<QCard class="q-px-lg q-py-md">
|
||||||
<VnRow
|
<VnRow
|
||||||
v-for="(row, index) in rows"
|
v-for="(row, index) in rows"
|
||||||
|
@ -85,6 +86,7 @@ const submitTaxes = async (data) => {
|
||||||
/>
|
/>
|
||||||
</VnRow>
|
</VnRow>
|
||||||
</QCard>
|
</QCard>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</CrudModel>
|
</CrudModel>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, computed, onBeforeMount } from 'vue';
|
import { ref, computed, onBeforeMount } from 'vue';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
import { useRoute } from 'vue-router';
|
|
||||||
import VnImg from 'src/components/ui/VnImg.vue';
|
import VnImg from 'src/components/ui/VnImg.vue';
|
||||||
import VnTable from 'components/VnTable/VnTable.vue';
|
import VnTable from 'components/VnTable/VnTable.vue';
|
||||||
import { toDate } from 'src/filters';
|
import { toDate } from 'src/filters';
|
||||||
|
@ -18,17 +17,13 @@ import VnSelect from 'src/components/common/VnSelect.vue';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import VnSection from 'src/components/common/VnSection.vue';
|
import VnSection from 'src/components/common/VnSection.vue';
|
||||||
|
|
||||||
const entityId = computed(() => route.params.id);
|
|
||||||
const { openCloneDialog } = cloneItem();
|
const { openCloneDialog } = cloneItem();
|
||||||
const { viewSummary } = useSummaryDialog();
|
const { viewSummary } = useSummaryDialog();
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const tableRef = ref();
|
const tableRef = ref();
|
||||||
const route = useRoute();
|
|
||||||
const dataKey = 'ItemList';
|
const dataKey = 'ItemList';
|
||||||
const validPriorities = ref([]);
|
const validPriorities = ref([]);
|
||||||
const defaultTag = ref();
|
const defaultItem = ref(null);
|
||||||
const defaultPriority = ref();
|
|
||||||
const defaultItem = ref();
|
|
||||||
|
|
||||||
const itemFilter = {
|
const itemFilter = {
|
||||||
include: [
|
include: [
|
||||||
|
@ -305,9 +300,7 @@ const columns = computed(() => [
|
||||||
onBeforeMount(async () => {
|
onBeforeMount(async () => {
|
||||||
const { data } = await axios.get('ItemConfigs/findOne');
|
const { data } = await axios.get('ItemConfigs/findOne');
|
||||||
defaultItem.value = data;
|
defaultItem.value = data;
|
||||||
console.log('defaultItem.value: ', defaultItem.value);
|
|
||||||
});
|
});
|
||||||
const dafaultComputed = computed(() => defaultItem.value);
|
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<VnSection
|
<VnSection
|
||||||
|
@ -325,6 +318,7 @@ const dafaultComputed = computed(() => defaultItem.value);
|
||||||
</template>
|
</template>
|
||||||
<template #body>
|
<template #body>
|
||||||
<VnTable
|
<VnTable
|
||||||
|
v-if="defaultItem"
|
||||||
:data-key="dataKey"
|
:data-key="dataKey"
|
||||||
ref="tableRef"
|
ref="tableRef"
|
||||||
search-url="ItemList"
|
search-url="ItemList"
|
||||||
|
@ -335,8 +329,8 @@ const dafaultComputed = computed(() => defaultItem.value);
|
||||||
title: t('item.list.newItem'),
|
title: t('item.list.newItem'),
|
||||||
onDataSaved: ({ id }) => tableRef.redirect(`${id}/basic-data`),
|
onDataSaved: ({ id }) => tableRef.redirect(`${id}/basic-data`),
|
||||||
formInitialData: {
|
formInitialData: {
|
||||||
tag: 1,
|
tag: defaultItem?.defaultTag,
|
||||||
priority: 1,
|
priority: defaultItem?.defaultPriority,
|
||||||
},
|
},
|
||||||
}"
|
}"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
|
@ -380,7 +374,6 @@ const dafaultComputed = computed(() => defaultItem.value);
|
||||||
</span>
|
</span>
|
||||||
</template>
|
</template>
|
||||||
<template #more-create-dialog="{ data }">
|
<template #more-create-dialog="{ data }">
|
||||||
{{ data }}
|
|
||||||
<VnInput
|
<VnInput
|
||||||
v-model="data.provisionalName"
|
v-model="data.provisionalName"
|
||||||
:label="t('Provisional name')"
|
:label="t('Provisional name')"
|
||||||
|
@ -388,7 +381,7 @@ const dafaultComputed = computed(() => defaultItem.value);
|
||||||
/>
|
/>
|
||||||
<VnSelect
|
<VnSelect
|
||||||
url="Tags"
|
url="Tags"
|
||||||
v-model="data.defaultTag"
|
v-model="data.tag"
|
||||||
:label="t('globals.tag')"
|
:label="t('globals.tag')"
|
||||||
:fields="['id', 'name']"
|
:fields="['id', 'name']"
|
||||||
option-label="name"
|
option-label="name"
|
||||||
|
@ -487,8 +480,5 @@ const dafaultComputed = computed(() => defaultItem.value);
|
||||||
</style>
|
</style>
|
||||||
<i18n>
|
<i18n>
|
||||||
es:
|
es:
|
||||||
New item: Nuevo artículo
|
|
||||||
Create Item: Crear artículo
|
|
||||||
You can search by id: Puedes buscar por id
|
|
||||||
Provisional name: Nombre provisional
|
Provisional name: Nombre provisional
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
|
@ -7,7 +7,7 @@ import FetchData from 'components/FetchData.vue';
|
||||||
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
|
import VnFilterPanel from 'src/components/ui/VnFilterPanel.vue';
|
||||||
import VnSelect from 'src/components/common/VnSelect.vue';
|
import VnSelect from 'src/components/common/VnSelect.vue';
|
||||||
import VnInput from 'src/components/common/VnInput.vue';
|
import VnInput from 'src/components/common/VnInput.vue';
|
||||||
|
import VnCheckbox from 'src/components/common/VnCheckbox.vue';
|
||||||
import { useArrayData } from 'composables/useArrayData';
|
import { useArrayData } from 'composables/useArrayData';
|
||||||
import { useValidator } from 'src/composables/useValidator';
|
import { useValidator } from 'src/composables/useValidator';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
|
|
|
@ -99,9 +99,6 @@ item:
|
||||||
concept: Concept
|
concept: Concept
|
||||||
denyOptions: Deny
|
denyOptions: Deny
|
||||||
scopeDays: Scope days
|
scopeDays: Scope days
|
||||||
searchbar:
|
|
||||||
label: Search item
|
|
||||||
info: You can search by id
|
|
||||||
descriptor:
|
descriptor:
|
||||||
item: Item
|
item: Item
|
||||||
buyer: Buyer
|
buyer: Buyer
|
||||||
|
@ -158,6 +155,7 @@ item:
|
||||||
isPhotoRequestedTooltip: This item does need a photo
|
isPhotoRequestedTooltip: This item does need a photo
|
||||||
isCustomInspectionRequired: Needs physical inspection (PIF)
|
isCustomInspectionRequired: Needs physical inspection (PIF)
|
||||||
description: Description
|
description: Description
|
||||||
|
fotoMotivation: Comment for the photographer
|
||||||
fixedPrice:
|
fixedPrice:
|
||||||
itemFk: Item ID
|
itemFk: Item ID
|
||||||
groupingPrice: Grouping price
|
groupingPrice: Grouping price
|
||||||
|
@ -216,7 +214,7 @@ item:
|
||||||
genus: Genus
|
genus: Genus
|
||||||
specie: Specie
|
specie: Specie
|
||||||
search: 'Search item'
|
search: 'Search item'
|
||||||
searchInfo: 'You can search by id'
|
searchInfo: 'You can search by id or barcode'
|
||||||
regularizeStock: Regularize stock
|
regularizeStock: Regularize stock
|
||||||
itemProposal: Items proposal
|
itemProposal: Items proposal
|
||||||
proposal:
|
proposal:
|
||||||
|
|
|
@ -148,15 +148,16 @@ item:
|
||||||
weightByPiece: Peso (gramos)/tallo
|
weightByPiece: Peso (gramos)/tallo
|
||||||
boxUnits: Unidades/caja
|
boxUnits: Unidades/caja
|
||||||
recycledPlastic: Plastico reciclado
|
recycledPlastic: Plastico reciclado
|
||||||
nonRecycledPlastic: Plático no reciclado
|
nonRecycledPlastic: Plástico no reciclado
|
||||||
isActive: Activo
|
isActive: Activo
|
||||||
hasKgPrice: Precio en kg
|
hasKgPrice: Precio en kg
|
||||||
isFragile: Frágil
|
isFragile: Frágil
|
||||||
isFragileTooltip: Se muestra en la web, app que este artículo no puede viajar (coronas, palmas, ...)
|
isFragileTooltip: Se muestra en la web, app que este artículo no puede viajar (coronas, palmas, ...)
|
||||||
isPhotoRequested: Hacer foto
|
isPhotoRequested: Hacer foto
|
||||||
isPhotoRequestedTooltip: Este artículo necesita una foto
|
isPhotoRequestedTooltip: Este artículo necesita una foto
|
||||||
isCustomInspectionRequired: Necesita inspección física (PIF)
|
isCustomInspectionRequired: Necesita insp. física (PIF)
|
||||||
description: Descripción
|
description: Descripción
|
||||||
|
photoMotivation: Comentario para el fotógrafo
|
||||||
fixedPrice:
|
fixedPrice:
|
||||||
itemFk: ID Artículo
|
itemFk: ID Artículo
|
||||||
groupingPrice: Precio grouping
|
groupingPrice: Precio grouping
|
||||||
|
@ -203,6 +204,8 @@ item:
|
||||||
minSalesQuantity: Cantidad mínima de venta
|
minSalesQuantity: Cantidad mínima de venta
|
||||||
genus: Genus
|
genus: Genus
|
||||||
specie: Specie
|
specie: Specie
|
||||||
|
search: 'Buscar artículo'
|
||||||
|
searchInfo: 'Puedes buscar por id de artículo o código de barras'
|
||||||
regularizeStock: Regularizar stock
|
regularizeStock: Regularizar stock
|
||||||
buyRequest:
|
buyRequest:
|
||||||
ticketId: 'ID Ticket'
|
ticketId: 'ID Ticket'
|
||||||
|
|
|
@ -203,19 +203,6 @@ export default {
|
||||||
},
|
},
|
||||||
component: () => import('src/pages/Item/ItemRequest.vue'),
|
component: () => import('src/pages/Item/ItemRequest.vue'),
|
||||||
},
|
},
|
||||||
{
|
|
||||||
path: 'waste-breakdown',
|
|
||||||
name: 'WasteBreakdown',
|
|
||||||
meta: {
|
|
||||||
title: 'wasteBreakdown',
|
|
||||||
icon: 'vn:claims',
|
|
||||||
},
|
|
||||||
beforeEnter: (to, from, next) => {
|
|
||||||
next({ name: 'ItemList' });
|
|
||||||
window.location.href =
|
|
||||||
'https://grafana.verdnatura.es/d/TTNXQAxVk';
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
path: 'fixed-price',
|
path: 'fixed-price',
|
||||||
name: 'ItemFixedPrice',
|
name: 'ItemFixedPrice',
|
||||||
|
|
Loading…
Reference in New Issue