<template>
	<div>
		<view v-for="(item, index) in listData" :key="index" @click="onClick(item)" :data-code="item" class="item"
			style="justify-content: flex-start; display: flex; font-size: 28rpx; min-height: 20px; background-color: #023F8F; color: white; border-radius: 20rpx; padding: 20px; margin: 20px;">
			<view style="display: flex; flex-direction: column; flex: 1;">
				<text>{{ item.productName }}</text>
				<!-- <text>记账卡</text> -->
			</view>
			<view>></view>
		</view>
	</div>
</template>
<script setup lang='ts'>
	import {
		ref
	} from 'vue';
	import {
		request
	} from "@/utils/network/request.js";

	let listData = ref([])

	//卡券渠道类型获取单项权益列表
	request("c00c18878cc543cbb8e089caf45dd5c8", {
		type: 2,
		data: {
			couponAgencyType: ['TUHU','ZFB'],
			
		},
		method: "POST",
		showLoading: true,
	}).then((item) => {
		let res = JSON.parse(item.bizContent)
		console.log(res, '=========');
		listData.value = res.data
	})

	function onClick(singId: any) {
		uni.navigateTo({
			url: '/subpackage/service/equity/equity?singleEquityId=' + singId.singleEquityId +
				'&couponAgencyType=' + singId.couponAgencyType + '&couponId=' + singId.couponId,
		})
	}
</script>
<style lang='scss' scoped>

</style>