Browse Source

Merge branch 'landong' of https://git.lotus-wallet.com/Loki/zsw-farm-bxg into sxx

home_hotList
whyneedname 2 years ago
parent
commit
6e5baa2130
  1. 58
      pages/shop/GoodsCollection/index.vue
  2. 1
      pages/user/coupon/GetCoupon/index.vue
  3. 1
      pages/user/coupon/UserCoupon/index.vue

58
pages/shop/GoodsCollection/index.vue

@ -24,7 +24,6 @@
</view> </view>
</view> </view>
<view class="collectionGoods" v-if="collectProductList.length > 0"> <view class="collectionGoods" v-if="collectProductList.length > 0">
<view class="item" v-for="(item, collectProductListIndex) in collectProductList" <view class="item" v-for="(item, collectProductListIndex) in collectProductList"
:key="collectProductListIndex" :data-index="collectProductListIndex" @touchstart="drawStart" :key="collectProductListIndex" :data-index="collectProductListIndex" @touchstart="drawStart"
@ -47,15 +46,9 @@
<!-- <view v-else class="review-box acea-row row-between" @click="goEvaluation(item)"> <!-- <view v-else class="review-box acea-row row-between" @click="goEvaluation(item)">
<view class="left acea-row row-column-between"> <view class="left acea-row row-column-between">
<view class="acea-row row-column-between"> <view class="acea-row row-column-between">
<view class="title"> <view class="title"></view>
<view class="title1"></view>
</view> <view class="title2"></view>
<view class="title1">
</view>
<view class="title2">
</view>
</view> </view>
<view @tap.stop="goMore" class="more"> <view @tap.stop="goMore" class="more">
MORE MORE
@ -66,21 +59,17 @@
</view> </view>
</view> --> </view> -->
<view v-else class="review-box acea-row row-between" @click="goEvaluation(item)"> <view v-else class="review-box acea-row row-between" @click="goEvaluation(item)">
<image src="@/static/images/ceping.png" mode="widthFix"></image> <image class="img" :src="item.homeImage" mode="aspectFill"></image>
<view @tap.stop="goMore" class="more"> <view class="more">
MORE MORE
</view> </view>
</view> </view>
<view class="delete" @tap.stop="delCollection(collectProductListIndex)" <view class="delete" @tap.stop="delCollection(collectProductListIndex)"
:style="item.right?'right: -122rpx;':''" :class="{'del-height':navType==1}">删除</view> :style="item.right?'right: -122rpx;':''" :class="{'del-height':navType==1}">删除</view>
</view> </view>
</view> </view>
<Loading :loaded="loadend" :loading="loading"></Loading> <Loading :loaded="loadend" :loading="loading"></Loading>
</view> </view>
@ -145,7 +134,6 @@
}, },
drawStart(e) { drawStart(e) {
console.log(155555);
var touch = e.touches[0]; var touch = e.touches[0];
// let index = e.currentTarget.dataset.index; // let index = e.currentTarget.dataset.index;
for (var index in this.collectProductList) { for (var index in this.collectProductList) {
@ -203,29 +191,21 @@
goEvaluation(item) { goEvaluation(item) {
this.$yrouter.push({ this.$yrouter.push({
// //
path: 'pages/shop/Evaluations/EvaluationDetail/index', path: '/pages/shop/Evaluations/EvaluationDetail/index',
query: { query: {
id: item.pid id: item.evaluationId
},
})
}, },
goMore() {
this.$yrouter.push({
//
path: 'pages/shop/Evaluations/index',
}) })
}, },
get_user_collect_product: function(navType) { get_user_collect_product: function(navType) {
let that = this let that = this
console.log(navType, '】】】】】】');
// if (that.loading) return //false if (that.loading) return //false
// if (that.loadend) return //false // if (that.loadend) return //false
that.loading = true that.loading = true
if (navType === 1) { if (navType === 1) {
// collectEvaluation/user // collectEvaluation/user
console.log('评测收藏==========');
getCollectEvaluation(that.page, that.limit, that.type).then(res => { getCollectEvaluation(that.page, that.limit, that.type).then(res => {
that.loading = false that.loading = false
//apply();js; //apply();js;
@ -244,7 +224,6 @@
} else { } else {
getCollectUser(that.page, that.limit, that.type).then(res => { getCollectUser(that.page, that.limit, that.type).then(res => {
that.loading = false that.loading = false
console.log('切换------------');
//apply();js; //apply();js;
var arr = []; var arr = [];
for (var i in res.data) { for (var i in res.data) {
@ -264,11 +243,11 @@
}, },
// //
delCollection: function(index) { delCollection: function(index) {
let that = this, let that = this
id = that.collectProductList[index].pid,
category = that.collectProductList[index].category
if (that.navType === 0) { if (that.navType === 0) {
let id = that.collectProductList[index].pid,
category = that.collectProductList[index].category
getCollectDel(id, category).then(function() { getCollectDel(id, category).then(function() {
uni.showToast({ uni.showToast({
title: '删除成功', title: '删除成功',
@ -282,7 +261,10 @@
}) })
} else { } else {
// //
delUserCollection(id, category).then(function() { let param={}
param.id=that.collectProductList[index].evaluationId,
param.category= "collect"
delUserCollection(param).then(function() {
uni.showToast({ uni.showToast({
title: '删除成功', title: '删除成功',
icon: 'success', icon: 'success',
@ -363,14 +345,16 @@
.review-box { .review-box {
// padding: 30rpx 30rpx 20rpx 30rpx; // padding: 30rpx 30rpx 20rpx 30rpx;
width: 687rpx; // width: 687rpx;
height: 240rpx; // height: 240rpx;
border-radius: 16rpx; border-radius: 16rpx;
background: #F5F6F8; background: #F5F6F8;
box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.15); box-shadow: 0rpx 10rpx 16rpx 0rpx rgba(0, 0, 0, 0.15);
position: relative; position: relative;
image { .img {
width: 100%; width: 687rpx;
height: 240rpx;
border-radius: 16rpx;
} }
.more { .more {

1
pages/user/coupon/GetCoupon/index.vue

@ -149,7 +149,6 @@ export default {
}, },
methods: { methods: {
goBannerDetail(item){ goBannerDetail(item){
console.log('----------------------------');
if (item.uniapp_url) { if (item.uniapp_url) {
this.$yrouter.push(item.uniapp_url) this.$yrouter.push(item.uniapp_url)
} }

1
pages/user/coupon/UserCoupon/index.vue

@ -195,7 +195,6 @@
}) })
}else{ }else{
getUserFailure().then(res=>{ getUserFailure().then(res=>{
console.log(res,'shixiao','============');
res.data.forEach(item=>{ res.data.forEach(item=>{
let futureDate=new Date(item.useEndTime).getTime() let futureDate=new Date(item.useEndTime).getTime()
let currentDate=new Date().getTime() let currentDate=new Date().getTime()

Loading…
Cancel
Save