From 0adbc72b09cbc1fd3c0f59cb65c3c476d65adc15 Mon Sep 17 00:00:00 2001 From: YYC <1833023622@qq.com> Date: 星期三, 17 五月 2023 18:36:02 +0800 Subject: [PATCH] 工单申请 --- igds-app/css/admin/work-record.css | 105 ++++-- igds-app/js/admin/security-patrol.js | 14 igds-app/work-apply.html | 10 igds-app/work-audit.html | 15 + igds-app/warn-list.html | 6 igds-app/js/admin/work-apply.js | 212 +++++++------- igds-app/js/admin/work-record.js | 70 ++++ igds-app/css/admin/work-audit.css | 202 ++++++++----- igds-app/js/admin/warn-list.js | 96 +++--- igds-app/js/admin/work-audit.js | 98 +++++- igds-app/work-record.html | 21 + 11 files changed, 542 insertions(+), 307 deletions(-) diff --git a/igds-app/css/admin/work-audit.css b/igds-app/css/admin/work-audit.css index f687ee5..b97d89d 100644 --- a/igds-app/css/admin/work-audit.css +++ b/igds-app/css/admin/work-audit.css @@ -1,88 +1,134 @@ -.ul-gdsh li> .con{ - margin-bottom: 11px; +.ul-gdsh li>.con { + margin-bottom: 11px; } -.ul-gdsh >li> .con{ - border-radius: 10px; - overflow: hidden; - background-color: #fff; - box-shadow: 0 0 4px rgba(0,64,40,.1); - margin-bottom: 15px; + +.ul-gdsh>li>.con { + border-radius: 10px; + overflow: hidden; + background-color: #fff; + box-shadow: 0 0 4px rgba(0, 64, 40, .1); + margin-bottom: 15px; } -.ul-gdsh .top{ - display: flex; - align-items: center; - justify-content: space-between; - padding: 13px 15px; - background: url(../../images/icons/g-i27.png) no-repeat center; - background-size: cover; + +.ul-gdsh .top { + display: flex; + align-items: center; + justify-content: space-between; + padding: 13px 15px; + background: url(../../images/icons/g-i27.png) no-repeat center; + background-size: cover; } -.ul-gdsh .top .left{ - flex:1; - font-size: 15px; - line-height: 1.7; - color: #000; + +.ul-gdsh .top .left { + flex: 1; + font-size: 15px; + line-height: 1.7; + color: #000; } -.ul-gdsh .line{ - overflow: hidden; + +.ul-gdsh .line { + overflow: hidden; } -.ul-gdsh .line .t{ - float: left; - min-width: 78px; + +.ul-gdsh .line .t { + float: left; + min-width: 78px; } -.ul-gdsh .line .v{ - text-overflow: ellipsis; - white-space: nowrap; - overflow: hidden; + +.ul-gdsh .line .v { + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; + font-weight: bold; +} + +.ul-gdsh .top .icon { + width: 35px; + height: 35px; + border-radius: 50%; + line-height: 35px; + text-align: center; + font-size: 0; + overflow: hidden; + background-color: #d4e9e0; +} + +.ul-gdsh .top .icon img { + display: inline-block; + vertical-align: middle; + max-width: 16px; +} + +.ul-gdsh .box { + padding: 15px; +} + +.ul-gdsh .time { + font-size: 13px; + color: #666666; + line-height: 25px; +} + +.ul-gdsh .btns { + display: flex; + align-items: center; + justify-content: space-between; + overflow: hidden; + margin-top: 9px; +} + +.ul-gdsh .btns .btn { + display: block; + border-radius: 17px; + text-align: center; + font-size: 16px; + color: #fff; + line-height: 35px; + height: 35px; + width: 47.5%; +} + +.ul-gdsh .btns .btn.refuse { + background: linear-gradient(90deg, #f58541, #edae55); +} + +.ul-gdsh .btns .btn.adopt { + background: linear-gradient(90deg, #23885e, #37a679); +} + +.gd-list .tit { + margin-top: 14px; +} + +.m-server { + width: 300px; + background-color: #fff; + border-radius: 10px; + overflow: hidden; + padding: 28px 25px 30px; +} + +.m-server .h3{ + text-align: center; + font-size: 18px; font-weight: bold; -} -.ul-gdsh .top .icon{ - width: 35px; - height: 35px; - border-radius: 50%; - line-height: 35px; - text-align: center; - font-size: 0; - overflow: hidden; - background-color: #d4e9e0; -} -.ul-gdsh .top .icon img{ - display: inline-block; - vertical-align: middle; - max-width: 16px; -} -.ul-gdsh .box{ - padding: 15px; -} -.ul-gdsh .time{ - font-size: 13px; - color: #666666; - line-height: 25px; -} -.ul-gdsh .btns{ - display: flex; - align-items: center; - justify-content: space-between; - overflow: hidden; - margin-top: 9px; -} -.ul-gdsh .btns .btn{ - display: block; - border-radius: 17px; - text-align: center; - font-size: 16px; - color: #fff; - line-height: 35px; - height: 35px; - width: 47.5%; -} -.ul-gdsh .btns .btn.refuse{ - background: linear-gradient(90deg,#f58541,#edae55); -} -.ul-gdsh .btns .btn.adopt{ - background: linear-gradient(90deg,#23885e,#37a679); + color: #000; + margin-bottom: 18px; } -.gd-list .tit{ - margin-top: 14px; -} +/* .m-pop-caution { + padding: 15px 15px 25px; +} */ + +.m-pop-caution .h3 span{ + color: #ff2323; + +} +.m-pop-caution textarea { + background-color: #f5f6f7; + border-radius: 10px; + margin-bottom: 15px; + border: none; + min-height: 100px; +} \ No newline at end of file diff --git a/igds-app/css/admin/work-record.css b/igds-app/css/admin/work-record.css index 88a6327..c7fd934 100644 --- a/igds-app/css/admin/work-record.css +++ b/igds-app/css/admin/work-record.css @@ -1,41 +1,82 @@ +.ul-sqjl>li>.con { + border-radius: 10px; + overflow: hidden; + background-color: #fff; + box-shadow: 0 0 4px rgba(0, 64, 40, .1); + margin-bottom: 15px; + position: relative; + padding: 0 15px 15px; +} -.ul-sqjl >li> .con{ - border-radius: 10px; - overflow: hidden; - background-color: #fff; - box-shadow: 0 0 4px rgba(0,64,40,.1); - margin-bottom: 15px; - position: relative; - padding: 0 15px 15px; +.ul-sqjl .title { + font-size: 15px; + color: #000; + line-height: 50px; } -.ul-sqjl .title{ - font-size: 15px; - color: #000; - line-height: 50px; + +.ul-sqjl .title b { + margin-left: 10px; } -.ul-sqjl .title b{ - margin-left: 10px; + +.ul-sqjl .time { + color: #666; + line-height: 20px; } -.ul-sqjl .time{ - color: #666; - line-height: 20px; + +.ul-sqjl .time p { + font-size: 13px; + margin-bottom: 0; } -.ul-sqjl .time p{ - font-size: 13px; - margin-bottom: 0; + +.ul-sqjl .time span { + margin-left: 10px; } -.ul-sqjl .time span{ - margin-left: 10px; + +.status { + position: absolute; + top: 0; + right: 0; + font-size: 0; + width: 51.5px; + pointer-events: none; } -.status{ - position: absolute; - top: 0; - right: 0; - font-size: 0; - width: 51.5px; - pointer-events: none; + +.status img { + display: block; + width: 100%; } -.status img{ - display: block; - width: 100%; + + +.m-server { + width: 300px; + background-color: #fff; + border-radius: 10px; + overflow: hidden; + padding: 28px 25px 30px; +} + +.m-server .h3 { + text-align: center; + font-size: 18px; + font-weight: bold; + color: #000; + margin-bottom: 18px; +} + + +/* .m-pop-caution { + padding: 15px 15px 25px; +} */ + +.m-pop-caution .h3 span { + color: #ff2323; + +} + +.m-pop-caution textarea { + background-color: #f5f6f7; + border-radius: 10px; + margin-bottom: 15px; + border: none; + min-height: 100px; } \ No newline at end of file diff --git a/igds-app/js/admin/security-patrol.js b/igds-app/js/admin/security-patrol.js index 8c84ff7..1e58491 100644 --- a/igds-app/js/admin/security-patrol.js +++ b/igds-app/js/admin/security-patrol.js @@ -49,9 +49,10 @@ data1.tokenAuth = user.tokenAuth; data2.tokenAuth = user.tokenAuth; data.data.deptId = selectDeptId; - data2.data.deptId = selectDeptId; + data1.data.deptId = selectDeptId; dateTime = getDate(new Date()) document.getElementById("date").value = dateTime; + console.log(JSON.stringify(data.data),"鐢靛瓙宸℃洿璁板綍","security-patrol") //鑾峰彇宸℃洿璁板綍 getPatrolList() @@ -113,7 +114,7 @@ } else { renderPatrol(); mui.toast(result.msg); - console.log(JSON.stringify(result)) + // console.log(JSON.stringify(result)) } }, error: function() { @@ -151,8 +152,7 @@ if (PatrolList && PatrolList.length > 0) { $.each(PatrolList, function(index, item) { html += '<li><div class="item"><div class="top">' - html += '<div class="date">' + item.createTime + '</div><div class="r-btn" id = "' + item.id + - '">鏌ョ湅鐓х墖</div></div>'; + html += '<div class="date">' + item.createTime + '</div><div class="r-btn" id = "' + item.id + '">鏌ョ湅鐓х墖</div></div>'; html += '<div class="cards"><div class="cd"><div class="con user">' html += '<div class="tit">鎵撳崱浜�</div><div class="txt">' + item.userName + '</div></div></div>'; html += '<div class="cd"><div class="con loc"><div class="tit">鍧愭爣</div>' @@ -217,8 +217,6 @@ $('.m-pop').fadeOut(); }); - - //浣跨敤鐩告満鎷嶇収 function cameraImg() { var cmr = plus.camera.getCamera(); @@ -245,7 +243,7 @@ }, function(t, status) { //涓婁紶瀹屾垚 if (status == 200) { - var html = ''; + // var html = ''; var obj = JSON.parse(t.responseText); mui.toast("涓婁紶鎴愬姛锛�"); data1.data.imgName = obj.data.fileName; @@ -290,8 +288,6 @@ } }) } - - // function getLatLon() { // plus.geolocation.getCurrentPosition(function(position) { diff --git a/igds-app/js/admin/warn-list.js b/igds-app/js/admin/warn-list.js index 8c7519c..10422bb 100644 --- a/igds-app/js/admin/warn-list.js +++ b/igds-app/js/admin/warn-list.js @@ -69,49 +69,45 @@ mui.alert("绯荤粺绻佸繖,璇烽噸璇曪紒", "鎻愮ず", ["纭畾"], function() {}, "div") } }) - // warnData ={ - // "data": [ - // { - // "id": "88", - // "name": "鎷夌洰浜涜皟", - // "type": "nostrud", - // "eventType": "cillumreprehenderitest", - // "level": "1", - // "status": "40", - // "time": "2006-11-01 14:01:36", - // "info": "dolor", - // "depotId": "6", - // "depotName": "", - // "remark":"00000" - // }, - // { - // "id": "56", - // "name": "娉曢兘璞″彨涓庡眬", - // "type": "cillumreprehenderitUt", - // "eventType": "in", - // "level": "2", - // "status": "20", - // "time": "1981-02-18 22:28:23", - // "info": "deserunt Excepteur aliqua veniam commodo", - // "depotId": "28", - // "depotName": "榫欑敤鏀圭礌", - // "remark":"1111" - // },{ - // "id": "72", - // "name": "鍗庢灄涔濆埆", - // "type": "exdeseruntcillumeu", - // "eventType": "aliqua sint dolor aute", - // "level": "1", - // "status": "10", - // "time": "1978-07-23 12:17:27", - // "info": "deserunt nostrud id tempor", - // "depotId": "70", - // "depotName": "鍘垮織閫夊彧", - // "remark":"" - // } - // ] - // } - + warnList = [{ + "id": "88", + "name": "鎷夌洰浜涜皟", + "type": "nostrud", + "eventType": "cillumreprehenderitest", + "level": "1", + "status": "40", + "time": "2006-11-01 14:01:36", + "info": "dolor", + "depotId": "6", + "depotName": "", + "remark": "00000" + }, + { + "id": "56", + "name": "娉曢兘璞″彨涓庡眬", + "type": "cillumreprehenderitUt", + "eventType": "in", + "level": "2", + "status": "20", + "time": "1981-02-18 22:28:23", + "info": "deserunt Excepteur aliqua veniam commodo", + "depotId": "28", + "depotName": "榫欑敤鏀圭礌", + "remark": "1111" + }, { + "id": "72", + "name": "鍗庢灄涔濆埆", + "type": "exdeseruntcillumeu", + "eventType": "aliqua sint dolor aute", + "level": "1", + "status": "10", + "time": "1978-07-23 12:17:27", + "info": "deserunt nostrud id tempor", + "depotId": "70", + "depotName": "鍘垮織閫夊彧", + "remark": "" + } + ] renderWarn(); } @@ -223,11 +219,11 @@ dataPop.data.id = warnId; var html = '' if (status == '10') { - html += '<button type="button" class="mui-btn cancel" onclick="handleWarn("1")">蹇界暐</button>' - html += '<button type="button" class="mui-btn confirm" onclick="handleWarn("2")">澶勭悊</button>' + 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); - $("#textareaPop").val(remark) + document.getElementById("textareaPop").value = remark; $('#m-pop').css('display', 'flex'); } //璀﹀憡澶勭悊 @@ -240,7 +236,8 @@ dataPop.data.status = '30' // mui.toast("璀﹀憡澶勭悊"); } - dataPop.data.remark = mui("#textareaPop")[0].value; + dataPop.data.remark = document.getElementById("textareaPop").value; + console.log(JSON.stringify(dataPop.data),"warn-list") //璇锋眰 mui.ajax(url, { type: "POST", @@ -250,10 +247,11 @@ data: JSON.stringify(dataPop), success: function(result) { if (result.code == "0000") { - console.log(JSON.stringify(result)) + mui.toast(result.msg); + // console.log(JSON.stringify(result)) } else { mui.toast(result.msg); - console.log(JSON.stringify(result)) + // console.log(JSON.stringify(result)) } }, error: function() { diff --git a/igds-app/js/admin/work-apply.js b/igds-app/js/admin/work-apply.js index 6c93a9f..7f57f76 100644 --- a/igds-app/js/admin/work-apply.js +++ b/igds-app/js/admin/work-apply.js @@ -1,4 +1,38 @@ var url = null; +var depotData; +var name = '' +var listPicker2 = []; +var list = [{ + value: 'ywj', + text: '钁d簨闀� 鍙舵枃娲�' +}, { + value: 'aaa', + text: '鎬荤粡鐞� 鑹続A' +}, { + value: 'lj', + text: '缃楄緫' +}, { + value: 'ymt', + text: '浜戝ぉ鏄�' +}, { + value: 'shq', + text: '鍙插己' +}, { + value: 'zhbh', + text: '绔犲寳娴�' +}, { + value: 'zhy', + text: '搴勯' +}, { + value: 'gyf', + text: '鍏充竴甯�' +}, { + value: 'zhz', + text: '鏅哄瓙' +}, { + value: 'gezh', + text: '姝岃��' +}] //宸ュ崟鐢宠 var data = { "interfaceId": "5701", @@ -13,12 +47,23 @@ } }; //鑾峰彇搴撳尯鍒楄〃 -var data = { +var data1 = { "interfaceId": "5002", "outId": "10002", "reqDateTime": new Date(), "tokenAuth": "", + "data": {} +}; + +//鑾峰彇浠撳簱鍒楄〃 +var data2 = { + "interfaceId": "5102", + "sign": "10102", + "outId": "10102", + "reqDateTime": new Date(), + "tokenAuth": "", "data": { + "deptId": "" } }; @@ -28,12 +73,16 @@ var selectDeptId = JSON.parse(localStorage.getItem('selectDeptId')); url = user.url + "/api-phone/v35/gateway"; data.tokenAuth = user.tokenAuth; - // data.data.deptId = selectDeptId; + data2.tokenAuth = user.tokenAuth; + data2.data.deptId = selectDeptId; + depotList(); + } function chooseDate() { var dtpicker = new mui.DtPicker({ - type: "date", //璁剧疆鏃ュ巻鍒濆瑙嗗浘妯″紡 + // type: "hour", //璁剧疆鏃ュ巻鍒濆瑙嗗浘妯″紡 + type: "datetime", // beginDate: new Date(2015, 04, 25), //璁剧疆寮�濮嬫棩鏈� // endDate: new Date(2016, 04, 25), //璁剧疆缁撴潫鏃ユ湡 @@ -48,7 +97,8 @@ function chooseDate1() { var dtpicker = new mui.DtPicker({ - type: "date", //璁剧疆鏃ュ巻鍒濆瑙嗗浘妯″紡 + // type: "hour", //璁剧疆鏃ュ巻鍒濆瑙嗗浘妯″紡 + type: "datetime", // beginDate: new Date(2015, 04, 25), //璁剧疆寮�濮嬫棩鏈� // endDate: new Date(2016, 04, 25), //璁剧疆缁撴潫鏃ユ湡 @@ -63,6 +113,7 @@ //宸ュ崟鐢宠 function workApply() { + console.log(JSON.stringify(data.data)) //鍙戦�佽姹傝繘琛屽伐鍗曠敵璇� mui.ajax(url, { type: "POST", @@ -74,6 +125,7 @@ if (result.code == "0000") { console.log(JSON.stringify(result)) } else { + // console.log(JSON.stringify(result)) mui.alert(result.msg, '鎻愮ず', ["纭畾"], function() {}, "div"); } }, @@ -83,10 +135,47 @@ }) } +function depotList() { + //鑾峰彇浠撳簱鍒楄〃 + mui.ajax(url, { + type: "POST", + dataType: "json", + crossDomain: true, + contentType: "application/json;charset=utf-8", + data: JSON.stringify(data2), + success: function(result) { + if (result.code == "0000") { + depotData = result.data + conversion(depotData); + // console.log(JSON.stringify(result)) + } else { + mui.alert(result.msg, '鎻愮ず', ["纭畾"], function() {}, "div"); + } + }, + error: function() { + mui.alert('绯荤粺绻佸繖,璇烽噸鏂扮櫥褰曞皾璇曪紒', '鎻愮ず', ["纭畾"], function() {}, "div"); + } + }) +} + +function conversion(data) { + var fenl = {} + $.each(data, function(index, item) { + fenl = { + value: item.name, + text: item.id, + } + listPicker2.push(fenl) + }) +} + //鎻愪氦 mui(".mui-scroll").on("tap", ".wp form .submit", function() { - console.log("111") workApply(); + window.location.reload(); + // window.setTimeout(function() { + // window.location.reload(); + // }, 200) }) mui('.mui-scroll-wrapper').scroll({ @@ -95,6 +184,8 @@ bounce: false, //鏄惁鍚敤鍥炲脊 deceleration: 0.0005 //flick 鍑忛�熺郴鏁帮紝绯绘暟瓒婂ぇ锛屾粴鍔ㄩ�熷害瓒婃參锛屾粴鍔ㄨ窛绂昏秺灏忥紝榛樿鍊�0.0006 }); + + (function($, doc) { $.init(); $.ready(function() { @@ -108,43 +199,14 @@ return obj[param] || ''; }; //鏅�氱ず渚� - var userPicker = new $.PopPicker(); - userPicker.setData([{ - value: 'ywj', - text: '钁d簨闀� 鍙舵枃娲�' - }, { - value: 'aaa', - text: '鎬荤粡鐞� 鑹続A' - }, { - value: 'lj', - text: '缃楄緫' - }, { - value: 'ymt', - text: '浜戝ぉ鏄�' - }, { - value: 'shq', - text: '鍙插己' - }, { - value: 'zhbh', - text: '绔犲寳娴�' - }, { - value: 'zhy', - text: '搴勯' - }, { - value: 'gyf', - text: '鍏充竴甯�' - }, { - value: 'zhz', - text: '鏅哄瓙' - }, { - value: 'gezh', - text: '姝岃��' - }]); var showUserPickerButton = doc.getElementById('ywlx'); - var userResult = doc.getElementById('ywlx-val'); showUserPickerButton.addEventListener('tap', function(event) { + var userResult = doc.getElementById('ywlx-val'); + var userPicker = new $.PopPicker(); + userPicker.setData(list); userPicker.show(function(items) { // userResult.innerText = JSON.stringify(items[0]); + console.log(JSON.stringify(items)) userResult.innerText = items[0].text; // userResult.previousSibling.style.display="none" jQuery(userResult).prev().hide() @@ -154,41 +216,11 @@ }, false); //----------------------------------------- //鎵�灞炲垎搴�: - var picker1 = new $.PopPicker(); - picker1.setData([{ - value: 'ywj', - text: '钁d簨闀� 鍙舵枃娲�' - }, { - value: 'aaa', - text: '鎬荤粡鐞� 鑹続A' - }, { - value: 'lj', - text: '缃楄緫' - }, { - value: 'ymt', - text: '浜戝ぉ鏄�' - }, { - value: 'shq', - text: '鍙插己' - }, { - value: 'zhbh', - text: '绔犲寳娴�' - }, { - value: 'zhy', - text: '搴勯' - }, { - value: 'gyf', - text: '鍏充竴甯�' - }, { - value: 'zhz', - text: '鏅哄瓙' - }, { - value: 'gezh', - text: '姝岃��' - }]); var showPicker1Button = doc.getElementById('ssfk'); - var picker1Result = doc.getElementById('ssfk-val'); showPicker1Button.addEventListener('tap', function(event) { + var picker1Result = doc.getElementById('ssfk-val'); + var picker1 = new $.PopPicker(); + picker1.setData(list); picker1.show(function(items) { // userResult.innerText = JSON.stringify(items[0]); picker1Result.innerText = items[0].text; @@ -200,50 +232,20 @@ }, false); //----------------------------------------- //鍏宠仈浠撳簱: - var picker2 = new $.PopPicker(); - picker2.setData([{ - value: 'ywj', - text: '钁d簨闀� 鍙舵枃娲�' - }, { - value: 'aaa', - text: '鎬荤粡鐞� 鑹続A' - }, { - value: 'lj', - text: '缃楄緫' - }, { - value: 'ymt', - text: '浜戝ぉ鏄�' - }, { - value: 'shq', - text: '鍙插己' - }, { - value: 'zhbh', - text: '绔犲寳娴�' - }, { - value: 'zhy', - text: '搴勯' - }, { - value: 'gyf', - text: '鍏充竴甯�' - }, { - value: 'zhz', - text: '鏅哄瓙' - }, { - value: 'gezh', - text: '姝岃��' - }]); var showPicker2Button = doc.getElementById('glck'); - var picker2Result = doc.getElementById('glck-val'); showPicker2Button.addEventListener('tap', function(event) { + var picker2Result = doc.getElementById('glck-val'); + var picker2 = new $.PopPicker(); + picker2.setData(listPicker2); picker2.show(function(items) { // userResult.innerText = JSON.stringify(items[0]); picker2Result.innerText = items[0].text; + data.data.depotId = items[0].value; // userResult.previousSibling.style.display="none" jQuery(picker2Result).prev().hide() //杩斿洖 false 鍙互闃绘閫夋嫨妗嗙殑鍏抽棴 //return false; }); }, false); - }); })(mui, document); \ No newline at end of file diff --git a/igds-app/js/admin/work-audit.js b/igds-app/js/admin/work-audit.js index 186708c..9e5e04f 100644 --- a/igds-app/js/admin/work-audit.js +++ b/igds-app/js/admin/work-audit.js @@ -30,7 +30,7 @@ data.tokenAuth = user.tokenAuth; data1.tokenAuth = user.tokenAuth; data.data.deptId = selectDeptId; - + getAuditList(); } @@ -50,15 +50,63 @@ } else { renderAuditList(); mui.alert(result.msg, '鎻愮ず', ["纭畾"], function() {}, "div"); - } }, error: function() { renderAuditList(); mui.alert('绯荤粺绻佸繖,璇烽噸鏂扮櫥褰曞皾璇曪紒', '鎻愮ず', ["纭畾"], function() {}, "div"); - + } }) + auditList = [{ + "id": "59", + "deptName": "1鍙蜂粨", + "applyUser": "in anim exercitation", + "applyUserName": "閮濆啗", + "type": "exercitation reprehenderit sint", + "startTime": "1974-07-05 21:56", + "endTime": "2013-08-19 05:43", + "info": "sed adipisicing quis irure", + "depotId": "90", + "depotName": "鍗充紶鐘舵柊浜旈檯" + }, + { + "id": "39", + "deptName": "1鍙蜂粨", + "applyUser": "dolor laboris", + "applyUserName": "琚佸己", + "type": "sed et sit irure eu", + "startTime": "2015-10-25 12:30", + "endTime": "1971-04-18 19:34", + "info": "reprehenderit qui quis pariatur anim", + "depotId": "89", + "depotName": "褰撳叆鐗╄繕绠�" + }, + { + "id": "55", + "deptName": "3鍙蜂粨", + "applyUser": "quis", + "applyUserName": "瀹嬩附", + "type": "in", + "startTime": "1994-10-12 18:25", + "endTime": "2008-01-19 00:26", + "info": "ex ullamco id dolor", + "depotId": "42", + "depotName": "鏂板父鎶�浣嶄腑" + }, + { + "id": "50", + "deptName": "2鍙蜂粨", + "applyUser": "dolor", + "applyUserName": "榛勮秴", + "type": "nostrud elit", + "startTime": "2018-07-07 10:25", + "endTime": "2000-11-07 10:02", + "info": "et minim", + "depotId": "53", + "depotName": "浜虹瀹冨啗棰�" + } + ] } function renderAuditList() { @@ -66,19 +114,26 @@ if (auditList && auditList.length > 0) { $.each(auditList, function(index, item) { html += '<li><div class="con"><div class="top"><div class="left">'; - html += '<div class="line"><div class="t">鐢宠浜�: </div><div class="v">' + item.applyUserName + '</div></div>'; - html += '<div class="line"><div class="t">鎵�灞炲垎搴�:</div><div class="v">' + (item.deptName == null ? "" : item.deptName) + '</div></div></div>'; - html += '<div class="right"><div class="icon" info="' + item.info + '"><img src="images/icons/g-i26.png" alt=""></div></div></div>'; - html += '<div class="box"><ul class="gd-list"><li><a href="" class="con" style="background-image: url(images/icons/a-bg12.png);">'; + html += '<div class="line"><div class="t">鐢宠浜�: </div><div class="v">' + item.applyUserName + + '</div></div>'; + html += '<div class="line"><div class="t">鎵�灞炲垎搴�:</div><div class="v">' + (item.deptName == null ? + "" : item.deptName) + '</div></div></div>'; + html += '<div class="right"><div class="icon" info="' + item.info + + '"><img src="images/icons/g-i26.png" alt=""></div></div></div>'; + html += + '<div class="box"><ul class="gd-list"><li><a href="" class="con" style="background-image: url(images/icons/a-bg12.png);">'; html += '<div class="tit">涓氬姟绫诲瀷:</div><div class="name">' + item.type + '</div></a></li>'; html += '<li><a href="" class="con" style="background-image: url(images/icons/a-bg13.png);">'; - html += '<div class="tit">鍏宠仈浠撳簱:</div><div class="name">' + (item.depotName == null ? "--" : item.depotName) + '</div></a></li></ul>'; + html += '<div class="tit">鍏宠仈浠撳簱:</div><div class="name">' + (item.depotName == null ? "--" : item + .depotName) + '</div></a></li></ul>'; html += '<div class="time">鏈夋晥鏈�: ' + item.startTime + '鑷�' + item.endTime + ' </div>'; - html += '<div class="btns" id="'+ item.id +'"><a href="" class="btn refuse">鎷掔粷</a><a href="" class="btn adopt">閫氳繃</a></div>'; + html += '<div class="btns"><a href="" id = "' + item.id + + '" class="btn refuse">鎷掔粷</a><a href="" id = "' + item.id + '" class="btn adopt">閫氳繃</a></div>'; html += '</div></div></div></li>'; }) } else { - html += '<li><div class="con"><div style="text-align: center;font-size: 20px;color:#dd524d;padding: 18px;">鏆傛棤宸ュ崟瀹℃牳淇℃伅</div></div></li>'; + html += + '<li><div class="con"><div style="text-align: center;font-size: 20px;color:#dd524d;padding: 18px;">鏆傛棤宸ュ崟瀹℃牳淇℃伅</div></div></li>'; } $("#handleList").html(html); } @@ -96,7 +151,7 @@ workAuditData = result.data; // console.log(JSON.stringify(auditList)) } else { - mui.alert(result.msg, '鎻愮ず', ["纭畾"], function() {}, "div"); + mui.alert(result.msg, '鎻愮ず', ["纭畾"], function() {}, "div"); } }, error: function() { @@ -106,29 +161,38 @@ } //鎷掔粷 -mui(".mui-scroll").on("tap",".wp ul li .refuse",function(){ +mui(".mui-scroll").on("tap", ".wp ul li .refuse", function() { var id = this.getAttribute("id"); + console.log(id) data1.data.id = id data1.data.status = '10' workAudit(); - console.log("鎷掔粷") + console.log(JSON.stringify(data1.data), "work-audit", "鎷掔粷") }) //閫氳繃 -mui(".mui-scroll").on("tap",".wp ul li .adopt",function(){ +mui(".mui-scroll").on("tap", ".wp ul li .adopt", function() { var id = this.getAttribute("id"); + console.log(id) data1.data.id = id data1.data.status = '20' workAudit(); - console.log("閫氳繃") + console.log(JSON.stringify(data1.data), "work-audit", "閫氳繃") }) //鏌ョ湅鐢宠鍐呭 -mui(".mui-scroll").on("tap",".wp ul li .icon",function(){ +mui(".mui-scroll").on("tap", ".wp ul li .icon", function() { var info = this.getAttribute("info") - mui.alert(info, '宸ュ崟鍐呭', ["纭畾"], function() {}, "div"); + // mui.alert(info, '宸ュ崟鍐呭', ["纭畾"], function() {}, "div"); + $("#textareaPop").val(info) + $('#m-pop').css('display', 'flex'); console.log("鐢宠鍐呭") }) +//鍏抽棴寮圭獥 +function closePop() { + $("#m-pop").css('display', 'none'); +} + mui('.mui-scroll-wrapper').scroll({ indicators: false, //鏄惁鏄剧ず婊氬姩鏉� deceleration: 0.0006, //闃诲凹绯绘暟,绯绘暟瓒婂皬婊戝姩瓒婄伒鏁� diff --git a/igds-app/js/admin/work-record.js b/igds-app/js/admin/work-record.js index de11e4c..2f63e8c 100644 --- a/igds-app/js/admin/work-record.js +++ b/igds-app/js/admin/work-record.js @@ -16,6 +16,7 @@ url = user.url + "/api-phone/v35/gateway"; data.tokenAuth = user.tokenAuth; data.data.userName = user.userName; + console.log(JSON.stringify(data.data),"work-record") getRecordList(); } @@ -42,24 +43,75 @@ mui.alert('绯荤粺绻佸繖,璇烽噸鏂扮櫥褰曞皾璇曪紒', '鎻愮ず', ["纭畾"], function() {}, "div"); } }) + recordList = [{ + "id": "59", + "deptName": "1鍙蜂粨", + "status": "10", + "applyUserName": "閮濆啗", + "type": "exercitation reprehenderit sint", + "startTime": "1974-07-05 21:56", + "endTime": "2013-08-19 05:43", + "info": "sed adipisicing quis irure", + "depotId": "90", + "depotName": "鍗充紶鐘舵柊浜旈檯" + }, + { + "id": "39", + "deptName": "1鍙蜂粨", + "status": "20", + "applyUserName": "琚佸己", + "type": "sed et sit irure eu", + "startTime": "2015-10-25 12:30", + "endTime": "1971-04-18 19:34", + "info": "reprehenderit qui quis pariatur anim", + "depotId": "89", + "depotName": "褰撳叆鐗╄繕绠�" + }, + { + "id": "55", + "deptName": "3鍙蜂粨", + "status": "20", + "applyUserName": "瀹嬩附", + "type": "in", + "startTime": "1994-10-12 18:25", + "endTime": "2008-01-19 00:26", + "info": "ex ullamco id dolor", + "depotId": "42", + "depotName": "鏂板父鎶�浣嶄腑" + }, + { + "id": "50", + "deptName": "2鍙蜂粨", + "status": "10", + "applyUserName": "榛勮秴", + "type": "nostrud elit", + "startTime": "2018-07-07 10:25", + "endTime": "2000-11-07 10:02", + "info": "et minim", + "depotId": "53", + "depotName": "浜虹瀹冨啗棰�" + } + ] } function renderRecordList() { var html = ''; if (recordList && recordList.length > 0) { $.each(recordList, function(index, item) { - html += '<li><div class="con" info = "' + item.info + '"><span class="status">'; + html += '<li><div class="con conInfo" info = "' + item.info + '"><span class="status">'; //宸插鏍� if (item.status == '10') { html += '<img src="images/icons/g-i29.png" alt=""></span>' } else if (item.status == '20') { // 寰呭鏍� html += '<img src="images/icons/g-i28.png" alt=""></span>' } - html += '<div class="title">鎵�灞炲垎搴�:<b>' + item.deptName + '</b></div><div class="box"><ul class="gd-list">'; + html += '<div class="title">鎵�灞炲垎搴�:<b>' + item.deptName + + '</b></div><div class="box"><ul class="gd-list">'; html += '<li><a href="" class="con"style="background-image: url(images/icons/a-bg12.png);">'; html += '<div class="tit">涓氬姟绫诲瀷:</div><div class="name">' + item.type + '</div></a></li>'; html += '<li><a href="" class="con"style="background-image: url(images/icons/a-bg13.png);">'; - html += '<div class="tit">鍏宠仈浠撳簱:</div><div class="name">' + (item.depotName == null ? "--" : item.depotName) + '</div></a></li></ul>'; + html += '<div class="tit">鍏宠仈浠撳簱:</div><div class="name">' + (item.depotName == null ? "--" : item + .depotName) + '</div></a></li></ul>'; html += '<div class="time"><p>鏈夋晥寮�濮嬫椂闂�: <span>' + item.startTime + '</span></p><p>鏈夋晥缁撴潫鏃堕棿: <span>' + item.endTime + '</span></p></div>'; }) @@ -68,16 +120,22 @@ '<li><div class="con"><div style="text-align: center;font-size: 20px;color:#dd524d;padding-top: 18px;">鏆傛棤鐢宠璁板綍淇℃伅</div></div></li>'; } $("#handleList").html(html); - } //鏌ョ湅淇℃伅 -mui(".mui-scroll").on("tap",".wp ul li .con",function(){ +mui(".mui-scroll").on("tap", ".wp ul li .conInfo", function() { var info = this.getAttribute("info"); - mui.alert(info, '宸ュ崟鍐呭', ["纭畾"], function() {}, "div"); + // mui.alert(info, '宸ュ崟鍐呭', ["纭畾"], function() {}, "div"); + $("#textareaPop").val(info) + $('#m-pop').css('display', 'flex'); console.log("鏌ョ湅淇℃伅") }) +//鍏抽棴寮圭獥 +function closePop() { + $("#m-pop").css('display', 'none'); +} + mui('.mui-scroll-wrapper').scroll({ indicators: false, //鏄惁鏄剧ず婊氬姩鏉� deceleration: 0.0006, //闃诲凹绯绘暟,绯绘暟瓒婂皬婊戝姩瓒婄伒鏁� diff --git a/igds-app/warn-list.html b/igds-app/warn-list.html index eab22dd..ba04b00 100644 --- a/igds-app/warn-list.html +++ b/igds-app/warn-list.html @@ -33,7 +33,7 @@ <div class="m-pow-dist"> <div class="m-caution-mana"> <ul class="ul-listmana ul-listcaut1" id="recordList"> - <!-- <li> + <li> <div class="con myfancy" onclick="openPop('11')"> <span class="type">鏈鐞�</span> <div class="tit"> @@ -151,8 +151,8 @@ </div> </form> <div class="btns" id="handleWarn"> - <button type="button" class="mui-btn cancel" onclick="handleWarn('1')">蹇界暐</button> - <button type="button" class="mui-btn confirm" onclick="handleWarn('2')">澶勭悊</button> + <div type="button" class="mui-btn cancel" onclick="handleWarn('1')">蹇界暐</div> + <div type="button" class="mui-btn confirm" onclick="handleWarn('2')">澶勭悊</div> </div> </div> <div class="close" onclick="closePop()"><span class="mui-icon mui-icon-close"></span></div> diff --git a/igds-app/work-apply.html b/igds-app/work-apply.html index 89c4aab..fc2874b 100644 --- a/igds-app/work-apply.html +++ b/igds-app/work-apply.html @@ -22,18 +22,18 @@ </header> <div class="mui-content"> - <div class="mui-scroll-wrapper g-src_box"> + <div class="mui-scroll-wrapper g-src_box" > <div class="mui-scroll"> <div class="wp"> <form action=""> - <div class="m-gd"> + <div class="m-gd" > <div class="group"> <div class="l">涓氬姟绫诲瀷:</div> <div class="r"> <div class="val" id="ywlx"> <div class="placeholder">璇烽�夋嫨</div> - <div class="real-val" id="ywlx-val" onclick="searchType()"></div> + <div class="real-val" id="ywlx-val" ></div> </div> </div> </div> @@ -42,7 +42,7 @@ <div class="r"> <div class="val" id="ssfk"> <div class="placeholder">璇烽�夋嫨</div> - <div class="real-val" id="ssfk-val" onclick="searchType()"></div> + <div class="real-val" id="ssfk-val" ></div> </div> </div> </div> @@ -51,7 +51,7 @@ <div class="r"> <div class="val" id="glck"> <div class="placeholder">璇烽�夋嫨</div> - <div class="real-val" id="glck-val" onclick="searchType()"></div> + <div class="real-val" id="glck-val" ></div> </div> </div> </div> diff --git a/igds-app/work-audit.html b/igds-app/work-audit.html index ad6bca6..1f7c8a7 100644 --- a/igds-app/work-audit.html +++ b/igds-app/work-audit.html @@ -160,6 +160,21 @@ </div> </div> </div> + + <div id="m-pop" class="m-pop"> + <div class="pop-bg"></div> + <div class="inner"> + <div class="m-server m-pop-caution"> + <div class="h3"><span class="red">*</span> 宸ュ崟鍐呭</div> + <form class=""> + <div class="mui-input-row"> + <textarea id="textareaPop" rows="" cols="" readonly></textarea> + </div> + </form> + </div> + <div class="close" onclick="closePop()"><span class="mui-icon mui-icon-close"></span></div> + </div> + </div> </div> </body> <script src="js/mui.min.js"></script> diff --git a/igds-app/work-record.html b/igds-app/work-record.html index 61eeca1..4ab1240 100644 --- a/igds-app/work-record.html +++ b/igds-app/work-record.html @@ -23,7 +23,7 @@ <div class="wp"> <ul class="ul-sqjl" id="handleList"> <li> - <div class="con" info="111"> + <div class="con conInfo" info="111"> <span class="status"> <img src="images/icons/g-i28.png" alt=""> </span> @@ -53,7 +53,7 @@ </div> </li> <li> - <div class="con" info="111" > + <div class="con conInfo" info="111" > <span class="status"> <img src="images/icons/g-i28.png" alt=""> </span> @@ -83,7 +83,7 @@ </div> </li> <li> - <div class="con" info="111"> + <div class="con conInfo" info="111"> <span class="status"> <img src="images/icons/g-i29.png" alt=""> </span> @@ -116,6 +116,21 @@ </div> </div> + + <div id="m-pop" class="m-pop"> + <div class="pop-bg"></div> + <div class="inner"> + <div class="m-server m-pop-caution"> + <div class="h3"><span class="red">*</span> 宸ュ崟鍐呭</div> + <form class=""> + <div class="mui-input-row"> + <textarea id="textareaPop" rows="" cols="" readonly></textarea> + </div> + </form> + </div> + <div class="close" onclick="closePop()"><span class="mui-icon mui-icon-close"></span></div> + </div> + </div> </div> </div> </body> -- Gitblit v1.9.3