修改referer
This commit is contained in:
parent
994e791771
commit
bb1f7fb50b
@ -582,6 +582,7 @@
|
|||||||
])),
|
])),
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
|
console.log('options', options);
|
||||||
this.referer = options.referer
|
this.referer = options.referer
|
||||||
if (options.product_type) {
|
if (options.product_type) {
|
||||||
this.product_type = options.product_type
|
this.product_type = options.product_type
|
||||||
@ -978,7 +979,6 @@
|
|||||||
});
|
});
|
||||||
let that = this;
|
let that = this;
|
||||||
const data = { product_type: this.product_type }
|
const data = { product_type: this.product_type }
|
||||||
console.log('data', data);
|
|
||||||
getProductDetail(that.id, data).then(res => {
|
getProductDetail(that.id, data).then(res => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
let storeInfo = res.data;
|
let storeInfo = res.data;
|
||||||
@ -1332,14 +1332,15 @@
|
|||||||
product_attr_unique: that.attr.productSelect !== undefined ? that.attr.productSelect.unique : "",
|
product_attr_unique: that.attr.productSelect !== undefined ? that.attr.productSelect.unique : "",
|
||||||
source: this.source,
|
source: this.source,
|
||||||
product_type: 0,
|
product_type: 0,
|
||||||
spread_id: this.currSpid
|
spread_id: this.currSpid,
|
||||||
|
referer: this.referer
|
||||||
};
|
};
|
||||||
postCartAdd(q)
|
postCartAdd(q)
|
||||||
.then(function(res) {
|
.then(function(res) {
|
||||||
that.isOpen = that.attr.cartAttr = false;
|
that.isOpen = that.attr.cartAttr = false;
|
||||||
if (news) {
|
if (news) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/users/order_confirm/index?cartId=${res.data.cart_id}&referer=${that.referer}`
|
url: `/pages/users/order_confirm/index?cartId=${res.data.cart_id}`
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
that.$util.Tips({
|
that.$util.Tips({
|
||||||
|
@ -4,12 +4,12 @@
|
|||||||
<view class="town-title">{{town}}里海云仓</view>
|
<view class="town-title">{{town}}里海云仓</view>
|
||||||
<view class="body-wrapper">
|
<view class="body-wrapper">
|
||||||
<block v-for="(item,index) in cloudList" :key="index">
|
<block v-for="(item,index) in cloudList" :key="index">
|
||||||
<navigator v-if="item.show" class="item"
|
<navigator class="item"
|
||||||
:url="`/pages/nongKe/goods_list/index?cate_id=${item.category_id}&street=${street_code}&name=${item.title}`"
|
:url="`/pages/nongKe/goods_list/index?cate_id=${item.category_id}&street=${street_code}&name=${item.category_name}`"
|
||||||
:style="{'background-image': `url(${item.bg})`}">
|
:style="{'background-image': `url(${item.background})`}">
|
||||||
<text class="item-title">{{item.title}}云仓服务</text>
|
<text class="item-title">{{item.category_name}}云仓服务</text>
|
||||||
<text>{{item.text}}</text>
|
<text>{{item.description}}</text>
|
||||||
<view class="chakan-btn" @click="navigator">查看</view>
|
<view class="chakan-btn">查看</view>
|
||||||
</navigator>
|
</navigator>
|
||||||
</block>
|
</block>
|
||||||
</view>
|
</view>
|
||||||
@ -24,105 +24,7 @@
|
|||||||
let src = 'https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/13';
|
let src = 'https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/13';
|
||||||
return {
|
return {
|
||||||
winHeight: 0,
|
winHeight: 0,
|
||||||
cloudList: [{
|
cloudList: [],
|
||||||
title: '商超服务',
|
|
||||||
text: '便捷商超购物,包送到家',
|
|
||||||
bg: src + '/shangchao.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 25
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '农副产品',
|
|
||||||
text: '瓜果蔬菜线上购买',
|
|
||||||
bg: src + '/nongfu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 26
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '生活服务',
|
|
||||||
text: '生活服务样样齐全',
|
|
||||||
bg: src + '/shenghuo.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 23
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '农业生产',
|
|
||||||
text: '种子化肥送到家',
|
|
||||||
bg: src + '/nongye.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 22
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '物流溯源',
|
|
||||||
text: '追溯产品源头',
|
|
||||||
bg: src + '/wuliu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2541
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '坝坝宴',
|
|
||||||
text: '农家各种酒席宴会',
|
|
||||||
bg: src + '/yan.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 21
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '文娱旅游',
|
|
||||||
text: '周边好玩景点',
|
|
||||||
bg: src + '/shangchao.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2542
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '民生公益',
|
|
||||||
text: '扶贫助学项目',
|
|
||||||
bg: src + '/minsheng.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2543
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '医疗保健',
|
|
||||||
text: '便捷医疗服务',
|
|
||||||
bg: src + '/yiliao.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2544
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '教育培训',
|
|
||||||
text: '更完善的教育系统',
|
|
||||||
bg: src + '/jiaoyu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2545
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '装修建筑',
|
|
||||||
text: '个人家庭商铺装修',
|
|
||||||
bg: src + '/zhuangxiu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2547
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '交金融宝',
|
|
||||||
text: '个人家庭商铺装修',
|
|
||||||
bg: src + '/zhuangxiu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2546
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '农贸基地',
|
|
||||||
text: '个人家庭商铺装修',
|
|
||||||
bg: src + '/zhuangxiu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2548
|
|
||||||
},
|
|
||||||
{
|
|
||||||
title: '供销综合',
|
|
||||||
text: '个人家庭商铺装修',
|
|
||||||
bg: src + '/zhuangxiu.png',
|
|
||||||
show: false,
|
|
||||||
category_id: 2549
|
|
||||||
}
|
|
||||||
],
|
|
||||||
street_code: '',
|
street_code: '',
|
||||||
town: ''
|
town: ''
|
||||||
}
|
}
|
||||||
@ -139,25 +41,14 @@
|
|||||||
},
|
},
|
||||||
onShow() {},
|
onShow() {},
|
||||||
onPullDownRefresh() {
|
onPullDownRefresh() {
|
||||||
|
this.getCloundShop()
|
||||||
uni.stopPullDownRefresh()
|
uni.stopPullDownRefresh()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async getCloundShop() {
|
async getCloundShop() {
|
||||||
const { data } = await getCityCloundShop({ street_code: 510502102 })
|
const { data } = await getCityCloundShop({ street_code: this.street_code })
|
||||||
data.length < 1 ? Toast("暂无云仓") : ''
|
this.cloudList = data
|
||||||
data.map(item => {
|
data.length < 1 ? Toast("暂无云仓") : '';
|
||||||
this.cloudList.forEach(itens => {
|
|
||||||
itens.show = true
|
|
||||||
// if (itens.category_id == item.category_id) {
|
|
||||||
// itens.show = true
|
|
||||||
// }
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
navigator() {
|
|
||||||
uni.navigateTo({
|
|
||||||
url: '/pages/user/index'
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user