From 34bfa7df61921f7d1798fc08db0b8d81828da96b Mon Sep 17 00:00:00 2001
From: hwh <332078369@qq.com>
Date: 星期二, 02 七月 2024 08:07:57 +0800
Subject: [PATCH] 物料、部门、功能设定
---
HTML/js/public.js | 16 ++++++++++++----
1 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/HTML/js/public.js b/HTML/js/public.js
index 27b625e..b1ca696 100644
--- a/HTML/js/public.js
+++ b/HTML/js/public.js
@@ -13,7 +13,7 @@
{
sendData(IP + "/Basis/GetFunSettingByNo?funSetNo="+"Fun013", {}, 'get', function (res) {
console.log(res.data.SetValue)
- if (res.code == 0) { //鎴愬姛
+ if (res.code == 200) { //鎴愬姛
if(res.data.IsEnable == 'NO')
{
pageCnt = parseInt(res.data.SetValue);
@@ -55,13 +55,12 @@
success: function (res, status, xhr) {
// console.log(res);
// console.log(status);
-
callbackFun(res);
},
error: function (res, status, error) {
// console.log(res);
// console.log(status);
- callbackFun(res, status, error);
+ callbackFun(res.responseJSON, status, error);
// layer.msg(res.statusText, {
// icon: 2,
// time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級
@@ -245,7 +244,7 @@
function GetIsSetColW()
{
sendData(IP + "/Basis/GetFunSettingByNo?funSetNo="+"Fun014", {}, 'get', function (res) {
- if (res.code == 0) { //鎴愬姛
+ if (res.code == 200) { //鎴愬姛
if(res.data.IsEnable == 'NO')
{
isSetColW=true;
@@ -333,4 +332,13 @@
}
}
});
+}
+
+var FnParseData = function (res) {
+ return {
+ "code": res.code == 200 ? 0 : res.code, // 瑙f瀽鎺ュ彛鐘舵��
+ "msg": res.msg, // 瑙f瀽鎻愮ず鏂囨湰
+ "count": res.data.Total, // 瑙f瀽鏁版嵁闀垮害
+ "data": res.data.Items // 瑙f瀽鏁版嵁鍒楄〃
+ };
}
\ No newline at end of file
--
Gitblit v1.8.0