This commit is contained in:
liuye
2024-06-27 15:32:54 +08:00
parent 988ee9bd91
commit a759c7aacf
2 changed files with 23 additions and 5 deletions

View File

@@ -6,7 +6,7 @@
height="100" :bar-style="barStyle"></u-tabs> height="100" :bar-style="barStyle"></u-tabs>
</div> </div>
<Situation v-if="tabIndex != 1" @toStoreDetail="toStoreDetail"></Situation> <Situation v-if="tabIndex != 1" @toStoreDetail="toStoreDetail"></Situation>
<Evaluate v-else @toEvaluateForm="toEvaluateForm" @toStoreDetail="toStoreDetail"></Evaluate> <Evaluate v-else @toEvaluateForm="toEvaluateForm" @toStoreDetail="toStoreDetail" :tabHeight="tabHeight"></Evaluate>
</div> </div>
</template> </template>
@@ -33,7 +33,8 @@ export default {
}, },
backgroundNavbar: { backgroundNavbar: {
background: '#fff', background: '#fff',
} },
tabHeight: 0
} }
}, },
computed: { computed: {
@@ -43,7 +44,17 @@ export default {
if(e.tabIndex) { if(e.tabIndex) {
this.tabIndex = e.tabIndex this.tabIndex = e.tabIndex
} }
let info = uni.createSelectorQuery().select(".tab");
info.boundingClientRect((data)=> { //data - 各种参数
this.tabHeight = data.height
console.log(this.tabHeight)
}).exec()
},
onShow() {
}, },
methods: { methods: {
change(e) { change(e) {

View File

@@ -84,10 +84,12 @@ export default {
navHeight: '' navHeight: ''
} }
}, },
props: {
tabHeight: {
type: String
}
},
created() { created() {
// var statusBarHeight = uni.getSystemInfoSync().statusBarHeight
this.navHeight = uni.getSystemInfoSync().statusBarHeight + 94
this.$dict.load(['operatorType', 'storeLevel']).then(() => { this.$dict.load(['operatorType', 'storeLevel']).then(() => {
var all = [{dictName: '全部', dictValue: ''}] var all = [{dictName: '全部', dictValue: ''}]
this.operatorTypeDict = all.concat( this.$dict.getDict('operatorType')) this.operatorTypeDict = all.concat( this.$dict.getDict('operatorType'))
@@ -95,6 +97,11 @@ export default {
this.getList() this.getList()
}) })
}, },
mounted() {
setTimeout(() => {
this.navHeight = uni.getSystemInfoSync().statusBarHeight + Number(this.tabHeight) + 44
}, 600)
},
methods: { methods: {
getList() { getList() {
if(this.current > this.pages) return if(this.current > this.pages) return