You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
45 lines
645 B
45 lines
645 B
<template>
|
|
<view class="pic">
|
|
<view class="piccontent">
|
|
<image :src="item" mode="aspectFill" @click="getPic(item,index)" v-for="(item,index) in pic" :key="index"></image>
|
|
</view>
|
|
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
export default{
|
|
data(){
|
|
return{
|
|
pic:[]
|
|
}
|
|
},
|
|
onLoad(option) {
|
|
console.log(option,"0099")
|
|
this.pic = option.pic.split(',')
|
|
},
|
|
methods:{
|
|
getPic(item,index){
|
|
uni.previewImage({
|
|
current: index,
|
|
urls: this.pic
|
|
|
|
});
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style scoped lang="scss">
|
|
.piccontent{
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
image{
|
|
flex:1;
|
|
height:200rpx;
|
|
border-radius: 10px;
|
|
margin: 10rpx;
|
|
|
|
}
|
|
}
|
|
</style> |