12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- <template>
- <view class="dataList">
- <view class="list" v-if="data.length > 0">
- <view class="item" v-for="d in data" @click="navto('/pages/product/product?id=' + d.id + '&is_integral=' + d.is_integral + '&is_gold=' + d.is_gold)">
- <view class="img">
- <image :src="d.image" mode=""></image>
- </view>
- <view class="name nowarp">
- {{ d.store_name }}
- </view>
- <view class="about">
-
- </view>
- <view class="allprice">
- <text class="price">¥{{ (d.price*1-d.max_integral*1).toFixed(2) }}</text>
- </view>
- </view>
- </view>
- <view class="load">
- ---------{{ data.loadingType == 'loadmore'?'加载中': '加载完成'}}---------
- </view>
- </view>
- </template>
- <script>
- export default {
- props: ['data'],
- methods: {
- navto(url){
- uni.navigateTo({
- url
- })
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- $grey: #95A0B1;
- $text: #333333;
- $red: #FF4C4C;
- .dataList {
- .list {
- padding: 20rpx;
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
- .item {
- background-color: #fff;
- border-radius: 10rpx;
- overflow: hidden;
- // box-shadow: 2rpx 2rpx 10rpx #e1e1e1;
- margin: 10rpx 0;
- width: 48%;
- height: 0;
- padding-bottom: calc(48% + 120rpx);
- .img {
- border-radius: 10rpx;
- overflow: hidden;
- width: 100%;
- height: 344rpx;
- image {
- width: 100%;
- height: 100%;
- }
- }
- .name {
- margin: 0 10rpx;
- font-size: 30rpx;
- font-weight: bold;
- }
- .allprice {
- padding: 20rpx 0;
- .price {
- color: $red;
- }
- .ot-price {
- color: $grey;
- text-decoration: line-through;
- font-size: 26rpx;
- }
- }
- }
- }
- .load {
- text-align: center;
- color: $grey;
- font-size: 28rpx;
- }
- }
- </style>
|