惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
Google Developers Blog
V
Vulnerabilities – Threatpost
A
Arctic Wolf
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Cisco Talos Blog
Cisco Talos Blog
Vercel News
Vercel News
Hugging Face - Blog
Hugging Face - Blog
H
Hacker News: Front Page
D
Docker
人人都是产品经理
人人都是产品经理
Attack and Defense Labs
Attack and Defense Labs
Forbes - Security
Forbes - Security
I
InfoQ
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
aimingoo的专栏
aimingoo的专栏
C
Cybersecurity and Infrastructure Security Agency CISA
H
Hackread – Cybersecurity News, Data Breaches, AI and More
Simon Willison's Weblog
Simon Willison's Weblog
腾讯CDC
WordPress大学
WordPress大学
T
Tenable Blog
P
Proofpoint News Feed
月光博客
月光博客
T
Tor Project blog
The Cloudflare Blog
罗磊的独立博客
S
Secure Thoughts
Application and Cybersecurity Blog
Application and Cybersecurity Blog
The Hacker News
The Hacker News
P
Palo Alto Networks Blog
I
Intezer
小众软件
小众软件
N
News | PayPal Newsroom
V
Visual Studio Blog
L
LINUX DO - 最新话题
W
WeLiveSecurity
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
T
Troy Hunt's Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
博客园_首页
D
DataBreaches.Net
P
Privacy International News Feed
博客园 - 三生石上(FineUI控件)
Hacker News - Newest:
Hacker News - Newest: "LLM"
S
Security Affairs
云风的 BLOG
云风的 BLOG
Recorded Future
Recorded Future
阮一峰的网络日志
阮一峰的网络日志

博客园 - bwteacher

fastadmin中前端表格中字段状态动态加载问题 mysql实用 mysql操作错误 fastadmin操作 fastadmin下的多级联动 CentOS7安装Python3.10环境 jdk-24及tomcat-11.0.9(解压版)安装配置 mermaid基于 JavaScript 的图表绘制工具 HbuilderX 小随笔 v-bind和v-model的区别 v-if和v-show的区别 uniapp中@tap与@click点击事件的差异 PHP常用数学函数 距离-有这么多类 bootstrap.table汇总 selectpage汇总 jQuery没有匹配到任何内容,返回什么? js数组常用方法 thinkphp控制器名称命名相关 php常见错误码 ThinkPHP的join关联查询不使用默认的表前缀 阿里云虚拟主机创建https
表单提交fastadmin form
bwteacher · 2025-07-31 · via 博客园 - bwteacher

1、引入form组件

require(['form'], function(Form){});

2、生成form元素

3、绑定事件之验证(也可以绑定总表单事件Form.events.bindevent(form))

Form.api.bindevent(form, success, error, submit);

4、提交

//提交表单的方法,在表单完成验证后进行提交
Form.api.submit(form, success, error, submit);

例子:

Form.api.bindevent($("form[role=form]"), function(data, ret){
    //如果我们需要在提交表单成功后做跳转,可以在此使用location.href="链接";进行跳转
    Toastr.success("成功");
}, function(data, ret){
      Toastr.success("失败");
}, function(success, error){
    //bindevent的第三个参数为提交前的回调
    //如果我们需要在表单提交前做一些数据处理,则可以在此方法处理
    //注意如果我们需要阻止表单,可以在此使用return false;即可
    //如果我们处理完成需要再次提交表单则可以使用submit提交,如下
    //Form.api.submit(this, success, error);
    return false;
});