Commit d5a3349c authored by 黄媛媛's avatar 黄媛媛

1

parent 076be7b0
...@@ -137,6 +137,7 @@ export default { ...@@ -137,6 +137,7 @@ export default {
} }
}, },
joinCar() { joinCar() {
console.log('操作')
this.u = uni.getStorageSync('mall_UserInfo'); this.u = uni.getStorageSync('mall_UserInfo');
if (!this.u) { if (!this.u) {
this.u = { this.u = {
...@@ -145,7 +146,10 @@ export default { ...@@ -145,7 +146,10 @@ export default {
}; };
this.showAuth = true; this.showAuth = true;
} else { } else {
this.$emit('join-car'); console.log('传入父组件')
this.$emit('joincar');
} }
}, },
buy() { buy() {
......
...@@ -166,7 +166,7 @@ ...@@ -166,7 +166,7 @@
<view style="width: calc(100vw - 20px); margin-left: 10px; overflow: hidden;"><goodlist :list="recommend"></goodlist></view> <view style="width: calc(100vw - 20px); margin-left: 10px; overflow: hidden;"><goodlist :list="recommend"></goodlist></view>
<u-skeleton v-if="loading" :loading="true" :animation="true" bgcolor="#FFF"></u-skeleton> <u-skeleton v-if="loading" :loading="true" :animation="true" bgcolor="#FFF"></u-skeleton>
<goodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.cover_pic" :favorite="g.favorite" :good-id="id" @join-car="joinCar" @buy="buy"></goodsaction> <goodsaction v-if="!loading" :good-name="g.name" :cover-pic="g.cover_pic" :favorite="g.favorite" :good-id="id" @joincar="joinCar" @buy="buy"></goodsaction>
<goodsku <goodsku
v-if="!loading && showSku" v-if="!loading && showSku"
border-radius="10" border-radius="10"
......
...@@ -2,9 +2,9 @@ export default { ...@@ -2,9 +2,9 @@ export default {
install(Vue, options) { install(Vue, options) {
Vue.prototype.host = "https://wx.weibaoge.cn/web/index.php?_mall_id=1285" Vue.prototype.host = "https://wx.weibaoge.cn/web/index.php?_mall_id=1285"
// Vue.prototype.host2 = "http://192.168.0.110:8200" // Vue.prototype.host2 = "http://192.168.0.110:8200"
// Vue.prototype.host2 = "https://mallApi.oytour.com" Vue.prototype.host2 = "https://mallApi.oytour.com"
// Vue.prototype.host2 = "http://192.168.2.16:8088" // Vue.prototype.host2 = "http://192.168.2.16:8088"
Vue.prototype.host2 = "http://192.168.2.65" // Vue.prototype.host2 = "http://192.168.2.65"
Vue.prototype.request = function(param, success, failed) { Vue.prototype.request = function(param, success, failed) {
//网络请求 //网络请求
uni.request({ uni.request({
...@@ -57,15 +57,15 @@ export default { ...@@ -57,15 +57,15 @@ export default {
} }
}else if(res.data.resultCode != 1) { }else if(res.data.resultCode != 1) {
if(res.data.couponResultCode==0){ if( res.data.message!=''){
}else{
uni.showToast({ uni.showToast({
title: res.data.message, title: res.data.message,
icon: "none", icon: "none",
}); });
} }
typeof failed == "function" && failed(res.data); typeof failed == "function" && failed(res.data);
} }
......
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