<template>
	<view class="page">
		<view class="head">
			<view class="logo-title">
				<image @click="goBack" src="../../static/left.png"></image>
				项目介绍
			</view>
			<view class="title">
			</view>
			<view class="setting-mess"></view>
		</view>
		
		<view class="main">
		<!-- 订单tab -->
		<view class="order-tab" :style="'background-color: rgba(255,255,255,'+(scrollTop/50)+');'">
			<view class="tab" :class="{'action':OrderType == item.id}" @click="onOrderTab(item.id)" v-for="item in list">
				<text>{{item.title}}</text>
				<text class="line"></text>
			</view>
		</view>
		<!-- 列表 -->
		<view class="order-list" v-if="OrderType=== item.id" v-for="item in list">
			<view v-html="item.content"></view>
			<view><image src="../../static/img/1.png" mode="widthFix"></image></view>
		</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				OrderType: 1,
				scrollTop: 0,
				list:[]
			};
		},
		onPageScroll(e) {
			this.scrollTop = e.scrollTop;
		},
		onLoad() {
			this.xmjs();
		},
		methods:{
			xmjs(){
				this.API.xmjs().then(res=>{
					console.log("项目介绍",res);
					this.list = res.data
				})
			},
			goBack() {
				uni.navigateBack({
					delta: 1
				});
			},
			onOrderTab(type){
				this.OrderType = type;
			},
			myorderdetail(){
				uni.navigateTo({
					url: '/pages/myorderdetail/myorderdetail',
				})
			},
		}
	}
</script>

<style scoped lang="scss">
	@import 'projectIntroduction.scss';
</style>
