wangfukang 3 weeks ago
parent
commit
c3fd3ad71c
  1. 8
      package2/shop/shopInfo.vue
  2. 7
      pages/index/index.vue

8
package2/shop/shopInfo.vue

@ -28,11 +28,11 @@
<input type="text" placeholder="请输入副标题" v-model="shop.subtitle" style="height: 100rpx;line-height: 100rpx;" /> <input type="text" placeholder="请输入副标题" v-model="shop.subtitle" style="height: 100rpx;line-height: 100rpx;" />
</view> </view>
</view> </view>
<view class="list-1"> <view class="list-1" style="height: auto;">
<view class="list-name"> <view class="list-name">
店铺地址 店铺地址
</view> </view>
<view class="list-right"> <view class="list-right" style="line-height: 20px;margin-top: 15px;">
{{shop.shopAddress}} {{shop.shopAddress}}
</view> </view>
</view> </view>
@ -103,7 +103,7 @@
} }
}, },
onLoad() { onLoad() {
this.shop = JSON.parse(uni.getStorageSync('shop')); this.shop = uni.getStorageSync('schoolShop')[0];
this.shopImages = this.shop.shopImages.split('@@') this.shopImages = this.shop.shopImages.split('@@')
this.huanjing = JSON.parse(this.shopImages[3])[0] this.huanjing = JSON.parse(this.shopImages[3])[0]
@ -149,7 +149,7 @@
let that = this; let that = this;
let hiver_token = uni.getStorageSync("hiver_token") let hiver_token = uni.getStorageSync("hiver_token")
await uni.uploadFile({ await uni.uploadFile({
url: getApp().globalData.mainurl + '/upload/file', url: that.tui.interfaceUrl() + '/upload/file',
filePath: path, filePath: path,
name: 'file', name: 'file',
header: { header: {

7
pages/index/index.vue

@ -1060,14 +1060,10 @@
that.mallAds = res.result.mallAds that.mallAds = res.result.mallAds
for(let i=0;i<that.mallAds.length;i++){ for(let i=0;i<that.mallAds.length;i++){
if(that.mallAds[i].position == 'home_top'){ if(that.mallAds[i].position == 'home_top'){
// //
if (that.mallAds[i].adImage.indexOf(',') !== -1) { if (that.mallAds[i].adImage.indexOf(',') !== -1) {
// {pic: url} // {pic: url}
that.adList = that.mallAds[i].adImage that.adList = that.mallAds[i].adImage.split(',').filter(item => item.trim() !== '').map(url => ({
.split(',')
.filter(item => item.trim() !== '') //
.map(url => ({
pic: url.trim() pic: url.trim()
})); }));
} else { } else {
@ -1107,6 +1103,7 @@
}).catch((res) => {}); }).catch((res) => {});
}, },
goAdPage(item) { goAdPage(item) {
console.log('hahahahah',item)
uni.navigateTo({ uni.navigateTo({
url: item.linkUrl + item.linkParams url: item.linkUrl + item.linkParams
}) })

Loading…
Cancel
Save