当前位置:网站首页>JvxeTable子表记录加载完毕事件
JvxeTable子表记录加载完毕事件
2022-06-30 02:48:00 【OK_boom】
JvxeTable其实用的是vxeTable,但是可惜的是vxeTable没有加载完毕事件。
查jvxeTable代码,发现JVxeTableMixin.methods.requestSubTableData最后一个参数success就是获取远程数据成功后的回调
目标:在子表加载完毕后,检查子表记录是否有未下跟单的记录,有的话才显示下跟单的按钮
- 第一步,在methods加入:
async updateMtMainPurchase() {
//判断是否显示采购已跟单
let mtMain = await getRefPromise(this, 'smpOrderMtMain')
let rows = mtMain.getAll().tableData
console.log(rows)
let res = rows.filter(item => {
return item.purStatus < 'B06A02'
})
return res.length>0
}
- 第2步,修改editAfter
将拉取子表远程数据的语句改为如下,就是拉取成功后停100毫秒就调用updateMtMainPurchase将返回结果更新到hasUnAssignPurchase
this.requestSubTableData(this.url.smpOrderMtMain.list, params, this.smpOrderMtMainTable,
()=>{
setTimeout(()=>{
that.updateMtMainPurchase().then(ret=>{
that.$set(that,'hasUnAssignPurchase',ret)
})
},100)
})
边栏推荐
- 如何在 JupyterLab 中把 ipykernel 切换到不同的 conda 虚拟环境?
- Lua Basics
- Intel-Hex , Motorola S-Record 格式详细解析
- Shenzhen CPDA Data Analyst Certification in July 2022
- What about punctuation in the first column of unity text
- Créer des compétences exquises dans l'éducation des créateurs
- Raki's notes on reading paper: neighborhood matching network for entity alignment
- 迅為恩智浦iTOP-IMX6開發平臺
- 并发请求下如何防重复提交
- The rigorous judgment of ID number is accurate to the last place in the team
猜你喜欢
What is a self signed certificate? Advantages and disadvantages of self signed SSL certificates?
Série de tutoriels cmake - 02 - génération de binaires à l'aide du Code cmake
Idea remote debugging remote JVM debug
Select sort
Welfare lottery | what are the highlights of open source enterprise monitoring zabbix6.0
What should academic presentation /ppt do?
FAQs for code signature and driver signature
Raki's notes on reading paper: named entity recognition as dependency parsing
三层交换机和二层交换机区别是什么
Time complexity analysis
随机推荐
C console format code
重看《Redis设计与实现》后记录几个要点
What are the requirements for NPDP product manager international certification examination?
FDA ESG规定:必须使用数字证书保证通信安全
Network neuroscience——网络神经科学综述
Network neuroscience -- a review of network Neuroscience
JMeter obtains cookies across thread groups or JMeter thread groups share cookies
打造创客教育中精湛技艺
Precautions for purchasing wildcard SSL certificate
Implementation of Sanzi chess with C language
Pytorch学习(二)
What is the difference between a layer 3 switch and a layer 2 switch
FAQs for code signature and driver signature
A quick look at the statistical data of 23 major cyber crimes from 2021 to 2022
Lua Basics
VScode如何Debug(调试)进入标准库文件/第三方包源码
What about punctuation in the first column of unity text
Call collections Sort() method, compare two person objects (by age ratio first, and by name ratio for the same age), and pass lambda expression as a parameter.
CMake教程系列-02-使用cmake代码生成二进制
Entering Jiangsu writers and poets carmine Jasmine World Book Day