<template>
	<uni-popup ref="popupItems">
		<com-popup @onClose="closePopup">
			<view v-for="(item, index) in scrapList" :key="index">
				<com-scrap-job-card :dataContent="item" @click='selectItem(item)'></com-scrap-job-card>
				<u-line></u-line>
			</view>
		</com-popup>
	</uni-popup>
</template>

<script>
	import comScrapJobCard from '@/pages/scrap/coms/comScrapJobCard.vue'
	import comPopup from '@/mycomponents/common/comPopup.vue'
	export default {
		emits: ["selectedItem"],
		components: {
			comPopup,
			comScrapJobCard
		},
		props: {

		},
		data() {
			return {
				scrapList: []
			}
		},
		methods: {
			openPopup(items) {
				this.scrapList = items;
				this.$refs['popupItems'].open("center");
			},
			closePopup() {
				this.$refs.popupItems.close()
			},
			selectItem(item) {
				this.$emit("selectedItem", item);
				this.$refs['popupItems'].close();
			},
		}
	}
</script>

<style>
</style>
