From 716ce196a6360cd0729d20723d7d49894bfbbc28 Mon Sep 17 00:00:00 2001
From: YYC <1833023622@qq.com>
Date: 星期二, 09 五月 2023 17:21:44 +0800
Subject: [PATCH] 出库值仓

---
 igds-app/js/admin/inout-in-handle-list.js  |    2 
 igds-app/inout-out-handle-list.html        |   33 +-
 igds-app/warn-list.html                    |    2 
 igds-app/js/admin/security-video.js        |   12 
 igds-app/js/admin/inout-out-handle.js      |  313 ++++++++++++++++++++++++++++
 igds-app/js/admin/warn-list.js             |   71 +++++
 igds-app/js/admin/inout-out-handle-list.js |  170 +++++++++++++++
 igds-app/inout-out-handle.html             |   41 +-
 8 files changed, 585 insertions(+), 59 deletions(-)

diff --git a/igds-app/inout-out-handle-list.html b/igds-app/inout-out-handle-list.html
index a8f74c0..0dd0d3f 100644
--- a/igds-app/inout-out-handle-list.html
+++ b/igds-app/inout-out-handle-list.html
@@ -24,22 +24,22 @@
 							<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>璞獳123GM</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">
@@ -91,6 +91,7 @@
 									</div>
 								</div>
 							</li>
+							
 							<li>
 								<div class="con">
 									<div class="top">
@@ -154,25 +155,15 @@
 		</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>
\ No newline at end of file
diff --git a/igds-app/inout-out-handle.html b/igds-app/inout-out-handle.html
index 553a933..be289bc 100644
--- a/igds-app/inout-out-handle.html
+++ b/igds-app/inout-out-handle.html
@@ -25,16 +25,16 @@
 						<form action="">
 							<div class="m-box_zc1 p15">
 								<div class="item">
-									<div class="tit">杞︾墝鍙�: <b>璞獳123GM</b></div>
+									<div class="tit">杞︾墝鍙�: <b id="plateNum">璞獳123GM</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>
@@ -42,23 +42,23 @@
 								<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>
@@ -70,7 +70,7 @@
 							<div class="m-box_zc1">
 								<div class="mui-input-row">
 									<label>鍊间粨鎵i噸:</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>
@@ -86,21 +86,22 @@
 
 			<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>
diff --git a/igds-app/js/admin/inout-in-handle-list.js b/igds-app/js/admin/inout-in-handle-list.js
index 6797402..5fa693f 100644
--- a/igds-app/js/admin/inout-in-handle-list.js
+++ b/igds-app/js/admin/inout-in-handle-list.js
@@ -46,7 +46,7 @@
 				renderData();
 			} else {
 				renderData();
-				mui.toast(result.mag);
+				mui.toast(result.msg);
 			}
 		},
 		error: function() {
diff --git a/igds-app/js/admin/inout-out-handle-list.js b/igds-app/js/admin/inout-out-handle-list.js
new file mode 100644
index 0000000..50c9d8c
--- /dev/null
+++ b/igds-app/js/admin/inout-out-handle-list.js
@@ -0,0 +1,170 @@
+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
+});
\ No newline at end of file
diff --git a/igds-app/js/admin/inout-out-handle.js b/igds-app/js/admin/inout-out-handle.js
new file mode 100644
index 0000000..5582017
--- /dev/null
+++ b/igds-app/js/admin/inout-out-handle.js
@@ -0,0 +1,313 @@
+var url = null;
+var depotData = null;
+var fileName1; //鐓х墖1鍚嶇О
+var fileName2; //鐓х墖2鍚嶇О
+var base64Img1; //鐓х墖1淇℃伅
+var base64Img2; //鐓х墖2淇℃伅
+var uploadUrl; //鐓х墖涓婁紶璺緞
+var deHandle; //鍊间粨鎵i噸
+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("璇峰厛濉啓鍊间粨鎵i噸");
+								}
+							}
+						} 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
+});
\ No newline at end of file
diff --git a/igds-app/js/admin/security-video.js b/igds-app/js/admin/security-video.js
index 8e873a8..7621866 100644
--- a/igds-app/js/admin/security-video.js
+++ b/igds-app/js/admin/security-video.js
@@ -4,8 +4,7 @@
 var data = {
 	"interfaceId": "5604",
 	"tokenAuth": "",
-	"sign": "10003",
-	"outId": "10003",
+	"outId": "56041",
 	"reqDateTime": new Date(),
 	"data": {
 		"deptId": ""
@@ -14,8 +13,7 @@
 var data1 = {
 	"interfaceId": "5605",
 	"tokenAuth": "",
-	"sign": "10003",
-	"outId": "10003",
+	"outId": "56051",
 	"reqDateTime": new Date(),
 	"data": {
 		"id": "",
@@ -71,15 +69,15 @@
 			$.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 +=
diff --git a/igds-app/js/admin/warn-list.js b/igds-app/js/admin/warn-list.js
index 525270c..287d930 100644
--- a/igds-app/js/admin/warn-list.js
+++ b/igds-app/js/admin/warn-list.js
@@ -4,8 +4,7 @@
 var data = {
 	"interfaceId": "5801",
 	"tokenAuth": "",
-	"sign": "10003",
-	"outId": "10003",
+	"outId": "58011",
 	"reqDateTime": new Date(),
 	"data": {
 		"deptId": "",
@@ -15,11 +14,10 @@
 var dataPop = {
 	"interfaceId": "5802",
 	"tokenAuth": "",
-	"sign": "10003",
-	"outId": "10003",
+	"outId": "58021",
 	"reqDateTime": new Date(),
 	"data": {
-		"id":"",
+		"id": "",
 		"status": "",
 		"remark": ""
 	}
@@ -71,7 +69,53 @@
 			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() {
@@ -137,7 +181,8 @@
 		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>';
 				}
@@ -154,7 +199,8 @@
 				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 +=
@@ -183,8 +229,15 @@
 
 
 //鎵撳紑寮圭獥
-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');
 }
 //璀﹀憡澶勭悊
@@ -197,7 +250,7 @@
 		dataPop.data.status = '30'
 		// mui.toast("璀﹀憡澶勭悊");
 	}
-    dataPop.data.remark = mui("#textareaPop")[0].value;
+	dataPop.data.remark = mui("#textareaPop")[0].value;
 	//璇锋眰
 	mui.ajax(url, {
 		type: "POST",
diff --git a/igds-app/warn-list.html b/igds-app/warn-list.html
index 8488db0..eab22dd 100644
--- a/igds-app/warn-list.html
+++ b/igds-app/warn-list.html
@@ -150,7 +150,7 @@
 								<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>

--
Gitblit v1.9.3