pcpuma_unam_operador/components/inputs/InputCorreo.vue

47 lines
1.0 KiB
Vue
Raw Normal View History

2022-08-29 02:56:55 +00:00
<template>
2022-08-29 12:46:09 +00:00
<b-field
:class="column ? `column ${columnSize} mb-0 pb-0` : ''"
:label="label || 'Correo'"
>
2022-08-29 02:56:55 +00:00
<b-input
icon="email"
placeholder="Correo"
2022-08-29 12:46:09 +00:00
type="email"
:disabled="disabled"
2022-08-29 02:56:55 +00:00
@keyup.enter.native="ejecutar()"
v-model="correo"
rounded
/>
</b-field>
</template>
<script>
export default {
props: {
2022-08-29 12:46:09 +00:00
column: { type: Boolean, required: false, default: false },
disabled: { type: Boolean, required: false, default: false },
2022-08-29 13:09:35 +00:00
ejecutar: {
typeof: Function,
required: false,
default: () => function () {},
},
2022-08-29 02:56:55 +00:00
correoPadre: { typeof: String, required: true, default: '' },
columnSize: { typeof: String, required: false, default: '' },
2022-08-29 12:46:09 +00:00
label: { typeof: String, required: false, default: '' },
2022-08-29 02:56:55 +00:00
},
data: () => {
return { correo: '' }
},
watch: {
correo() {
this.$emit('correo', this.correo)
},
correoPadre() {
this.correo = this.correoPadre
},
},
}
</script>
<style scoped></style>