<template>
	<view class="pages">
		<view class="contents">
			<view class="box">

				<view class="title">
					{{tableList.content.title}}
				</view>
				<view class="time">
					{{tableList.createTime}}
				</view>
				<view class="desc">
					<view v-if="tableList.content.type == '2'">
						<image :src="tableList.content.content" style="width: 100%;" mode="widthFix"></image>
					</view>
					<view v-else >{{tableList.content.content}}</view>

				</view>



			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				tableList: {},
				pageindex: {
					id: '',
					pageNumber: 1,
					pageSize: 10,
				},
			}
		},
		onLoad(option) {
			let ce = decodeURIComponent(option.item)
			this.tableList = JSON.parse(ce)
			console.error(this.tableList)
			if(this.tableList.isRead == '0') {
				let info = {
					"receiptId": this.tableList.receiptId,
					"messageId": this.tableList.messageId,              
					"phone": this.tableList.phone 
				}
				this.$http.sendRequest('/cereMessage/readMessage', 'POST',info,1).then(res => {
				})
			}
			
		},
	
		methods: {

			
		}
	}
</script>

<style lang="scss" scoped>
	.pages {
		width: 100vw;
		height: 100%;
		position: relative;
		overflow-y: auto;
		background-color: #f6f6f6;
		padding: 0 20px;

		.contents {
			width: 100%;
			border-radius: 20rpx;
			background-color: #fff;
			margin-top: 20rpx;

			.box {
				width: 94%;
				margin: 0 auto;
				padding: 28rpx 40rpx 28rpx 10rpx;

				.title {
					font-size: 30rpx;
					font-weight: bold;
				}

				.time {
					margin: 20rpx 0;
					color: #888D9C;
					font-size: 24rpx;
				}

				.desc {
					color: #888D9C;
					font-size: 24rpx;
					text-align: justify;
					margin-top: 10px;
				}
			}
		}
	}
</style>