feat: refs #8277 add entry type selection and localization to EntryControl
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
This commit is contained in:
parent
e00fae2412
commit
234269bdef
|
@ -9,6 +9,7 @@ import VnSelectSupplier from 'src/components/common/VnSelectSupplier.vue';
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const companies = ref([]);
|
const companies = ref([]);
|
||||||
const countries = ref([]);
|
const countries = ref([]);
|
||||||
|
const entryTypes = ref([]);
|
||||||
const columns = computed(() => [
|
const columns = computed(() => [
|
||||||
{
|
{
|
||||||
name: 'company',
|
name: 'company',
|
||||||
|
@ -81,7 +82,6 @@ const columns = computed(() => [
|
||||||
component: markRaw(VnSelectSupplier),
|
component: markRaw(VnSelectSupplier),
|
||||||
label: null,
|
label: null,
|
||||||
name: 'supplierFk',
|
name: 'supplierFk',
|
||||||
url: 'Suppliers',
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -89,13 +89,21 @@ const columns = computed(() => [
|
||||||
label: t('globals.country'),
|
label: t('globals.country'),
|
||||||
columnFilter: {
|
columnFilter: {
|
||||||
component: 'select',
|
component: 'select',
|
||||||
name: 'country',
|
name: 'countryFk',
|
||||||
options: countries.value,
|
options: countries.value,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'description',
|
name: 'description',
|
||||||
label: t('globals.description'),
|
label: t('entry.control.entryType'),
|
||||||
|
columnFilter: {
|
||||||
|
component: 'select',
|
||||||
|
label: null,
|
||||||
|
name: 'typeFk',
|
||||||
|
options: entryTypes.value,
|
||||||
|
optionLabel: 'description',
|
||||||
|
optionValue: 'code',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'payDem',
|
name: 'payDem',
|
||||||
|
@ -105,6 +113,10 @@ const columns = computed(() => [
|
||||||
name: 'amount',
|
name: 'amount',
|
||||||
label: t('globals.amount'),
|
label: t('globals.amount'),
|
||||||
format: ({ amount }) => toCurrency(amount),
|
format: ({ amount }) => toCurrency(amount),
|
||||||
|
columnFilter: {
|
||||||
|
component: 'number',
|
||||||
|
name: 'amount',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'isBooked',
|
name: 'isBooked',
|
||||||
|
@ -129,10 +141,10 @@ const columns = computed(() => [
|
||||||
// label: t('entry.agencyMode'),
|
// label: t('entry.agencyMode'),
|
||||||
// format: (row) => row.agencyMode,
|
// format: (row) => row.agencyMode,
|
||||||
// },
|
// },
|
||||||
// {
|
{
|
||||||
// name: 'isAgricultural',
|
name: 'isAgricultural',
|
||||||
// label: t('entry.isAgricultural'),
|
label: t('entry.isAgricultural'),
|
||||||
// },
|
},
|
||||||
// {
|
// {
|
||||||
// name: 'account',
|
// name: 'account',
|
||||||
// label: t('globals.account'),
|
// label: t('globals.account'),
|
||||||
|
@ -156,15 +168,20 @@ const columns = computed(() => [
|
||||||
@on-fetch="(data) => (companies = data)"
|
@on-fetch="(data) => (companies = data)"
|
||||||
auto-load
|
auto-load
|
||||||
/>
|
/>
|
||||||
|
<FetchData
|
||||||
|
url="EntryTypes"
|
||||||
|
:filter="{ fields: ['code', 'description'] }"
|
||||||
|
@on-fetch="(data) => (entryTypes = data)"
|
||||||
|
auto-load
|
||||||
|
/>
|
||||||
<VnTable
|
<VnTable
|
||||||
data-key="entryControl"
|
data-key="entryControl"
|
||||||
url="Entries/control"
|
url="Entries/control"
|
||||||
:columns
|
:columns
|
||||||
auto-load
|
auto-load
|
||||||
:right-search="false"
|
|
||||||
:disable-option="{ card: true }"
|
:disable-option="{ card: true }"
|
||||||
redirect="Entry"
|
redirect="Entry"
|
||||||
:order="['landed DESC']"
|
:order="['landed DESC']"
|
||||||
>
|
:right-search="false"
|
||||||
</VnTable>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -133,6 +133,7 @@ entry:
|
||||||
payDem: Payment term
|
payDem: Payment term
|
||||||
isBooked: B
|
isBooked: B
|
||||||
received: R
|
received: R
|
||||||
|
entryType: Entry type
|
||||||
entryFilter:
|
entryFilter:
|
||||||
params:
|
params:
|
||||||
isExcludedFromAvailable: Excluded from available
|
isExcludedFromAvailable: Excluded from available
|
||||||
|
|
|
@ -83,6 +83,7 @@ entry:
|
||||||
payDem: Plazo de pago
|
payDem: Plazo de pago
|
||||||
isBooked: C
|
isBooked: C
|
||||||
received: R
|
received: R
|
||||||
|
entryType: Tipo de entrada
|
||||||
params:
|
params:
|
||||||
entryFk: Entrada
|
entryFk: Entrada
|
||||||
observationTypeFk: Tipo de observación
|
observationTypeFk: Tipo de observación
|
||||||
|
|
Loading…
Reference in New Issue