<el-button type="text" @click="open4">点击打开 Message Box</el-button>
methods: {
open4() {
const h = this.$createElement;
const aTemp = 'https://www.baidu.com/?tn=98010089_dg&ch=8';
this.$msgbox({
title: '消息',
message: h('p', null, [
h('span', null, '内容可以是 '),
h('a', {
//普通html特性
attrs: {
href:aTemp
},
//相当于`v-bind:style`
style: {
color: 'red',
fontSize: '14px'},
},
'百度'
)
]),
showCancelButton: true,
confirmButtonText: '确定',
cancelButtonText: '取消',
beforeClose: (action, instance, done) => {
if (action === 'confirm') {
instance.confirmButtonLoading = true;
instance.confirmButtonText = '执行中...';
setTimeout(() => {
done();
setTimeout(() => {
instance.confirmButtonLoading = false;
}, );
}, );
} else {
done();
}
}
}).then(action => {
alert('>>>>>');
this.$message({
type: 'info',
message: 'action: ' + action
});
});
}
},

来源 https://www.cnblogs.com/websmile/p/9167913.html

随机推荐

  1. layui表单

    {include file="Public:inner_header" /} <link rel="stylesheet" href="__ST ...

  2. 更改和配置本地yum源

    查看yum 存放位置 [root@web01 yum.repos.d]# ll /etc/yum.repos.d/ total -rw-r--r--. root root Jun CentOS-Bas ...

  3. Keras Conv1d 参数及输入输出详解

    Conv1d(in_channels,out_channels,kernel_size,stride=1,padding=0,dilation=1,groups=1,bias=True) filter ...

  4. 某公司git代码管理,到如何上线

  5. linux网络编程之socket编程(十二)

    今天继续学习socket编程,期待的APEC会议终于在京召开了,听说昨晚鸟巢那灯火通明,遍地礼花,有点08年奥运会的架势,有种冲动想去瞅见一下习大大的真容,"伟大的祖国,我爱你~~~&quo ...

  6. MySQL进阶18- 存储过程- 创建语句-参数模式(in/out/inout-对应三个例子) -调用语法-delimiter 结束标记'$'- 删除/查看/修改-三个练习

    /* MySQL-进阶18 存储过程 和 函数 存储过程和函数:类似于java中的方法 好处: 1.提高代码的重用性 2.简化操作 */ #存储过程 /* 含义: 一组已经预见编译好的SQL语句的集合 ...

  7. Vue多语言支持

    i18n插件实现多语言支持,本文以中英文为例记录一下配置过程. 1.配置 1.1安装:npm install vue-i18n --save 1.2创建中英文配置项文件 src/lang目录下创建以下 ...

  8. Laravel - 解决连接MySQL时报"The server requested authentication method unknown to the client”错误

    2019-04-12发布:hangge阅读:934   1,问题描述 最近建了个 Laravel 项目,当配置好 MySQL 数据库进行请求时,页面报如下错误:   SQLSTATE[HY000] [ ...

  9. postgrepSQL psql基础操作

    1.登录postgrepSQL psql 2.退出postgrepSQL \q 3.查看postgrepSQL里面的数据库 1)psql -l 2)\ l 4.切换DB \c db_name 5.查看 ...

  10. 百度UE编辑器从word粘贴公式

    图片的复制无非有两种方法,一种是图片直接上传到服务器,另外一种转换成二进制流的base64码 目前限chrome浏览器使用,但是项目要求需要支持所有的浏览器,包括Windows和macOS系统.没有办 ...