首页修改

This commit is contained in:
魏啾 2024-05-30 11:57:46 +08:00
parent d3dc53783e
commit d140ef4f41
2 changed files with 18 additions and 14 deletions

View File

@ -3,10 +3,10 @@ const debug = process.env.NODE_ENV == 'development' ? true : false;
const proxyApi = "/api"
// #endif
// #ifdef MP-WEIXIN || APP
const proxyApi = 'http://192.168.2.42:9889/cashierService' // 王伟
// const proxyApi = 'http://192.168.2.42:9889/cashierService' // 王伟
// const proxyApi = 'http://192.168.2.74:9888/cashierService' // 帆哥
// const proxyApiwws = 'ws://192.168.2.74:9888/cashierService' // 测试
// const proxyApi = 'https://wxcashiertest.sxczgkj.cn/cashierService' // 测试
const proxyApi = 'https://wxcashiertest.sxczgkj.cn/cashierService' // 测试
const proxyApiwws = 'wss://wxcashiertest.sxczgkj.cn/cashierService' // 测试
// #endif
@ -16,10 +16,10 @@ const baseUrl = debug ? proxyApi : "https://wxcashiertest.sxczgkj.cn/cashierServ
const baseUrlwws = 'ws://cashier.sxczgkj.cn/cashierService'
// #endif
// #ifdef APP || MP-WEIXIN
// const baseUrl = debug ? proxyApi : 'https://cashier.sxczgkj.cn/cashierService'// 线上
// const baseUrlwws = debug ? proxyApiwws : 'wss://cashier.sxczgkj.cn/cashierService' // 线上
const baseUrl = 'https://wxcashiertest.sxczgkj.cn/cashierService'// 测试
const baseUrlwws ='wss://wxcashiertest.sxczgkj.cn/cashierService' // 测试
const baseUrl = debug ? proxyApi : 'https://cashier.sxczgkj.cn/cashierService'// 线上
const baseUrlwws = debug ? proxyApiwws : 'wss://cashier.sxczgkj.cn/cashierService' // 线上
// const baseUrl = 'https://wxcashiertest.sxczgkj.cn/cashierService'// 测试
// const baseUrlwws ='wss://wxcashiertest.sxczgkj.cn/cashierService' // 测试
// #endif
// import VConsole from "./vConsole.js"

View File

@ -92,8 +92,11 @@
<view class="fivecontent_item_boxitem flex-between">
<image :src="item.image" mode=""></image>
<view class="fivecontent_item_boxitemleft flex-colum-start">
<view class="fivecontent_item_boxitemleftone flex-between" style="display: flex;justify-content: space-between;align-items: center;">
<view>{{item.productName.length>7?item.productName.substring(0,7)+'...':item.productName}}</view>
<view class="fivecontent_item_boxitemleftone flex-between"
style="display: flex;justify-content: space-between;align-items: center;">
<view>
{{item.productName.length>7?item.productName.substring(0,7)+'...':item.productName}}
</view>
<text>已抢{{item.realSalesNumber}}</text>
</view>
<view class="flex-start flexstartboxfttow">
@ -137,7 +140,7 @@
</view>
</view>
</view>
</view>
</view>
<u-loadmore height='40' :status="form.status" iconSize='24' fontSize='24' />
<!-- </scroll-view> -->
@ -385,7 +388,7 @@
this.seighT = data.windowHeight;
this.$u.getRect('.fourcontent').then(res => {
console.log(res.top)
this.Topdistance = res.top - res.height - 20 //
this.Topdistance = res.top - res.height - 18 //
})
}
})
@ -487,14 +490,16 @@
async viewHistory(item, index) {
this.viewHistoryindex = index
if (item.dictName == 'allCity') {
console.log(item, 111)
let res = await this.api.locationdistrict({
keywords: uni.cache.get('getLocationstorage').address
})
this.clickhometoplistmenulist.detail = res.data
this.clickhometoplistmenulist.quilt = '1'
} else {
console.log(item, 222)
this.clickhometoplistmenulist.detail = item.detail
this.clickhometoplistmenulist.quilt = ''
this.clickhometoplistmenulist = item
}
uni.pageScrollTo({
scrollTop: this.Topdistance,
@ -503,7 +508,7 @@
if (item.isChild) {
this.showproductlist = true
} else {
this.form.other = item.description //1KM 1 0
this.form.type = item.value //1KM 1 0
this.form.page = 1
this.form.size = 10
this.form.status = 'loadmore'
@ -549,7 +554,6 @@
this.onLoadhome()
this.hometoplist.menu[this.viewHistoryindex].name = uni.cache.get('getLocationstorage').address
this.subCategoryList = []
this.clickhometoplistmenulist.quilt = '' // 1 1
} else {
this.subCategoryList = category.category.districts;
}
@ -569,7 +573,6 @@
this.form.status = 'loadmore'
this.homelist = []
this.onLoadhome()
this.clickhometoplistmenulist.quilt = '' // 1 1
},
}
@ -698,6 +701,7 @@
padding: 32rpx 28rpx;
overflow-x: auto;
flex-wrap: nowrap;
.fourcontent_item {
flex-wrap: nowrap;
margin-left: 22rpx;