[new feature]Sku: 组件新增图片预览功能 (#2019)

* feat: SKU组件新增图片预览功能
This commit is contained in:
Jackie Zhang
2018-11-02 21:13:14 +08:00
committed by wny
parent 7e07def544
commit a5576762d8
2 changed files with 48 additions and 1 deletions

View File

@@ -1,6 +1,6 @@
<template>
<div :class="b()" class="van-hairline--bottom">
<div :class="b('img-wrap')">
<div :class="b('img-wrap')" @click="previewImage">
<img :src="goodsImg" >
</div>
<div :class="b('goods-info')">
@@ -49,6 +49,10 @@ export default create({
if (matchedSku && matchedSku.imgUrl) {
return matchedSku.imgUrl;
}
},
previewImage() {
this.skuEventBus.$emit('sku:previewImage', this.goodsImg);
}
}
});