| | |
| | | <img src="images/icons/g-i33.png" alt=""> |
| | | </div> |
| | | <div class="inpbox"> |
| | | <input type="search" class="mui-input-clear" placeholder="请è¾å
¥è½¦çä¿¡æ¯æ£ç´¢" value=""> |
| | | <input id="plateNum" type="search" class="mui-input-clear" placeholder="请è¾å
¥è½¦çä¿¡æ¯æ£ç´¢" value=""> |
| | | </div> |
| | | <div class="s-btn"><img src="images/icons/g-i22.png" alt="">读å¡</div> |
| | | <button type="button" class="mui-btn">æ¥è¯¢</button> |
| | | <button type="button" class="mui-btn" onclick="getOutHandleList()">æ¥è¯¢</button> |
| | | </div> |
| | | </form> |
| | | </div> |
| | | <div class="mui-scroll-wrapper rkzc"> |
| | | <div class="mui-scroll"> |
| | | <div class="wp"> |
| | | <ul class="ul-rkzc"> |
| | | <ul class="ul-rkzc" id="handleList"> |
| | | <li> |
| | | <div class="con"> |
| | | <div class="top"> |
| | | <div class="info">车çå·: <b>豫A123GM</b></div> |
| | | <a href="" class="link">å¼ä»<span class="mui-icon mui-icon-arrowright"></span></a> |
| | | <a href="" id="" class="link">å¼ä»<span class="mui-icon mui-icon-arrowright"></span></a> |
| | | </div> |
| | | <div class="box"> |
| | | <div class="item"> |
| | |
| | | </div> |
| | | </div> |
| | | </li> |
| | | |
| | | <li> |
| | | <div class="con"> |
| | | <div class="top"> |
| | |
| | | </div> |
| | | </body> |
| | | <script src="./js/mui.min.js"></script> |
| | | <script src="./js/jquery.js"></script> |
| | | <script src="./js/admin/inout-out-handle-list.js"></script> |
| | | <script type="text/javascript" charset="utf-8"> |
| | | //muiåå§å |
| | | mui.init(); |
| | | |
| | | mui('.mui-scroll-wrapper').scroll({ |
| | | indicators: false, //æ¯å¦æ¾ç¤ºæ»å¨æ¡ |
| | | deceleration: 0.0006, //é»å°¼ç³»æ°,ç³»æ°è¶å°æ»å¨è¶çµæ |
| | | bounce: false, //æ¯å¦å¯ç¨åå¼¹ |
| | | deceleration: 0.0005 //flick åéç³»æ°ï¼ç³»æ°è¶å¤§ï¼æ»å¨éåº¦è¶æ
¢ï¼æ»å¨è·ç¦»è¶å°ï¼é»è®¤å¼0.0006 |
| | | }); |
| | | |
| | | //åè½æ¨¡å跳转 |
| | | mui(".mui-scroll-wrapper").on("tap", ".mui-scroll ul li a", function() { |
| | | var id = this.getAttribute("id"); |
| | | |
| | | mui.openWindow({ |
| | | url: "inout-out-handle.html", |
| | | id: "inout-out-handle" |
| | | mui.plusReady(function(){ |
| | | //æ°æ®åå§å |
| | | init(); |
| | | }) |
| | | |
| | | }); |
| | | </script> |
| | | </html> |
| | |
| | | <form action=""> |
| | | <div class="m-box_zc1 p15"> |
| | | <div class="item"> |
| | | <div class="tit">车çå·: <b>豫A123GM</b></div> |
| | | <div class="tit">车çå·: <b id="plateNum">豫A123GM</b></div> |
| | | <ul class="g-listb2"> |
| | | <li> |
| | | <div class="con" style="background-image: url(images/icons/g-i24.png);"> |
| | | å¼ä»ä»åº: <b>15å·ä»</b> |
| | | å¼ä»ä»åº: <b id="depotName">15å·ä»</b> |
| | | </div> |
| | | </li> |
| | | <li> |
| | | <div class="con" style="background-image: url(images/icons/g-i25.png);"> |
| | | ä¿ç®¡å: <b>å¼ ä¸</b> |
| | | ä¿ç®¡å: <b id="storeKeeperName">å¼ ä¸</b> |
| | | </div> |
| | | </li> |
| | | </ul> |
| | |
| | | <div class="item"> |
| | | <div class="tit"><b>æ·»å ç
§ç</b></div> |
| | | <div class="m-files"> |
| | | <div class="box"> |
| | | <div class="box" onclick="choosePic('1')" > |
| | | <div class="con"> |
| | | <label class="lab"> |
| | | <input type="file" name="" id="" hidden /> |
| | | <label class="lab" id="boxImg1"> |
| | | <div class="icon"> |
| | | <img src="images/icons/g-i23.png" alt=""> |
| | | </div> |
| | | <div class="t">æç
§ä¸ä¼ </div> |
| | | <!-- <img src="images/spad0.png"/> --> |
| | | </label> |
| | | </div> |
| | | |
| | | </div> |
| | | <div class="box"> |
| | | <div class="box" onclick="choosePic('2')" > |
| | | <div class="con"> |
| | | <label class="lab"> |
| | | <input type="file" name="" id="" hidden /> |
| | | <label class="lab" id="boxImg2"> |
| | | <div class="icon"> |
| | | <img src="images/icons/g-i23.png" alt=""> |
| | | <img id="img2" src="images/icons/g-i23.png" alt=""> |
| | | </div> |
| | | <div class="t">æç
§ä¸ä¼ </div> |
| | | </label> |
| | |
| | | <div class="m-box_zc1"> |
| | | <div class="mui-input-row"> |
| | | <label>å¼ä»æ£é:</label> |
| | | <input type="text" class="mui-input-clear" placeholder="请è¾å
¥éé"> |
| | | <input id="number" type="text" class="mui-input-clear" placeholder="请è¾å
¥éé"> |
| | | <span class="unit">KG</span> |
| | | </div> |
| | | </div> |
| | |
| | | |
| | | <div class="m-bot_btn"> |
| | | <div class="box"> |
| | | <button type="button" class="mui-btn mui-btn-block bot-btn end">ç»æå¼ä»</button> |
| | | <button type="button" class="mui-btn mui-btn-block bot-btn start">å¼å§å¼ä»</button> |
| | | <button type="button" class="mui-btn mui-btn-block bot-btn end" onclick="toHandle('end')">ç»æå¼ä»</button> |
| | | <button type="button" class="mui-btn mui-btn-block bot-btn start" onclick="toHandle('start')">å¼å§å¼ä»</button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </body> |
| | | <script src="js/mui.min.js"></script> |
| | | <script src="js/jquery.js"></script> |
| | | <script src="js/admin/inout-out-handle.js"></script> |
| | | <script type="text/javascript" charset="utf-8"> |
| | | //muiåå§å |
| | | mui.init(); |
| | | |
| | | mui('.mui-scroll-wrapper').scroll({ |
| | | indicators: false, //æ¯å¦æ¾ç¤ºæ»å¨æ¡ |
| | | deceleration: 0.0006, //é»å°¼ç³»æ°,ç³»æ°è¶å°æ»å¨è¶çµæ |
| | | bounce: false, //æ¯å¦å¯ç¨åå¼¹ |
| | | deceleration: 0.0005 //flick åéç³»æ°ï¼ç³»æ°è¶å¤§ï¼æ»å¨éåº¦è¶æ
¢ï¼æ»å¨è·ç¦»è¶å°ï¼é»è®¤å¼0.0006 |
| | | }); |
| | | mui.plusReady(function(){ |
| | | //æ°æ®åå§å |
| | | init(); |
| | | }) |
| | | </script> |
| | | </html> |
| | |
| | | renderData(); |
| | | } else { |
| | | renderData(); |
| | | mui.toast(result.mag); |
| | | mui.toast(result.msg); |
| | | } |
| | | }, |
| | | error: function() { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | var url = null; |
| | | var outHandleData = null; |
| | | var data = { |
| | | "interfaceId": "5206", |
| | | "outId": "10206", |
| | | "reqDateTime": new Date(), |
| | | "tokenAuth": "", |
| | | "data": { |
| | | "deptId": "", |
| | | "type": "OUT", |
| | | "plateNum": "", |
| | | "intelCard": "" |
| | | } |
| | | }; |
| | | |
| | | //åå§åæ°æ® |
| | | function init() { |
| | | var user = JSON.parse(localStorage.getItem('user')); |
| | | var selectDeptId = JSON.parse(localStorage.getItem('selectDeptId')); |
| | | url = user.url + "/api-phone/v35/gateway"; |
| | | data.tokenAuth = user.tokenAuth; |
| | | data.data.deptId = selectDeptId; |
| | | getOutHandleList(); |
| | | } |
| | | |
| | | //æ¥è¯¢åºåºè®°å½ |
| | | function getOutHandleList() { |
| | | outHandleData = null; |
| | | data.data.plateNum = mui("#plateNum")[0].value; |
| | | // //è¯·æ± |
| | | // mui.ajax(url, { |
| | | // type: "POST", |
| | | // dataType: "json", |
| | | // crossDomain: true, |
| | | // contentType: "application/json;charset=utf-8", |
| | | // data: JSON.stringify(data), |
| | | // success: function(result) { |
| | | // if (result.code == "0000") { |
| | | // outHandleData = result.data; |
| | | // console.log("if",JSON.stringify(result)) |
| | | // renderData(); |
| | | // } else { |
| | | // renderData(); |
| | | // mui.toast(result.msg); |
| | | // console.log("else",JSON.stringify(result)) |
| | | // } |
| | | // }, |
| | | // error: function() { |
| | | // mui.alert("ç³»ç»ç¹å¿,请éè¯ï¼", "æç¤º", ["ç¡®å®"], function() {}, "div") |
| | | // } |
| | | // }) |
| | | outHandleData = [{ |
| | | "id": "44", |
| | | "plateNum": "97", |
| | | "deHandle": "ut", |
| | | "depotId": "16", |
| | | "depotName": "éå¼ ååæ»", |
| | | "foodVariety": "magna pariatur laboris sunt dolor", |
| | | "foodVarietyName": "ææ¸
é¤", |
| | | "foodLevel": "fugiat", |
| | | "foodLevelName": "åºåçåæ°æ¯å§", |
| | | "storeKeeperName":"" |
| | | }, |
| | | { |
| | | "id": "62", |
| | | "plateNum": "71", |
| | | "deHandle": "dolore ut non", |
| | | "depotId": "79", |
| | | "depotName": "å¢è±¡å®ç«æ ·", |
| | | "foodVariety": "Lorem est", |
| | | "foodVarietyName": "叿¡ç¾¤æ±è¢«å¢ä¸¤", |
| | | "foodLevel": "ex labore", |
| | | "foodLevelName": "æå¨åç§°æ
å¹¶", |
| | | "storeKeeperName":"2" |
| | | }, |
| | | { |
| | | "id": "96", |
| | | "plateNum": "61", |
| | | "deHandle": "nulla magna ut proident cillum", |
| | | "depotId": "42", |
| | | "depotName": "æ¡å
¨ä»", |
| | | "foodVariety": "aliquip", |
| | | "foodVarietyName": "è¿å¼é¶å¨é
å¹²", |
| | | "foodLevel": "in id sunt", |
| | | "foodLevelName": "没置å®ä½¿æ", |
| | | "storeKeeperName":"3" |
| | | }, |
| | | { |
| | | "id": "61", |
| | | "plateNum": "17", |
| | | "deHandle": "commodo", |
| | | "depotId": "80", |
| | | "depotName": "å±è§å¿«ç«å
¨é¢", |
| | | "foodVariety": "voluptate eu Lorem", |
| | | "foodVarietyName": "ä»è¾¹æ´¾æ¯é离", |
| | | "foodLevel": "dolor", |
| | | "foodLevelName": "è£
第ä¸", |
| | | "storeKeeperName":"4" |
| | | } |
| | | ] |
| | | renderData(); |
| | | } |
| | | |
| | | //渲æé¡µé¢ |
| | | function renderData() { |
| | | var html = ''; |
| | | if (outHandleData) { |
| | | if (outHandleData && outHandleData.length > 0) { |
| | | $.each(outHandleData, function(index, item) { |
| | | html += '<li><div class="con"><div class="top">'; |
| | | html += '<div class="info">车çå·: <b>' + (item.plateNum == null ? "" : item.plateNum) + |
| | | '</b></div>'; |
| | | html += '<a href="" id = "' + item.id + '" plateNum = "' + item.plateNum + '" depotName = "' + |
| | | item.depotName + '" storeKeeperName = "' + (item.storeKeeperName == ""||item.storeKeeperName == "" ? '--' : item.storeKeeperName)+ |
| | | '" class="link">å¼ä»<span class="mui-icon mui-icon-arrowright"></span></a>'; |
| | | html += '</div><div class="box">'; |
| | | html += |
| | | '<div class="item"><div class="conbox" style="background-image: url(images/icons/g-i19.png);">'; |
| | | html += '<div class="h3">' + (item.depotName == null ? "" : item.depotName) + '</div>'; |
| | | html += '<div class="bot">ç®æ ä»åº</div></div></div>'; |
| | | html += |
| | | '<div class="item"><div class="conbox" style="background-image: url(images/icons/g-i20.png);">'; |
| | | html += '<div class="h3">' + (item.foodVarietyName == null ? "" : item.foodVarietyName) + |
| | | '</div>'; |
| | | html += '<div class="bot">ç²®é£åç§</div></div></div>'; |
| | | html += |
| | | '<div class="item"><div class="conbox" style="background-image: url(images/icons/g-i21.png);">'; |
| | | html += '<div class="h3">' + (item.foodLevelName == null ? "" : item.foodLevelName) + '</div>'; |
| | | html += '<div class="bot">ç²®é£ç级</div></div></div>'; |
| | | html += '</div></div></li>'; |
| | | }) |
| | | } else { |
| | | html += |
| | | '<li><div class="con"><div style="text-align: center;font-size: 20px;color:#dd524d;padding-top: 16px;">ææ å
¥åºå¾
å¼ä»ä¿¡æ¯</div></div></li>'; |
| | | } |
| | | } else { |
| | | html += |
| | | '<li><div class="con"><div style="text-align: center;font-size: 20px;color:#dd524d;padding-top: 16px;">ææ å
¥åºå¾
å¼ä»ä¿¡æ¯</div></div></li>'; |
| | | } |
| | | $("#handleList").html(html); |
| | | } |
| | | |
| | | //åè½æ¨¡å跳转 |
| | | mui(".mui-scroll-wrapper").on("tap", ".mui-scroll ul li a", function() { |
| | | var id = this.getAttribute("id"); |
| | | var depotName = this.getAttribute("depotName") |
| | | var plateNum = this.getAttribute("plateNum") |
| | | var storeKeeperName = this.getAttribute("storeKeeperName") |
| | | mui.openWindow({ |
| | | url: "inout-out-handle.html", |
| | | id: "inout-out-handle", |
| | | extras: { |
| | | data:{ |
| | | serialNumber: id, |
| | | plateNum: plateNum, |
| | | depotName: depotName, |
| | | storeKeeperName:storeKeeperName |
| | | } |
| | | } |
| | | |
| | | }) |
| | | |
| | | }); |
| | | |
| | | mui('.mui-scroll-wrapper').scroll({ |
| | | indicators: false, //æ¯å¦æ¾ç¤ºæ»å¨æ¡ |
| | | deceleration: 0.0006, //é»å°¼ç³»æ°,ç³»æ°è¶å°æ»å¨è¶çµæ |
| | | bounce: false, //æ¯å¦å¯ç¨åå¼¹ |
| | | deceleration: 0.0005 //flick åéç³»æ°ï¼ç³»æ°è¶å¤§ï¼æ»å¨éåº¦è¶æ
¢ï¼æ»å¨è·ç¦»è¶å°ï¼é»è®¤å¼0.0006 |
| | | }); |
¶Ô±ÈÐÂÎļþ |
| | |
| | | var url = null; |
| | | var depotData = null; |
| | | var fileName1; //ç
§ç1åç§° |
| | | var fileName2; //ç
§ç2åç§° |
| | | var base64Img1; //ç
§ç1ä¿¡æ¯ |
| | | var base64Img2; //ç
§ç2ä¿¡æ¯ |
| | | var uploadUrl; //ç
§çä¸ä¼ è·¯å¾ |
| | | var deHandle; //å¼ä»æ£é |
| | | var data = { |
| | | "interfaceId": "5208", |
| | | "outId": "10208", |
| | | "reqDateTime": new Date(), |
| | | "tokenAuth": "", |
| | | "data": { |
| | | "type": "OUT", |
| | | "id": "", |
| | | "intelCard": "" |
| | | } |
| | | }; |
| | | |
| | | var data1 = { |
| | | "interfaceId": "5207", |
| | | "outId": "10207", |
| | | "reqDateTime": new Date(), |
| | | "tokenAuth": "", |
| | | "data": { |
| | | "type": "", |
| | | "id": "", |
| | | "fileName1": "", |
| | | "fileName2": "", |
| | | "deHandle": "", |
| | | "lon": "", |
| | | "lat": "" |
| | | } |
| | | } |
| | | |
| | | |
| | | //åå§åæ°æ® |
| | | function init() { |
| | | |
| | | var user = JSON.parse(localStorage.getItem('user')); |
| | | var selectDeptId = JSON.parse(localStorage.getItem('selectDeptId')); |
| | | url = user.url + "/api-phone/v35/gateway"; |
| | | uploadUrl = user.url + "/api-phone/v35/upload-img"; |
| | | data.tokenAuth = user.tokenAuth; |
| | | //è·åä»ä¸ä¸ä¸ªé¡µé¢ä¼ éçæ°æ® |
| | | var self = plus.webview.currentWebview(); |
| | | depotData = self.data; |
| | | data.data.id = depotData.serialNumber; |
| | | // data.data.intelCard = depotData.intelCard; |
| | | $("#plateNum").html(depotData.plateNum); |
| | | $("#depotName").html(depotData.depotName); |
| | | $("#storeKeeperName").html(depotData.storeKeeperName); |
| | | |
| | | } |
| | | |
| | | function toHandle(tag) { |
| | | //å¼ä» |
| | | if (tag == 'start') { //å¼å§å¼ä» |
| | | data1.data.type = tag; |
| | | mui.ajax(url, { |
| | | type: "POST", |
| | | dataType: "json", |
| | | crossDomain: true, |
| | | contentType: "application/json;charset=utf-8", |
| | | data: JSON.stringify(data), |
| | | success: function(result) { |
| | | if (result.data.code == '0000') { |
| | | //å¤æè¯¥å¼ä»æ¯å¦å¤äºå¨å¼ä»ç¶æ |
| | | if (result.data.progress == 'HANDLE') { |
| | | //夿å忝å¦å·²ç»å¼å§è¿è¡å¼ä» |
| | | if (result.data.handelStart == null) { |
| | | //åé请æ±ï¼å¼å§å¼ä» |
| | | mui.ajax(url, { |
| | | type: "POST", |
| | | dataType: "json", |
| | | crossDomain: true, |
| | | contentType: "application/json;charset=utf-8", |
| | | data: JSON.stringify(data1), |
| | | success: function(result) { |
| | | mui.toast("å¼å§è£
ç²®ï¼è¯·ä¸ä¼ å¾çï¼"); |
| | | //éæ°è¯·æ±è·ååå详æ
并渲æ |
| | | getDetail(); |
| | | }, |
| | | error: function() { |
| | | mui.alert('å¼å§è£
ç²®æäº¤å¤±è´¥ï¼è¯·éæ°æä½ï¼', 'æç¤º', ["ç¡®å®"], function() {}, |
| | | "div"); |
| | | } |
| | | }) |
| | | } else { |
| | | mui.toast("å·²å¼å§è£
ç²®ï¼"); |
| | | } |
| | | } else { |
| | | //妿ä¸å¨å¼ä»ç¶æï¼ç»åºæç¤ºä¿¡æ¯ï¼ä¸è¿è¡æäº¤ |
| | | mui.alert("该ååä¸å¨å¼ä»ç¶æï¼ä¸è½è¿è¡å¼ä»ï¼", 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | } |
| | | } else { |
| | | mui.toast(result.msg); |
| | | } |
| | | }, |
| | | error: function() { |
| | | mui.alert('ç³»ç»ç¹å¿,请éè¯ï¼', 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | } |
| | | }) |
| | | } else { //ç»æå¼ä» |
| | | mui.ajax(url, { |
| | | type: "POST", |
| | | dataType: "json", |
| | | crossDomain: true, |
| | | contentType: "application/json;charset=utf-8", |
| | | data: JSON.stringify(data), |
| | | success: function(result) { |
| | | if (result.data.code == '0000') { |
| | | //å¤æè¯¥å¼ä»æ¯å¦å¤äºå¨å¼ä»ç¶æ |
| | | if (result.data.progress == 'HANDLE') { |
| | | //夿å忝å¦å·²ç»å¼å§è¿è¡å¼ä» |
| | | if (result.data.handelStart) { |
| | | deHandle = $("#number")[0].value; |
| | | if (fileName1 == null || fileName2 == null) { |
| | | mui.toast("请å
ä¸ä¼ å¾çï¼"); |
| | | } else { |
| | | if (deHandle) { |
| | | data1.data.type = tag; |
| | | data1.data.fileName1 = fileName1; |
| | | data1.data.fileName2 = fileName2; |
| | | data1.data.deHandle = deHandle; |
| | | mui.ajax(url, { |
| | | type: "POST", |
| | | dataType: "json", |
| | | crossDomain: true, |
| | | contentType: "application/json;charset=utf-8", |
| | | data: JSON.stringify(data1), |
| | | success: function(result) { |
| | | mui.toast("å¼ä»å®æï¼"); |
| | | //è¿åä¸ä¸é¡µ |
| | | mui.back(); |
| | | }, |
| | | error: function(result) { |
| | | mui.alert(result.msg, 'æç¤º', ["ç¡®å®"], function() {}, |
| | | "div"); |
| | | } |
| | | }) |
| | | } else { |
| | | mui.toast("请å
å¡«åå¼ä»æ£é"); |
| | | } |
| | | } |
| | | } else { |
| | | mui.toast("请å
ç¹å»å¼å§è£
ç²®ï¼å¹¶ä¸ä¼ å¾çï¼"); |
| | | } |
| | | } else { |
| | | //妿ä¸å¨å¼ä»ç¶æï¼ç»åºæç¤ºä¿¡æ¯ï¼ä¸è¿è¡æäº¤ |
| | | mui.alert("该ååä¸å¨å¼ä»ç¶æï¼ä¸è½è¿è¡å¼ä»ï¼", 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | } |
| | | } else { |
| | | mui.toast(result.msg) |
| | | } |
| | | |
| | | }, |
| | | error: function() { |
| | | mui.alert('ç³»ç»ç¹å¿,请éè¯ï¼', 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | } |
| | | }) |
| | | } |
| | | |
| | | } |
| | | //æç
§ä¸ä¼ |
| | | function choosePic(typeNum) { |
| | | //è·åå®ä½ä¿¡æ¯ |
| | | // if (latitude == null || longitude == null) { |
| | | // return; |
| | | // } |
| | | //ä¸ä¼ å¾çåï¼è¯·æ±æ¥çå忝é½å·²ç»å¼å§å¸ç²® |
| | | // mui.ajax(url, { |
| | | // type: "POST", |
| | | // dataType: "json", |
| | | // crossDomain: true, |
| | | // contentType: "application/json;charset=utf-8", |
| | | // data: JSON.stringify(data), |
| | | // success: function(result) { |
| | | // if (result.code == '0000') { |
| | | // if (result.data.handleStart != null) { |
| | | // var btnArray = [{ |
| | | // title: "æç
§ä¸ä¼ " |
| | | // }, { |
| | | // title: "ä»ç¸åéæ©" |
| | | // }]; |
| | | // plus.nativeUI.actionSheet({ |
| | | // title: "è¯·éæ©", |
| | | // cancel: "åæ¶", |
| | | // buttons: btnArray |
| | | // }, |
| | | // function(e) { |
| | | // var index = e.index; |
| | | // switch (index) { |
| | | // case 1: |
| | | // cameraImg(typeNum); |
| | | // break; |
| | | // case 2: |
| | | // galleryImg(typeNum); |
| | | // break; |
| | | // } |
| | | // }); |
| | | // } else { |
| | | // mui.toast("请å
ç¹å»å¼å§è£
ç²®ï¼"); |
| | | // } |
| | | // } else { |
| | | // mui.alert(result.msg, 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | // } |
| | | // }, |
| | | // error: function() { |
| | | // mui.alert('ç³»ç»ç¹å¿,请éè¯ï¼', 'æç¤º', ["ç¡®å®"], function() {}, "div"); |
| | | // } |
| | | // }) |
| | | |
| | | |
| | | var btnArray = [{ |
| | | title: "æç
§ä¸ä¼ " |
| | | }, { |
| | | title: "ä»ç¸åéæ©" |
| | | }]; |
| | | plus.nativeUI.actionSheet({ |
| | | title: "è¯·éæ©", |
| | | cancel: "åæ¶", |
| | | buttons: btnArray |
| | | }, |
| | | function(e) { |
| | | var index = e.index; |
| | | switch (index) { |
| | | case 1: |
| | | cameraImg(typeNum); |
| | | break; |
| | | case 2: |
| | | galleryImg(typeNum); |
| | | break; |
| | | } |
| | | }); |
| | | }; |
| | | |
| | | //使ç¨ç¸æºæç
§ |
| | | function cameraImg(typeNum) { |
| | | var cmr = plus.camera.getCamera(); |
| | | cmr.captureImage(function(p) { |
| | | //æå |
| | | plus.io.resolveLocalFileSystemURL(p, function(entry) { |
| | | var path = entry.toLocalURL(); //è·å¾å¾çè·¯å¾ |
| | | uploadImg(path, typeNum); |
| | | }, function(e) { |
| | | mui.toast("读åæç
§å¾çé误ï¼è¯·éè¯ï¼" + e.msg); |
| | | }); |
| | | }, function(e) { |
| | | mui.toast("æç
§å¤±è´¥ï¼è¯·éè¯ï¼" + e.msg); |
| | | }); |
| | | } |
| | | |
| | | //卿¬å°ç¸åéæ© |
| | | function galleryImg(typeNum) { |
| | | plus.gallery.pick(function(path) { |
| | | uploadImg(path, typeNum); |
| | | }, function(e) { |
| | | mui.toast("没æéæ©å¾ç" + e.msg); |
| | | }); |
| | | } |
| | | |
| | | //ä¸ä¼ ç
§ç |
| | | function uploadImg(path, typeNum) { |
| | | //转åçå¾
æ¡ |
| | | var wt = plus.nativeUI.showWaiting(); |
| | | //ä¸ä¼ |
| | | var task = plus.uploader.createUpload(uploadUrl, { |
| | | method: "POST" |
| | | }, |
| | | function(t, status) { //ä¸ä¼ 宿 |
| | | if (status == 200) { |
| | | var html = ''; |
| | | var obj = JSON.parse(t.responseText); |
| | | mui.toast("ä¸ä¼ æåï¼"); |
| | | if (typeNum == "1") { |
| | | html += '<img src="'+path+'">' |
| | | $("#boxImg1").html(html); |
| | | base64Img1 = path; |
| | | fileName1 = obj.data.fileName; |
| | | } |
| | | if (typeNum == "2") { |
| | | html += '<img src="'+path+'">' |
| | | $("#boxImg2").html(html); |
| | | base64Img2 = path; |
| | | fileName2 = obj.data.fileName; |
| | | } |
| | | //å
³é转åçå¾
æ¡ |
| | | wt.close(); |
| | | } else { |
| | | mui.toast("ä¸ä¼ 失败ï¼è¯·éè¯ï¼"); |
| | | //å
³é转åçå¾
æ¡ |
| | | wt.close(); |
| | | } |
| | | }); |
| | | //æºå¸¦è½¦çåæ° |
| | | task.addData("plateNum", depotData.plateNum); |
| | | //å¾çä¿¡æ¯ |
| | | task.addFile(path, { |
| | | key: "uploadkey" |
| | | }); |
| | | task.start(); |
| | | } |
| | | |
| | | |
| | | |
| | | mui('.mui-scroll-wrapper').scroll({ |
| | | indicators: false, //æ¯å¦æ¾ç¤ºæ»å¨æ¡ |
| | | deceleration: 0.0006, //é»å°¼ç³»æ°,ç³»æ°è¶å°æ»å¨è¶çµæ |
| | | bounce: false, //æ¯å¦å¯ç¨åå¼¹ |
| | | deceleration: 0.0005 //flick åéç³»æ°ï¼ç³»æ°è¶å¤§ï¼æ»å¨éåº¦è¶æ
¢ï¼æ»å¨è·ç¦»è¶å°ï¼é»è®¤å¼0.0006 |
| | | }); |
| | |
| | | var data = { |
| | | "interfaceId": "5604", |
| | | "tokenAuth": "", |
| | | "sign": "10003", |
| | | "outId": "10003", |
| | | "outId": "56041", |
| | | "reqDateTime": new Date(), |
| | | "data": { |
| | | "deptId": "" |
| | |
| | | var data1 = { |
| | | "interfaceId": "5605", |
| | | "tokenAuth": "", |
| | | "sign": "10003", |
| | | "outId": "10003", |
| | | "outId": "56051", |
| | | "reqDateTime": new Date(), |
| | | "data": { |
| | | "id": "", |
| | |
| | | $.each(videoList, function(index, item) { |
| | | if (index % 3 == 0) { |
| | | html += |
| | | '<li><a onclick="getVideo('+item.id,item.playType+')" class="con" style="background-image: url(images/icons/g-i15.png);">'; |
| | | '<li><a onclick="getVideo(\''+item.id+'\',\''+item.playType+'\')" class="con" style="background-image: url(images/icons/g-i15.png);">'; |
| | | } |
| | | if (index % 3 == 1) { |
| | | html += |
| | | '<li><a onclick="getVideo('+item.id,item.playType+')" class="con" style="background-image: url(images/icons/g-i16.png);">'; |
| | | '<li><a onclick="getVideo(\''+item.id+'\',\''+item.playType+'\')" class="con" style="background-image: url(images/icons/g-i16.png);">'; |
| | | } |
| | | if (index % 3 == 2) { |
| | | html += |
| | | '<li><a onclick="getVideo('+item.id,item.playType+')" class="con" style="background-image: url(images/icons/g-i17.png);">'; |
| | | '<li><a onclick="getVideo(\''+item.id+'\',\''+item.playType+'\')" class="con" style="background-image: url(images/icons/g-i17.png);">'; |
| | | } |
| | | if (item.type = '02') { |
| | | html += |
| | |
| | | var data = { |
| | | "interfaceId": "5801", |
| | | "tokenAuth": "", |
| | | "sign": "10003", |
| | | "outId": "10003", |
| | | "outId": "58011", |
| | | "reqDateTime": new Date(), |
| | | "data": { |
| | | "deptId": "", |
| | |
| | | var dataPop = { |
| | | "interfaceId": "5802", |
| | | "tokenAuth": "", |
| | | "sign": "10003", |
| | | "outId": "10003", |
| | | "outId": "58021", |
| | | "reqDateTime": new Date(), |
| | | "data": { |
| | | "id":"", |
| | |
| | | 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":"" |
| | | // } |
| | | // ] |
| | | // } |
| | | |
| | | |
| | | renderWarn(); |
| | | } |
| | | |
| | | |
| | | //é»è®¤è·åå½å¤©æ¥æ(yyyy-MM-dd) |
| | | function getDate() { |
| | |
| | | var warnList = warnData.data; |
| | | if (warnList && warnList.length > 0) { |
| | | $.each(warnList, function(index, item) { |
| | | html += '<li><div class="con myfancy" onclick="openPop('+item.id+')">'; |
| | | html += '<li><div class="con myfancy" onclick="openPop(\'' + item.id + '\',\'' + (item.remark == |
| | | null ? "" : item.remark) + '\',\'' + item.status + '\')">'; |
| | | if (item.status == '10') { |
| | | html += '<span class="type">æªå¤ç</span>'; |
| | | } |
| | |
| | | html += '<div class="txt">'; |
| | | html += '<div class="box"><div class="group c"><div class="desc">' + item.type + |
| | | '</div><div class="ort">è¦åç±»å</div></div></div>'; |
| | | html += '<div class="box"><div class="group c1"><div class="desc">' + item.depotName + |
| | | html += '<div class="box"><div class="group c1"><div class="desc">' + (item.depotName == null || |
| | | item.depotName == "" ? "--" : item.depotName) + |
| | | '</div><div class="ort">ä»åºåç§°</div></div></div>'; |
| | | if (item.level == '1') { |
| | | html += |
| | |
| | | |
| | | |
| | | //æå¼å¼¹çª |
| | | function openPop(warnId) { |
| | | function openPop(warnId, remark, status) { |
| | | 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>' |
| | | } |
| | | $("#handleWarn").html(html); |
| | | $("#textareaPop").val(remark) |
| | | $('#m-pop').css('display', 'flex'); |
| | | } |
| | | //è¦åå¤ç |
| | |
| | | <textarea id="textareaPop" rows="" cols="" placeholder="请è¾å
¥è¯´æ"></textarea> |
| | | </div> |
| | | </form> |
| | | <div class="btns"> |
| | | <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> |