From 05b78270e86c6f266e5213e11e2e7441d5a4ba0a Mon Sep 17 00:00:00 2001 From: RuoYi Date: Sat, 14 Mar 2020 11:47:36 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=A8=E6=A0=BC=E6=A0=91=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E8=8E=B7=E5=8F=96=E6=95=B0=E6=8D=AE=E5=90=8E=E5=93=8D=E5=BA=94?= =?UTF-8?q?=E5=9B=9E=E8=B0=83=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/static/ruoyi/js/ry-ui.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/ruoyi-admin/src/main/resources/static/ruoyi/js/ry-ui.js b/ruoyi-admin/src/main/resources/static/ruoyi/js/ry-ui.js index c3cc0931..4714d896 100644 --- a/ruoyi-admin/src/main/resources/static/ruoyi/js/ry-ui.js +++ b/ruoyi-admin/src/main/resources/static/ruoyi/js/ry-ui.js @@ -562,12 +562,15 @@ var table = { return $.common.uniqueFn(rows); }, // 请求获取数据后处理回调函数,校验异常状态提醒 - responseHandler: function(data) { - if (data.code != undefined && data.code != 0) { - $.modal.alertWarning(data.msg); + responseHandler: function(res) { + if (typeof table.options.responseHandler == "function") { + table.options.responseHandler(res); + } + if (res.code != undefined && res.code != 0) { + $.modal.alertWarning(res.msg); return []; } else { - return data; + return res; } }, },