换了 wxc2bb94c0ddda1032

This commit is contained in:
魏啾
2024-06-04 10:34:13 +08:00
parent 697f207683
commit d09082e6ea
2 changed files with 22 additions and 14 deletions

View File

@@ -56,7 +56,7 @@
"quickapp" : {}, "quickapp" : {},
/* */ /* */
"mp-weixin" : { "mp-weixin" : {
"appid" : "wxd88fffa983758a30", "appid" : "wxc2bb94c0ddda1032",
"setting" : { "setting" : {
"urlCheck" : false, "urlCheck" : false,
"minified" : true, "minified" : true,

View File

@@ -50,16 +50,19 @@
<!-- 今日上线 --> <!-- 今日上线 -->
<todaylist :todayList='hometoplist.todayList' :salesList='hometoplist.salesList'></todaylist> <todaylist :todayList='hometoplist.todayList' :salesList='hometoplist.salesList'></todaylist>
<!-- 类目 --> <!-- 类目 -->
<view class="fourcontent flex-between" v-if="!isFixedTop"> <view class="fourcontent">
<view class="fourcontent_item flex-start" v-for="(item,index) in hometoplist.menu" :key="index" <!-- 用于防止榻卸 -->
@click="viewHistory(item,index)" <view class="flex-between" style="flex-wrap: inherit;" v-if="!isFixedTop">
:class="!item.isChild && viewHistoryindex == index ? 'fourcontent_itemactev':''"> <view class="fourcontent_item flex-start" v-for="(item,index) in hometoplist.menu" :key="index"
<text style="margin-right: 10rpx;">{{item.name}}</text> @click="viewHistory(item,index)"
<u-icon v-if="item.isChild" style="margin-left: 10rpx;" name="arrow-down-fill" color="#333333" :class="!item.isChild && viewHistoryindex == index ? 'fourcontent_itemactev':''">
size="16"></u-icon> <text style="margin-right: 10rpx;">{{item.name}}</text>
<u-icon v-if="item.isChild" style="margin-left: 10rpx;" name="arrow-down-fill" color="#333333"
size="16"></u-icon>
</view>
</view> </view>
</view> </view>
<view class="fivecontent"> <view class="fivecontent">
<!-- <view class="fivecontent" :style="{'height':seighT + 'px'}"> --> <!-- <view class="fivecontent" :style="{'height':seighT + 'px'}"> -->
<!-- <scroll-view :style="{'height':seighT + 'px'}" scroll-y @scrolltolower="loadMore" <!-- <scroll-view :style="{'height':seighT + 'px'}" scroll-y @scrolltolower="loadMore"
@@ -488,6 +491,10 @@
}, },
// 点击元素到指定位置 // 点击元素到指定位置
async viewHistory(item, index) { async viewHistory(item, index) {
uni.pageScrollTo({
scrollTop: this.Topdistance,
duration: 300
});
this.viewHistoryindex = index this.viewHistoryindex = index
if (item.dictName == 'allCity') { if (item.dictName == 'allCity') {
let res = await this.api.locationdistrict({ let res = await this.api.locationdistrict({
@@ -499,14 +506,15 @@
this.clickhometoplistmenulist.detail = item.detail this.clickhometoplistmenulist.detail = item.detail
this.clickhometoplistmenulist.quilt = '' this.clickhometoplistmenulist.quilt = ''
} }
uni.pageScrollTo({
scrollTop: this.Topdistance,
duration: 300
});
if (item.isChild) { if (item.isChild) {
this.form.type = '' //先清空后赋值 this.form.type = '' //先清空后赋值
this.showproductlist = true this.showproductlist = true
} else { } else {
// 以下没有多选处理
if(item.value == this.form.type){// 再次选择取消选中
this.viewHistoryindex = ''
}
this.form.type = item.value == this.form.type ? "" : item.value //附近1KM 1选中 0不选中 this.form.type = item.value == this.form.type ? "" : item.value //附近1KM 1选中 0不选中
this.form.page = 1 this.form.page = 1
this.form.size = 10 this.form.size = 10
@@ -514,7 +522,7 @@
this.homelist = [] this.homelist = []
this.onLoadhome() this.onLoadhome()
} }
}, },
// 选择元素的指定选项 // 选择元素的指定选项
clickdetail(item, index) { clickdetail(item, index) {