0
0
Fork 0

refs #5834 feat: replace QInput by VnInput

This commit is contained in:
Javier Segarra 2024-01-31 09:00:48 +01:00
parent 0287ec4932
commit fea618b213
1 changed files with 17 additions and 9 deletions

View File

@ -1,6 +1,7 @@
<script setup> <script setup>
import { reactive, ref } from 'vue'; import { reactive, ref } from 'vue';
import { useI18n } from 'vue-i18n'; import { useI18n } from 'vue-i18n';
import VnInput from 'src/components/common/VnInput.vue';
import VnSelectFilter from 'src/components/common/VnSelectFilter.vue'; import VnSelectFilter from 'src/components/common/VnSelectFilter.vue';
import FetchData from 'components/FetchData.vue'; import FetchData from 'components/FetchData.vue';
@ -54,16 +55,18 @@ const onDataSaved = (data) => {
<template #form-inputs="{ data, validate }"> <template #form-inputs="{ data, validate }">
<VnRow class="row q-gutter-md q-mb-md"> <VnRow class="row q-gutter-md q-mb-md">
<div class="col"> <div class="col">
<QInput <VnInput
:label="t('name')" :label="t('name')"
v-model="data.name" v-model="data.name"
:required="true"
:rules="validate('bankEntity.name')" :rules="validate('bankEntity.name')"
/> />
</div> </div>
<div class="col"> <div class="col">
<QInput <VnInput
:label="t('swift')" :label="t('swift')"
v-model="data.bic" v-model="data.bic"
:required="true"
:rules="validate('bankEntity.bic')" :rules="validate('bankEntity.bic')"
/> />
</div> </div>
@ -82,7 +85,12 @@ const onDataSaved = (data) => {
/> />
</div> </div>
<div v-if="showEntityField" class="col"> <div v-if="showEntityField" class="col">
<QInput :label="t('id')" v-model="data.id"/> <VnInput
:label="t('id')"
v-model="data.id"
:required="true"
:rules="validate('city.name')"
/>
</div> </div>
</VnRow> </VnRow>
</template> </template>
@ -93,15 +101,15 @@ const onDataSaved = (data) => {
en: en:
title: New bank entity title: New bank entity
subtitle: Please, ensure you put the correct data! subtitle: Please, ensure you put the correct data!
name: Name * name: Name
swift: Swift * swift: Swift
country: Country country: Country
id: Entity code * id: Entity code
es: es:
title: Nueva entidad bancaria title: Nueva entidad bancaria
subtitle: ¡Por favor, asegúrate de poner los datos correctos! subtitle: ¡Por favor, asegúrate de poner los datos correctos!
name: Nombre * name: Nombre
swift: Swift * swift: Swift
country: País country: País
id: Código de la entidad * id: Código de la entidad
</i18n> </i18n>