在线编辑保存时增加询问
This commit is contained in:
parent
1f36630a34
commit
00c56759e5
@ -1 +1 @@
|
|||||||
3.9.43beta6
|
3.9.43beta7
|
||||||
@ -213,6 +213,11 @@ function f(){
|
|||||||
});
|
});
|
||||||
//监听提交
|
//监听提交
|
||||||
form.on('submit(saveBtn)', function (data) {
|
form.on('submit(saveBtn)', function (data) {
|
||||||
|
layer.confirm('确认保存?', {
|
||||||
|
title: "操作提示",
|
||||||
|
icon: 0,
|
||||||
|
btn: ['确定']
|
||||||
|
} ,function(index){
|
||||||
let txt = editor.getValue();
|
let txt = editor.getValue();
|
||||||
// console.log(txt);
|
// console.log(txt);
|
||||||
let postData = {
|
let postData = {
|
||||||
@ -232,6 +237,9 @@ function f(){
|
|||||||
layer.msg(ret.msg);
|
layer.msg(ret.msg);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
layer.close(index);
|
||||||
|
});
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@ -123,6 +123,11 @@
|
|||||||
});
|
});
|
||||||
//监听提交
|
//监听提交
|
||||||
form.on('submit(saveBtn)', function (data) {
|
form.on('submit(saveBtn)', function (data) {
|
||||||
|
layer.confirm('确认保存?', {
|
||||||
|
title: "操作提示",
|
||||||
|
icon: 0,
|
||||||
|
btn: ['确定']
|
||||||
|
} ,function(index){
|
||||||
let txt = $('#script_code').val();
|
let txt = $('#script_code').val();
|
||||||
// console.log(txt);
|
// console.log(txt);
|
||||||
let postData = {
|
let postData = {
|
||||||
@ -142,6 +147,10 @@
|
|||||||
layer.msg(ret.msg);
|
layer.msg(ret.msg);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
layer.close(index);
|
||||||
|
});
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user