0
0
Fork 0

refs: #6764 rename VnSelect

This commit is contained in:
jcasado 2024-04-25 08:34:40 +02:00
parent 716dd4e28f
commit aa58838ad7
14 changed files with 67 additions and 63 deletions

View File

@ -7,7 +7,7 @@ import axios from 'axios';
import { useState } from 'src/composables/useState';
import { useSession } from 'src/composables/useSession';
import { localeEquivalence } from 'src/i18n/index';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnRow from 'components/ui/VnRow.vue';
import FetchData from 'components/FetchData.vue';
@ -172,24 +172,24 @@ function copyUserToken() {
<QSeparator inset class="q-mx-lg" />
<div class="col q-gutter-xs q-pa-md">
<VnRow>
<VnSelectFilter
<VnSelect
:label="t('components.userPanel.localWarehouse')"
v-model="user.localWarehouseFk"
:options="warehousesData"
option-label="name"
option-value="id"
/>
<VnSelectFilter
<VnSelect
:label="t('components.userPanel.localBank')"
hide-selected
v-model="user.localBankFk"
:options="accountBankData"
option-label="bank"
option-value="id"
></VnSelectFilter>
></VnSelect>
</VnRow>
<VnRow>
<VnSelectFilter
<VnSelect
:label="t('components.userPanel.localCompany')"
hide-selected
v-model="user.companyFk"
@ -197,7 +197,7 @@ function copyUserToken() {
option-label="code"
option-value="id"
/>
<VnSelectFilter
<VnSelect
:label="t('components.userPanel.userWarehouse')"
hide-selected
v-model="user.warehouseFk"
@ -207,7 +207,7 @@ function copyUserToken() {
/>
</VnRow>
<VnRow>
<VnSelectFilter
<VnSelect
:label="t('components.userPanel.userCompany')"
hide-selected
v-model="user.companyFk"

View File

@ -97,7 +97,7 @@ function handleLocation(data, location) {
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
</VnSelect>
</div>
</VnRow>

View File

@ -9,7 +9,7 @@ import FetchData from 'components/FetchData.vue';
import FormModel from 'components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnSelectDialog from 'src/components/common/VnSelectDialog.vue';
import CustomerCreateNewPostcode from 'src/components/CreateNewPostcodeForm.vue';
import CustomerNewCustomsAgent from 'src/pages/Customer/components/CustomerNewCustomsAgent.vue';
@ -101,7 +101,7 @@ function handleLocation(data, location) {
/>
<div class="row justify-between q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('Agency')"
:options="agencyModes"
:rules="validate('route.agencyFk')"
@ -121,7 +121,7 @@ function handleLocation(data, location) {
</div>
<VnRow class="row q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('Incoterms')"
:options="incoterms"
hide-selected

View File

@ -11,7 +11,7 @@ import useNotify from 'src/composables/useNotify';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
const { notify } = useNotify();
@ -152,7 +152,7 @@ const toCustomerFileManagement = () => {
/>
</div>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Company')"
:options="optionsCompanies"
:rules="validate('entry.companyFk')"
@ -165,7 +165,7 @@ const toCustomerFileManagement = () => {
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Warehouse')"
:options="optionsWarehouses"
option-label="name"
@ -174,7 +174,7 @@ const toCustomerFileManagement = () => {
/>
</div>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Type')"
:options="optionsDmsTypes"
option-label="name"

View File

@ -10,7 +10,7 @@ import useNotify from 'src/composables/useNotify';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
const { notify } = useNotify();
@ -128,7 +128,7 @@ const toCustomerFileManagement = () => {
/>
</div>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Company')"
:options="optionsCompanies"
:rules="validate('entry.companyFk')"
@ -141,7 +141,7 @@ const toCustomerFileManagement = () => {
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Warehouse')"
:options="optionsWarehouses"
option-label="name"
@ -150,7 +150,7 @@ const toCustomerFileManagement = () => {
/>
</div>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Type')"
:options="optionsDmsTypes"
option-label="name"

View File

@ -12,7 +12,7 @@ import useNotify from 'src/composables/useNotify';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnInputDate from 'src/components/common/VnInputDate.vue';
import CustomerSamplesPreview from 'src/pages/Customer/components/CustomerSamplesPreview.vue';
@ -253,7 +253,7 @@ const toCustomerSamples = () => {
<QCard class="card-width q-pa-lg">
<QForm>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Sample')"
:options="optionsSamplesVisible"
@update:model-value="setSampleType"
@ -306,7 +306,7 @@ const toCustomerSamples = () => {
v-if="sampleType?.hasCompany || sampleType?.datepickerEnabled"
>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Company')"
:options="optionsCompanies"
:rules="validate('entry.companyFk')"
@ -319,7 +319,7 @@ const toCustomerSamples = () => {
/>
</div>
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('Address')"
:options="optionsClientsAddressess"
hide-selected
@ -345,7 +345,7 @@ const toCustomerSamples = () => {
<QTooltip>{{ t('Edit address') }}</QTooltip>
</QIcon>
</template>
</VnSelectFilter>
</VnSelect>
</div>
</VnRow>

View File

@ -4,7 +4,7 @@ import { useI18n } from 'vue-i18n';
import { useRouter } from 'vue-router';
import FetchData from 'components/FetchData.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import FormModel from 'components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
@ -90,7 +90,7 @@ onBeforeMount(async () => {
v-model="data.provisionalName"
:label="t('item.create.name')"
/>
<VnSelectFilter
<VnSelect
:label="t('item.create.tag')"
v-model="data.tag"
:options="tagsOptions"
@ -98,7 +98,7 @@ onBeforeMount(async () => {
option-label="name"
hide-selected
/>
<VnSelectFilter
<VnSelect
:label="t('item.create.priority')"
v-model="data.priority"
:options="validPriorities"
@ -108,7 +108,7 @@ onBeforeMount(async () => {
/>
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('item.create.type')"
v-model="data.typeFk"
:options="itemTypesOptions"
@ -131,8 +131,8 @@ onBeforeMount(async () => {
</QItemLabel>
</QItem>
</template>
</VnSelectFilter>
<VnSelectFilter
</VnSelect>
<VnSelect
:label="t('item.create.intrastat')"
v-model="data.intrastatFk"
:options="intrastatsOptions"
@ -152,10 +152,10 @@ onBeforeMount(async () => {
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
</VnSelect>
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('item.create.origin')"
v-model="data.originFk"
:options="originsOptions"

View File

@ -7,7 +7,7 @@ import FetchData from 'components/FetchData.vue';
import FetchedTags from 'components/ui/FetchedTags.vue';
import TableVisibleColumns from 'src/components/common/TableVisibleColumns.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import ItemDescriptorProxy from '../Item/Card/ItemDescriptorProxy.vue';
import WorkerDescriptorProxy from 'src/pages/Worker/Card/WorkerDescriptorProxy.vue';
import ItemSummary from '../Item/Card/ItemSummary.vue';
@ -201,7 +201,7 @@ const columns = computed(() => [
align: 'left',
sortable: true,
columnFilter: {
component: VnSelectFilter,
component: VnSelect,
filterParamKey: 'typeFk',
type: 'select',
filterValue: null,
@ -222,7 +222,7 @@ const columns = computed(() => [
align: 'left',
sortable: true,
columnFilter: {
component: VnSelectFilter,
component: VnSelect,
type: 'select',
filterValue: null,
event: getInputEvents,
@ -242,7 +242,7 @@ const columns = computed(() => [
align: 'left',
sortable: true,
columnFilter: {
component: VnSelectFilter,
component: VnSelect,
type: 'select',
filterValue: null,
event: getInputEvents,
@ -261,7 +261,7 @@ const columns = computed(() => [
align: 'left',
sortable: true,
columnFilter: {
component: VnSelectFilter,
component: VnSelect,
type: 'select',
filterValue: null,
event: getInputEvents,
@ -280,7 +280,7 @@ const columns = computed(() => [
align: 'left',
sortable: true,
columnFilter: {
component: VnSelectFilter,
component: VnSelect,
filterParamKey: 'buyerFk',
type: 'select',
filterValue: null,

View File

@ -7,7 +7,7 @@ import FetchData from 'src/components/FetchData.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import VnInput from 'src/components/common/VnInput.vue';
import FormModel from 'components/FormModel.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
const { t } = useI18n();
const route = useRoute();
@ -40,7 +40,7 @@ const filter = {
<VnInput v-model="data.column" :label="t('parking.column')" />
</VnRow>
<VnRow>
<VnSelectFilter
<VnSelect
v-model="data.sectorFk"
option-value="id"
option-label="description"

View File

@ -4,7 +4,7 @@ import { useI18n } from 'vue-i18n';
import VnFilterPanel from 'components/ui/VnFilterPanel.vue';
import VnInput from 'components/common/VnInput.vue';
import FetchData from 'src/components/FetchData.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
const { t } = useI18n();
defineProps({
@ -45,7 +45,7 @@ const emit = defineEmits(['search']);
</QItem>
<QItem>
<QItemSection>
<VnSelectFilter
<VnSelect
v-model="params.sectorFk"
option-value="id"
option-label="description"

View File

@ -6,7 +6,7 @@ import { useI18n } from 'vue-i18n';
import FormModel from 'components/FormModel.vue';
import FetchData from 'components/FetchData.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnSelectFilter from 'components/common/VnSelectFilter.vue';
import VnSelect from 'components/common/VnSelect.vue';
import VnInputDate from 'components/common/VnInputDate.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
@ -134,7 +134,7 @@ const redirectToTicketList = (_, { id }) => {
<template #form="{ data }">
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('ticket.create.client')"
v-model="data.clientId"
:options="clientOptions"
@ -155,12 +155,12 @@ const redirectToTicketList = (_, { id }) => {
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
</VnSelect>
</div>
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('ticket.create.address')"
v-model="data.addressId"
:options="addressesOptions"
@ -182,7 +182,7 @@ const redirectToTicketList = (_, { id }) => {
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
</VnSelect>
</div>
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
@ -197,7 +197,7 @@ const redirectToTicketList = (_, { id }) => {
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('ticket.create.warehouse')"
v-model="data.warehouseId"
:options="warehousesOptions"
@ -210,7 +210,7 @@ const redirectToTicketList = (_, { id }) => {
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<div class="col">
<VnSelectFilter
<VnSelect
:label="t('ticket.create.agency')"
v-model="data.agencyModeId"
:options="agenciesOptions"

View File

@ -7,7 +7,7 @@ import FetchData from 'components/FetchData.vue';
import FormModel from 'src/components/FormModel.vue';
import VnRow from 'components/ui/VnRow.vue';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
const route = useRoute();
const { t } = useI18n();
@ -27,7 +27,7 @@ const workerFilter = {
},
{ relation: 'sip', scope: { fields: ['extension', 'secret'] } },
{ relation: 'department', scope: { include: { relation: 'department' } } },
{ relation: 'client', scope: {fields:['phone']} },
{ relation: 'client', scope: { fields: ['phone'] } },
],
};
const workersFilter = {
@ -87,11 +87,15 @@ const maritalStatus = [
:label="t('Mobile extension')"
clearable
/>
<VnInput v-model="data.client.phone" :label="t('Personal phone')" clearable />
<VnInput
v-model="data.client.phone"
:label="t('Personal phone')"
clearable
/>
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('Boss')"
:options="workersOptions"
hide-selected
@ -110,8 +114,8 @@ const maritalStatus = [
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
<VnSelectFilter
</VnSelect>
<VnSelect
:label="t('Marital status')"
:options="maritalStatus"
hide-selected
@ -122,7 +126,7 @@ const maritalStatus = [
</VnRow>
<VnRow class="row q-gutter-md q-mb-md">
<VnSelectFilter
<VnSelect
:label="t('Origin country')"
:options="countriesOptions"
hide-selected
@ -130,7 +134,7 @@ const maritalStatus = [
option-value="id"
v-model="data.originCountryFk"
/>
<VnSelectFilter
<VnSelect
:label="t('Education level')"
:options="educationLevelsOptions"
hide-selected

View File

@ -2,7 +2,7 @@
import WorkerEventLabel from 'pages/Worker/Card/WorkerEventLabel.vue';
import FetchData from 'components/FetchData.vue';
import { useI18n } from 'vue-i18n';
import VnSelectFilter from 'components/common/VnSelectFilter.vue';
import VnSelect from 'components/common/VnSelect.vue';
import { useRoute } from 'vue-router';
import { computed, ref } from 'vue';
import { toDateFormat } from '../../../filters/date';
@ -150,7 +150,7 @@ const yearList = ref(generateYears());
<QList dense class="list q-gutter-y-sm q-my-lg">
<QItem>
<QItemSection>
<VnSelectFilter
<VnSelect
:label="t('Year')"
v-model="selectedYear"
:options="yearList"
@ -164,7 +164,7 @@ const yearList = ref(generateYears());
</QItem>
<QItem>
<QItemSection>
<VnSelectFilter
<VnSelect
:label="t('Contract')"
v-model="selectedBusinessFk"
:options="contractList"
@ -191,7 +191,7 @@ const yearList = ref(generateYears());
</QItemSection>
</QItem>
</template>
</VnSelectFilter>
</VnSelect>
</QItemSection>
</QItem>
</QList>

View File

@ -3,7 +3,7 @@ import { reactive, ref, computed, onBeforeMount } from 'vue';
import { useI18n } from 'vue-i18n';
import { useRoute } from 'vue-router';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import VnSelect from 'src/components/common/VnSelect.vue';
import FormModelPopup from 'components/FormModelPopup.vue';
import VnInputTime from 'components/common/VnInputTime.vue';
@ -84,7 +84,7 @@ onBeforeMount(() => {
:required="true"
:is-clearable="false"
/>
<VnSelectFilter
<VnSelect
:label="t('Type')"
v-model="data.direction"
:options="entryDirections"