From b3ac00069f9594f6ec0077cbb91516e26e13c3b6 Mon Sep 17 00:00:00 2001 From: luxiaotao1123 <t1341870251@163.com> Date: 星期六, 01 八月 2020 15:23:26 +0800 Subject: [PATCH] #当前本版十分完美、冻结 --- src/main/webapp/static/layuiadmin/lib/admin.js | 28 +++++++++++++++++++++------- 1 files changed, 21 insertions(+), 7 deletions(-) diff --git a/src/main/webapp/static/layuiadmin/lib/admin.js b/src/main/webapp/static/layuiadmin/lib/admin.js index 6f6f1f6..1f8af78 100644 --- a/src/main/webapp/static/layuiadmin/lib/admin.js +++ b/src/main/webapp/static/layuiadmin/lib/admin.js @@ -381,9 +381,24 @@ ,note: function(othis){ var mobile = admin.screen() < 2 ,note = layui.data(setter.tableName).note; - + // 鑾峰彇婵�娲荤姸鎬� + var activation = false; + var exprTime; + $.ajax({ + url: baseUrl+"/system/activation/auth", + dataType:'json', + method: 'GET', + async: false, + success: function (res) { + if (res.code === 200) { + activation = true; + exprTime = res.data; + } + } + }); + events.note.index = admin.popup({ - title: 'WMS 绉橀挜' + title: (activation?"宸叉縺娲伙紙鏈夋晥鏈熻嚦"+exprTime+"锛�":"Activation Code(鏈縺娲�)") // title: 'license' ,shade: 0 ,offset: [ @@ -395,7 +410,7 @@ ,skin: 'layadmin-note layui-anim layui-anim-upbit' ,content: '<textarea placeholder="鍐呭"></textarea>' ,resize: false - ,btn: ['娣诲姞', '鍙栨秷'] + ,btn: [(activation?"鏇存柊":"绔嬪嵆婵�娲�"), '鍙栨秷'] ,success: function(layero, index){ var textarea = layero.find('textarea') ,value = note === undefined ? '' : note; @@ -411,13 +426,13 @@ $.ajax({ url: baseUrl+"/system/secret/auth", headers: {'token': localStorage.getItem('token')}, - data: "secret="+note, + data: "secret="+$("#LAY_adminNote").children("textarea").val(), dataType:'json', method: 'POST', success: function (res) { - console.log(note) if (res.code === 200) { - layer.msg(res.msg) + layer.msg(res.msg); + layer.close(index); } else if (res.code === 403) { top.location.href = baseUrl+"/login"; } else { @@ -425,7 +440,6 @@ } } }); - layer.close(index); } ,btn2: function(index, layero){ layer.close(index); -- Gitblit v1.9.1