7383-testToMaster #370
|
@ -22,6 +22,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||||
- (Tickets) => Se añade la opción de clonar ticket. #6951
|
- (Tickets) => Se añade la opción de clonar ticket. #6951
|
||||||
- (Parking) => Se añade la sección Parking. #5186
|
- (Parking) => Se añade la sección Parking. #5186
|
||||||
|
|
||||||
|
- (Rutas) => Se añade el campo "servida" a la tabla y se añade también a los filtros. #7130
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
|
|
@ -127,7 +127,6 @@ async function paginate() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function endPagination() {
|
function endPagination() {
|
||||||
hasMoreData.value = arrayData.hasMoreData.value;
|
|
||||||
isLoading.value = false;
|
isLoading.value = false;
|
||||||
emit('onFetch', store.data);
|
emit('onFetch', store.data);
|
||||||
emit('onPaginate');
|
emit('onPaginate');
|
||||||
|
@ -183,11 +182,12 @@ defineExpose({ fetch, addFilter });
|
||||||
</QCard>
|
</QCard>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<QInfiniteScroll
|
<QInfiniteScroll
|
||||||
v-if="store.data"
|
v-if="store.data"
|
||||||
@load="onLoad"
|
@load="onLoad"
|
||||||
:offset="offset"
|
:offset="offset"
|
||||||
:disable="disableInfiniteScroll || !arrayData.hasMoreData.value"
|
:disable="disableInfiniteScroll || !arrayData.hasMoreData"
|
||||||
class="full-width"
|
class="full-width"
|
||||||
v-bind="$attrs"
|
v-bind="$attrs"
|
||||||
>
|
>
|
||||||
|
|
|
@ -98,7 +98,7 @@ export function useArrayData(key, userOptions) {
|
||||||
const { limit } = filter;
|
const { limit } = filter;
|
||||||
|
|
||||||
hasMoreData.value = response.data.length >= limit;
|
hasMoreData.value = response.data.length >= limit;
|
||||||
|
store.hasMoreData = hasMoreData.value;
|
||||||
if (append) {
|
if (append) {
|
||||||
if (!store.data) store.data = [];
|
if (!store.data) store.data = [];
|
||||||
for (const row of response.data) store.data.push(row);
|
for (const row of response.data) store.data.push(row);
|
||||||
|
@ -169,7 +169,7 @@ export function useArrayData(key, userOptions) {
|
||||||
}
|
}
|
||||||
|
|
||||||
async function loadMore() {
|
async function loadMore() {
|
||||||
if (!hasMoreData.value) return;
|
if (!hasMoreData.value && !store.hasMoreData) return;
|
||||||
|
|
||||||
store.skip = store.limit * page.value;
|
store.skip = store.limit * page.value;
|
||||||
page.value += 1;
|
page.value += 1;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
customerFilter:
|
customerFilter:
|
||||||
filter:
|
filter:
|
||||||
name: 'Name'
|
name: Name
|
||||||
socialName: 'Social name'
|
socialName: Social name
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
customerFilter:
|
customerFilter:
|
||||||
filter:
|
filter:
|
||||||
name: 'Nombre'
|
name: Nombre
|
||||||
socialName: 'Razón Social'
|
socialName: Razón Social
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
import { ref } from 'vue';
|
import { ref } from 'vue';
|
||||||
import { useRoute } from 'vue-router';
|
import { useRoute } from 'vue-router';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
|
import { useRole } from 'src/composables/useRole';
|
||||||
|
|
||||||
import FetchData from 'components/FetchData.vue';
|
import FetchData from 'components/FetchData.vue';
|
||||||
import FormModel from 'components/FormModel.vue';
|
import FormModel from 'components/FormModel.vue';
|
||||||
|
@ -15,6 +16,8 @@ import { toDate } from 'src/filters';
|
||||||
|
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
|
const { hasAny } = useRole();
|
||||||
|
const isAdministrative = () => hasAny(['administrative']);
|
||||||
|
|
||||||
const suppliersOptions = ref([]);
|
const suppliersOptions = ref([]);
|
||||||
const travelsOptions = ref([]);
|
const travelsOptions = ref([]);
|
||||||
|
@ -206,6 +209,7 @@ const onFilterTravelSelected = (formData, id) => {
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<QCheckbox
|
<QCheckbox
|
||||||
|
v-if="isAdministrative()"
|
||||||
v-model="data.isBooked"
|
v-model="data.isBooked"
|
||||||
:label="t('entry.basicData.booked')"
|
:label="t('entry.basicData.booked')"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
entryList:
|
entryList:
|
||||||
list:
|
list:
|
||||||
inventoryEntry: 'Inventory entry'
|
inventoryEntry: Inventory entry
|
||||||
virtualEntry: 'Virtual entry'
|
virtualEntry: Virtual entry
|
||||||
entryFilter:
|
entryFilter:
|
||||||
filter:
|
filter:
|
||||||
search: 'General search'
|
search: General search
|
||||||
reference: 'Reference'
|
reference: Reference
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
entryList:
|
entryList:
|
||||||
list:
|
list:
|
||||||
inventoryEntry: 'Es inventario'
|
inventoryEntry: Es inventario
|
||||||
virtualEntry: 'Es una redada'
|
virtualEntry: Es una redada
|
||||||
entryFilter:
|
entryFilter:
|
||||||
filter:
|
filter:
|
||||||
search: 'Búsqueda general'
|
search: Búsqueda general
|
||||||
reference: 'Referencia'
|
reference: Referencia
|
||||||
|
|
|
@ -257,7 +257,7 @@ const requiredFieldRule = (val) => val || t('globals.requiredField');
|
||||||
const isAdministrative = () => hasAny(['administrative']);
|
const isAdministrative = () => hasAny(['administrative']);
|
||||||
|
|
||||||
const isAgricultural = () =>
|
const isAgricultural = () =>
|
||||||
invoiceIn.value.supplier.sageWithholdingFk == config.value[0].sageWithholdingFk;
|
invoiceIn.value?.supplier?.sageWithholdingFk === config.value[0]?.sageWithholdingFk;
|
||||||
|
|
||||||
function showPdfInvoice() {
|
function showPdfInvoice() {
|
||||||
if (isAgricultural()) openReport(`InvoiceIns/${entityId.value}/invoice-in-pdf`);
|
if (isAgricultural()) openReport(`InvoiceIns/${entityId.value}/invoice-in-pdf`);
|
||||||
|
|
|
@ -197,6 +197,15 @@ const warehouseList = ref([]);
|
||||||
/>
|
/>
|
||||||
</QItemSection>
|
</QItemSection>
|
||||||
</QItem>
|
</QItem>
|
||||||
|
<QItem>
|
||||||
|
<QItemSection>
|
||||||
|
<QCheckbox
|
||||||
|
v-model="params.isOk"
|
||||||
|
:label="t('Served')"
|
||||||
|
toggle-indeterminate
|
||||||
|
/>
|
||||||
|
</QItemSection>
|
||||||
|
</QItem>
|
||||||
</template>
|
</template>
|
||||||
</VnFilterPanel>
|
</VnFilterPanel>
|
||||||
</template>
|
</template>
|
||||||
|
@ -212,6 +221,7 @@ en:
|
||||||
workerFk: Worker
|
workerFk: Worker
|
||||||
from: From
|
from: From
|
||||||
to: To
|
to: To
|
||||||
|
Served: Served
|
||||||
es:
|
es:
|
||||||
params:
|
params:
|
||||||
warehouseFk: Almacén
|
warehouseFk: Almacén
|
||||||
|
@ -229,4 +239,5 @@ es:
|
||||||
Worker: Trabajador
|
Worker: Trabajador
|
||||||
From: Desde
|
From: Desde
|
||||||
To: Hasta
|
To: Hasta
|
||||||
|
Served: Servida
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
|
@ -11,8 +11,8 @@ import VnInputDate from 'components/common/VnInputDate.vue';
|
||||||
import VnInput from 'components/common/VnInput.vue';
|
import VnInput from 'components/common/VnInput.vue';
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import VnInputTime from 'components/common/VnInputTime.vue';
|
import VnInputTime from 'components/common/VnInputTime.vue';
|
||||||
import RouteSearchbar from "pages/Route/Card/RouteSearchbar.vue";
|
import RouteSearchbar from 'pages/Route/Card/RouteSearchbar.vue';
|
||||||
import {useStateStore} from "stores/useStateStore";
|
import { useStateStore } from 'stores/useStateStore';
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
|
@ -26,6 +26,7 @@ const defaultInitialData = {
|
||||||
description: '',
|
description: '',
|
||||||
vehicleFk: null,
|
vehicleFk: null,
|
||||||
workerFk: null,
|
workerFk: null,
|
||||||
|
isOk: false,
|
||||||
};
|
};
|
||||||
|
|
||||||
const workerList = ref([]);
|
const workerList = ref([]);
|
||||||
|
@ -211,6 +212,7 @@ const onSave = (data, response) => {
|
||||||
size="sm"
|
size="sm"
|
||||||
v-model="data.isOk"
|
v-model="data.isOk"
|
||||||
:label="t('Is served')"
|
:label="t('Is served')"
|
||||||
|
clearable
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</VnRow>
|
</VnRow>
|
||||||
|
|
|
@ -187,6 +187,15 @@ const ticketColumns = ref([
|
||||||
:label="t('route.summary.packages')"
|
:label="t('route.summary.packages')"
|
||||||
:value="getTotalPackages(entity.tickets)"
|
:value="getTotalPackages(entity.tickets)"
|
||||||
/>
|
/>
|
||||||
|
<QCheckbox
|
||||||
|
:label="
|
||||||
|
entity.route.isOk
|
||||||
|
? t('route.summary.closed')
|
||||||
|
: t('route.summary.open')
|
||||||
|
"
|
||||||
|
v-model="entity.route.isOk"
|
||||||
|
:disable="true"
|
||||||
|
/>
|
||||||
</QCard>
|
</QCard>
|
||||||
<QCard class="vn-one">
|
<QCard class="vn-one">
|
||||||
<div class="header">
|
<div class="header">
|
||||||
|
@ -278,6 +287,10 @@ en:
|
||||||
m3: m³
|
m3: m³
|
||||||
packaging: Packaging
|
packaging: Packaging
|
||||||
ticket: Ticket
|
ticket: Ticket
|
||||||
|
closed: Closed
|
||||||
|
open: Open
|
||||||
|
yes: Yes
|
||||||
|
no: No
|
||||||
es:
|
es:
|
||||||
route:
|
route:
|
||||||
summary:
|
summary:
|
||||||
|
@ -301,4 +314,8 @@ es:
|
||||||
client: Cliente
|
client: Cliente
|
||||||
warehouse: Almacén
|
warehouse: Almacén
|
||||||
packaging: Encajado
|
packaging: Encajado
|
||||||
|
closed: Cerrada
|
||||||
|
open: Abierta
|
||||||
|
yes: Sí
|
||||||
|
no: No
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
|
@ -95,6 +95,13 @@ const columns = computed(() => [
|
||||||
sortable: true,
|
sortable: true,
|
||||||
align: 'left',
|
align: 'left',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'isServed',
|
||||||
|
label: t('Served'),
|
||||||
|
field: (row) => Boolean(row.isOk),
|
||||||
|
sortable: true,
|
||||||
|
align: 'left',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'actions',
|
name: 'actions',
|
||||||
label: '',
|
label: '',
|
||||||
|
@ -265,7 +272,7 @@ const openTicketsDialog = (id) => {
|
||||||
auto-load
|
auto-load
|
||||||
>
|
>
|
||||||
<template #body="{ rows }">
|
<template #body="{ rows }">
|
||||||
<div class="q-pa-md">
|
<div class="q-pa-md route-table">
|
||||||
<QTable
|
<QTable
|
||||||
v-model:selected="selectedRows"
|
v-model:selected="selectedRows"
|
||||||
:columns="columns"
|
:columns="columns"
|
||||||
|
@ -279,7 +286,7 @@ const openTicketsDialog = (id) => {
|
||||||
:no-data-label="t('globals.noResults')"
|
:no-data-label="t('globals.noResults')"
|
||||||
>
|
>
|
||||||
<template #body-cell-worker="{ row }">
|
<template #body-cell-worker="{ row }">
|
||||||
<QTd>
|
<QTd class="table-input-cell">
|
||||||
<VnSelectFilter
|
<VnSelectFilter
|
||||||
:label="t('Worker')"
|
:label="t('Worker')"
|
||||||
v-model="row.workerFk"
|
v-model="row.workerFk"
|
||||||
|
@ -312,7 +319,7 @@ const openTicketsDialog = (id) => {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-agency="{ row }">
|
<template #body-cell-agency="{ row }">
|
||||||
<QTd>
|
<QTd class="table-input-cell">
|
||||||
<VnSelectFilter
|
<VnSelectFilter
|
||||||
:label="t('Agency')"
|
:label="t('Agency')"
|
||||||
v-model="row.agencyModeFk"
|
v-model="row.agencyModeFk"
|
||||||
|
@ -329,7 +336,7 @@ const openTicketsDialog = (id) => {
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
<template #body-cell-vehicle="{ row }">
|
<template #body-cell-vehicle="{ row }">
|
||||||
<QTd>
|
<QTd class="table-input-cell">
|
||||||
<VnSelectFilter
|
<VnSelectFilter
|
||||||
:label="t('Vehicle')"
|
:label="t('Vehicle')"
|
||||||
v-model="row.vehicleFk"
|
v-model="row.vehicleFk"
|
||||||
|
@ -397,6 +404,19 @@ const openTicketsDialog = (id) => {
|
||||||
/>
|
/>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
|
<template #body-cell-isServed="props">
|
||||||
|
<QTd>
|
||||||
|
<QCheckbox v-model="props.value" disable>
|
||||||
|
<QTooltip>
|
||||||
|
{{
|
||||||
|
props.value
|
||||||
|
? t('Route is closed')
|
||||||
|
: t('Route is not served')
|
||||||
|
}}
|
||||||
|
</QTooltip>
|
||||||
|
</QCheckbox>
|
||||||
|
</QTd>
|
||||||
|
</template>
|
||||||
<template #body-cell-actions="props">
|
<template #body-cell-actions="props">
|
||||||
<QTd :props="props">
|
<QTd :props="props">
|
||||||
<div class="flex items-center no-wrap table-actions">
|
<div class="flex items-center no-wrap table-actions">
|
||||||
|
@ -455,7 +475,7 @@ const openTicketsDialog = (id) => {
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.table-input-cell {
|
.table-input-cell {
|
||||||
min-width: 150px;
|
max-width: 143px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.route-list {
|
.route-list {
|
||||||
|
@ -466,6 +486,11 @@ const openTicketsDialog = (id) => {
|
||||||
.table-actions {
|
.table-actions {
|
||||||
gap: 12px;
|
gap: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.lock-icon-cell {
|
||||||
|
text-align: center;
|
||||||
|
margin-left: -20%;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<i18n>
|
<i18n>
|
||||||
en:
|
en:
|
||||||
|
@ -479,6 +504,7 @@ es:
|
||||||
Description: Descripción
|
Description: Descripción
|
||||||
Hour started: Hora inicio
|
Hour started: Hora inicio
|
||||||
Hour finished: Hora fin
|
Hour finished: Hora fin
|
||||||
|
Served: Servida
|
||||||
newRoute: Nueva Ruta
|
newRoute: Nueva Ruta
|
||||||
Clone Selected Routes: Clonar rutas seleccionadas
|
Clone Selected Routes: Clonar rutas seleccionadas
|
||||||
Select the starting date: Seleccione la fecha de inicio
|
Select the starting date: Seleccione la fecha de inicio
|
||||||
|
@ -490,4 +516,6 @@ es:
|
||||||
Add ticket: Añadir tickets
|
Add ticket: Añadir tickets
|
||||||
Preview: Vista previa
|
Preview: Vista previa
|
||||||
Summary: Resumen
|
Summary: Resumen
|
||||||
|
Route is closed: La ruta está cerrada
|
||||||
|
Route is not served: La ruta no está servida
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
travelFilter:
|
travelFilter:
|
||||||
filter:
|
filter:
|
||||||
warehouseOutFk: 'Warehouse Out'
|
warehouseOutFk: Warehouse Out
|
||||||
warehouseInFk: 'Warehouse In'
|
warehouseInFk: Warehouse In
|
||||||
agencyModeFk: 'Agency'
|
agencyModeFk: Agency
|
||||||
scopeDays: 'Days onward'
|
scopeDays: Days onward
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
travelFilter:
|
travelFilter:
|
||||||
filter:
|
filter:
|
||||||
warehouseInFk: 'Alm. entrada'
|
warehouseInFk: Alm. entrada
|
||||||
warehouseOutFk: 'Alm. salida'
|
warehouseOutFk: Alm. salida
|
||||||
agencyModeFk: 'Agencia'
|
agencyModeFk: Agencia
|
||||||
scopeDays: 'Días adelante'
|
scopeDays: Días adelante
|
||||||
|
|
|
@ -27,7 +27,10 @@ export default defineConfig({
|
||||||
sassVariables: 'src/quasar-variables.scss',
|
sassVariables: 'src/quasar-variables.scss',
|
||||||
}),
|
}),
|
||||||
VueI18nPlugin({
|
VueI18nPlugin({
|
||||||
include: path.resolve(__dirname, 'src/i18n/**'),
|
include: [
|
||||||
|
path.resolve(__dirname, 'src/i18n/**'),
|
||||||
|
path.resolve(__dirname, 'src/pages/**/locale/**'),
|
||||||
|
],
|
||||||
}),
|
}),
|
||||||
jsconfigPaths(),
|
jsconfigPaths(),
|
||||||
],
|
],
|
||||||
|
|
Loading…
Reference in New Issue