| | |
| | | Pub_Close(2); |
| | | } else { |
| | | Pub_Close(1); |
| | | } |
| | | } |
| | | //var index = parent.layer.getFrameIndex(window.name); //å
å¾å°å½åiframeå±çç´¢å¼ |
| | | //parent.layer.close(index); //åæ§è¡å
³é |
| | | }); |
| | |
| | | , done: function (res, curr, count) { |
| | | |
| | | } |
| | | }; |
| | | }; |
| | | } |
| | | |
| | | //ä¿å |
| | |
| | | |
| | | //å¢å ä¸è¡ |
| | | function btnAddLine(NewRow) { |
| | | //table.cache["mainTable"].push(NewRow); |
| | | //option.data = table.cache["mainTable"]; |
| | | //table.render(option); |
| | | var tableBak = table.cache["mainTable"]; //è·åä¹åç¼è¾è¿çè¡¨æ ¼æ°æ® |
| | | buttonArr = [];//æ¸
空æ°ç» |
| | | for (var i = 0; i < tableBak.length; i++) { |
| | | buttonArr.push(tableBak[i]); //å°ä¹åçæ°æ®åå¨ |
| | | table.cache["mainTable"].push(NewRow); |
| | | option.data = table.cache["mainTable"]; |
| | | table.render(option); |
| | | for (var i = 1; i <= option.data.length; i++) { |
| | | $('#HAnalysisMethod' + i + '').find("option[value='" + option.data[i - 1].HAnalysisMethod + "']").attr("selected", true); |
| | | $('#HDefectLevel' + i + '').find("option[value='" + option.data[i - 1].HDefectLevel + "']").attr("selected", true); |
| | | $('#HStatus' + i + '').find("option[value='" + option.data[i - 1].HStatus + "']").attr("selected", true); |
| | | |
| | | if (option.data[i - 1].HDestructInspect) { |
| | | $('#HDestructInspect' + i + '').attr("checked", true); |
| | | } |
| | | if (option.data[i - 1].HKeyInspect) { |
| | | $('#HKeyInspect' + i + '').attr("checked", true); |
| | | } |
| | | } |
| | | buttonArr.push(NewRow); //å¨å°¾é¨å ä¸è¡ |
| | | table.reload("mainTable", { |
| | | data: buttonArr //å°æ°æ®éæ°è½½å
¥è¡¨æ ¼ |
| | | }) |
| | | form.render('select'); |
| | | form.render('checkbox'); |
| | | } |
| | | |
| | | //å¤å¶ä¸è¡ |
| | |
| | | table.cache["mainTable"].push(JSON.parse(copyrow));//å°å¤å¶çè¡å¼ºè½¬æjson追å å°è¡¨æ ¼ä¸ |
| | | option.data = table.cache["mainTable"];//å°æ°æ®ç»å®å°dataä¸ |
| | | table.render(option);//å°æ°æ®æ¸²æå°è¡¨æ ¼ä¸ |
| | | for (var i = 1; i <= option.data.length; i++) { |
| | | $('#HAnalysisMethod' + i + '').find("option[value='" + option.data[i - 1].HAnalysisMethod + "']").attr("selected", true); |
| | | $('#HDefectLevel' + i + '').find("option[value='" + option.data[i - 1].HDefectLevel + "']").attr("selected", true); |
| | | $('#HStatus' + i + '').find("option[value='" + option.data[i - 1].HStatus + "']").attr("selected", true); |
| | | |
| | | if (option.data[i - 1].HDestructInspect) { |
| | | $('#HDestructInspect' + i + '').attr("checked", true); |
| | | } |
| | | if (option.data[i - 1].HKeyInspect) { |
| | | $('#HKeyInspect' + i + '').attr("checked", true); |
| | | } |
| | | } |
| | | form.render('select'); |
| | | form.render('checkbox'); |
| | | } |
| | | } |
| | | |