Compare commits
8 Commits
dev
...
7065-testU
Author | SHA1 | Date |
---|---|---|
|
e41ed4eff5 | |
|
be894f52c1 | |
|
e77e96ffed | |
|
035979cb70 | |
|
828bb61f52 | |
|
9767668798 | |
|
4ad2f936e8 | |
|
85140999ab |
|
@ -1,9 +1,13 @@
|
|||
import { vi, describe, expect, it, beforeEach, beforeAll, afterEach } from 'vitest';
|
||||
import { vi, describe, expect, it, beforeEach, afterEach } from 'vitest';
|
||||
import { createWrapper } from 'app/test/vitest/helper';
|
||||
import UserPanel from 'src/components/UserPanel.vue';
|
||||
import axios from 'axios';
|
||||
import { useState } from 'src/composables/useState';
|
||||
|
||||
vi.mock('src/utils/quasarLang', () => ({
|
||||
default: vi.fn(),
|
||||
}));
|
||||
|
||||
describe('UserPanel', () => {
|
||||
let wrapper;
|
||||
let vm;
|
||||
|
@ -39,7 +43,7 @@ describe('UserPanel', () => {
|
|||
await vm.saveDarkMode(true);
|
||||
expect(axios.patch).toHaveBeenCalledWith('/UserConfigs/115', { darkMode: true });
|
||||
expect(vm.user.darkMode).toBe(true);
|
||||
vm.updatePreferences();
|
||||
await vm.updatePreferences();
|
||||
expect(vm.darkMode).toBe(true);
|
||||
});
|
||||
|
||||
|
@ -48,7 +52,7 @@ describe('UserPanel', () => {
|
|||
await vm.saveLanguage(userLanguage);
|
||||
expect(axios.patch).toHaveBeenCalledWith('/VnUsers/115', { lang: userLanguage });
|
||||
expect(vm.user.lang).toBe(userLanguage);
|
||||
vm.updatePreferences();
|
||||
await vm.updatePreferences();
|
||||
expect(vm.locale).toBe(userLanguage);
|
||||
});
|
||||
|
||||
|
|
|
@ -171,8 +171,7 @@ onMounted(() => {
|
|||
});
|
||||
|
||||
const arrayDataKey =
|
||||
$props.dataKey ??
|
||||
($props.url?.length > 0 ? $props.url : ($attrs.name ?? $attrs.label));
|
||||
$props.dataKey ?? ($props.url?.length > 0 ? $props.url : $attrs.name ?? $attrs.label);
|
||||
|
||||
const arrayData = useArrayData(arrayDataKey, {
|
||||
url: $props.url,
|
||||
|
@ -221,7 +220,7 @@ async function fetchFilter(val) {
|
|||
optionFilterValue.value ??
|
||||
(new RegExp(/\d/g).test(val)
|
||||
? optionValue.value
|
||||
: (optionFilter.value ?? optionLabel.value));
|
||||
: optionFilter.value ?? optionLabel.value);
|
||||
|
||||
let defaultWhere = {};
|
||||
if ($props.filterOptions.length) {
|
||||
|
@ -240,7 +239,7 @@ async function fetchFilter(val) {
|
|||
|
||||
const { data } = await arrayData.applyFilter(
|
||||
{ filter: filterOptions },
|
||||
{ updateRouter: false },
|
||||
{ updateRouter: false }
|
||||
);
|
||||
setOptions(data);
|
||||
return data;
|
||||
|
@ -273,7 +272,7 @@ async function filterHandler(val, update) {
|
|||
ref.setOptionIndex(-1);
|
||||
ref.moveOptionSelection(1, true);
|
||||
}
|
||||
},
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -309,7 +308,7 @@ function handleKeyDown(event) {
|
|||
if (inputValue) {
|
||||
const matchingOption = myOptions.value.find(
|
||||
(option) =>
|
||||
option[optionLabel.value].toLowerCase() === inputValue.toLowerCase(),
|
||||
option[optionLabel.value].toLowerCase() === inputValue.toLowerCase()
|
||||
);
|
||||
|
||||
if (matchingOption) {
|
||||
|
@ -321,11 +320,11 @@ function handleKeyDown(event) {
|
|||
}
|
||||
|
||||
const focusableElements = document.querySelectorAll(
|
||||
'a:not([disabled]), button:not([disabled]), input:not([disabled]), textarea:not([disabled]), select:not([disabled]), details:not([disabled]), [tabindex]:not([tabindex="-1"]):not([disabled])',
|
||||
'a:not([disabled]), button:not([disabled]), input:not([disabled]), textarea:not([disabled]), select:not([disabled]), details:not([disabled]), [tabindex]:not([tabindex="-1"]):not([disabled])'
|
||||
);
|
||||
const currentIndex = Array.prototype.indexOf.call(
|
||||
focusableElements,
|
||||
event.target,
|
||||
event.target
|
||||
);
|
||||
if (currentIndex >= 0 && currentIndex < focusableElements.length - 1) {
|
||||
focusableElements[currentIndex + 1].focus();
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
<script setup>
|
||||
import { computed } from 'vue';
|
||||
import VnSelect from 'components/common/VnSelect.vue';
|
||||
|
||||
const model = defineModel({ type: [String, Number, Object] });
|
||||
const url = 'Suppliers';
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
@ -9,11 +11,10 @@ const model = defineModel({ type: [String, Number, Object] });
|
|||
:label="$t('globals.supplier')"
|
||||
v-bind="$attrs"
|
||||
v-model="model"
|
||||
url="Suppliers"
|
||||
:url="url"
|
||||
option-value="id"
|
||||
option-label="nickname"
|
||||
:fields="['id', 'name', 'nickname', 'nif']"
|
||||
:filter-options="['id', 'name', 'nickname', 'nif']"
|
||||
sort-by="name ASC"
|
||||
>
|
||||
<template #option="scope">
|
||||
|
|
|
@ -352,7 +352,7 @@ globals:
|
|||
from: Desde
|
||||
to: Hasta
|
||||
supplierFk: Proveedor
|
||||
supplierRef: Nº factura
|
||||
supplierRef: Ref. proveedor
|
||||
serial: Serie
|
||||
amount: Importe
|
||||
awbCode: AWB
|
||||
|
|
|
@ -125,7 +125,7 @@ function deleteFile(dmsFk) {
|
|||
<VnInput
|
||||
clearable
|
||||
clear-icon="close"
|
||||
:label="t('invoiceIn.supplierRef')"
|
||||
:label="t('Supplier ref')"
|
||||
v-model="data.supplierRef"
|
||||
/>
|
||||
</VnRow>
|
||||
|
@ -310,6 +310,7 @@ function deleteFile(dmsFk) {
|
|||
supplierFk: Supplier
|
||||
es:
|
||||
supplierFk: Proveedor
|
||||
Supplier ref: Ref. proveedor
|
||||
Expedition date: Fecha expedición
|
||||
Operation date: Fecha operación
|
||||
Undeductible VAT: Iva no deducible
|
||||
|
|
|
@ -186,7 +186,7 @@ const createInvoiceInCorrection = async () => {
|
|||
clickable
|
||||
@click="book(entityId)"
|
||||
>
|
||||
<QItemSection>{{ t('invoiceIn.descriptorMenu.book') }}</QItemSection>
|
||||
<QItemSection>{{ t('invoiceIn.descriptorMenu.toBook') }}</QItemSection>
|
||||
</QItem>
|
||||
</template>
|
||||
</InvoiceInToBook>
|
||||
|
@ -197,7 +197,7 @@ const createInvoiceInCorrection = async () => {
|
|||
@click="triggerMenu('unbook')"
|
||||
>
|
||||
<QItemSection>
|
||||
{{ t('invoiceIn.descriptorMenu.unbook') }}
|
||||
{{ t('invoiceIn.descriptorMenu.toUnbook') }}
|
||||
</QItemSection>
|
||||
</QItem>
|
||||
<QItem
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<script setup>
|
||||
import { ref, computed, onBeforeMount } from 'vue';
|
||||
import { ref, computed } from 'vue';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
import axios from 'axios';
|
||||
|
@ -12,7 +12,6 @@ import VnSelect from 'src/components/common/VnSelect.vue';
|
|||
import useNotify from 'src/composables/useNotify.js';
|
||||
import VnInputDate from 'src/components/common/VnInputDate.vue';
|
||||
import VnInputNumber from 'src/components/common/VnInputNumber.vue';
|
||||
import { toCurrency } from 'filters/index';
|
||||
|
||||
const route = useRoute();
|
||||
const { notify } = useNotify();
|
||||
|
@ -27,7 +26,7 @@ const invoiceInFormRef = ref();
|
|||
const invoiceId = +route.params.id;
|
||||
const filter = { where: { invoiceInFk: invoiceId } };
|
||||
const areRows = ref(false);
|
||||
const totals = ref();
|
||||
|
||||
const columns = computed(() => [
|
||||
{
|
||||
name: 'duedate',
|
||||
|
@ -67,8 +66,6 @@ const columns = computed(() => [
|
|||
},
|
||||
]);
|
||||
|
||||
const totalAmount = computed(() => getTotal(invoiceInFormRef.value.formData, 'amount'));
|
||||
|
||||
const isNotEuro = (code) => code != 'EUR';
|
||||
|
||||
async function insert() {
|
||||
|
@ -76,10 +73,6 @@ async function insert() {
|
|||
await invoiceInFormRef.value.reload();
|
||||
notify(t('globals.dataSaved'), 'positive');
|
||||
}
|
||||
|
||||
onBeforeMount(async () => {
|
||||
totals.value = (await axios.get(`InvoiceIns/${invoiceId}/getTotals`)).data;
|
||||
});
|
||||
</script>
|
||||
<template>
|
||||
<FetchData
|
||||
|
@ -160,7 +153,7 @@ onBeforeMount(async () => {
|
|||
<QTd />
|
||||
<QTd />
|
||||
<QTd>
|
||||
{{ toCurrency(totalAmount) }}
|
||||
{{ getTotal(rows, 'amount', { currency: 'default' }) }}
|
||||
</QTd>
|
||||
<QTd>
|
||||
<template v-if="isNotEuro(invoiceIn.currency.code)">
|
||||
|
@ -242,16 +235,7 @@ onBeforeMount(async () => {
|
|||
v-shortcut="'+'"
|
||||
size="lg"
|
||||
round
|
||||
@click="
|
||||
() => {
|
||||
if (!areRows) insert();
|
||||
else
|
||||
invoiceInFormRef.insert({
|
||||
amount: (totals.totalTaxableBase - totalAmount).toFixed(2),
|
||||
invoiceInFk: invoiceId,
|
||||
});
|
||||
}
|
||||
"
|
||||
@click="!areRows ? insert() : invoiceInFormRef.insert()"
|
||||
/>
|
||||
</QPageSticky>
|
||||
</template>
|
||||
|
|
|
@ -193,7 +193,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
|||
<InvoiceIntoBook>
|
||||
<template #content="{ book }">
|
||||
<QBtn
|
||||
:label="t('Book')"
|
||||
:label="t('To book')"
|
||||
color="orange-11"
|
||||
text-color="black"
|
||||
@click="book(entityId)"
|
||||
|
@ -224,7 +224,10 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
|||
</span>
|
||||
</template>
|
||||
</VnLv>
|
||||
<VnLv :label="t('invoiceIn.supplierRef')" :value="entity.supplierRef" />
|
||||
<VnLv
|
||||
:label="t('invoiceIn.list.supplierRef')"
|
||||
:value="entity.supplierRef"
|
||||
/>
|
||||
<VnLv
|
||||
:label="t('invoiceIn.summary.currency')"
|
||||
:value="entity.currency?.code"
|
||||
|
@ -354,7 +357,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
|||
entity.totals.totalTaxableBaseForeignValue &&
|
||||
toCurrency(
|
||||
entity.totals.totalTaxableBaseForeignValue,
|
||||
currency,
|
||||
currency
|
||||
)
|
||||
}}</QTd>
|
||||
</QTr>
|
||||
|
@ -389,7 +392,7 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
|||
entity.totals.totalDueDayForeignValue &&
|
||||
toCurrency(
|
||||
entity.totals.totalDueDayForeignValue,
|
||||
currency,
|
||||
currency
|
||||
)
|
||||
}}
|
||||
</QTd>
|
||||
|
@ -469,5 +472,5 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
|||
Search invoice: Buscar factura recibida
|
||||
You can search by invoice reference: Puedes buscar por referencia de la factura
|
||||
Totals: Totales
|
||||
Book: Contabilizar
|
||||
To book: Contabilizar
|
||||
</i18n>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<script setup>
|
||||
import { ref, computed, nextTick } from 'vue';
|
||||
import { ref, computed } from 'vue';
|
||||
import { useRoute } from 'vue-router';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
import { useArrayData } from 'src/composables/useArrayData';
|
||||
|
@ -25,6 +25,7 @@ const sageTaxTypes = ref([]);
|
|||
const sageTransactionTypes = ref([]);
|
||||
const rowsSelected = ref([]);
|
||||
const invoiceInFormRef = ref();
|
||||
const expenseRef = ref();
|
||||
|
||||
defineProps({
|
||||
actionIcon: {
|
||||
|
@ -96,20 +97,6 @@ const columns = computed(() => [
|
|||
},
|
||||
]);
|
||||
|
||||
const taxableBaseTotal = computed(() => {
|
||||
return getTotal(invoiceInFormRef.value.formData, 'taxableBase');
|
||||
});
|
||||
|
||||
const taxRateTotal = computed(() => {
|
||||
return getTotal(invoiceInFormRef.value.formData, null, {
|
||||
cb: taxRate,
|
||||
});
|
||||
});
|
||||
|
||||
const combinedTotal = computed(() => {
|
||||
return +taxableBaseTotal.value + +taxRateTotal.value;
|
||||
});
|
||||
|
||||
const filter = {
|
||||
fields: [
|
||||
'id',
|
||||
|
@ -138,7 +125,7 @@ function taxRate(invoiceInTax) {
|
|||
return ((taxTypeSage / 100) * taxableBase).toFixed(2);
|
||||
}
|
||||
|
||||
function autocompleteExpense(evt, row, col, ref) {
|
||||
function autocompleteExpense(evt, row, col) {
|
||||
const val = evt.target.value;
|
||||
if (!val) return;
|
||||
|
||||
|
@ -147,17 +134,22 @@ function autocompleteExpense(evt, row, col, ref) {
|
|||
({ id }) => id == useAccountShortToStandard(param),
|
||||
);
|
||||
|
||||
ref.vnSelectDialogRef.vnSelectRef.toggleOption(lookup);
|
||||
expenseRef.value.vnSelectDialogRef.vnSelectRef.toggleOption(lookup);
|
||||
}
|
||||
|
||||
function setCursor(ref) {
|
||||
nextTick(() => {
|
||||
const select = ref.vnSelectDialogRef
|
||||
? ref.vnSelectDialogRef.vnSelectRef
|
||||
: ref.vnSelectRef;
|
||||
select.$el.querySelector('input').setSelectionRange(0, 0);
|
||||
const taxableBaseTotal = computed(() => {
|
||||
return getTotal(invoiceInFormRef.value.formData, 'taxableBase');
|
||||
});
|
||||
|
||||
const taxRateTotal = computed(() => {
|
||||
return getTotal(invoiceInFormRef.value.formData, null, {
|
||||
cb: taxRate,
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
const combinedTotal = computed(() => {
|
||||
return +taxableBaseTotal.value + +taxRateTotal.value;
|
||||
});
|
||||
</script>
|
||||
<template>
|
||||
<FetchData
|
||||
|
@ -195,24 +187,14 @@ function setCursor(ref) {
|
|||
<template #body-cell-expense="{ row, col }">
|
||||
<QTd>
|
||||
<VnSelectDialog
|
||||
:ref="`expenseRef-${row.$index}`"
|
||||
ref="expenseRef"
|
||||
v-model="row[col.model]"
|
||||
:options="col.options"
|
||||
:option-value="col.optionValue"
|
||||
:option-label="col.optionLabel"
|
||||
:filter-options="['id', 'name']"
|
||||
:tooltip="t('Create a new expense')"
|
||||
@keydown.tab="
|
||||
autocompleteExpense(
|
||||
$event,
|
||||
row,
|
||||
col,
|
||||
$refs[`expenseRef-${row.$index}`],
|
||||
)
|
||||
"
|
||||
@update:model-value="
|
||||
setCursor($refs[`expenseRef-${row.$index}`])
|
||||
"
|
||||
@keydown.tab="autocompleteExpense($event, row, col)"
|
||||
>
|
||||
<template #option="scope">
|
||||
<QItem v-bind="scope.itemProps">
|
||||
|
@ -228,7 +210,7 @@ function setCursor(ref) {
|
|||
</QTd>
|
||||
</template>
|
||||
<template #body-cell-taxablebase="{ row }">
|
||||
<QTd shrink>
|
||||
<QTd>
|
||||
<VnInputNumber
|
||||
clear-icon="close"
|
||||
v-model="row.taxableBase"
|
||||
|
@ -239,16 +221,12 @@ function setCursor(ref) {
|
|||
<template #body-cell-sageiva="{ row, col }">
|
||||
<QTd>
|
||||
<VnSelect
|
||||
:ref="`sageivaRef-${row.$index}`"
|
||||
v-model="row[col.model]"
|
||||
:options="col.options"
|
||||
:option-value="col.optionValue"
|
||||
:option-label="col.optionLabel"
|
||||
:filter-options="['id', 'vat']"
|
||||
data-cy="vat-sageiva"
|
||||
@update:model-value="
|
||||
setCursor($refs[`sageivaRef-${row.$index}`])
|
||||
"
|
||||
>
|
||||
<template #option="scope">
|
||||
<QItem v-bind="scope.itemProps">
|
||||
|
@ -266,15 +244,11 @@ function setCursor(ref) {
|
|||
<template #body-cell-sagetransaction="{ row, col }">
|
||||
<QTd>
|
||||
<VnSelect
|
||||
:ref="`sagetransactionRef-${row.$index}`"
|
||||
v-model="row[col.model]"
|
||||
:options="col.options"
|
||||
:option-value="col.optionValue"
|
||||
:option-label="col.optionLabel"
|
||||
:filter-options="['id', 'transaction']"
|
||||
@update:model-value="
|
||||
setCursor($refs[`sagetransactionRef-${row.$index}`])
|
||||
"
|
||||
>
|
||||
<template #option="scope">
|
||||
<QItem v-bind="scope.itemProps">
|
||||
|
@ -292,7 +266,7 @@ function setCursor(ref) {
|
|||
</QTd>
|
||||
</template>
|
||||
<template #body-cell-foreignvalue="{ row }">
|
||||
<QTd shrink>
|
||||
<QTd>
|
||||
<VnInputNumber
|
||||
:class="{
|
||||
'no-pointer-events': !isNotEuro(currency),
|
||||
|
|
|
@ -56,7 +56,7 @@ const cols = computed(() => [
|
|||
{
|
||||
align: 'left',
|
||||
name: 'supplierRef',
|
||||
label: t('invoiceIn.supplierRef'),
|
||||
label: t('invoiceIn.list.supplierRef'),
|
||||
},
|
||||
{
|
||||
align: 'left',
|
||||
|
@ -177,7 +177,7 @@ const cols = computed(() => [
|
|||
:required="true"
|
||||
/>
|
||||
<VnInput
|
||||
:label="t('invoiceIn.supplierRef')"
|
||||
:label="t('invoiceIn.list.supplierRef')"
|
||||
v-model="data.supplierRef"
|
||||
/>
|
||||
<VnSelect
|
||||
|
|
|
@ -4,7 +4,6 @@ import { useQuasar } from 'quasar';
|
|||
import { useI18n } from 'vue-i18n';
|
||||
import VnConfirm from 'src/components/ui/VnConfirm.vue';
|
||||
import { useArrayData } from 'src/composables/useArrayData';
|
||||
import qs from 'qs';
|
||||
const { notify, dialog } = useQuasar();
|
||||
const { t } = useI18n();
|
||||
|
||||
|
@ -13,51 +12,29 @@ defineExpose({ checkToBook });
|
|||
const { store } = useArrayData();
|
||||
|
||||
async function checkToBook(id) {
|
||||
let messages = [];
|
||||
|
||||
const hasProblemWithTax = (
|
||||
await axios.get('InvoiceInTaxes/count', {
|
||||
params: {
|
||||
where: JSON.stringify({
|
||||
invoiceInFk: id,
|
||||
or: [{ taxTypeSageFk: null }, { transactionTypeSageFk: null }],
|
||||
}),
|
||||
},
|
||||
})
|
||||
).data?.count;
|
||||
|
||||
if (hasProblemWithTax)
|
||||
messages.push(t('The VAT and Transaction fields have not been informed'));
|
||||
let directBooking = true;
|
||||
|
||||
const { data: totals } = await axios.get(`InvoiceIns/${id}/getTotals`);
|
||||
const taxableBaseNotEqualDueDay = totals.totalDueDay != totals.totalTaxableBase;
|
||||
const vatNotEqualDueDay = totals.totalDueDay != totals.totalVat;
|
||||
|
||||
if (taxableBaseNotEqualDueDay && vatNotEqualDueDay)
|
||||
messages.push(t('The sum of the taxable bases does not match the due dates'));
|
||||
if (taxableBaseNotEqualDueDay && vatNotEqualDueDay) directBooking = false;
|
||||
|
||||
const dueDaysCount = (
|
||||
await axios.get('InvoiceInDueDays/count', {
|
||||
params: {
|
||||
where: JSON.stringify({
|
||||
const { data: dueDaysCount } = await axios.get('InvoiceInDueDays/count', {
|
||||
where: {
|
||||
invoiceInFk: id,
|
||||
dueDated: { gte: Date.vnNew() },
|
||||
}),
|
||||
},
|
||||
})
|
||||
).data?.count;
|
||||
});
|
||||
|
||||
if (dueDaysCount) messages.push(t('Some due dates are less than or equal to today'));
|
||||
if (dueDaysCount) directBooking = false;
|
||||
|
||||
if (directBooking) return toBook(id);
|
||||
|
||||
if (!messages.length) toBook(id);
|
||||
else
|
||||
dialog({
|
||||
component: VnConfirm,
|
||||
componentProps: {
|
||||
title: t('Are you sure you want to book this invoice?'),
|
||||
message: messages.reduce((acc, msg) => `${acc}<p>${msg}</p>`, ''),
|
||||
},
|
||||
}).onOk(() => toBook(id));
|
||||
componentProps: { title: t('Are you sure you want to book this invoice?') },
|
||||
}).onOk(async () => await toBook(id));
|
||||
}
|
||||
|
||||
async function toBook(id) {
|
||||
|
@ -82,7 +59,4 @@ async function toBook(id) {
|
|||
es:
|
||||
Are you sure you want to book this invoice?: ¿Estás seguro de querer asentar esta factura?
|
||||
It was not able to book the invoice: No se pudo contabilizar la factura
|
||||
Some due dates are less than or equal to today: Algún vencimiento tiene una fecha menor o igual que hoy
|
||||
The sum of the taxable bases does not match the due dates: La suma de las bases imponibles no coincide con la de los vencimientos
|
||||
The VAT and Transaction fields have not been informed: No se han informado los campos de iva y/o transacción
|
||||
</i18n>
|
||||
|
|
|
@ -3,10 +3,10 @@ invoiceIn:
|
|||
searchInfo: Search incoming invoices by ID or supplier fiscal name
|
||||
serial: Serial
|
||||
isBooked: Is booked
|
||||
supplierRef: Invoice nº
|
||||
list:
|
||||
ref: Reference
|
||||
supplier: Supplier
|
||||
supplierRef: Supplier ref.
|
||||
file: File
|
||||
issued: Issued
|
||||
dueDated: Due dated
|
||||
|
@ -19,6 +19,8 @@ invoiceIn:
|
|||
unbook: Unbook
|
||||
delete: Delete
|
||||
clone: Clone
|
||||
toBook: To book
|
||||
toUnbook: To unbook
|
||||
deleteInvoice: Delete invoice
|
||||
invoiceDeleted: invoice deleted
|
||||
cloneInvoice: Clone invoice
|
||||
|
@ -68,3 +70,4 @@ invoiceIn:
|
|||
isBooked: Is booked
|
||||
account: Ledger account
|
||||
correctingFk: Rectificative
|
||||
|
|
@ -3,10 +3,10 @@ invoiceIn:
|
|||
searchInfo: Buscar facturas recibidas por ID o nombre fiscal del proveedor
|
||||
serial: Serie
|
||||
isBooked: Contabilizada
|
||||
supplierRef: Nº factura
|
||||
list:
|
||||
ref: Referencia
|
||||
supplier: Proveedor
|
||||
supplierRef: Ref. proveedor
|
||||
issued: F. emisión
|
||||
dueDated: F. vencimiento
|
||||
file: Fichero
|
||||
|
@ -15,10 +15,12 @@ invoiceIn:
|
|||
descriptor:
|
||||
ticketList: Listado de tickets
|
||||
descriptorMenu:
|
||||
book: Contabilizar
|
||||
unbook: Descontabilizar
|
||||
book: Asentar
|
||||
unbook: Desasentar
|
||||
delete: Eliminar
|
||||
clone: Clonar
|
||||
toBook: Contabilizar
|
||||
toUnbook: Descontabilizar
|
||||
deleteInvoice: Eliminar factura
|
||||
invoiceDeleted: Factura eliminada
|
||||
cloneInvoice: Clonar factura
|
||||
|
@ -66,3 +68,4 @@ invoiceIn:
|
|||
isBooked: Contabilizada
|
||||
account: Cuenta contable
|
||||
correctingFk: Rectificativa
|
||||
|
||||
|
|
|
@ -65,19 +65,10 @@ const columns = computed(() => [
|
|||
name: 'name',
|
||||
...defaultColumnAttrs,
|
||||
create: true,
|
||||
columnFilter: {
|
||||
component: 'select',
|
||||
attrs: {
|
||||
url: 'Items',
|
||||
fields: ['id', 'name', 'subName'],
|
||||
optionLabel: 'name',
|
||||
optionValue: 'name',
|
||||
uppercase: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
label: t('item.fixedPrice.groupingPrice'),
|
||||
field: 'rate2',
|
||||
name: 'rate2',
|
||||
...defaultColumnAttrs,
|
||||
component: 'input',
|
||||
|
@ -85,6 +76,7 @@ const columns = computed(() => [
|
|||
},
|
||||
{
|
||||
label: t('item.fixedPrice.packingPrice'),
|
||||
field: 'rate3',
|
||||
name: 'rate3',
|
||||
...defaultColumnAttrs,
|
||||
component: 'input',
|
||||
|
@ -93,6 +85,7 @@ const columns = computed(() => [
|
|||
|
||||
{
|
||||
label: t('item.fixedPrice.minPrice'),
|
||||
field: 'minPrice',
|
||||
name: 'minPrice',
|
||||
...defaultColumnAttrs,
|
||||
component: 'input',
|
||||
|
@ -115,6 +108,7 @@ const columns = computed(() => [
|
|||
},
|
||||
{
|
||||
label: t('item.fixedPrice.ended'),
|
||||
field: 'ended',
|
||||
name: 'ended',
|
||||
...defaultColumnAttrs,
|
||||
columnField: {
|
||||
|
@ -130,6 +124,7 @@ const columns = computed(() => [
|
|||
|
||||
{
|
||||
label: t('globals.warehouse'),
|
||||
field: 'warehouseFk',
|
||||
name: 'warehouseFk',
|
||||
...defaultColumnAttrs,
|
||||
columnClass: 'shrink',
|
||||
|
@ -420,6 +415,7 @@ function handleOnDataSave({ CrudModelRef }) {
|
|||
'row-key': 'id',
|
||||
selection: 'multiple',
|
||||
}"
|
||||
:use-model="true"
|
||||
v-model:selected="rowsSelected"
|
||||
:create-as-dialog="false"
|
||||
:create="{
|
||||
|
|
|
@ -107,10 +107,7 @@ export default defineRouter(function (/* { store, ssrContext } */) {
|
|||
'Failed to fetch dynamically imported module',
|
||||
'Importing a module script failed',
|
||||
];
|
||||
state.set(
|
||||
'error',
|
||||
errorMessages.some((error) => message.startsWith(error)),
|
||||
);
|
||||
state.set('error', errorMessages.some(message.includes));
|
||||
});
|
||||
return Router;
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue