Selaa lähdekoodia

钣金喷漆商品bug、评论bug

baijunde 1 vuosi sitten
vanhempi
commit
3a521b5996
2 muutettua tiedostoa jossa 9 lisäystä ja 4 poistoa
  1. 4 1
      pages/evaluate/evaluate.vue
  2. 5 3
      pages/product/creatProduct.vue

+ 4 - 1
pages/evaluate/evaluate.vue

@@ -48,6 +48,7 @@
 						<view class=" headr">
 							<view class="left">
 								<view class="img">
+									
 									<image :src="item.commentsReply" mode="" v-if="item.commentsReply"></image>
 									<image src="/static/avatar_boy.png" mode="" v-else></image>
 								</view>
@@ -195,6 +196,7 @@
 							console.log(res)
 							this.appraiseList = this.appraiseList.concat(res.data.result.records)
 							this.mescroll.endSuccess(res.data.result.records.length, res.data.result.total);; // 结束下拉刷新状态
+							console.log(this.appraiseList)
 						}
 					}).catch(() => {
 					this.mescroll.endErr()
@@ -208,15 +210,16 @@
 				this.$http.post('/app/comments/reply',data).then(res =>{
 					console.log(res)
 					if(res.data.code == 200){
+						item.reply = ''
 						uni.showToast({
 							icon:'none',
 							title:'回复成功'
 						})
+						this.appraiseList = []
 						let page = {
 							num: 1,
 							size: 10
 						}
-							this.appraiseList = []
 						this.getcommentList(page)
 					}
 					

+ 5 - 3
pages/product/creatProduct.vue

@@ -355,6 +355,7 @@
 				selectVaule: 0, //钣金喷漆选择
 				all: false, //是否全选
 				reverse: false, //是否反选
+				selectProductSunItem:[]
 			}
 		},
 		methods: {
@@ -426,10 +427,10 @@
 					this.form.specItems.forEach(item => {
 						// item.replaced = true
 						if(item.replaced){
-							temp.push(item)
+							this.selectProductSunItem.push(item)
 						}
 					})
-					this.form.specItems = temp
+					// this.form.specItems = temp
 				}
 				
 				//基础信息必填提示
@@ -474,7 +475,7 @@
 						icon: 'none'
 					});
 					return
-				} else if (this.form.categoryId == '1945013773786701826' && temp.length ==0) {
+				} else if (this.form.categoryId == '1945013773786701826' && this.selectProductSunItem.length ==0) {
 					uni.showToast({
 						title: '请选择最少一个配置',
 						icon: 'none'
@@ -629,6 +630,7 @@
 			//提交审核
 			submit() {
 				console.log(this.form)
+				this.form.specItems = this.selectProductSunItem
 				this.makeChecked ? this.form.preBook = 1 : this.form.preBook = 0
 				if (!this.form.saleStartDate) {
 					uni.showToast({