当前位置:网站首页>Tips for using jeditabletable
Tips for using jeditabletable
2022-07-07 08:31:00 【OK_ boom】
JEditableTable Use the default criteria to query
JEditableTable By weaving in JeecgListMixin To implement the query ,created Priority will be given to implementation JVxeTableModelMixin Of created, So priority will be given to load once data.
Fortunately, it has a switch to turn it off and automatically load data .
In our own inquiry vue Processing , stay data Add in disableMixinCreated:true And in created You can load the data manually .
created() {
this.getSuperFieldList()
this.$nextTick(()=>{
if (this.type=='purchase'){
this.$set(this.queryParam,'approved',"1")
}
this.loadData();
// Initialize dictionary configuration Define on your own page
this.initDictConfig();
})
}
JEditableTable Modify the default value of the record
There's been a lot of attempts , Finally, make sure to modify JEditableTable Of dataSource And it needs to trigger its monitoring function to load new data into the interface , but JEditableTable Of dataSource No listening deep, It needs to be added to monitor dataSource Changes in content .
dataSource: {
immediate: true,
deep: true,
handler: function (newValue) {
// compatible IE
this.getElementPromise('tbody').then(() => {
this.initialize()
this._pushByDataSource(newValue)
})
}
},
The following is to be achieved , When data linkage makes JEditableTable Inside select Type of field options Refresh again and JEditableTable The value of this field of all records is cleared
async prodCatChange(value){
//tbVendor yes JEditableTable example
let tbVendor = await getRefPromise(this, 'smpProductVendor')
let column=tbVendor.columns.filter(m=>m.key=='vendorId')[0]
column.options=[]// Must empty , Otherwise, the superposition will be recorded
tbVendor._loadDictConcatToOptions(column)
let dataSource=this.smpProductVendorTable.dataSource
dataSource.forEach(item=>{
item.vendorId='.'
})
dataSource.forEach(item=>{
item.vendorId=''
})
},
Why should we put vendorId Set twice ? Because if you set it once , Repeat this method and it will not trigger again tbVendor Of dataSource monitor .
边栏推荐
- Detailed explanation of apply, also, let, run functions and principle analysis of internal source code in kotlin
- 单元测试报告成功率低
- Implement your own dataset using bisenet
- Learn how to compile basic components of rainbow from the source code
- POJ - 3616 Milking Time(DP+LIS)
- 在 Rainbond 中一键安装高可用 Nacos 集群
- 如何理解分布式架构和微服务架构呢
- How to realize the high temperature alarm of the machine room in the moving ring monitoring system
- 解析创新教育体系中的创客教育
- Improve the delivery efficiency of enterprise products (1) -- one click installation and upgrade of enterprise applications
猜你喜欢
解析创新教育体系中的创客教育
Splunk查询csv lookup table数据动态查询
In go language, function is a type
Exercise arrangement 2.10, 11
提高企业产品交付效率系列(1)—— 企业应用一键安装和升级
Opencv learning note 4 - expansion / corrosion / open operation / close operation
opencv学习笔记二——图像基本操作
单场带货涨粉10万,农村主播竟将男装卖爆单?
Through the "last mile" of legal services for the masses, fangzheng Puhua labor and personnel law self-service consulting service platform has been frequently "praised"
eBPF Cilium实战(2) - 底层网络可观测性
随机推荐
GOLand idea intellij 无法输入汉字
归并排序和非比较排序
Splunk子查询模糊匹配csv中字段值为*
利用 Helm 在各类 Kubernetes 中安装 Rainbond
Interface as a parameter (interface callback)
饥荒云服管理脚本
CCTV is so warm-hearted that it teaches you to write HR's favorite resume hand in hand
Zcmu--1396: queue problem (2)
Using helm to install rainbow in various kubernetes
The use of generics and vararg variable parameters in kotlin
One click deployment of highly available emqx clusters in rainbow
Don't stop chasing the wind and the moon. Spring mountain is at the end of Pingwu
Installation and configuration of PLSQL
The reified keyword in kotlin is used for generics
单场带货涨粉10万,农村主播竟将男装卖爆单?
opencv学习笔记二——图像基本操作
Pvtv2--pyramid vision transformer V2 learning notes
接口作为参数(接口回调)
Openvscode cloud ide joins rainbow integrated development system
Domain specific language / DSL in kotlin