layer.open({
type: 1,
title: '充值',
skin: 'layui-Inpour', //样式类名
move: false,//禁止拖动弹框
content: $(".pay_note"),
cancel: function (index, layero) {//关闭按钮方法
window.location.reload();
}
type: 1,
title: '充值',
skin: 'layui-Inpour', //样式类名
move: false,//禁止拖动弹框
content: $(".pay_note"),
cancel: function (index, layero) {//关闭按钮方法
window.location.reload();
}
});
2.页面button按钮,点击事件判断用户是否勾选按钮,如果使用自己写的弹框第二次会弹不出来,所以使用layer.alert()。
layer.alert('您的风险等级:稳健型!', {
skin: 'layer-popup',
move: false,//禁止拖动弹框
yes: function (index, layero) {//确认按钮事件
window.location.href = '/UserManage/SecurityCenter/TotalSafetyinfo.aspx';
}, cancel: function () {//右上角取消按钮事件
window.location.href = '/UserManage/SecurityCenter/TotalSafetyinfo.aspx';
}
})