<template>
	<view class="main">
		<view class="statusBar">

			<view class="all">
				<text>全部</text>
				<image class="barImg" src="../../static/hoem/ic_filter.png"></image>
			</view>

			<view class="filter" @click="show = true">
				<text>筛选</text>
				<image class="barImg" src="../../static/hoem/ic_search.png"></image>
			</view>

		</view>
		<view class="bgList">
			<view class="inspectionList" v-for="item in inspectionList" :key="item.id">

				<view class="toiletInfo">
					<view class="info">
						<image class="hread" src="../../static/hoem/ic_hread.png"></image>
						<view class="title">
							<view class="toiletName">G0001公厕</view>
							<view class="devicesName">设备：A101，A102，A103</view>
						</view>
					</view>

					<view class="toInspected"> 待巡查</view>
				</view>
				<u-line class="line" length="90%"></u-line>

				<view class="inspectionInfo">
					<text>最近巡查：2024-08-12 12:00</text>
				</view>
				<view class="people">
					<text>巡查人员：张三三</text>
				</view>
				<u-line class="line" length="90%"></u-line>

				<view class="patrol">
					<view></view>
					<view class="butPeople" @click="butpatrol">巡查</view>
				</view>
			</view>
		</view>

		<u-popup :show="show" :rou1d="10" mode="center" @close="close" @open="open">
			<view class="upopup">
				<view class="popup">
					<view class="close">
						<view></view>
						<view>
							<image @click="dismiss"  class="icClose" src="../../static/hoem/ic_close.png"></image>
						</view>
					</view>
					<view class="title">上传巡查信息</view>


				</view>
				<view class="region">
					<view>巡查区域</view>
					<view class="editRegion"><input placeholder="选择巡查区域"></input>
						<image class="ic_botom" src="../../static/hoem/ic_filter.png"></image>
					</view>
				</view>
				<view class="region">
					<view style="display: flex;">
						<view>巡查内容</view>
						<view class="prompt">(如：添加厕纸完成)</view>
					</view>

					<view class="editRegion"><input placeholder="选择巡查内容"></input>
						<image class="ic_botom" src="../../static/hoem/ic_filter.png"></image>
					</view>
				</view>

				<view class="uploadPicture">
					<view>上传巡查照片</view>
					<u-upload class="pictureItem" :fileList="fileList1" @afterRead="afterRead" @delete="deletePic"
						name="1" multiple :maxCount="10"></u-upload>
				</view>

				<view class="notes">
					<view>备注信息</view>
					<view>
						<u--textarea class="notes_input" v-model="value1" placeholder="请输入内容"></u--textarea>
					</view>
				</view>
				<view class="butSubmit">
					<view style="margin-top: 30rpx;">
						提交
					</view>
				</view>

			</view>
		</u-popup>


	</view>

	</view>

</template>

<script>
	export default {
		data() {
			return {
				fileList1: [],
				inspectionList: [{
					id: 1
				}, {
					id: 2
				}, {
					id: 3
				}, {
					id: 4
				}, {
					id: 5
				}, {
					id: 6
				}, {
					id: 7
				}, {
					id: 8
				}],
				show: false
			}

		},
		methods: {
			open() {

			},
			close() {
				this.show = false

			},
			butpatrol() {
				this.show = true
			}
			,dismiss(){
				this.show = false
			}
		}
	}
</script>

<style lang="scss">
	.main {
		display: block;
		background-color: #F8F4F4;

		.upopup {
			height: 1120rpx;
			.close {
				display: flex;
				justify-content: space-between;
				.icClose {
					width: 40rpx;
					height: 40rpx;
				}
			}

			.uploadPicture {
				padding: 24rpx;

				.pictureItem {
					margin-top: 10rpx;
				}
			}

			.butSubmit {
				height: 80rpx;
				background: linear-gradient(90deg, #FCD4D2 0%, #FB262A 100%);
				border-radius: 40rpx 40rpx 40rpx 40rpx;
				text-align: center;
				color: white;
				width: 302rpx;
				margin: auto;
				line-height: 80rpx;
			}

			.notes {
				padding-left: 24rpx;
				padding-right: 24rpx;

				.notes_input {
					margin-top: 10rpx;
					background: #F8F4F4;
					border-radius: 4rpx 4rpx 4rpx 4rpx;
				}
			}

			.popup {
				padding: 24rpx;
				width: 634rpx;
				background: linear-gradient(180deg, #FDEDEE 0%, #FFFFFF 100%);
				border-radius: 20rpx 20rpx 20rpx 20rpx;



				.title {
					text-align: center;
					font-weight: 800;
					font-size: 30rpx;
					color: #333333;

				}
			}

			.region {
				padding: 24rpx;

				.prompt {
					padding-top: 10rpx;
					padding-left: 10rpx;
					font-size: 24rpx;
					color: #999999;
				}

				.editRegion {
					display: flex;
					margin-top: 10rpx;
					padding: 20rpx;
					align-items: center;
					font-size: 24rpx;
					color: #999999;
					background: #F8F4F4;
					border-radius: 4rpx 4rpx 4rpx 4rpx;
					justify-content: space-between;

					.ic_botom {
						width: 18rpx;
						height: 18rpx;
					}
				}

			}
		}

		.patrol {
			display: flex;
			justify-content: space-between;
			padding: 20rpx;

			.butPeople {
				width: 94rpx;
				height: 45rpx;
				color: white;
				text-align: center;
				background: linear-gradient(90deg, #FCD4D2 0%, #FB262A 100%);
				border-radius: 8rpx 8rpx 8rpx 8rpx;
			}
		}

		.bgList {
			padding: 24rpx;

			.inspectionList {
				display: block;
				padding: 24rpx;
				margin-top: 20rpx;
				background-color: #FFFFFF;
				position: relative;
				border-radius: 14rpx 14rpx 14rpx 14rpx;

				.inspectionInfo {
					display: flex;
					color: #999999;
					font-size: 24rpx;

				}

				.people {
					display: flex;
					color: #999999;
					font-size: 24rpx;
				}

				.line {
					padding: 20rpx;
					padding-right: 15rpx;
				}

				.toiletInfo {
					display: flex;
					justify-content: space-between;

					.toInspected {
						width: 125rpx;
						height: 54rpx;
						text-align: center;
						color: #FB262A;
						position: absolute;
						top: 0%;
						right: 0%;
						background: #FDEDEE;
						border-radius: 0rpx 14rpx 0rpx 0rpx;
					}

					.info {
						display: flex;
					}

					.title {
						padding-left: 10rpx;

						.toiletName {
							color: #333333;
							font-size: 28rpx;
							font-weight: 700;
						}

						.devicesName {
							color: #999999;
							font-size: 24rpx;
						}
					}

					.hread {
						width: 75rpx;
						height: 75rpx;
					}
				}


			}
		}

		.statusBar {
			display: flex;
			align-items: center;
			padding: 22rpx;
			justify-content: space-around;
			background: linear-gradient(91deg, #FDEDEE 0%, #FFFFFF 100%);
			border-radius: 0rpx 0rpx 0rpx 0rpx;

			.barImg {
				padding: 7rpx;
				width: 18rpx;
				height: 18rpx;
			}

		}


	}
</style>