element 弹框关闭报错
<template>
<el-container style="padding: 00px 20px 0px 20px">
<el-dialog
title="售电公司注册审批记录"
:visible.sync="innerVisible"
width="60%"
@close="closeDialog"
:close-on-click-modal="true"
:modal="false"
>
</el-dialog>
</el-container>
</template> <script>
import FlowNodeInsInfoRegApi from '@/api/pxf-service-imarketservice/imarketMemberManage/registerCheck/FlowNodeInsInfoRegApi'
import moment from 'moment'
export default {
props: {
accessVisible: Boolean,
membersRegInfo: {
type: Object,
default: function() {
return {}
}
},
states: {
type: Object,
default: function() {
return {}
}
},
processNum: {
type: String,
default: ''
}
},
data() {
return {
innerVisible: false,
mmFlowNodeInsInfoRegList: [],
scopeFlowNodeInsInfoRegList: [],
scopeInfos: [],
scopeProcessNum: '',
scopeAll: '',
}
},
watch: { accessVisible(newValue) {
this.innerVisible = newValue
}
},
mounted() {
if (this.accessVisible) {
this.init()
this.queryByProcessNum(this.processNum, 1)
this.queryByProcessNum(this.scopeProcessNum, 0)
}
},
methods: {
closeDialog() {
this.$emit('close-dialog')
},
close() {
this.$emit('update:visible') // 传递关闭事件
this.$emit('close-dialog')
},
closeModal(e) {
if (this.visible) {
document.querySelector('.dialog').contains(e.target) ? '' : this.close() // 判断点击的落点在不在dialog对话框内,如果在对话框外就调用this.close()方法关闭对话框
}
},
init() {
this.scopeInfos = this.membersRegInfo.scopeInfos.filter(item => item.isRegAdd !== 1 && item.state !== '01')
// 默认第一业务范围
this.scopeProcessNum = ''
if (this.scopeInfos.length > 0) {
if (this.scopeProcessNum === '') {
this.scopeProcessNum = this.scopeInfos[0].processNum
}
}
// 拼接所有业务范围
this.scopeAll = ''
this.membersRegInfo.scopeInfos.forEach((item) => {
this.scopeAll += item.name + '、'
})
if (this.scopeAll.indexOf('、') > -1) {
this.scopeAll = this.scopeAll.substr(0, this.scopeAll.length - 1)
}
},
queryByProcessNum(processNum, isRegAdd) {
if (!processNum) {
return
}
FlowNodeInsInfoRegApi.queryByProcessNum(processNum).then(result => {
if (isRegAdd === 1) {
this.mmFlowNodeInsInfoRegList = result.data
} else {
this.scopeFlowNodeInsInfoRegList = result.data
}
}).catch(err => {
console.log(err)
})
},
applicationDateFormat(row) {
var date = row.applicationDate
if (!date) {
return ''
}
return moment(date).format('YYYY-MM-DD')
},
dateFormat(row, column) {
var date = row[column.property]
if (!date) {
return ''
}
return moment(date).format('YYYY-MM-DD HH:mm:ss')
},
close() {
this.$emit('close-dialog')
},
formatterState(row, column) {
var state = row[column.property]
return this.states[state]
}
}
}
</script> <style scoped> </style>
element 弹框关闭报错的更多相关文章
- angularJs $mdDialog和$uibModal弹框关闭传值
$mdDialog以一个点击button按钮出现弹框为例: $scope.btn=function($event,row){ var dScope = $scope.$new(true); dScop ...
- 记一次layui弹框关闭问题
我在博客园记录过layui关于弹框关闭问题,文章为layui关闭弹出层,这次出现了特殊情况,之前是通过layer.closeAll()解决了这个问题,但是这次解决不了.而换成parent.layer. ...
- 关于点击弹框外部区域弹框关闭的交互处理(前端JS)
常见需求场景 前端在处理交互的时候,经常遇到这样的场景,点击一个按钮,出现一个弹框,点击外部区域,弹框关闭. 解决方法 思路说明: 1.给弹框的div父级都加个类名,如: 2.在document绑定一 ...
- TOMCAT 关闭报错:Tomcat did not stop in time. PID file was not removed
关闭tomcat的时候,报出如下错误信息: # ./shutdown.sh Using CATALINA_BASE: /opt/openkm-6.3.1-community/tomcat Using ...
- Element和vue框架报错提示
上面报错提示Error in render function: "TypeError:Cannot read property '$options' of undefined" 就 ...
- spring boot thymeleaf 标签未关闭报错
每天学习一点点 编程PDF电子书免费下载: http://www.shitanlife.com/code spring boot,input标签未关闭报bug,代码稍有不慎就出小问题,后来百度,goo ...
- netty-websocket-spring-boot-starter关闭报错 io/netty/channel/AbstractChannel$AbstractUnsafe io/netty/util/concurrent/GlobalEventExecutor
报错 java.lang.NoClassDefFoundError: io/netty/channel/AbstractChannel$AbstractUnsafe$ at io.netty.chan ...
- gridView AspNetPager 翻页时 弹出窗体关闭报错
gridView AspNetPager 翻页后,你右击刷新或F5会发现弹出一个刷新页面. 这是因为默认翻页都是用dopostback方式回发的.因为这时的页面已经不是原来的页面.所以会弹出提示. 这 ...
- mysql配置mha高可用防火墙未关闭报错
########################################################################## l 问题背景:检查主从复制之后做高可用报错 [r ...
随机推荐
- centos搭建lamp环境参考(根据腾讯云实验室)
1.安装MYSQL 使用 yum 安装 MySQL: yum install mysql-server -y 安装完成后,启动 MySQL 服务: service mysqld restart 设置 ...
- Leetcode 9. Palindrome Number(水)
9. Palindrome Number Easy Determine whether an integer is a palindrome. An integer is a palindrome w ...
- pandas中的describe方法
- 解决 ffmpeg 在avformat_find_stream_info执行时间太长
用ffmpeg做demux,网上很多参考文章.对于网络流,avformt_find_stream_info()函数默认需要花费较长的时间进行流格式探测,那么,如何减少探测时间内? 可以通过设置AVFo ...
- (转)JNI参数传递|Surface && sign签名对应
http://blog.csdn.net/stefzeus/article/details/6622011 char* Get_Surface(JNIEnv *env, jclass cls, job ...
- 在一个shell中查看管理 任务(前台和后台)/工作jobs 的命令
在一个shell中查看管理 任务(前台和后台)/工作jobs 的命令 jobs是在同一个shell环境而言, 才有意义的. 为什么有jobs这个命令? 是因为, 如果从cmd line运行gui程序时 ...
- AtomicInteger 源码分析
AtomicInteger AtomicInteger 能解决什么问题?什么时候使用 AtomicInteger? 支持原子更新的 int 值. 如何使用 AtomicInteger? 1)需要被多线 ...
- 阶段1 语言基础+高级_1-3-Java语言高级_06-File类与IO流_08 转换流_5_InputStreamReader介绍&代码实现
强转chart:类型 GBK
- 阶段1 语言基础+高级_1-3-Java语言高级_06-File类与IO流_05 IO字符流_2_字符输入流读取字符数据
读取的文件有中文也有英文 强转为char类型 缓冲读取多个字符 使用string的构造方法转换为字符输出
- 抓包工具之—charles碎言碎语
一.Charles常见使用场景: 1.Charles是跨平台的抓包工具,支持Windows,mac或Linux平台: 2.获取请求信息.测试接口时,若接口文档中的参数不清楚或没有接口文档时,可以通过抓 ...