41 lines
1.2 KiB
Plaintext
41 lines
1.2 KiB
Plaintext
|
|
|
||
|
|
layui.define(["layer"], function (exports) {
|
||
|
|
var layer = layui.layer;
|
||
|
|
var obj = {
|
||
|
|
rightPopupLayer: function (content,id) {
|
||
|
|
let layerIndex = parent.layer.open({
|
||
|
|
type: 2,
|
||
|
|
title: false,
|
||
|
|
offset: ["10%", "100%"],
|
||
|
|
skin: "layui-anim layui-anim-rl layui-layer-adminRight",
|
||
|
|
closeBtn: 0,
|
||
|
|
content: content,
|
||
|
|
shadeClose: true,
|
||
|
|
area: ["40%", "90%"],
|
||
|
|
success: function () {
|
||
|
|
let iframeWin = parent.window["layui-layer-iframe" + layerIndex];
|
||
|
|
iframeWin.setParams(id);
|
||
|
|
}
|
||
|
|
});
|
||
|
|
let op_width = parent.$(".layui-anim-rl").outerWidth();
|
||
|
|
parent
|
||
|
|
.$(".layui-layer-shade")
|
||
|
|
.off("click")
|
||
|
|
.on("click", function () {
|
||
|
|
parent
|
||
|
|
.$(".layui-anim-rl")
|
||
|
|
.animate(
|
||
|
|
{ left: "+=" + op_width + "px" },
|
||
|
|
300,
|
||
|
|
"linear",
|
||
|
|
function () {
|
||
|
|
parent.$(".layui-anim-rl").remove();
|
||
|
|
|
||
|
|
parent.$(".layui-layer-shade").remove();
|
||
|
|
}
|
||
|
|
);
|
||
|
|
});
|
||
|
|
},
|
||
|
|
};
|
||
|
|
exports("rightPopup4", obj);
|
||
|
|
});
|