chenkainan 12 months ago
parent
commit
014ca22436
  1. 16
      compoents/userReviews.vue
  2. 2
      subPackages/hotelHomestay/detail.vue
  3. 2
      subPackages/line/detail.vue
  4. 2
      subPackages/order/commentList.vue
  5. 2
      subPackages/techan/detail.vue
  6. 2
      subPackages/ticketBooking/detail.vue

16
compoents/userReviews.vue

@ -31,7 +31,7 @@
<script> <script>
export default { export default {
props:['goodsId'], props:['goodsId','goodsType'],
data() { data() {
return { return {
commentList: [], commentList: [],
@ -46,18 +46,20 @@
this.commentList = [] this.commentList = []
this.commentNum = 0 this.commentNum = 0
if (!this.goodsId) return if (!this.goodsId) return
this.Post({ let query = {offset: 0,limit: 2}
goods_id: this.goodsId, if (this.goodsType=='goodsId') {
offset: 0, query.goods_id = this.goodsId
limit: 2 } else {
}, '/api/scenic/getGoodsCommentByScenicId').then(res => { query.scenic_id = this.goodsId
}
this.Post(query, '/api/scenic/getGoodsCommentByScenicId').then(res => {
this.commentList = res.data this.commentList = res.data
this.commentNum = res.msg this.commentNum = res.msg
}) })
}, },
viewAll () { viewAll () {
uni.navigateTo({ uni.navigateTo({
url:'/subPackages/eventCalendar/detail?id='+this.id url:`/subPackages/order/commentList?${this.goodsType}=`+this.goodsId
}) })
}, },

2
subPackages/hotelHomestay/detail.vue

@ -133,7 +133,7 @@
</view> </view>
<template v-if="id"> <template v-if="id">
<userReviewsVue :goodsId="id"></userReviewsVue> <userReviewsVue :goodsId="id" goodsType="scenicId"></userReviewsVue>
<moreGoodsVue :goodsId="id"></moreGoodsVue> <moreGoodsVue :goodsId="id"></moreGoodsVue>
</template> </template>

2
subPackages/line/detail.vue

@ -42,7 +42,7 @@
</view> </view>
<template v-if="id"> <template v-if="id">
<userReviewsVue :goodsId="id"></userReviewsVue> <userReviewsVue :goodsId="id" goodsType="goodsId"></userReviewsVue>
<moreGoodsVue :goodsId="id"></moreGoodsVue> <moreGoodsVue :goodsId="id"></moreGoodsVue>
</template> </template>
</view> </view>

2
subPackages/order/commentList.vue

@ -51,10 +51,8 @@
</template> </template>
<script> <script>
import Base from "@/components/Base";
export default { export default {
name: "commentList", name: "commentList",
extends: Base,
data() { data() {
return { return {
id: null, id: null,

2
subPackages/techan/detail.vue

@ -55,7 +55,7 @@
</view> </view>
<template v-if="id"> <template v-if="id">
<userReviewsVue :goodsId="id"></userReviewsVue> <userReviewsVue :goodsId="id" ></userReviewsVue>
<moreGoodsVue :goodsId="id"></moreGoodsVue> <moreGoodsVue :goodsId="id"></moreGoodsVue>
</template> </template>
</view> </view>

2
subPackages/ticketBooking/detail.vue

@ -122,7 +122,7 @@
</view> </view>
<template v-if="id"> <template v-if="id">
<userReviewsVue :goodsId="id"></userReviewsVue> <userReviewsVue :goodsId="id" goodsType="scenicId"></userReviewsVue>
<moreGoodsVue :goodsId="id"></moreGoodsVue> <moreGoodsVue :goodsId="id"></moreGoodsVue>
</template> </template>

Loading…
Cancel
Save