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 ...
随机推荐
- Bugku web 计算器
计算器 打开网页,想输入正确的计算结果发现只输进去一位数??? 遇事不决先F12看一眼源码,发现flag
- android 启动默认的邮件客户端,多附件的问题
目前开发的app中需要发送邮件,所以需要调用android默认的邮件客户端,并需要添加多个邮件附件,我该通过哪个组件调用默认的客户端?用什么组件来支持多个附件的电子邮件? 是通过下面的哪一个?(Int ...
- winXP 系统下ubuntu-12.04 硬盘安装
目地:实现XP ubuntu双系统,引导可选择. 出处:根查阅网络资料和自己的安装体检,记录如是. 系统版本:windowsXP SP3 Ubuntu 12.04 工具资源:grup4dos 2 ...
- iOS-KMNavigationBarTransition 框架学习
最后更新: 2017-06-21 一.文件结构 二.KMSwizzle KMSwizzle主要就一个方法交换的代码 2.1 class_getInstanceMethod() 获取某个类实例的方法, ...
- 《Vue前端开发手册》
序言 为了统一前端的技术栈问题,技术开发二部规定开发技术必须以Vue为主. 为了更好的规范公司的前端框架,现以我前端架构师为主,编写以下开发规范,如有不当的地方,欢迎批评教育并慢慢改善该开发文档,谢谢 ...
- firefox的group群组功能很好!
================================ /usr/share/themes中有一些主题,包括: adwaita: 阿德维塔, 不二论 anaconda等等. 计算机环境: f ...
- python进行数据库迁移的时候显示(TypeError: __init__() missing 1 required positional argument: 'on_delete')
进行数据库迁移的时候,显示 TypeError: __init__() missing 1 required positional argument: 'on_delete' 图示: 出现原因: 在 ...
- Vue知识整理4:v-html标签
可以在数据绑定中使用html标签,这样在变量里可以使用html标签输出结果,如下所示:
- 【ABAP系列】SAP ABAP选择屏幕(SELECTION SCREEN)事件解析
公众号:SAP Technical 本文作者:matinal 原文出处:http://www.cnblogs.com/SAPmatinal/ 原文链接:[ABAP系列]SAP ABAP选择屏幕(SEL ...
- airtest自动化中的poco+python连接手机实现ui自动化
airtest:http://airtest.netease.com/docs/docs_AirtestIDE-zh_CN/index.html官网地址 AirtestIDE:跨平台的UI自动化测试编 ...