From 04e1cfad6afc9ca5f80fc8c774c5fd101b090879 Mon Sep 17 00:00:00 2001 From: weizhiqiang <598748873@qq.com> Date: Fri, 11 Mar 2022 20:11:55 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E9=83=A8=E5=88=86=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E8=AF=B7=E6=B1=82=E7=B1=BB=E5=9E=8B=E9=94=99=E8=AF=AF?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../template/js/systheme/systheme.js | 20 +++++++++---------- .../main/resources/template/js/index/index.js | 8 ++++---- .../template/js/syspersonal/editpassword.js | 6 +++--- 3 files changed, 17 insertions(+), 17 deletions(-) diff --git a/userauth/src/main/resources/template/js/systheme/systheme.js b/userauth/src/main/resources/template/js/systheme/systheme.js index 0348fab88..e6483ca47 100644 --- a/userauth/src/main/resources/template/js/systheme/systheme.js +++ b/userauth/src/main/resources/template/js/systheme/systheme.js @@ -37,35 +37,35 @@ layui.config({ //桌面背景选择 $('.bgPicItem').on('click', function () { var bgSrc = $(this).attr('picUrl'); - AjaxPostUtil.request({url:reqBasePath + "sys025", params:{winBgPicUrl: bgSrc}, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "sys025", params: {winBgPicUrl: bgSrc}, type: 'json', method: "PUT", callback: function(json){ if(json.returnCode == 0){ $('.background-preview').css('background-image', 'url(' + bgSrc + ')'); winui.resetBg(bgSrc); }else{ - winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); + winui.window.msg(json.returnMessage, {icon: 2, time: 2000}); } }}); }); - //桌面锁屏背景选择 + // 桌面锁屏背景选择 $('.lockBgPicItem').on('click', function () { var bgSrc = $(this).attr('picUrl'); - AjaxPostUtil.request({url:reqBasePath + "sys026", params:{winLockBgPicUrl: bgSrc}, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "sys026", params: {winLockBgPicUrl: bgSrc}, type: 'json', method: "PUT", callback: function(json){ if(json.returnCode == 0){ $('.lockscreen-preview').css('background-image', 'url(' + bgSrc + ')'); winui.resetLockBg(bgSrc); }else{ - winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); + winui.window.msg(json.returnMessage, {icon: 2, time: 2000}); } }}); }); - //颜色选择 + // 颜色选择 $('.color-choose>div').on('click', function () { var color = Number($(this)[0].classList[0].replace('theme-color-', '')); - AjaxPostUtil.request({url:reqBasePath + "sys024", params:{themeColor: color}, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "sys024", params: {themeColor: color}, type: 'json', method: "PUT", callback: function(json){ if(json.returnCode == 0){ winui.resetColor(color); }else{ - winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); + winui.window.msg(json.returnMessage, {icon: 2, time: 2000}); } }}); }); @@ -132,12 +132,12 @@ layui.config({ }); }, 'click .bgPicItem1':function(index, row){ var bgSrc = row.picUrl; - AjaxPostUtil.request({url:reqBasePath + "sys025", params:{winBgPicUrl: bgSrc}, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "sys025", params: {winBgPicUrl: bgSrc}, type:'json', method: "PUT", callback: function(json){ if(json.returnCode == 0){ $('.background-preview').css('background-image', 'url(' + bgSrc + ')'); winui.resetBg(bgSrc); }else{ - winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); + winui.window.msg(json.returnMessage, {icon: 2, time: 2000}); } }}); } diff --git a/web/src/main/resources/template/js/index/index.js b/web/src/main/resources/template/js/index/index.js index ddda26ad4..7ae1f65b6 100644 --- a/web/src/main/resources/template/js/index/index.js +++ b/web/src/main/resources/template/js/index/index.js @@ -252,7 +252,7 @@ layui.config({ winui.lockScreen(function(password) { if(!isNull(password)) { var pJudge = false; - AjaxPostUtil.request({url: reqBasePath + "login008", params: {password: password}, type: 'json', callback: function(json) { + AjaxPostUtil.request({url: reqBasePath + "login008", params: {password: password}, type: 'json', method: "POST", callback: function(json) { if(json.returnCode == 0) { pJudge = true; }else{ @@ -426,17 +426,17 @@ layui.config({ winui.lockScreen(function (password) { if(!isNull(password)){ var pJudge = false; - AjaxPostUtil.request({url:reqBasePath + "login008", params:{password: password}, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "login008", params: {password: password}, type: 'json', method: "POST", callback: function(json){ if(json.returnCode == 0){ pJudge = true; }else{ pJudge = false; - winui.window.msg(json.returnMessage, { shift: 6 }); + winui.window.msg(json.returnMessage, {shift: 6}); } }, async: false}); return pJudge; }else{ - winui.window.msg('请输入密码', { shift: 6 }); + winui.window.msg('请输入密码', {shift: 6}); return false; } }); diff --git a/web/src/main/resources/template/js/syspersonal/editpassword.js b/web/src/main/resources/template/js/syspersonal/editpassword.js index 230358003..135662c50 100644 --- a/web/src/main/resources/template/js/syspersonal/editpassword.js +++ b/web/src/main/resources/template/js/syspersonal/editpassword.js @@ -36,19 +36,19 @@ layui.config({ newPassword: $("#newPassword").val(), oldPassword: $("#oldPassword").val() }; - AjaxPostUtil.request({url:reqBasePath + "login007", params:params, type:'json', callback:function(json){ + AjaxPostUtil.request({url: reqBasePath + "login007", params:params, type: 'json', method: "POST", callback: function(json){ if(json.returnCode == 0){ parent.layer.close(index); parent.refreshCode = '0'; }else{ - winui.window.msg(json.returnMessage, {icon: 2,time: 2000}); + winui.window.msg(json.returnMessage, {icon: 2, time: 2000}); } }}); } return false; }); - //取消 + // 取消 $("body").on("click", "#cancle", function(){ parent.layer.close(index); }); -- GitLab