乡村相册 考勤配置

This commit is contained in:
yanran200730
2022-05-23 15:23:10 +08:00
parent a9596faa9e
commit 75034e8c35
11 changed files with 860 additions and 149 deletions

View File

@@ -10,7 +10,7 @@
<div class="wrapper">
<div class="top">
<span @click="isShow = false">取消</span>
<span>确定</span>
<span @click="confirm">确定</span>
</div>
<div class="address-search">
<div class="address-search__wrapper">
@@ -30,7 +30,7 @@
<div class="address-btn">
<span>打卡有效范围</span>
<div class="right" @click="isShowScope = true">
<i>{{ distance[chooseIndex] }}</i>
<i>{{ distance[chooseIndex] }}</i>
<image src="./images/w-right.png" />
</div>
</div>
@@ -75,7 +75,7 @@
lib: null,
map: null,
latLng: null,
distance: ['100', '200', '300', '400', '500'],
distance: ['100', '200', '300', '400', '500'],
addressList: [],
page: 1,
marker: null,
@@ -124,12 +124,26 @@
})
},
confirm () {
const address = this.addressList[this.currIndex]
uni.$emit('address', {
address: address.address,
title: address.title,
lat: address.location.lat,
lng: address.location.lng,
distance: this.distance[this.chooseIndex]
})
uni.navigateBack({
delta: 1
})
},
chooseAddress (index) {
this.addMarker(this.addressList[index].location)
this.currIndex = index
},
addMarker (position) {
addMarker (position) {
if (this.marker) {
this.marker.setMap(null)
this.marker = null
@@ -181,7 +195,7 @@
}
})
}, 500)
},
},
getAddress () {
this.currIndex = 0
@@ -257,7 +271,7 @@
line-height: 1;
font-style: normal;
}
.wrapper {
height: 100%;
overflow: hidden;
@@ -383,4 +397,4 @@
height: 100%;
}
}
</style>
</style>