first commit
This commit is contained in:
92
pages/steadyDetails/steadyDetails.css
Normal file
92
pages/steadyDetails/steadyDetails.css
Normal file
@@ -0,0 +1,92 @@
|
||||
page{
|
||||
background: #F0F0F0;
|
||||
}
|
||||
/* 主体开始 */
|
||||
.steadyDetails-block{
|
||||
background:#F9F9F9;
|
||||
}
|
||||
/* 时间开始 */
|
||||
.time-block{
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background:rgba(255,255,255,1);
|
||||
height: 94rpx;
|
||||
padding: 0 40rpx;
|
||||
}
|
||||
.time-location{
|
||||
font-size: 30rpx;
|
||||
color: #000000;
|
||||
}
|
||||
.time-text{
|
||||
color: #000000;
|
||||
font-size: 30rpx;
|
||||
}
|
||||
/* 时间结束 */
|
||||
/* 基础信息开始 */
|
||||
.index-block{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: flex-start;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
.index-title{
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
background: #FFFFFF;
|
||||
height: 102rpx;
|
||||
}
|
||||
.index-title-left{
|
||||
width: 6rpx;
|
||||
height: 34rpx;
|
||||
margin-left: 40rpx;
|
||||
}
|
||||
.index-title-right{
|
||||
height: 42rpx;
|
||||
font-size: 30rpx;
|
||||
color: #000000;
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
.index-content{
|
||||
margin-top: 20rpx;
|
||||
background: #FFFFFF;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
height: 92rpx;
|
||||
}
|
||||
.index-content-text{
|
||||
color: #303233;
|
||||
font-size: 30rpx;
|
||||
margin-left: 80rpx;
|
||||
height: 42rpx;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.index-content-pic{
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-right: 30rpx;
|
||||
}
|
||||
/* 基础信息结束 */
|
||||
/* 重试页面开始 */
|
||||
.error-block{
|
||||
height: 60%;
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
position: absolute;
|
||||
top: -10%;
|
||||
margin-top: 300rpx;
|
||||
}
|
||||
.retry_button{
|
||||
margin-top: 10rpx;
|
||||
border-radius: 10%;
|
||||
}
|
||||
/* 重试页面结束 */
|
||||
/* 主体结束 */
|
||||
111
pages/steadyDetails/steadyDetails.vue
Normal file
111
pages/steadyDetails/steadyDetails.vue
Normal file
@@ -0,0 +1,111 @@
|
||||
<template>
|
||||
<view class="">
|
||||
<back :pageNameFlag="pageNameFlag" :pageName='pageName'></back>
|
||||
<view class="steadyDetails-block" v-if="errorFlag==0">
|
||||
<!-- 时间模块 -->
|
||||
<view class="time-block">
|
||||
<view class="time-location">
|
||||
{{lineName}}
|
||||
</view>
|
||||
<view class="time-text">
|
||||
{{showTime}}
|
||||
</view>
|
||||
</view>
|
||||
<!-- 指标类型 -->
|
||||
<view class="index-block">
|
||||
<view class="index-title">
|
||||
<image src="/static/pic/rectangle.png" class="index-title-left"></image>
|
||||
<view class="index-title-right">
|
||||
指标类型
|
||||
</view>
|
||||
</view>
|
||||
<view class="index-content" @click="jumpToSteadyIndex(steadyTarget.typeCode,steadyTarget.typeName)" v-for="steadyTarget in steadyTargetList">
|
||||
<view class="index-content-text">
|
||||
{{steadyTarget.typeName}}
|
||||
</view>
|
||||
<image src="/static/pic/jump.png" class="index-content-pic"></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="error-block" v-else>
|
||||
<view class="error-text">
|
||||
网络出错请重试
|
||||
</view>
|
||||
<button class="retry_button" @click="retry">重试</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import back from '../../components/back.vue';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
pageNameFlag:1,
|
||||
pageName:'越限监测点详情',
|
||||
radioFlag:0,
|
||||
lineName:'',
|
||||
showTime:'',
|
||||
lineIndex:'',
|
||||
steadyTargetList:[],
|
||||
timeID:'',
|
||||
errorFlag:0
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
steadyTarget(){
|
||||
var that = this;
|
||||
uni.request({
|
||||
url: that.serverUrl+'/steadymsg/steadyTarget',
|
||||
method: 'POST',
|
||||
data: {
|
||||
lineIndex: that.lineIndex,
|
||||
timeID:that.timeID
|
||||
},
|
||||
header: {
|
||||
'content-type': 'application/x-www-form-urlencoded'
|
||||
},
|
||||
sslVerify: false,
|
||||
success: (res) => {
|
||||
uni.hideLoading();
|
||||
if (res.data.resultCode == '10000') {
|
||||
that.steadyTargetList = eval(res.data.data);
|
||||
} else {
|
||||
that.errorFlag = 1
|
||||
}
|
||||
},
|
||||
fail: (re) => {
|
||||
that.errorFlag = 1
|
||||
}
|
||||
});
|
||||
},
|
||||
jumpToSteadyIndex(typeCode,typeName){
|
||||
var that = this;
|
||||
uni.navigateTo({
|
||||
url:'../steadyIndex/steadyIndex?typeCode='+typeCode+"&lineIndex="+that.lineIndex+"&timeID="+that.timeID+"&typeName="+typeName
|
||||
})
|
||||
},
|
||||
retry(){
|
||||
this.errorFlag=0;
|
||||
this.steadyTarget();
|
||||
}
|
||||
},
|
||||
onLoad(e) {
|
||||
uni.showLoading({
|
||||
mask:true,
|
||||
});
|
||||
this.showTime=e.showTime;
|
||||
this.lineName = e.lineName;
|
||||
this.lineIndex=e.lineIndex;
|
||||
this.timeID=e.timeID;
|
||||
this.steadyTarget();
|
||||
},
|
||||
components:{
|
||||
back
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
@import url("steadyDetails.css");
|
||||
</style>
|
||||
Reference in New Issue
Block a user