当前位置:网站首页>Jvxetable implant j-popup with slot
Jvxetable implant j-popup with slot
2022-07-06 05:22:00 【OK_ boom】
The previous article talked about how to determine according to the current record jpopup field whether disabled(https://blog.csdn.net/rocklee/article/details/125581874?spm=1001.2014.3001.5501), Here is how to use slot Slot mode assignment template by j-popup
<template #prodSeq="{row, rowIndex, $rowIndex, column}" >
<j-popup
v-model="row.prodSeq"
:code="column.popupCode"
:field="column.field"
:column="column"
:value="row[column.key]"
:renderOptions="{listeners:$listeners}"
:orgFields="column.orgFields"
:destFields="column.destFields"
:param="column.param"
:sorter="column.sorter"
:row="row"
:multi="false"
:disabled="!column.props.getDisabled(row,column)"
@input="(value,others,oldValue,row)=>updateMainMtRecord(value,others,oldValue,row,column,rowIndex)"
></j-popup>
</template>
slot Inside jpopup Specified parameters
– param Filter parameters specified when browsing records
– row The current record brought in
– disabled Dynamically determine whether to disable
– input Callback eventsInsert this slot
Specify the configuration of a field as slot:
{
title: ' materiel SQ',
key: 'prodSeq',
type: JVXETypes.slot,
slotName:'prodSeq',
fixed: 'left',
width:"150px",
popupCode:"getProds",
field:"prod_seq",
orgFields:"id,prod_name,prod_seq,spec,fukuang,mazhong,unit",
destFields:"prodId,prodName,prodSeq,productInfo.spec,productInfo.fukuang,productInfo.mazhong,productInfo.unit",
placeholder: ' Please enter ${title}',
defaultValue:'',
param: {prod_cat:'B04A01'},
props:{
formType:this.type,
getDisabled: (row,column,ref)=>{return !(!!row['clone']||(this.formType||!!ref&&ref.$attrs.formType)=='edit')}
},
validateRules: [{ required: true, message: '${title} Can't be empty ' }],
}
- Jpopup Modification of
data() Added oldValue:
data() {
return {
showText: '',
title: '',
oldValue:'',
avalid: true,
extendParam: {}
}
}
openModal() want oldValue Save the original value
openModal() {
if (this.disabled === false) {
this.oldValue=this.row[this.column.key]
this.$refs.jPopupOnlReport.show()
}
}
Last callback Change the last sentence to :
this.$emit('input', str, res,this.oldValue,this.row)
边栏推荐
- 集合详解之 Collection + 面试题
- Oracle query table index, unique constraint, field
- Sliding window problem review
- Qt TCP 分包粘包的解决方法
- 02. 开发博客项目之数据存储
- Jvxetable用slot植入j-popup
- JDBC calls the stored procedure with call and reports an error
- Oracle deletes duplicate data, leaving only one
- HAC集群修改管理员用户密码
- RT thread analysis - object container implementation and function
猜你喜欢
[leetcode16] the sum of the nearest three numbers (double pointer)
04. Project blog log
JS quick start (II)
Pix2pix: image to image conversion using conditional countermeasure networks
Vulhub vulnerability recurrence 67_ Supervisor
Check the useful photo lossless magnification software on Apple computer
Modbus协议通信异常
Sword finger offer II 039 Maximum rectangular area of histogram
Using stopwatch to count code time
February 12 relativelayout
随机推荐
ByteDance program yuan teaches you how to brush algorithm questions: I'm not afraid of the interviewer tearing the code
Three.js学习-光照和阴影(了解向)
Vulhub vulnerability recurrence 73_ Webmin
Notes, continuation, escape and other symbols
Yolov5 tensorrt acceleration
[noip2009 popularization group] score line delimitation
Vulhub vulnerability recurrence 69_ Tiki Wiki
First acquaintance with CDN
Review of double pointer problems
指针经典笔试题
Questions d'examen écrit classiques du pointeur
What are the advantages of the industry private network over the public network? What specific requirements can be met?
Easy to understand I2C protocol
Promotion hung up! The leader said it wasn't my poor skills
03. 开发博客项目之登录
Mongodb basic knowledge summary
[mask requirements of OSPF and Isis in multi access network]
Huawei od computer test question 2
Postman Association
GAMES202-WebGL中shader的编译和连接(了解向)