Merge branch 'dev' into 8118-createComponentVnDropdown
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
commit
44ec056cfa
|
@ -158,20 +158,12 @@ function deleteFile(dmsFk) {
|
||||||
</VnRow>
|
</VnRow>
|
||||||
<VnRow>
|
<VnRow>
|
||||||
<VnSelect
|
<VnSelect
|
||||||
:label="t('Undeductible VAT')"
|
:label="t('invoiceIn.summary.sage')"
|
||||||
v-model="data.deductibleExpenseFk"
|
v-model="data.withholdingSageFk"
|
||||||
:options="expenses"
|
:options="sageWithholdings"
|
||||||
option-value="id"
|
option-value="id"
|
||||||
option-label="id"
|
option-label="withholding"
|
||||||
:filter-options="['id', 'name']"
|
/>
|
||||||
data-cy="invoiceInBasicDataDeductibleExpenseFk"
|
|
||||||
>
|
|
||||||
<template #option="scope">
|
|
||||||
<QItem v-bind="scope.itemProps">
|
|
||||||
{{ `${scope.opt.id}: ${scope.opt.name}` }}
|
|
||||||
</QItem>
|
|
||||||
</template>
|
|
||||||
</VnSelect>
|
|
||||||
|
|
||||||
<div class="row no-wrap">
|
<div class="row no-wrap">
|
||||||
<VnInput
|
<VnInput
|
||||||
|
@ -271,16 +263,6 @@ function deleteFile(dmsFk) {
|
||||||
data-cy="invoiceInBasicDataCompanyFk"
|
data-cy="invoiceInBasicDataCompanyFk"
|
||||||
/>
|
/>
|
||||||
</VnRow>
|
</VnRow>
|
||||||
<VnRow>
|
|
||||||
<VnSelect
|
|
||||||
:label="t('invoiceIn.summary.sage')"
|
|
||||||
v-model="data.withholdingSageFk"
|
|
||||||
:options="sageWithholdings"
|
|
||||||
option-value="id"
|
|
||||||
option-label="withholding"
|
|
||||||
data-cy="invoiceInBasicDataWithholdingSageFk"
|
|
||||||
/>
|
|
||||||
</VnRow>
|
|
||||||
</template>
|
</template>
|
||||||
</FormModel>
|
</FormModel>
|
||||||
<QDialog v-model="documentDialogRef.show">
|
<QDialog v-model="documentDialogRef.show">
|
||||||
|
@ -332,7 +314,6 @@ function deleteFile(dmsFk) {
|
||||||
supplierFk: Proveedor
|
supplierFk: Proveedor
|
||||||
Expedition date: Fecha expedición
|
Expedition date: Fecha expedición
|
||||||
Operation date: Fecha operación
|
Operation date: Fecha operación
|
||||||
Undeductible VAT: Iva no deducible
|
|
||||||
Document: Documento
|
Document: Documento
|
||||||
Download file: Descargar archivo
|
Download file: Descargar archivo
|
||||||
Entry date: Fecha asiento
|
Entry date: Fecha asiento
|
||||||
|
|
|
@ -40,6 +40,13 @@ const vatColumns = ref([
|
||||||
sortable: true,
|
sortable: true,
|
||||||
align: 'left',
|
align: 'left',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'isDeductible',
|
||||||
|
label: 'invoiceIn.isDeductible',
|
||||||
|
field: (row) => row.isDeductible,
|
||||||
|
sortable: true,
|
||||||
|
align: 'center',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'vat',
|
name: 'vat',
|
||||||
label: 'invoiceIn.summary.sageVat',
|
label: 'invoiceIn.summary.sageVat',
|
||||||
|
@ -274,10 +281,6 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
:label="t('invoiceIn.summary.sage')"
|
:label="t('invoiceIn.summary.sage')"
|
||||||
:value="entity.sageWithholding?.withholding"
|
:value="entity.sageWithholding?.withholding"
|
||||||
/>
|
/>
|
||||||
<VnLv
|
|
||||||
:label="t('invoiceIn.summary.vat')"
|
|
||||||
:value="entity.expenseDeductible?.name"
|
|
||||||
/>
|
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('invoiceIn.card.company')"
|
:label="t('invoiceIn.card.company')"
|
||||||
:value="entity.company?.code"
|
:value="entity.company?.code"
|
||||||
|
@ -335,6 +338,15 @@ const getLink = (param) => `#/invoice-in/${entityId.value}/${param}`;
|
||||||
</QTh>
|
</QTh>
|
||||||
</QTr>
|
</QTr>
|
||||||
</template>
|
</template>
|
||||||
|
<template #body-cell-isDeductible="{ row }">
|
||||||
|
<QTd align="center">
|
||||||
|
<QCheckbox
|
||||||
|
v-model="row.isDeductible"
|
||||||
|
disable
|
||||||
|
data-cy="isDeductible_checkbox"
|
||||||
|
/>
|
||||||
|
</QTd>
|
||||||
|
</template>
|
||||||
<template #body-cell-vat="{ value: vatCell }">
|
<template #body-cell-vat="{ value: vatCell }">
|
||||||
<QTd :title="vatCell" shrink>
|
<QTd :title="vatCell" shrink>
|
||||||
{{ vatCell }}
|
{{ vatCell }}
|
||||||
|
|
|
@ -53,6 +53,13 @@ const columns = computed(() => [
|
||||||
sortable: true,
|
sortable: true,
|
||||||
align: 'left',
|
align: 'left',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'isDeductible',
|
||||||
|
label: t('invoiceIn.isDeductible'),
|
||||||
|
field: (row) => row.isDeductible,
|
||||||
|
model: 'isDeductible',
|
||||||
|
align: 'center',
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'sageiva',
|
name: 'sageiva',
|
||||||
label: t('Sage iva'),
|
label: t('Sage iva'),
|
||||||
|
@ -119,6 +126,7 @@ const filter = {
|
||||||
'foreignValue',
|
'foreignValue',
|
||||||
'taxTypeSageFk',
|
'taxTypeSageFk',
|
||||||
'transactionTypeSageFk',
|
'transactionTypeSageFk',
|
||||||
|
'isDeductible',
|
||||||
],
|
],
|
||||||
where: {
|
where: {
|
||||||
invoiceInFk: route.params.id,
|
invoiceInFk: route.params.id,
|
||||||
|
@ -230,6 +238,14 @@ function setCursor(ref) {
|
||||||
</VnSelectDialog>
|
</VnSelectDialog>
|
||||||
</QTd>
|
</QTd>
|
||||||
</template>
|
</template>
|
||||||
|
<template #body-cell-isDeductible="{ row }">
|
||||||
|
<QTd align="center">
|
||||||
|
<QCheckbox
|
||||||
|
v-model="row.isDeductible"
|
||||||
|
data-cy="isDeductible_checkbox"
|
||||||
|
/>
|
||||||
|
</QTd>
|
||||||
|
</template>
|
||||||
<template #body-cell-taxablebase="{ row }">
|
<template #body-cell-taxablebase="{ row }">
|
||||||
<QTd shrink>
|
<QTd shrink>
|
||||||
<VnInputNumber
|
<VnInputNumber
|
||||||
|
@ -324,6 +340,7 @@ function setCursor(ref) {
|
||||||
</QTd>
|
</QTd>
|
||||||
<QTd />
|
<QTd />
|
||||||
<QTd />
|
<QTd />
|
||||||
|
<QTd />
|
||||||
<QTd>
|
<QTd>
|
||||||
{{ toCurrency(taxRateTotal) }}
|
{{ toCurrency(taxRateTotal) }}
|
||||||
</QTd>
|
</QTd>
|
||||||
|
|
|
@ -4,6 +4,7 @@ invoiceIn:
|
||||||
serial: Serial
|
serial: Serial
|
||||||
isBooked: Is booked
|
isBooked: Is booked
|
||||||
supplierRef: Invoice nº
|
supplierRef: Invoice nº
|
||||||
|
isDeductible: Deductible
|
||||||
list:
|
list:
|
||||||
ref: Reference
|
ref: Reference
|
||||||
supplier: Supplier
|
supplier: Supplier
|
||||||
|
|
|
@ -4,6 +4,7 @@ invoiceIn:
|
||||||
serial: Serie
|
serial: Serie
|
||||||
isBooked: Contabilizada
|
isBooked: Contabilizada
|
||||||
supplierRef: Nº factura
|
supplierRef: Nº factura
|
||||||
|
isDeductible: Deducible
|
||||||
list:
|
list:
|
||||||
ref: Referencia
|
ref: Referencia
|
||||||
supplier: Proveedor
|
supplier: Proveedor
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
/// <reference types="cypress" />
|
/// <reference types="cypress" />
|
||||||
describe('InvoiceInVat', () => {
|
describe('InvoiceInVat', () => {
|
||||||
const thirdRow = 'tbody > :nth-child(3)';
|
const thirdRow = 'tbody > :nth-child(3)';
|
||||||
const firstLineVat = 'tbody > :nth-child(1) > :nth-child(4)';
|
const firstLineVat = 'tbody > :nth-child(1) ';
|
||||||
const vats = '[data-cy="vat-sageiva"]';
|
const vats = '[data-cy="vat-sageiva"]';
|
||||||
const dialogInputs = '.q-dialog label input';
|
const dialogInputs = '.q-dialog label input';
|
||||||
const addBtn = 'tbody tr:nth-child(1) td:nth-child(2) .--add-icon';
|
const addBtn = 'tbody tr:nth-child(1) td:nth-child(2) .--add-icon';
|
||||||
|
@ -18,6 +18,17 @@ describe('InvoiceInVat', () => {
|
||||||
cy.get(vats).eq(0).should('have.value', '8: H.P. IVA 21% CEE');
|
cy.get(vats).eq(0).should('have.value', '8: H.P. IVA 21% CEE');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('should mark the line as deductible VAT', () => {
|
||||||
|
cy.get(`${firstLineVat} [data-cy="isDeductible_checkbox"]`).click();
|
||||||
|
|
||||||
|
cy.saveCard();
|
||||||
|
|
||||||
|
cy.get(`${firstLineVat} [data-cy="isDeductible_checkbox"]`)
|
||||||
|
|
||||||
|
.click();
|
||||||
|
cy.saveCard();
|
||||||
|
});
|
||||||
|
|
||||||
it('should add a new row', () => {
|
it('should add a new row', () => {
|
||||||
cy.addRow();
|
cy.addRow();
|
||||||
cy.fillRow(thirdRow, [true, 2000000001, 30, 'H.P. IVA 10']);
|
cy.fillRow(thirdRow, [true, 2000000001, 30, 'H.P. IVA 10']);
|
||||||
|
|
Loading…
Reference in New Issue