<template>
	<view class="page">

		<navbar title="考证咨询" />

		<view class="list">
			<view class="item" 
			v-for="(item, index) in list" :key="index"
			@click="$utils.navigateTo('/pages_order/work/postConsult?id=' + item.id)">
				<image :src="item.headImage" 
				class="image"
				mode="widthFix"></image>
				
				<view class="info">
					<view class="title">
						{{item.name}}
					</view>
					<view class="text">
						<uv-parse :content="item.summary"></uv-parse>
					</view>
				</view>
			</view>
		</view>


		<tabber select="2" />
	</view>
</template>

<script>
	import tabber from '@/components/base/tabbar.vue'
	import mixinList from '@/mixins/list.js'
	export default {
		mixins : [mixinList],
		components: {
			tabber,
		},
		computed: {
		},
		data() {
			return {
				mixinsListApi : 'queryCert',
			}
		},
		onShow() {
		},
		//滚动到屏幕底部
		onReachBottom() {},
		methods: {
			// addMaterial(){
			// 	if(this.$utils.verificationAll(this.form,{
			// 		code:'请输入兑换码'
			// 	})) {
			// 		return
			// 	}
			// 	this.$api('addMaterial',this.form, res =>{
			// 		if(res.code == 200){
			// 			uni.showToast({
			// 				title:'兑换成功',
			// 				icon: 'none'
			// 			})	
			// 		}
			// 	})
			// },

		}
	}
</script>

<style scoped lang="scss">
	.page {
		.list{
			.item{
				display: flex;
				margin: 20rpx;
				padding: 20rpx;
				background-color: #fff;
				border-radius: 20rpx;
				.image{
					width: 200rpx;
					border-radius: 20rpx;
					margin-right: 20rpx;
					flex-shrink: 0;
				}
				.info{
					flex: 1;
					display: flex;
					flex-direction: column;
					justify-content: center;
					align-items: center;
					text-align: center;
					.title{
						font-weight: 900;
					}
					.text{
						font-size: 26rpx;
						color: #777;
					}
				}
			}
		}
	}
</style>