deming/components/shop/shop-item/index.vue

43 lines
811 B
Vue
Raw Normal View History

2020-06-11 09:34:23 +08:00
<template>
2020-08-04 19:08:04 +08:00
<view class="shop-item" @click="toClassifyPage">
2020-06-30 18:06:50 +08:00
<image :src="info.goodscn_pic"></image>
<text class="u-line-1">{{ info.gc_name }}</text>
2020-06-11 09:34:23 +08:00
</view>
</template>
<script>
export default {
2020-06-18 14:57:26 +08:00
name:"shopItem",
2020-06-30 18:06:50 +08:00
props: {
info: Object,
2020-08-04 19:08:04 +08:00
},
methods: {
toClassifyPage() {
this.$u.route('pageC/classify/goods', {
cid: this.info.gc_id,
cname: this.info.gc_name,
});
}
2020-06-30 18:06:50 +08:00
}
2020-06-11 09:34:23 +08:00
}
</script>
<style lang="scss" scoped>
.shop-item{
display: flex;
flex-direction: column;
align-items: center;
2020-08-04 19:08:04 +08:00
justify-content: center;
width: 100rpx;
2020-06-11 09:34:23 +08:00
>image{
width: 80rpx;
height: 80rpx;
border-radius: 50%;
}
>text{
2020-08-04 19:08:04 +08:00
width: 100%;
2020-06-11 09:34:23 +08:00
font-size: 24rpx;
color: #333;
margin-top: 14rpx;
2020-08-04 19:08:04 +08:00
text-align: center;
2020-06-11 09:34:23 +08:00
}
}
</style>