Commit 4b2edd92 by cwq0219

bug修复

1 parent b927f5b4
...@@ -8,9 +8,17 @@ ...@@ -8,9 +8,17 @@
<img v-for="(item, index) in scope.scope.starLevel" :key="index" class="icon-star" src="@/assets/icon-star.png"/> <img v-for="(item, index) in scope.scope.starLevel" :key="index" class="icon-star" src="@/assets/icon-star.png"/>
</div> </div>
<div slot="goodsImage" class="table-image" slot-scope="scope"> <div slot="goodsImage" class="table-image" slot-scope="scope">
<img class="img-60" :src="scope.scope.goodsImage" /> <span v-if="!scope.scope.imgUrls">-</span>
<img v-else class="img-60" :src="scope.scope.imgUrls[0]" @click="handleImgLook(scope.scope.imgUrls)"/>
</div> </div>
</GLTable> </GLTable>
<el-dialog v-if="isImgVisible" title="查看" :visible.sync="isImgVisible">
<div class="dialog-look">
<span v-for="(item, index) in dialogObj.imgUrls" :key="index">
<el-image style="width: 200px; height: 200px; margin-right: 10px;" :src="item" :preview-src-list="[item]" ></el-image>
</span>
</div>
</el-dialog>
</div> </div>
</div> </div>
</template> </template>
...@@ -26,6 +34,12 @@ export default { ...@@ -26,6 +34,12 @@ export default {
searchForm: { searchForm: {
goodsId: '' goodsId: ''
}, },
isImgVisible: false,
// imgUrls: [],,
dialogObj: {
imgUrls: [],
uploadType: 'img'
},
// 表格 // 表格
getListApi: this.$apis.proManage.getGoodsCommentListApi, getListApi: this.$apis.proManage.getGoodsCommentListApi,
tableParams: { tableParams: {
...@@ -78,8 +92,17 @@ export default { ...@@ -78,8 +92,17 @@ export default {
setTableFinishFun() { setTableFinishFun() {
//接收到的数据为空 //接收到的数据为空
this.$refs.commentRef.data.length ? (this.$refs.commentRef.tableHeightValues = '') : this.$refs.commentRef.setTableHeightFun() this.$refs.commentRef.data.length ? (this.$refs.commentRef.tableHeightValues = '') : this.$refs.commentRef.setTableHeightFun()
},
handleImgLook(imgUrls) {
this.isImgVisible = !this.isImgVisible
this.dialogObj = {
imgUrls: imgUrls,
uploadType: 'img'
}
} }
} }
} }
</script> </script>
<style></style> <style>
</style>
...@@ -286,7 +286,7 @@ export default { ...@@ -286,7 +286,7 @@ export default {
}, },
handleSingleSelectClose(isCancel = false) { handleSingleSelectClose(isCancel = false) {
if(isCancel) { if(isCancel) {
this.getGoodInfo(this.selectedProInfo.id) this.selectedProInfo.id && this.getGoodInfo(this.selectedProInfo.id)
} }
this.isSingleSelectVisible = !this.isSingleSelectVisible this.isSingleSelectVisible = !this.isSingleSelectVisible
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!