Commit 1333464e by 李嘉林

选择规格组件测试

parent d915a381
......@@ -5,4 +5,20 @@ export default {
getLiveInfo(options) {
return requestPOST1(`${process.env.OLSHOP_URL}/liveBroadcastInfo/getLiveBroadcastInfoByIds?liveBroadcastId=${options}`);
},
// 查询所有产品规格详情
getProductGoodsByProductInfo(options) {
return requestPOST(`${process.env.OLSHOP_URL}/product/get_product_goods_by_product_info`, options);
},
// 获取商品所有规格
getProductGoodsSpecifications(options) {
return requestPOST(`${process.env.OLSHOP_URL}/product/get_goods_specifications`, options);
},
// 查询产品信息
getProductGoodsByMixId(options) {
return requestPOST(`${process.env.OLSHOP_URL}/product/get_product_goods_by_mix_id`, options);
},
// 添加购物车
addCart(options) {
return requestPOST(`${process.env.OLSHOP_URL}/cart/add_item`, options);
},
};
\ No newline at end of file
<template>
<!-- 讲解商品模块 -->
<div class="livedExplainGoods">
</div>
</template>
<script type="text/ecmascript-6">
export default {
name: "",
data() {
return {};
},
components: {},
computed: {},
created() {},
mounted() {},
methods: {}
};
</script>
<style lang="scss" scoped>
.livedExplainGoods {
}
</style>
......@@ -25,7 +25,7 @@
<span>{{999}}</span>
</p>
</div>
<div class="icon">
<div class="icon" @click="showSpeDia(item)">
<van-icon name="shopping-cart" />
</div>
</div>
......@@ -33,10 +33,13 @@
</div>
</div>
</van-popup>
<!-- 选择规格弹层 -->
<livedSelectionSpe :show="showSpe" :productInfoId="productInfoId" @closeSpeDia="closeSpeDia"></livedSelectionSpe>
</div>
</template>
<script type="text/ecmascript-6">
import livedSelectionSpe from "@/components/livedModel/livedSelectionSpe";
export default {
props: {
showDia: {
......@@ -72,10 +75,14 @@ export default {
"//img3.imgtn.bdimg.com/it/u=3743111107,1940472030&fm=11&gp=0.jpg",
price: 123
}
]
],
showSpe:false,
productInfoId:0,
};
},
components: {},
components: {
livedSelectionSpe
},
computed: {},
created() {},
mounted() {},
......@@ -83,6 +90,13 @@ export default {
// 关闭
closeDia() {
this.$emit("changeStatus");
},
showSpeDia(val){
this.showSpe=true;
// 调用规格列表及价格信息传入组件先展示
},
closeSpeDia(){
this.showSpe=false;
}
}
};
......
......@@ -4,6 +4,8 @@
"usingComponents": {
"van-button": "/static/vant/button/index",
"van-icon": "/static/vant/icon/index",
"van-popup": "/static/vant/popup/index"
"van-popup": "/static/vant/popup/index",
"van-stepper": "/static/vant/stepper/index"
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment