refactor: 移除身份证照片
This commit is contained in:
@@ -38,7 +38,7 @@
|
|||||||
v-model="form.cardnum"
|
v-model="form.cardnum"
|
||||||
/>
|
/>
|
||||||
</view>
|
</view>
|
||||||
<view class="py-15 text-14">
|
<!-- <view class="py-15 text-14">
|
||||||
<view class="flex items-center">
|
<view class="flex items-center">
|
||||||
<image src="@/static/images/page-sub/realname/realname-card.png" class="w-20 h-20" />
|
<image src="@/static/images/page-sub/realname/realname-card.png" class="w-20 h-20" />
|
||||||
<view class="ml-8">证件照片</view>
|
<view class="ml-8">证件照片</view>
|
||||||
@@ -67,7 +67,7 @@
|
|||||||
<image :src="fcardimage" class="w-315 h-168" mode="aspectFit" />
|
<image :src="fcardimage" class="w-315 h-168" mode="aspectFit" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
</view>
|
</view>
|
||||||
<view class="fixed bottom-0 left-0 right-0 pb-safe">
|
<view class="fixed bottom-0 left-0 right-0 pb-safe">
|
||||||
<button class="btn-gradient text-white rounded-full m-15 text-16" @click="onSubmit">
|
<button class="btn-gradient text-white rounded-full m-15 text-16" @click="onSubmit">
|
||||||
@@ -138,22 +138,23 @@ const onBack = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const onSubmit = async () => {
|
const onSubmit = async () => {
|
||||||
if (!form.value.realname || !form.value.cardnum) {
|
if (!/^[\u4e00-\u9fa5·]{2,8}$/.test(form.value.realname)) {
|
||||||
await showModal('请填写完整信息')
|
await showModal('姓名格式错误')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!/^\d{17}[\d|x]$/.test(form.value.cardnum)) {
|
if (!/^\d{17}[\d|x]$/.test(form.value.cardnum)) {
|
||||||
await showModal('身份证号格式错误')
|
await showModal('身份证号格式错误')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if (!zcardimage.value || !fcardimage.value) {
|
// if (!zcardimage.value || !fcardimage.value) {
|
||||||
await showModal('请上传身份证照片')
|
// await showModal('请上传身份证照片')
|
||||||
return
|
// return
|
||||||
}
|
// }
|
||||||
await realNameAuthAPI({
|
await realNameAuthAPI({
|
||||||
...form.value,
|
...form.value,
|
||||||
zcardimage: zcardimage.value,
|
// zcardimage: zcardimage.value,
|
||||||
fcardimage: fcardimage.value,
|
// fcardimage: fcardimage.value,
|
||||||
})
|
})
|
||||||
await showModal('提交成功,请耐心等待审核!')
|
await showModal('提交成功,请耐心等待审核!')
|
||||||
realnameInfo.value = await getRealNameAuthAPI().then((res) => {
|
realnameInfo.value = await getRealNameAuthAPI().then((res) => {
|
||||||
@@ -167,8 +168,8 @@ const onGoHome = () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
const { data: zcardimage, run: onUploadZCardImage } = useUpload()
|
// const { data: zcardimage, run: onUploadZCardImage } = useUpload()
|
||||||
const { data: fcardimage, run: onUploadFCardImage } = useUpload()
|
// const { data: fcardimage, run: onUploadFCardImage } = useUpload()
|
||||||
|
|
||||||
const realnameInfo = ref(null)
|
const realnameInfo = ref(null)
|
||||||
onLoad(async () => {
|
onLoad(async () => {
|
||||||
|
|||||||
Reference in New Issue
Block a user