From 4afbfec2c380ac132a18f82212159994928fa1fb Mon Sep 17 00:00:00 2001
From: zyx <zyx123456>
Date: 星期二, 16 一月 2024 14:06:13 +0800
Subject: [PATCH] # 权限
---
src/main/webapp/static/js/pla/plaDetl.js | 82 +++++++++++++++++++++++++++++++++++-----
1 files changed, 71 insertions(+), 11 deletions(-)
diff --git a/src/main/webapp/static/js/pla/plaDetl.js b/src/main/webapp/static/js/pla/plaDetl.js
index 2bae082..48be961 100644
--- a/src/main/webapp/static/js/pla/plaDetl.js
+++ b/src/main/webapp/static/js/pla/plaDetl.js
@@ -37,6 +37,12 @@
,{field: 'a', align: 'center',title: 'a鍊�', hide:true,edit:true}
,{field: 'b', align: 'center',title: 'b鍊�', hide:true,edit:true}
,{field: 'fillIn', align: 'center',title: '濉厖(%)',hide:true,edit:true}
+ ,{field: 'str1', align: 'center',title: '鎷変几寮哄害MPa',hide:true,edit:true}
+ ,{field: 'str2', align: 'center',title: '鏂浼搁暱鐜�%',hide:true,edit:true}
+ ,{field: 'str3', align: 'center',title: '缂哄彛鍐插嚮KJ/m2',hide:true,edit:true}
+ ,{field: 'str4', align: 'center',title: '缁村崱鈩�',hide:true,edit:true}
+ ,{field: 'str5', align: 'center',title: '鍗婄粨鏅舵椂闂磎in',hide:true,edit:true}
+ ,{field: 'str6', align: 'center',title: '缁撴櫠搴�%',hide:true,edit:true}
,{field: 'massState', align: 'center',title: '璐ㄩ噺鐘舵��',edit:true}
,{field: 'problem', align: 'center',title: '澶囨敞',edit:true}
,{field: 'stash', align: 'center',title: '浠撳簱',edit:true}
@@ -45,14 +51,14 @@
,{field: 'qtyAnfme', align: 'center',title: '寰呭嚭搴撻噸閲忥紙KG锛�',hide:true}
,{field: 'status', align: 'center',title: '鐘舵��', templet: setState ,edit:true}
,{align: 'center', title: '娴佽浆鏄庣粏', toolbar: '#tbLook'}
- ,{field: 'orderNo', align: 'center',title: '鍗曞彿', hide:true}
- ,{field: 'pakoutTime', align: 'center',title: '鍑哄簱鏃堕棿', hide:true}
- ,{field: 'orderWeight', align: 'center',title: '閲嶉噺', hide:true}
- ,{field: 'handlerBy', align: 'center',title: '缁忓姙浜�', hide:true}
- ,{field: 'transfer', align: 'center',title: '娴佽浆褰㈠紡', hide:true}
- ,{field: 'customer', align: 'center',title: '瀹㈡埛鍚嶇О', hide:true}
- ,{field: 'allocate', align: 'center',title: '璋冩嫧鍒�', hide:true}
- ,{field: 'memo', align: 'center',title: '澶囨敞', hide:true}
+ // ,{field: 'orderNo', align: 'center',title: '鍗曞彿', hide:true}
+ // ,{field: 'pakoutTime', align: 'center',title: '鍑哄簱鏃堕棿', hide:true}
+ // ,{field: 'orderWeight', align: 'center',title: '閲嶉噺', hide:true}
+ // ,{field: 'handlerBy', align: 'center',title: '缁忓姙浜�', hide:true}
+ // ,{field: 'transfer', align: 'center',title: '娴佽浆褰㈠紡', hide:true}
+ // ,{field: 'customer', align: 'center',title: '瀹㈡埛鍚嶇О', hide:true}
+ // ,{field: 'allocate', align: 'center',title: '璋冩嫧鍒�', hide:true}
+ // ,{field: 'memo', align: 'center',title: '澶囨敞', hide:true}
];
return cols;
}
@@ -68,6 +74,8 @@
return "<span style='color: black'>閮ㄥ垎鍑哄簱</span>"
}else if(data.status === "鍏ㄩ儴鍑哄簱"){
return "<span style='color: gray'>鍏ㄩ儴鍑哄簱</span>"
+ }else if(data.status === "鏆傚叆搴�"){
+ return "<span style='color: purple'>鏆傚叆搴�</span>"
}
}
@@ -226,7 +234,59 @@
});
}
break;
-
+ case "deleteData":
+ var data = checkStatus.data;
+ if (data.length === 0){
+ layer.msg('璇烽�夋嫨鏁版嵁');
+ } else {
+ layer.confirm('纭畾鍒犻櫎'+(data.length===1?'姝�':data.length)+'鏉℃暟鎹悧', function(){
+ $.ajax({
+ url: baseUrl+"/pla/delete/auth",
+ headers: {'token': localStorage.getItem('token')},
+ data: JSON.stringify(data),
+ contentType:'application/json;charset=UTF-8',
+ method: 'POST',
+ traditional:true,
+ success: function (res) {
+ if (res.code === 200){
+ layer.closeAll();
+ tableReload(false);
+ } else if (res.code === 403){
+ top.location.href = baseUrl+"/";
+ } else {
+ layer.msg(res.msg)
+ }
+ }
+ })
+ });
+ }
+ break;
+ case "viladate":
+ var data = checkStatus.data;
+ if (data.length === 0){
+ layer.msg('璇烽�夋嫨鏁版嵁');
+ } else {
+ layer.confirm('纭畾鏍¢獙'+(data.length===1?'姝�':data.length)+'鏉℃暟鎹悧', function(){
+ $.ajax({
+ url: baseUrl+"/pla/viladate/auth",
+ headers: {'token': localStorage.getItem('token')},
+ data: JSON.stringify(data),
+ contentType:'application/json;charset=UTF-8',
+ method: 'POST',
+ traditional:true,
+ success: function (res) {
+ if (res.code === 200){
+ layer.closeAll();
+ tableReload(false);
+ } else if (res.code === 403){
+ top.location.href = baseUrl+"/";
+ } else {
+ layer.msg(res.msg)
+ }
+ }
+ })
+ });
+ }
}
})
@@ -435,7 +495,7 @@
for(var i=0; i<data.length; i++){
if(data[i].LAY_CHECKED){
- if(data[i].status === "寰呭叆搴�" || data[i].status === "鍏ㄩ儴鍑哄簱"|| data[i].weightAnfme <= data[i].qtyAnfme){
+ if(data[i].status === "鏆傚叆搴�" || data[i].status === "寰呭叆搴�" || data[i].status === "鍏ㄩ儴鍑哄簱"|| data[i].weightAnfme <= data[i].qtyAnfme){
layer.msg("閫変腑鐨勬槑缁嗚繕鏈叆搴撴垨鑰呭凡鍏ㄩ儴鍑哄簱鎴栬�呮病鏈夊墿浣欏彲鍑洪噸閲忥紝璇烽噸鏂伴�夋嫨");
return;
}
@@ -483,7 +543,7 @@
let dataOld = [];
for(var i=0; i<data.length; i++){
if(data[i].LAY_CHECKED){
- if(data[i].status === "寰呭叆搴�" || data[i].status === "鍏ㄩ儴鍑哄簱"){
+ if(data[i].status === "鏆傚叆搴�" || data[i].status === "寰呭叆搴�" || data[i].status === "鍏ㄩ儴鍑哄簱"){
layer.msg("閫変腑鐨勬槑缁嗚繕鏈叆搴撴垨鑰呭凡鍏ㄩ儴鍑哄簱锛岃閲嶆柊閫夋嫨");
return;
}
--
Gitblit v1.9.1