|
@@ -13,13 +13,16 @@
|
|
<!-- 网点信息及设备 -->
|
|
<!-- 网点信息及设备 -->
|
|
<view class="details" v-if="stationData">
|
|
<view class="details" v-if="stationData">
|
|
<view class="details-address">
|
|
<view class="details-address">
|
|
- <view>{{ stationData.name }}</view>
|
|
|
|
- <view>{{ stationData.provinceName }}{{ stationData.cityName }}{{ stationData.districtName }}{{ stationData.address }}</view>
|
|
|
|
- <view>
|
|
|
|
- 营业时间:
|
|
|
|
- <text v-for="(tItem, tInd) in stationData.deliveryTimeRuleItemList" :key="tInd">
|
|
|
|
- {{ tItem.openTime }} - {{ tItem.closeTime }}{{ tInd == stationData.deliveryTimeRuleItemList.length - 1 ? '' : ',' }}
|
|
|
|
- </text>
|
|
|
|
|
|
+ <image src="/static/md-big-pic.png" class="store-pic"></image>
|
|
|
|
+ <view class="store-info">
|
|
|
|
+ <view>{{ stationData.name }}</view>
|
|
|
|
+ <view>{{ stationData.provinceName }}{{ stationData.cityName }}{{ stationData.districtName }}{{ stationData.address }}</view>
|
|
|
|
+ <view>
|
|
|
|
+ 营业时间:
|
|
|
|
+ <text v-for="(tItem, tInd) in stationData.deliveryTimeRuleItemList" :key="tInd">
|
|
|
|
+ {{ tItem.openTime }} - {{ tItem.closeTime }}{{ tInd == stationData.deliveryTimeRuleItemList.length - 1 ? '' : ',' }}
|
|
|
|
+ </text>
|
|
|
|
+ </view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
<!-- 设备列表 -->
|
|
<!-- 设备列表 -->
|
|
@@ -29,16 +32,12 @@
|
|
<view class="details-dev-cons">
|
|
<view class="details-dev-cons">
|
|
<view class="dev-item" v-for="boxItem in item.deviceTypeBoxList">
|
|
<view class="dev-item" v-for="boxItem in item.deviceTypeBoxList">
|
|
<view class="item-pic-con">
|
|
<view class="item-pic-con">
|
|
- <!-- <image class="full-" src="/static/full-bg.png"></image> -->
|
|
|
|
- <text class="full-sign">
|
|
|
|
- 已满
|
|
|
|
- </text>
|
|
|
|
- <u-image height="80" width="80" :src="`/static/${boxItem.rubbishType}.png`"></u-image>
|
|
|
|
|
|
+ <text v-if="boxItem.flag==1" class="full-sign">已满</text>
|
|
|
|
+ <u-image height="80" width="80" :src="`/static/${boxItem.rubbishType}.png`" class="type-sign"></u-image>
|
|
</view>
|
|
</view>
|
|
<view class="dev-main">
|
|
<view class="dev-main">
|
|
<view>
|
|
<view>
|
|
{{ boxItem.rubbishTypeDictValue }}
|
|
{{ boxItem.rubbishTypeDictValue }}
|
|
- <u-tag v-if="boxItem.flag==1" text="已满" size="mini" mode="dark" type="info" />
|
|
|
|
</view>
|
|
</view>
|
|
<view class="rule-con">
|
|
<view class="rule-con">
|
|
{{ getRule(boxItem.rubbishType).rubbishWeight }}g/
|
|
{{ getRule(boxItem.rubbishType).rubbishWeight }}g/
|
|
@@ -73,34 +72,30 @@
|
|
onLoad(options) {
|
|
onLoad(options) {
|
|
this.stationId = options.id
|
|
this.stationId = options.id
|
|
this.stationNo = options.stationNo
|
|
this.stationNo = options.stationNo
|
|
- // 获取经纬度
|
|
|
|
- this.getLocation()
|
|
|
|
this.getStation() // 网点信息
|
|
this.getStation() // 网点信息
|
|
this.getDevice() // 设备信息
|
|
this.getDevice() // 设备信息
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- // 获取经纬度
|
|
|
|
- getLocation() {
|
|
|
|
- const _this = this;
|
|
|
|
- uni.getLocation({
|
|
|
|
- type: 'wgs84',
|
|
|
|
- success: function(res) {
|
|
|
|
- _this.lng = res.longitude
|
|
|
|
- _this.lat = res.latitude
|
|
|
|
- },
|
|
|
|
- fail: function(error) {
|
|
|
|
- console.log(error)
|
|
|
|
- uni.showToast({ icon: 'none', title: '定位失败' })
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- },
|
|
|
|
// 网点信息
|
|
// 网点信息
|
|
getStation(){
|
|
getStation(){
|
|
stationDetail({ id: this.stationId }).then(res => {
|
|
stationDetail({ id: this.stationId }).then(res => {
|
|
if(res.status == 200){
|
|
if(res.status == 200){
|
|
this.stationData = res.data
|
|
this.stationData = res.data
|
|
|
|
+ this.markers = []
|
|
|
|
+ this.markers.push({
|
|
|
|
+ latitude: res.data.lat,
|
|
|
|
+ longitude: res.data.lng,
|
|
|
|
+ width: 30,
|
|
|
|
+ height: 30,
|
|
|
|
+ iconPath: "/static/store.png"
|
|
|
|
+ })
|
|
|
|
+ this.lng = res.data.lng
|
|
|
|
+ this.lat = res.data.lat
|
|
}else{
|
|
}else{
|
|
this.stationData = null
|
|
this.stationData = null
|
|
|
|
+ this.markers = []
|
|
|
|
+ this.lng = ''
|
|
|
|
+ this.lat = ''
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
@@ -109,16 +104,6 @@
|
|
stationDevice({ stationNo: this.stationNo }).then(res => {
|
|
stationDevice({ stationNo: this.stationNo }).then(res => {
|
|
if(res.status == 200){
|
|
if(res.status == 200){
|
|
this.deviceData = res.data
|
|
this.deviceData = res.data
|
|
- this.markers = []
|
|
|
|
- for(let i=0; i<res.data.length; i++){
|
|
|
|
- this.markers.push({
|
|
|
|
- latitude: res.data[i].lat,
|
|
|
|
- longitude: res.data[i].lng,
|
|
|
|
- width: 30,
|
|
|
|
- height: 30,
|
|
|
|
- iconPath: "/static/store.png"
|
|
|
|
- })
|
|
|
|
- }
|
|
|
|
}else{
|
|
}else{
|
|
this.deviceData = []
|
|
this.deviceData = []
|
|
}
|
|
}
|
|
@@ -143,19 +128,27 @@
|
|
.details{
|
|
.details{
|
|
margin: 20upx;
|
|
margin: 20upx;
|
|
.details-address{
|
|
.details-address{
|
|
|
|
+ display: flex;
|
|
padding: 20upx;
|
|
padding: 20upx;
|
|
background: #FFFFFF;
|
|
background: #FFFFFF;
|
|
border-radius: 15upx;
|
|
border-radius: 15upx;
|
|
box-shadow: 0upx 3upx 6upx #eee;
|
|
box-shadow: 0upx 3upx 6upx #eee;
|
|
margin-bottom: 20upx;
|
|
margin-bottom: 20upx;
|
|
- >view{
|
|
|
|
- font-size: 24upx;
|
|
|
|
- padding: 5upx 0;
|
|
|
|
- color: #666;
|
|
|
|
- &:first-child{
|
|
|
|
- font-weight: bold;
|
|
|
|
- font-size: 30upx;
|
|
|
|
- color: #333;
|
|
|
|
|
|
+ .store-pic{
|
|
|
|
+ width: 130rpx;
|
|
|
|
+ height:130rpx;
|
|
|
|
+ margin-right: 20rpx;
|
|
|
|
+ }
|
|
|
|
+ .store-info{
|
|
|
|
+ >view{
|
|
|
|
+ font-size: 24upx;
|
|
|
|
+ padding: 5upx 0;
|
|
|
|
+ color: #666;
|
|
|
|
+ &:first-child{
|
|
|
|
+ font-weight: bold;
|
|
|
|
+ font-size: 30upx;
|
|
|
|
+ color: #333;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -174,7 +167,7 @@
|
|
}
|
|
}
|
|
}
|
|
}
|
|
.details-dev-cons{
|
|
.details-dev-cons{
|
|
- padding: 10upx;
|
|
|
|
|
|
+ padding: 10upx 0;
|
|
display: flex;
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
flex-wrap: wrap;
|
|
.dev-item{
|
|
.dev-item{
|
|
@@ -182,7 +175,7 @@
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|
|
> view{
|
|
> view{
|
|
- padding: 15upx 10upx;
|
|
|
|
|
|
+ padding: 25upx 10upx 15upx 0;
|
|
&:last-child{
|
|
&:last-child{
|
|
view{
|
|
view{
|
|
display: flex;
|
|
display: flex;
|
|
@@ -194,13 +187,21 @@
|
|
}
|
|
}
|
|
}
|
|
}
|
|
.item-pic-con{
|
|
.item-pic-con{
|
|
|
|
+ position: relative;
|
|
|
|
+ padding-left: 30rpx;
|
|
.full-sign{
|
|
.full-sign{
|
|
font-size: 24rpx;
|
|
font-size: 24rpx;
|
|
padding: 4rpx 10rpx 14rpx;
|
|
padding: 4rpx 10rpx 14rpx;
|
|
color: #fff;
|
|
color: #fff;
|
|
background: url('/static/full-bg.png') no-repeat;
|
|
background: url('/static/full-bg.png') no-repeat;
|
|
background-size: 100% 100%;
|
|
background-size: 100% 100%;
|
|
- transform: scale(1.5);
|
|
|
|
|
|
+ transform: scale(0.8);
|
|
|
|
+ position: absolute;
|
|
|
|
+ left: 0;
|
|
|
|
+ top: 0;
|
|
|
|
+ width: 68rpx;
|
|
|
|
+ height: 55rpx;
|
|
|
|
+ z-index: 9;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
.dev-main{
|
|
.dev-main{
|