<template>
	<view class="center">
		<view class="flex-column mlr-30">
			<!-- 用户类型accountType（1=保洁，2=保安，3=维修） -->
			<image v-if="userInfo.accountType==1" @click="onClick(0)" class="item"
				src="/pagesMine/static/icon_ygzy_2.png"></image>
			<image v-if="userInfo.accountType==2" @click="onClick(1)" class="item"
				src="/pagesMine/static/icon_ygzy_1.png"></image>
			<image v-if="userInfo.accountType==3" @click="onClick(2)" class="item"
				src="/pagesMine/static/icon_ygzy_3.png"></image>
			<image v-if="userInfo.accountType!=3" @click="onClick(3)" class="item2"
				src="/pagesMine/static/icon_ygzy_4.png"></image>
		</view>


	</view>
</template>

<script>
	export default {
		data() {
			return {
				userInfo: '',

			};
		},
		onLoad(options) {
			this.userInfo = uni.getStorageSync('userInfo_yg')
		},
		methods: {
			open() {

			},
			close() {

			},
			onClick(index) {
				if (index == 0) {
					this.$wskj.to("/pagesMine/pages/dk_submit")
					return
				}
				if (index == 1) {
					this.$wskj.to("/pagesMine/pages/dk_submit")
					return
				}
				if (index == 2) {
					this.$wskj.to("/pagesMine/pages/wx_lsgd")
					return
				}
				if (index == 3) {
					this.$wskj.to("/pagesMine/pages/dkjl")
					return
				}
			}
		}
	};
</script>

<style>
	.center {
		height: 100vh;
		display: flex;
		flex-direction: column;
		background: #F2F2F2;
	}

	.item {
		width: 100%;
		height: 200rpx;
		margin-top: 20rpx;
	}

	.item2 {
		width: 100%;
		height: 150rpx;
		margin-top: 20rpx;
	}
</style>