xhj пре 3 година
родитељ
комит
9a1f3b9a4a

+ 25 - 0
warning/reconditionAlarm/reconditionAlarm.css

@@ -134,4 +134,29 @@
 	font-weight: 500;
 	font-size: 28rpx;
 	text-align: center;
+}
+
+/* 按钮 */
+.bottom-btns{
+	position: fixed;
+	left: 0;
+	right: 0;
+	bottom: 0;
+	background: #FFFFFF;
+	box-shadow: 0rpx -5rpx 15rpx 1rpx rgba(0,0,0,0.05);
+	border-radius: 0rpx 0rpx 0rpx 0rpx;
+	opacity: 1;
+	z-index: 10;
+}
+.btn{
+	margin: 30rpx;
+	line-height: 76rpx;
+	padding: 10rpx 0;
+	background: #EB5C20;
+	border-radius: 100rpx;
+	opacity: 1;
+	color: #fff;
+	text-align: center;
+	font-weight: 500;
+	font-size: 36rpx;
 }

+ 25 - 3
warning/reconditionAlarm/reconditionAlarm.vue

@@ -1,6 +1,7 @@
 <template>
 	<view>
-		<view class="order-item" v-for="item,index in groupList" @click="openPop(item)">
+		<!-- @click="openPop(item)" -->
+		<view class="order-item" v-for="item,index in 10" >
 			<view class="ddflex order-item-header">
 				<view class="order-time">类型:{{item.type}}</view>
 				<block>
@@ -28,7 +29,16 @@
 			</view>
 		</view>
 		
-		<bottom-pop v-if="showPop" :showPop='showPop' :btnColor="'#11BB8B'" :showBtn='false' title="解除提醒"
+		
+		<view style="height: 185rpx;" class="savepadding"></view>
+		<view class="bottom-btns savepadding">
+			<view class="btn ddflex" @click="saomaFn" style="justify-content: center;">
+				<image src="../static/images/saoma.png" style="width: 50rpx;height: 50rpx;margin-right: 23rpx;"></image>
+				扫码处理</view>
+		</view>
+		
+		
+		<!-- <bottom-pop v-if="showPop" :showPop='showPop' :btnColor="'#11BB8B'" :showBtn='false' title="解除提醒"
 			@closePop="closePop()" @popSubmit="popSubmit()">
 			<view>
 				<view>
@@ -40,7 +50,7 @@
 					<view class="btn2" @click="jumpUrl('warning/reconditionAlarmUpload/reconditionAlarmUpload')">上传检修记录</view>
 				</view>
 			</view>
-		</bottom-pop>
+		</bottom-pop> -->
 		
 	</view>
 </template>
@@ -127,6 +137,18 @@
 					}
 				)
 			},
+			saomaFn(){
+				// 只允许通过相机扫码
+				uni.scanCode({
+					onlyFromCamera: false,
+					success: (res) =>{
+						console.log('条码类型:' + res.scanType);
+						console.log('条码内容:' + res.result);
+						// did设备id
+						this.jumpUrl('warning/reconditionAlarmUpload/reconditionAlarmUpload?id='+res.result)
+					}
+				});
+			}
 		},
 		mounted() {
 			

+ 14 - 0
warning/reconditionAlarmUpload/reconditionAlarmUpload.css

@@ -110,4 +110,18 @@ page {
 	color: #FFFFFF;
 	text-align: center;
 	margin:30rpx auto;
+}
+
+/*  */
+.img-box{
+	width: 690rpx;
+	height: 230rpx;
+	background: #FFFFFF;
+	border-radius: 8rpx 8rpx 8rpx 8rpx;
+	opacity: 1;
+	border: 2rpx dashed #A8A5A5;
+	margin: auto;
+	margin-top: 30rpx;
+	flex-direction: column;
+	justify-content: center;
 }

+ 30 - 12
warning/reconditionAlarmUpload/reconditionAlarmUpload.vue

@@ -1,45 +1,63 @@
 <template>
 	<view>
-		<view class="input-box ddflex">
+		<!-- <view class="input-box ddflex">
 			<view class="input fflex">
 				<input class="fflex" placeholder="请输入设备编号"/>
 			</view>
 			<image class="saoma" src="../../static/pages/images/saoma.png"></image>
-		</view>
+		</view> -->
 		
 		<view>
 			<view class="item ddflex">
-				<view class="label">所属门店</view>
+				<view class="label">类型</view>
 				<view class="item-input fflex">
-					<input v-model="name" :disabled="true" class="fflex"/>
+					整柜巡检
 				</view>
 			</view>
 			<view class="item ddflex">
-				<view class="label">机柜名称</view>
+				<view class="label">机柜编号</view>
 				<view class="item-input fflex">
-					<input v-model="name" :disabled="true" class="fflex"/>
+					CHZD04TTCC200329109
 				</view>
 			</view>
 			<view class="item ddflex">
-				<view class="label">巡检时间</view>
+				<view class="label">描述</view>
 				<view class="item-input fflex">
-					<biaofundatetimepicker class="biao fflex" :dateStr="time"
-						placeholder="巡检时间" fields="minute" @change="changeEndDatetimePicker"></biaofundatetimepicker>
+					定期巡检提醒
 				</view>
 			</view>
 			<view class="item ddflex">
+				<view class="label">提醒时间</view>
+				<view class="item-input fflex">
+					2022-12-31 17:16:37
+				</view>
+			</view>
+			<!-- <view class="item ddflex">
+				<view class="label">提醒时间</view>
+				<view class="item-input fflex">
+					<biaofundatetimepicker class="biao fflex" :dateStr="time"
+						placeholder="提醒时间" fields="minute" @change="changeEndDatetimePicker"></biaofundatetimepicker>
+				</view>
+			</view> -->
+			<!-- <view class="item ddflex">
 				<view class="label">检修记录表</view>
 				<view class="item-input fflex" style="color: #2A82E4;" @click="choiceImages">
 					点击上传
 				</view>
+			</view> -->
+			
+			<view class="img-box ddflex" @click="choiceImages" v-if="imageList.length==0">
+				<image style="width: 54rpx;height: 54rpx;margin-bottom: 12rpx;" src="../static/images/xj.png"></image>
+				<view>添加图片</view>
 			</view>
+			<image v-else style="width: 100%;margin: 30rpx;" :src="imageList[0]" mode="widthFix" @click="choiceImages"></image>
 			
-			<view class="ddflex" style="margin-bottom: 40rpx;padding: 30rpx;">
+			<!-- <view class="ddflex" style="margin-bottom: 40rpx;padding: 30rpx;">
 				<view class="product-image" v-for="item,index in imageList">
 					<image style="width: 100%;height: 100%;margin-bottom: 0;" :src="item"></image>
 					<image class="product-image-delete" src="../static/images/imagecuo.png" @click="removeProductImage(index)"></image>
 				</view>
-			</view>
+			</view> -->
 			
 		</view>
 		
@@ -191,7 +209,7 @@
 				var promise = Promise.all(allList.map(tempFilePath => {
 					return new Promise(function(resolve, reject) {
 						req.loadIng("上传中");
-						req.uploadFile('/api/upload', tempFilePath.filePath, res => {
+						req.uploadFile('/api/nocheck/upload', tempFilePath.filePath, res => {
 							that.imageList = that.imageList.concat(res.src);
 							resolve()
 						});

BIN
warning/static/images/saoma.png


BIN
warning/static/images/xj.png