样式
This commit is contained in:
@@ -98,11 +98,23 @@
|
||||
show: false,
|
||||
distanceToTop: -300,
|
||||
distanceToLeft: -300,
|
||||
windowHeight: '',
|
||||
val1: ''
|
||||
};
|
||||
},
|
||||
onLoad (options) {
|
||||
this.title = options.title
|
||||
uni.getSystemInfo({
|
||||
success: (info) => {
|
||||
this.windowHeight = info.windowHeight
|
||||
}
|
||||
})
|
||||
const query = uni.createSelectorQuery().in(this)
|
||||
query
|
||||
.select('.pop_point_wrap')
|
||||
.boundingClientRect(data => {
|
||||
console.log(data)
|
||||
}).exec()
|
||||
},
|
||||
created () {
|
||||
this.initArea()
|
||||
@@ -110,8 +122,8 @@
|
||||
methods: {
|
||||
selectPoint () {
|
||||
this.pointArr.map(el => {
|
||||
if (val1 === el.device_code || val1 === el.device_name) {
|
||||
|
||||
if (this.val1 === el.device_code || this.val1 === el.device_name) {
|
||||
console.log(this.val1)
|
||||
}
|
||||
})
|
||||
},
|
||||
@@ -138,6 +150,7 @@
|
||||
query
|
||||
.select(`#site_item_box_${index}`)
|
||||
.boundingClientRect(data => {
|
||||
console.log(data.top)
|
||||
if (data) {
|
||||
this.distanceToTop = data.top + (data.height / 2) - 9
|
||||
this.distanceToLeft = data.left
|
||||
|
||||
Reference in New Issue
Block a user