页面修改

This commit is contained in:
THK3121 2023-09-11 16:01:39 +08:00
parent a1fd0875d7
commit 18d3622cff
2 changed files with 42 additions and 16 deletions

View File

@ -9,8 +9,8 @@ let httpApiThree
// 网络接口修改此字符 小程序域名要求https
// let httpApi = 'http://192.168.31.110:8324' // 测试
if (process.env.NODE_ENV === "development") {
httpApi = 'https://shop.lihaink.cn' // 生产
// httpApi = "https://crmeb-test.shop.lihaink.cn"
// httpApi = 'https://shop.lihaink.cn' // 生产
httpApi = "https://crmeb-test.shop.lihaink.cn"
// httpApi = "http://192.168.0.222"
// httpApi = "http://192.168.0.108:8325"
// httpApi = 'http://192.168.0.108:8325'

View File

@ -17,8 +17,9 @@
</view> -->
<view class="" v-if="cloudList.length>0">
<view class="">
<!-- <view style="height: var(--status-bar-height);"></view> -->
<!-- <view :style="`height: ${appInfo.top}px;background-color: red;z-index: 99999;`"></view> -->
<transition name="fade">
<view class="head" style="padding-top: var(--status-bar-height);" v-if="showtit">
<view style="display: flex;align-items: center;">
@ -59,7 +60,7 @@
<u--image :showLoading="true" src="/static/images/LHYC/QB.png" width="50.82rpx"
height="50.82rpx"></u--image>
<text class="">全部</text>
<view class="flag">
<view class="flags">
</view>
</view>
@ -75,7 +76,7 @@
:circular="true" previous-margin='0rpx' next-margin='0rpx' :current="current"
:disable-touch="true">
<swiper-item v-for="(item,index) in cloudList">
<u--image :showLoading="true" :src="item.cover" width="750rpx"
<u--image :showLoading="true" :src="item.cover" :class="act_img" width="750rpx"
height="998.83rpx"></u--image>
</swiper-item>
</swiper>
@ -97,15 +98,15 @@
</swiper-item>
</swiper>
</view>
<view class="content_sift" :style="{position:pocls,top:headtop+'px'}" v-if="!showtit">
<view :class="{act:item.act}" v-for="item,index in actList" :key="index"
@click="screenGoods(item.screen,index)">
{{item.tit}}
</view>
</view>
<transition name="fade">
<view class="content">
<view class="content_sift" :style="{position:pocls,top:(headtop+16)+'px'}" v-if="!showtit">
<view :class="{act:item.act}" v-for="item,index in actList" :key="index"
@click="screenGoods(item.screen,index)">
{{item.tit}}
</view>
</view>
<view class="goods_list" v-if="goodsList.length>0">
<view class="empty" v-if='showLoading'>
<u-loading-icon v-if='showLoading' text="加载中" textSize="18"></u-loading-icon>
@ -280,8 +281,9 @@
showtit: true,
cartList: [],
activeClass: 'activeClass',
headtop: "",
headtop: 0,
page_num: 1,
act_img: "",
actList: [{
tit: '综合',
act: "",
@ -338,13 +340,15 @@
.select('.content')
.boundingClientRect(rect => {
// console.log(rect)
if (rect.top <= this.headtop) {
if (rect.top <= (this.headtop + 16)) {
this.pocls = 'fixed'
this.act_swiper = 'act_swiper'
this.act_img = 'act_img'
} else {
this.pocls = ''
this.act_swiper = ''
this.act_img = ''
}
})
@ -352,11 +356,20 @@
if (this.headtop) return
uni.createSelectorQuery()
.in(this)
.select('.flag')
.select('.flags')
.boundingClientRect(rect => {
this.headtop = rect.top
console.log(rect.top)
})
.exec();
// uni.createSelectorQuery()
// .in(this)
// .select('.content_sift')
// .boundingClientRect(rect => {
// // this.headtop += rect.height
// console.log(this.headtop)
// })
// .exec();
},
onPullDownRefresh() {
uni.stopPullDownRefresh()
@ -478,6 +491,11 @@
</script>
<style lang="scss" scoped>
.flags {
background-color: red;
z-index: 99999999;
}
.box {
position: relative;
@ -488,7 +506,7 @@
// border-top: 5px solid red;
z-index: 99;
background-color: #F4F4F4;
padding: 0 10rpx;
// padding: 0 10rpx;
}
@ -647,6 +665,7 @@
.goods_list {
min-height: 100vh;
padding: 0 10rpx;
// background-color: red;
.goods {
@ -717,6 +736,12 @@
overflow: hidden;
}
.act_img {
// transition:t;
transform: translateY(-848rpx);
}
// .act_swiper2 {
// height: 998rpx;
// }
@ -727,6 +752,7 @@
display: flex;
justify-content: space-around;
background-color: white;
// background-color: green;
z-index: 99;
box-sizing: border-box;