当前位置:网站首页>No logic is executed after the El form is validated successfully
No logic is executed after the El form is validated successfully
2022-07-02 05:08:00 【Attacking Yuan people】
form Forms validate No logic is executed after success
01. Problem analysis
1. The prompt will be executed when the verification form fails , No logic is executed after passing , As shown in the figure below

2. According to the correct logic , The console will output success, But the task logic is not executed after the verification , Therefore, it is the method return problem after the validation rule passes
02. View existing rules
1. see form Forms rules Logic , As shown in the figure below

2. The age is verified in the figure , Prompt for null value
3. Most of the time, I feel that there is no problem in such verification , But only the wrong logic is executed here , Not executing the correct logic , Therefore, it is necessary to execute the correct logic when it is worth it
03. Problem solving
1. Add correct processing logic to the verification method , As shown in the figure below

2. Added callbak() Method , Used for logical execution after verification
Be careful
1. All methods of customizing validation rules , whatever ( situation ) It needs to be implemented in all cases callback() Method
边栏推荐
- 6.30年终小结,学生时代结束
- fastText文本分类
- Summary of common string processing functions in C language
- Ansible installation and use
- The underlying principle of go map (storage and capacity expansion)
- VMware installation win10 reports an error: operating system not found
- 解析少儿编程中的动手搭建教程
- [quick view opencv] familiar with CV matrix operation with image splicing examples (3)
- Embedded-c language-8-character pointer array / large program implementation
- 农业生态领域智能机器人的应用
猜你喜欢

el-cascader回显只选中不显示的问题

Line by line explanation of yolox source code of anchor free series network (7) -- obj in head_ loss、Cls_ Loss and reg_ Calculation and reverse transmission of loss I

ansible安装与使用

Virtual machine installation deepin system

Application of intelligent robot in agricultural ecology

2022阿里巴巴全球数学竞赛 第4题 虎虎生威(盲盒问题、集卡问题)解决思路

函数栈帧的创建和销毁

List of common bugs in software testing

10 minute quick start UI automation ----- puppeter

Save the CDA from the disc to the computer
随机推荐
el-cascader回显只选中不显示的问题
Solution: the agent throws an exception error
2022阿里巴巴全球数学竞赛 第4题 虎虎生威(盲盒问题、集卡问题)解决思路
The El cascader echo only selects the questions that are not displayed
LeetCode 241. 为运算表达式设计优先级(分治/记忆化递归/动态规划)
fastText文本分类
关于Steam 教育的知识整理
Getting started with pytest ----- confitest Application of PY
Use of typescript classes
How to modify data file path in DM database
Mouse events in JS
Pycharm breakpoint management: temporarily cancel some breakpoints + run directly to a line
函数栈帧的创建和销毁
Case sharing | intelligent Western Airport
Analyzing the hands-on building tutorial in children's programming
删除排序数组中的重复项go语言实现
Ansible installation and use
数学问题(数论)试除法做质数的判断、分解质因数,筛质数
How to configure PostgreSQL 12.9 to allow remote connections
Video cover image setting, put cover images into multiple videos in the simplest way