refactor(EntryPreAccount): refs #8277 rename accountType to fiscalCode and update related data fetching
gitea/salix-front/pipeline/pr-dev This commit is unstable Details

This commit is contained in:
Jorge Penadés 2025-04-17 16:27:00 +02:00
parent 412e04b1ff
commit 200b1ab329
3 changed files with 16 additions and 14 deletions

View File

@ -39,7 +39,7 @@ const table = useTemplateRef('table');
const companies = ref([]);
const countries = ref([]);
const entryTypes = ref([]);
const entryAccounts = ref([]);
const supplierFiscalTypes = ref([]);
const warehouses = ref([]);
const defaultDmsDescription = ref();
const dmsTypeId = ref();
@ -165,13 +165,14 @@ const columns = computed(() => [
},
},
{
name: 'accountType',
label: t('entry.preAccount.accountType'),
name: 'fiscalCode',
label: t('entry.preAccount.fiscalCode'),
format: ({ fiscalCode }) => t(fiscalCode),
columnFilter: {
component: 'select',
name: 'accountType',
options: entryAccounts.value,
optionLabel: 'type',
name: 'fiscalCode',
options: supplierFiscalTypes.value,
optionLabel: 'locale',
optionValue: 'code',
sortBy: 'code',
},
@ -327,10 +328,11 @@ async function createInvoice() {
auto-load
/>
<FetchData
url="EntryAccounts"
:filter="{ fields: ['code', 'type'] }"
url="supplierFiscalTypes"
:filter="{ fields: ['code'] }"
@on-fetch="
(data) => (entryAccounts = data.map((x) => ({ ...x, type: t(x.type) })))
(data) =>
(supplierFiscalTypes = data.map((x) => ({ locale: t(x.code), ...x })))
"
auto-load
/>
@ -466,10 +468,10 @@ async function createInvoice() {
en:
IntraCommunity: Intra-community
NonCommunity: Non-community
CanaryIsland: Canary Islands
CanaryIslands: Canary Islands
es:
IntraCommunity: Intracomunitario
NonCommunity: Extracomunitario
IntraCommunity: Intracomunitaria
NonCommunity: Extracomunitaria
CanaryIsland: Islas Canarias
National: Nacional
</i18n>

View File

@ -135,7 +135,7 @@ entry:
isReceived: R
entryType: Entry type
isAgricultural: Agricultural
accountType: Account type
fiscalCode: Account type
daysAgo: Max 365 days
search: Search
searchInfo: You can search by supplier name or nickname

View File

@ -86,7 +86,7 @@ entry:
isReceived: R
entryType: Tipo de entrada
isAgricultural: Agricultural
accountType: Tipo de cuenta
fiscalCode: Tipo de cuenta
daysAgo: Máximo 365 días
search: Buscar
searchInfo: Puedes buscar por nombre o alias de proveedor