Online导入开启校验用法

最后更新于:2022-04-02 07:20:27

>导入检验:当我们在Online设计器设置了表单检验,需要导入的时候进行检验,不通过的不能导入,那么请参考此文章 ## 效果展示 >只允许输入中文 >失败 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/b7/bb/b7bb79c0f5eb199c89a1dafcbfa9a9ee_1911x980.png) >成功 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/f4/eb/f4eb29e833981927d78d662f61d7a3e8_1911x980.png) ## 新增online表单,表名叫做`student`,并添加字段 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/e0/df/e0df2c72bef3ed8ddd67cee61c842012_1912x900.png) >添加一个`name`字段,名字叫`学生信息` ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/58/ff/58ff8480c43af62d56d205bac135d139_1920x922.png) >添加自定义规则检验`^[\u4e00-\u9fa5]+$`,只允许输入中文 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/d9/c2/d9c24f93ceacfda796e2108a8e2baee8_1915x657.png) ## 重点-> 在导入中选中是否开启检验 >点击功能测试 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/56/5e/565eeb208b88edd51f30ce3c9e8db225_1616x399.png) >开启检验,点击确定即可 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/52/c2/52c21bd89ff29b3a7153cbf0cd6f24b1_1346x413.png) 效果展示 >失败 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/b7/bb/b7bb79c0f5eb199c89a1dafcbfa9a9ee_1911x980.png) >成功 ![](https://docs.gechiui.com/gc-content/uploads/sites/kancloud/f4/eb/f4eb29e833981927d78d662f61d7a3e8_1911x980.png) ------------------------------ ### 注意: 导入时,不作唯一校验,想要实现,只能在数据库表中设置字段的唯一索引。
';