From 1ab3b2b780c69b1d063ac21b9988593e94f67670 Mon Sep 17 00:00:00 2001 From: YYC <1833023622@qq.com> Date: 星期五, 09 六月 2023 10:16:19 +0800 Subject: [PATCH] 工单无数据调整 --- igds-app/js/admin/warn-list.js | 38 ++++++++++++++++++++++++++++++-------- 1 files changed, 30 insertions(+), 8 deletions(-) diff --git a/igds-app/js/admin/warn-list.js b/igds-app/js/admin/warn-list.js index 399937f..7ebf6e3 100644 --- a/igds-app/js/admin/warn-list.js +++ b/igds-app/js/admin/warn-list.js @@ -109,7 +109,6 @@ // } // ] - renderWarn(); } @@ -176,8 +175,7 @@ var html = ''; if (warnList && warnList.length > 0) { $.each(warnList, function(index, item) { - html += '<li><div class="con myfancy" onclick="openPop(\'' + item.id + '\',\'' + (item.remark == - null ? "" : item.remark) + '\',\'' + item.status + '\')">'; + html += '<li><div class="con myfancy" id="'+item.id+'" remark="'+(item.remark == null ? "" : item.remark) +'" status="'+item.status+'" >'; if (item.status == '10') { html += '<span class="type">鏈鐞�</span>'; }else if (item.status == '20') { @@ -207,16 +205,27 @@ html += '<div class="time">' + item.time + '</div></div></li>'; }) } else { - html += - '<li><div class="con myfancy" style="text-align: center;font-size: 20px;color:#dd524d">鏆傛棤璀﹀憡淇℃伅</div></li>'; + html += '<li><div class="con myfancy" id="0" remark="鏆傛棤璀﹀憡淇℃伅" status="30">'; + html += '<span class="type k">宸插鐞�</span>'; + html += '<div class="tit">璀﹀憡鍚嶇О: <span>鏆傛棤璀﹀憡淇℃伅</span></div>'; + html += '<div class="txt">'; + html += '<div class="box"><div class="group c"><div class="desc">--</div><div class="ort">璀﹀憡绫诲瀷</div></div></div>'; + html += '<div class="box"><div class="group c1"><div class="desc">--</div><div class="ort">浠撳簱鍚嶇О</div></div></div>'; + html += '<div class="box"><div class="group level-1"><div class="desc">鏃�</div><div class="ort">璀﹀憡绾у埆</div></div></div></div>'; + html += '<div class="tit coation">璀﹀憡鍐呭: <span>鏃犺鍛婂唴瀹�</span></div>'; + html += '<div class="time">'+dateTime+'</div></div></li>'; + // html += + // '<li><div class="con myfancy" style="text-align: center;font-size: 20px;color:#dd524d">鏆傛棤璀﹀憡淇℃伅</div></li>'; } $("#recordList").html(html); } - //鎵撳紑寮圭獥 -function openPop(warnId, remark, status) { +mui(".mui-scroll-wrapper").on("tap", ".m-caution-mana ul li .myfancy", function() { + var warnId = this.getAttribute("id"); + var status = this.getAttribute("status"); + var remark = this.getAttribute("remark"); dataPop.data.id = warnId; var html = '' if (status == '10') { @@ -226,7 +235,20 @@ $("#handleWarn").html(html); document.getElementById("textareaPop").value = remark; $('#m-pop').css('display', 'flex'); -} +}) + +// //鎵撳紑寮圭獥 +// function openPop(warnId, remark, status) { +// dataPop.data.id = warnId; +// var html = '' +// if (status == '10') { +// html += '<div type="button" class="mui-btn cancel" onclick="handleWarn(\'' + 1 + '\')">蹇界暐</div>' +// html += '<div type="button" class="mui-btn confirm" onclick="handleWarn(\'' + 2 + '\')">澶勭悊</div>' +// } +// $("#handleWarn").html(html); +// document.getElementById("textareaPop").value = remark; +// $('#m-pop').css('display', 'flex'); +// } //璀﹀憡澶勭悊 function handleWarn(tag) { if (tag == "1") { -- Gitblit v1.9.3