<template>
	<view>
		<u-navbar title="故障上报" title-color="#101010"></u-navbar>
		<view class="main">
			<!-- 故障设备 -->
			<view class="fault-equipment">
				<view class="title">
					<text class="asterisk">*</text>故障设备

				</view>
				<view class="value">
					<view class="placeholder">
						请选择设备
					</view>
					<view class="icon">
						<u-icon name="arrow-right" color="#acacac"></u-icon>
					</view>
				</view>
			</view>
			<!-- 故障类型 -->
			<view class="fault-type">
				<view class="title">
					<text class="asterisk">*</text>请选择故障类型：
				</view>
				<view class="type">
					<view class="type-item item-checked">
						温度异常
					</view>
					<view class="type-item ">
						电压异常
					</view>
					<view class="type-item ">
						设备离线
					</view>
					<view class="type-item ">
						其他问题
					</view>
				</view>
			</view>
		</view>
		<!-- 照片上传 -->
		<view class="picture-upload">
			<view class="title">
				现场照片/视频（最多4张）
			</view>
			<view class="upload">
				<u-upload :action="action" :file-list="fileList" max-count="4" width="144" height="144"></u-upload>
			</view>
		</view>
		<!-- 故障描述 -->
		<view class="fault-description">
			<view class="title">
				故障描述
			</view>
			<view class="textarea">
				<textarea placeholder="请详细描述故障现象，以便我们更准确快速的为您解决问题
"></textarea>
			</view>
		</view>
		<!-- 底部 -->
		<view class="bottom">
			<button class="submit">提交工单</button>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {

			}
		},
		methods: {

		}
	}
</script>

<style lang="scss" scoped>
	.main {
		background-color: #fff;

		// 故障设备
		.fault-equipment {
			display: flex;
			align-items: center;
			padding: 24rpx 32rpx;
			border-bottom: 1px solid rgba(221, 221, 221, 1);

			.title {
				font-size: 32rpx;
				color: #777777;
				width: 144rpx;

				.asterisk {
					color: rgba(238, 49, 56, 1);

				}
			}

			.value {
				display: flex;
				align-items: center;
				justify-content: space-between;
				margin-left: 64rpx;
				flex: 1;

				.placeholder {
					color: rgba(172, 172, 172, 1);
					font-size: 32rpx;
				}
			}
		}

		// 故障类型
		.fault-type {
			.title {
				font-size: 32rpx;
				color: #111111;
				padding: 32rpx 32rpx 0;
				font-weight: bold;

				.asterisk {
					color: rgba(238, 49, 56, 1);

				}
			}

			.type {
				display: flex;
				justify-content: space-between;
				padding: 24rpx 32rpx;

				.type-item {
					border: 1px solid rgba(216, 223, 232, 1);
					color: rgba(16, 16, 16, 1);
					width: 160rpx;
					line-height: 66rpx;
					text-align: center;
					border-radius: 4px;
				}

				.item-checked {
					background-color: rgba(22, 119, 255, 1);
					color: rgba(255, 255, 255, 1);
				}
			}
		}
	}

	// 照片上传 故障描述
	.picture-upload,
	.fault-description {
		padding: 32rpx 32rpx;
		background-color: #fff;
		margin-top: 24rpx;

		.title {
			color: rgb(16, 16, 16);
			font-size: 32rpx;
			margin-bottom: 24rpx;
			font-weight: bold;
		}

		.textarea {

			/deep/.uni-textarea-placeholder {
				color: #b2b2b2;
			}

			/deep/uni-textarea {
				width: 660rpx;
				height: 180rpx;

			}
		}
	}
 
   // 底部
   .bottom{
	   padding: 20rpx 32rpx;
	   background-color: #fff;
	   position: fixed;
	   left: 0;
	   right: 0;
	   bottom: 0;
	   .submit{
		   border-radius: 4px;
		   background-color: rgba(22,119,255,1);
		   color: rgba(255,255,255,1);
		   font-size: 32rpx;
		   line-height: 80rpx;
	   }
   }


</style>