feat:增加校验

This commit is contained in:
admin 2024-09-06 10:52:02 +08:00
parent bb471250d8
commit f6bba9e78d
6 changed files with 8 additions and 0 deletions

View File

@ -126,6 +126,7 @@
"scope.userInfo": true, "scope.userInfo": true,
"scope.snsapi_base": true "scope.snsapi_base": true
}, },
"pageOrientation": "auto",
"globalStyle": { "globalStyle": {
"navigationBarTextStyle": "black", "navigationBarTextStyle": "black",
"navigationBarTitleText": "智能回收", "navigationBarTitleText": "智能回收",

View File

@ -47,6 +47,7 @@
:customStyle="{}" :customStyle="{}"
border="none" border="none"
:disabled="item.disabled" :disabled="item.disabled"
:type="['contactInfo', 'recyclingWeight'].indexOf(item.key) > -1 ? 'number' : 'text'"
> >
<template #suffix> <template #suffix>
<text v-if="item.unit"> <text v-if="item.unit">

View File

@ -47,6 +47,7 @@
:customStyle="{}" :customStyle="{}"
border="none" border="none"
:disabled="item.disabled" :disabled="item.disabled"
:type="['contactInfo'].indexOf(item.key) > -1 ? 'number' : 'text'"
> >
<template #suffix> <template #suffix>
<text v-if="item.unit"> <text v-if="item.unit">

View File

@ -31,6 +31,7 @@
:customStyle="{}" :customStyle="{}"
border="none" border="none"
:disabled="item.disabled" :disabled="item.disabled"
:type="['contactPhone'].indexOf(item.key) > -1 ? 'number' : 'text'"
> >
<template #suffix> <template #suffix>
<text v-if="item.unit"> <text v-if="item.unit">

View File

@ -31,6 +31,7 @@
:customStyle="{}" :customStyle="{}"
border="none" border="none"
:disabled="item.disabled" :disabled="item.disabled"
:type="['contactInfo', 'curbWeight'].indexOf(item.key) > -1 ? 'number' : 'text'"
> >
<template #suffix> <template #suffix>
<text v-if="item.unit"> <text v-if="item.unit">
@ -105,6 +106,7 @@ import { url } from "@/utils/data";
import { PictureApi, VehicleApi, UserApi } from "@/services"; import { PictureApi, VehicleApi, UserApi } from "@/services";
import pinia from "@/store"; import pinia from "@/store";
import { useMemberStore } from "@/store/index"; import { useMemberStore } from "@/store/index";
import valid from "@/utils/validate";
const store = useMemberStore(pinia); const store = useMemberStore(pinia);
const model1 = reactive<any>({ const model1 = reactive<any>({
formData: {}, formData: {},
@ -280,6 +282,7 @@ const contrlModalParams = reactive<any>({
}, },
}); });
const handleSelect = (key: string, v: any) => { const handleSelect = (key: string, v: any) => {
contrlModalParams[key].isShow = false; contrlModalParams[key].isShow = false;
if (key === "vehicleType") { if (key === "vehicleType") {

View File

@ -31,6 +31,7 @@
:customStyle="{}" :customStyle="{}"
border="none" border="none"
:disabled="item.disabled" :disabled="item.disabled"
:type="['contactInfo'].indexOf(item.key) > -1 ? 'number' : 'text'"
> >
<template #suffix> <template #suffix>
<text v-if="item.unit"> <text v-if="item.unit">