From 50a68a1fef8b2646352be0104f6c9fed36b1efbf Mon Sep 17 00:00:00 2001
From: CJJ <Administrator@192.168.10.27>
Date: 星期五, 14 十二月 2018 11:12:25 +0800
Subject: [PATCH] 修改
---
gx_tieta/WebRoot/mobil/batt-infor-unapproved-edit.html | 20 +++++----
gx_tieta/WebRoot/mobil/batt-approved.html | 8 +++-
gx_tieta/WebRoot/mobil/batt-unapproved.html | 48 +++++++++++-------------
3 files changed, 39 insertions(+), 37 deletions(-)
diff --git a/gx_tieta/WebRoot/mobil/batt-approved.html b/gx_tieta/WebRoot/mobil/batt-approved.html
index a3790d1..e4bb200 100644
--- a/gx_tieta/WebRoot/mobil/batt-approved.html
+++ b/gx_tieta/WebRoot/mobil/batt-approved.html
@@ -330,8 +330,12 @@
console.info(i);
arrTd[i]='<a onclick="getButIndex(this)" class="ui-btn ui-btn-inline ui-corner-all operat-but" data-position-to="window"'+'but-index='+i+'>鐢垫睜缁勫疄鏃舵暟鎹�</a>';
continue;
- }
- arrTd[i]=i*10;
+ }
+ if(i=13){
+ arrTd[i]=1002102;
+ }else{
+ arrTd[i]=i;
+ }
}
createTbl(tblCon, arrTh, arrTd);
diff --git a/gx_tieta/WebRoot/mobil/batt-infor-unapproved-edit.html b/gx_tieta/WebRoot/mobil/batt-infor-unapproved-edit.html
index 3c1a91f..6c7b6aa 100644
--- a/gx_tieta/WebRoot/mobil/batt-infor-unapproved-edit.html
+++ b/gx_tieta/WebRoot/mobil/batt-infor-unapproved-edit.html
@@ -53,7 +53,13 @@
var temp = getCookie("eleparm");
var tempindex = getCookie("eleparmindex");
var tempnum = getCookie("eleparmnum");
+ //var temp
//console.info(temp);
+ var tempgroupid = getCookie("elegroupid");
+ console.info(tempgroupid);
+ tempgroupid = JSON.parse(tempgroupid);
+ console.info(tempindex);
+ console.info(tempnum);
temp=JSON.parse(temp);
tempindex = JSON.parse(tempindex);
tempnum =JSON.parse(tempnum);
@@ -180,12 +186,7 @@
<input type="text" id="FBSDeviceName" data-mini="true" />
</td>
</tr>
- <tr>
- <td>鐢垫睜缁処D</td>
- <td>
- <input type="text" readonly unselectable="on" value="123" id="BattGroupId" class="unable" class="uncheck" data-mini="true" />
- </td>
- </tr>
+
<tr>
<td>鏈烘埧鍐呯數姹犵粍缂栧彿</td>
<td>
@@ -346,7 +347,7 @@
document.getElementById("FbsDeviceIp_WG").value = temp[10];
document.getElementById("FBSDeviceName").value = temp[11];
//document.getElementById("GroupIndexInFBSDevice").value = temp[12];
- document.getElementById("BattGroupId").value = temp[13];
+ //document.getElementById("BattGroupId").value = temp[13];
document.getElementById("BattGroupNum").value = temp[14];
//document.getElementById("BattGroupName").value = temp[15];
document.getElementById("FloatVolLevel").value = temp[16];
@@ -377,6 +378,7 @@
// 鏍煎紡鍖栨彁浜ゅ悗鍙颁俊鎭殑瀵硅薄鏁扮粍淇敼
function getUpdateArr(){
var arr = new Array();
+
for(var i=0;i<tempindex.length;i++){
var battString = "#battname"+i;
var index = String(i);
@@ -400,7 +402,7 @@
FbsDeviceIp_WG : $("#FbsDeviceIp_WG").val(), // 缃戝叧
FBSDeviceName : $("#FBSDeviceName").val(), //璁惧鍚嶇О
GroupIndexInFBSDevice : i, //fbs璁惧绱㈠紩
- BattGroupId : $("#BattGroupId").val(), //鐢垫睜缁刬d
+ BattGroupId : tempgroupid[i], //鐢垫睜缁刬d
BattGroupNum : $("#BattGroupNum").val(), //鏈烘埧鍐呯數姹犵粍缂栧彿
BattGroupName : $(battString).val(),
FloatVolLevel : $("#FloatVolLevel").val(), //娴厖鐢靛帇闃�鍊�
@@ -460,7 +462,7 @@
console.info(model);
if(model.code ==1){
alert("淇敼鎴愬姛");
- window.location.href="batt-unapproved.html"
+ //window.location.href="batt-unapproved.html"
}else{
alert("淇敼澶辫触!");
//window.location.href="batt-unapproved.html"
diff --git a/gx_tieta/WebRoot/mobil/batt-unapproved.html b/gx_tieta/WebRoot/mobil/batt-unapproved.html
index 3993033..1cb5ba3 100644
--- a/gx_tieta/WebRoot/mobil/batt-unapproved.html
+++ b/gx_tieta/WebRoot/mobil/batt-unapproved.html
@@ -162,7 +162,7 @@
console.warn($(t).attr("but-index")+' 淇敼');
var index = $(t).attr("but-index");
setcookiedit(index);
- window.location.href="batt-infor-unapproved-edit.html";
+ //window.location.href="batt-infor-unapproved-edit.html";
return ;
}
@@ -178,7 +178,7 @@
$("#edit").click(function(){
//searchHomeInfoByName(homename);
- window.location.href="batt-infor-unapproved-edit.html";
+ //window.location.href="batt-infor-unapproved-edit.html";
});
$("#delete").click(function(){ //鍒犻櫎鐢垫睜缁�
var parm = battDeleteparm();
@@ -267,25 +267,14 @@
}
});
}
- /* for(i=0;i<340;i++){
- if(i%34==33){
- arrTd[i]='<a onclick="getEditButIndex(this)" id="edit" class="ui-btn ui-btn-inline ui-corner-all operat-but" data-position-to="window"'+'but-index='+i+'>淇敼</a>'+'<a onclick="getDeleteButIndex(this)" href="#myPopup" id="" data-rel="popup" class="ui-btn ui-btn-inline ui-corner-all operat-but fr" data-position-to="window"'+'but-index='+i+'>鍒犻櫎</a>';
-
- continue;
-
- }
-
- arrTd[i]=i*10;
- }
-
- createTbl(tblCon, arrTh, arrTd);
- }*/
-
+
+ //鏌ヨ褰撳墠鏈烘埧鏈夊嚑涓數姹犵粍锛屽苟set鍏OOKIE
function searchHomeInfoByName(id) {
var groupName = new Array();
- var index = 0;
+ //var index = 0;
var num =new Array();
- var index1 = 0;
+ var groupId = new Array();
+ //var index1 = 0;
var temp = {
binf:{
StationId:id, // 鐪�
@@ -308,14 +297,20 @@
data = data.data;
for(var i=0;i<data.length;i++){
console.info(data[i]);
- groupName[index++] = data[i].binf.BattGroupName;
- num[index1++] = data[i].num;
+ groupName[i] = data[i].binf.BattGroupName;
+ num[i] = data[i].num;
+ groupId[i] = data[i].binf.BattGroupId;
}
+
var json = JSON.stringify(groupName);
- var json1 =JSON.stringify(num);
- setCookie("eleparmindex",json);
- setCookie("eleparmnum",json1);
- console.info(groupName);
+ var json1 =JSON.stringify(num);
+ var json2 = JSON.stringify(groupId);
+ setCookie("eleparmindex",json); //鐢垫睜缁勫悕绉�
+ setCookie("eleparmnum",json1); //鐢垫睜缁勭紪鍙�
+ console.info(groupName);
+ setCookie("elegroupid",json2);
+ console.info(json2)
+ window.location.href="batt-infor-unapproved-edit.html";
}
})
@@ -334,11 +329,12 @@
}
}
arrcookie.push($("#newbattnum").val());
- var id = arrcookie[0];
+ var id = arrcookie[0]; //鏈烘埧ID
//console.info(id);
- searchHomeInfoByName(id);
var json=window.JSON.stringify(arrcookie);
setCookie("eleparm",json); //杩欓噷setcookie,鑻ユ湁涓婁竴鏉ookie鍒欐竻绌轰笂涓�绗�
+ searchHomeInfoByName(id);
+
}
function delBatt(parm){
$.ajax({
--
Gitblit v1.9.1