update 树查询table 增加一个选项,可以在"只看本级"和"查看本级及以下"之间切换

新增用户时的一些格式验证
This commit is contained in:
2021-07-02 15:42:56 +08:00
parent 3725f586d2
commit 072aabdd22
6 changed files with 75 additions and 7 deletions

View File

@@ -350,10 +350,31 @@ export default class form extends Component {
</Radio.Button>
</Radio.Group>
</Form.Item>
<Form.Item label="邮箱" name="email">
<Form.Item
label="邮箱"
name="email"
rules={[
{
pattern: /^\w{3,}(\.\w+)*@[A-z0-9]+(\.[A-z]{2,5}){1,2}$/,
message: '邮箱格式不正确',
trigger: 'blur',
},
]}
>
<Input autoComplete="off" placeholder="请输入邮箱" />
</Form.Item>
<Form.Item label="手机号" name="phone">
<Form.Item
label="手机号"
name="phone"
rules={[
{
pattern:
/^((13[0-9])|(14[5,7])|(15[^4,\\D])|(17[0,1,3,6-8])|(18[0-9])|(19[8,9])|(166))[0-9]{8}$/,
message: '手机号格式不正确',
trigger: 'blur',
},
]}
>
<Input autoComplete="off" placeholder="请输入手机号" />
</Form.Item>
<Form.Item label="电话" name="tel">