<template>
	<view class="activity">
		<!-- <image @click.stop="navToDetailPage" src="https://img.caimei365.com/group1/M00/03/9A/Cmis216Zf8GAb_UqABE6NiwUUZs004.jpg" mode="widthFix"></image> -->
	   <web-view :webview-styles="webviewStyles" :src="activityPath"></web-view>
	</view>
</template>

<script>
	export default {
	    data() {
	        return {
	            webviewStyles: {
	                progress: {
	                    color: '#FF3333'
	                }
	            },
				productID:'',
				activityPath:'',
				
	        }
	    },
		onLoad(option) {
			// console.log(option)
			switch(option.linkType){
				case '7':
					this.activityPath = 'https://www.caimei365.com/repair.html'
					break;
				case '99':
					this.activityPath = 'https://www.caimei365.com/help/1000.html'
					break;
				case '101':
					this.activityPath = 'https://www.caimei365.com/repair/form.html'
					break;
			}
			// console.log(this.activityPath)
			// uni.setNavigationBarTitle({title:'多重精华,多重修复'});
		},
		methods:{
			navToDetailPage() {//跳转商品详情页
				this.$api.navigateTo(`/pages/goods/product?id=${this.productID}`)
			},
		}
	}
</script>
	
<style lang="scss">
	.activity{
		width: 100%;
		height: auto;
		image{
			width: 100%;
			height: auto;
		}
	}
</style>
