perf: Mobile phone is set as a required field

This commit is contained in:
zhaojisen 2024-06-19 11:27:55 +08:00
parent e4c7b1d8cf
commit 1e82ca3f66
7 changed files with 18 additions and 36 deletions

View File

@ -1,6 +1,6 @@
<template> <template>
<div> <div>
<el-input v-model="rawValue.phone" :placeholder="$tc('InputPhone')" @input="OnInputChange"> <el-input v-model="rawValue.phone" required :placeholder="$tc('InputPhone')" @input="OnInputChange">
<el-select <el-select
slot="prepend" slot="prepend"
:placeholder="$tc('Select')" :placeholder="$tc('Select')"

View File

@ -5,6 +5,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { PhoneInput, UpdateToken } from '@/components/Form/FormFields' import { PhoneInput, UpdateToken } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'CMPP2', name: 'CMPP2',
@ -57,6 +58,7 @@ export default {
component: UpdateToken component: UpdateToken
}, },
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },
@ -64,12 +66,6 @@ export default {
return 'patch' return 'patch'
} }
} }
}, }
computed: {},
methods: {}
} }
</script> </script>
<style scoped>
</style>

View File

@ -5,6 +5,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { PhoneInput, UpdateToken } from '@/components/Form/FormFields' import { PhoneInput, UpdateToken } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'SMSAlibaba', name: 'SMSAlibaba',
@ -64,6 +65,7 @@ export default {
component: UpdateToken component: UpdateToken
}, },
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },

View File

@ -5,6 +5,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { JsonEditor, PhoneInput } from '@/components/Form/FormFields' import { JsonEditor, PhoneInput } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'SMSCustom', name: 'SMSCustom',
@ -56,6 +57,7 @@ export default {
helpText: this.$t('CustomParams') helpText: this.$t('CustomParams')
}, },
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },
@ -63,12 +65,6 @@ export default {
return 'patch' return 'patch'
} }
} }
}, }
computed: {},
methods: {}
} }
</script> </script>
<style scoped>
</style>

View File

@ -8,6 +8,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { PhoneInput } from '@/components/Form/FormFields' import { PhoneInput } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'SMSFileCustom', name: 'SMSFileCustom',
@ -49,6 +50,7 @@ export default {
], ],
fieldsMeta: { fieldsMeta: {
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },
@ -56,12 +58,6 @@ export default {
return 'patch' return 'patch'
} }
} }
}, }
computed: {},
methods: {}
} }
</script> </script>
<style scoped>
</style>

View File

@ -5,6 +5,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { PhoneInput, UpdateToken } from '@/components/Form/FormFields' import { PhoneInput, UpdateToken } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'SMSHuawei', name: 'SMSHuawei',
@ -72,6 +73,7 @@ export default {
label: this.$t('AppEndpoint') label: this.$t('AppEndpoint')
}, },
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },
@ -79,12 +81,6 @@ export default {
return 'put' return 'put'
} }
} }
}, }
computed: {},
methods: {}
} }
</script> </script>
<style scoped>
</style>

View File

@ -5,6 +5,7 @@
<script> <script>
import BaseSMS from './Base.vue' import BaseSMS from './Base.vue'
import { PhoneInput, UpdateToken } from '@/components/Form/FormFields' import { PhoneInput, UpdateToken } from '@/components/Form/FormFields'
import { Required } from '@/components/Form/DataForm/rules'
export default { export default {
name: 'SMSTencent', name: 'SMSTencent',
@ -64,6 +65,7 @@ export default {
component: UpdateToken component: UpdateToken
}, },
SMS_TEST_PHONE: { SMS_TEST_PHONE: {
rules: [Required],
component: PhoneInput component: PhoneInput
} }
}, },
@ -71,12 +73,6 @@ export default {
return 'put' return 'put'
} }
} }
}, }
computed: {},
methods: {}
} }
</script> </script>
<style scoped>
</style>