分类接口对接

This commit is contained in:
”chenxuelian“
2022-12-26 20:16:44 +08:00
parent 51d34b2732
commit 3d04398b7c
4 changed files with 43 additions and 7 deletions

View File

@@ -146,10 +146,6 @@
this.tabCurrent = data.index
this.needsPublishForm = {}
},
changeCity(data) {
this.needsPublishForm.city = data.data.join('')
console.log('showCityPicker = true')
},
getCityValue(data) {
this.showCityPicker = false
this.needsPublishForm.city = data.join('/')

View File

@@ -105,6 +105,7 @@
uni.stopPullDownRefresh()
},
onLoad() {
this.getImgUrl()
this.$apiServe.getCategories().then(res => {
console.log(res)
}).finally(_ => {})
@@ -151,6 +152,16 @@
uni.navigateTo({
url: '../../packageSearch/goods-category-search/category-index'
})
},
getImgUrl() {
this.$apiServe.getImgUrl().then(res => {
console.log(res)
try {
uni.setStorageSync('img_url', res.data.data.img_url);
} catch (e) {
// error
}
}).finally(_ => {})
}
}
}