fix: refs #8388 improve table column widths

This commit is contained in:
Jorge Penadés 2025-01-31 12:53:38 +01:00
parent 0fcd969c97
commit 42b86f05ce
1 changed files with 23 additions and 9 deletions

View File

@ -117,7 +117,7 @@ const isNotEuro = (code) => code != 'EUR';
function taxRate(invoiceInTax) {
const sageTaxTypeId = invoiceInTax.taxTypeSageFk;
const taxRateSelection = sageTaxTypes.value.find(
(transaction) => transaction.id == sageTaxTypeId
(transaction) => transaction.id == sageTaxTypeId,
);
const taxTypeSage = taxRateSelection?.rate ?? 0;
const taxableBase = invoiceInTax?.taxableBase ?? 0;
@ -131,14 +131,14 @@ function autocompleteExpense(evt, row, col) {
const param = isNaN(val) ? row[col.model] : val;
const lookup = expenses.value.find(
({ id }) => id == useAccountShortToStandard(param)
({ id }) => id == useAccountShortToStandard(param),
);
expenseRef.value.vnSelectDialogRef.vnSelectRef.toggleOption(lookup);
}
const taxableBaseTotal = computed(() => {
return getTotal(invoiceInFormRef.value.formData, 'taxableBase', );
return getTotal(invoiceInFormRef.value.formData, 'taxableBase');
});
const taxRateTotal = computed(() => {
@ -147,13 +147,9 @@ const taxRateTotal = computed(() => {
});
});
const combinedTotal = computed(() => {
return +taxableBaseTotal.value + +taxRateTotal.value;
});
</script>
<template>
<FetchData
@ -283,7 +279,7 @@ const combinedTotal = computed(() => {
row.taxableBase = await getExchange(
val,
row.currencyFk,
invoiceIn.issued
invoiceIn.issued,
);
}
"
@ -462,6 +458,24 @@ const combinedTotal = computed(() => {
border-radius: 50px;
background-color: $primary;
}
.q-table tbody tr td {
&:nth-child(3),
&:nth-child(6),
&:nth-child(7),
&:nth-child(8) {
width: 105px;
}
// &:nth-child(8) {
// width: 30px;
// }
&:nth-child(2) {
max-width: 110px;
}
&:nth-child(4) {
max-width: 85px;
}
}
</style>
<i18n>
es: