This commit is contained in:
parent
0c5d6bb6bc
commit
1694f91e7a
4
App.vue
4
App.vue
|
|
@ -1,8 +1,11 @@
|
||||||
<script>
|
<script>
|
||||||
import soket from "/utils/soket.js"
|
import soket from "/utils/soket.js"
|
||||||
|
import upapp from "/utils/upapp.js"
|
||||||
export default {
|
export default {
|
||||||
onLaunch: function() {
|
onLaunch: function() {
|
||||||
// 生成设备唯一码
|
// 生成设备唯一码
|
||||||
|
// upapp()
|
||||||
|
|
||||||
let _Android =uni.getStorageSync('cid') || new Date().getTime()
|
let _Android =uni.getStorageSync('cid') || new Date().getTime()
|
||||||
// #ifdef APP
|
// #ifdef APP
|
||||||
// 获取设备码
|
// 获取设备码
|
||||||
|
|
@ -33,6 +36,7 @@
|
||||||
// #endif
|
// #endif
|
||||||
},
|
},
|
||||||
onShow: function() {
|
onShow: function() {
|
||||||
|
|
||||||
console.log('App Show')
|
console.log('App Show')
|
||||||
},
|
},
|
||||||
onHide: function() {
|
onHide: function() {
|
||||||
|
|
|
||||||
|
|
@ -37,16 +37,11 @@
|
||||||
})
|
})
|
||||||
},500)
|
},500)
|
||||||
}
|
}
|
||||||
|
uni.$emit('back',Props.modelValue)
|
||||||
})
|
})
|
||||||
onBackPress(() => {
|
uni.$on('close',()=>{
|
||||||
if (Props.modelValue) {
|
|
||||||
Props.modelValue=false;
|
Props.modelValue=false;
|
||||||
|
|
||||||
Emits("update:modelValue",false)
|
Emits("update:modelValue",false)
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
15
pages.json
15
pages.json
|
|
@ -17,6 +17,21 @@
|
||||||
"style": {
|
"style": {
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "pages/upapp",
|
||||||
|
"style": {
|
||||||
|
"app-plus": {
|
||||||
|
"animationDuration": 200,
|
||||||
|
"animationType": "fade-in",
|
||||||
|
"background": "transparent",
|
||||||
|
"backgroundColorTop": "transparent",
|
||||||
|
"popGesture": "none",
|
||||||
|
"scrollIndicator": false,
|
||||||
|
"titleNView": false
|
||||||
|
},
|
||||||
|
"disableScroll": true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -102,6 +102,7 @@
|
||||||
import passingTheCar from "./pages/passingTheCar.vue"
|
import passingTheCar from "./pages/passingTheCar.vue"
|
||||||
import warningInformation from "./pages/warningInformation.vue"
|
import warningInformation from "./pages/warningInformation.vue"
|
||||||
import qjcamera from "./pages/camera.vue"
|
import qjcamera from "./pages/camera.vue"
|
||||||
|
|
||||||
import {
|
import {
|
||||||
nextTick,
|
nextTick,
|
||||||
ref,
|
ref,
|
||||||
|
|
@ -113,8 +114,11 @@
|
||||||
} from "/appapi/index.js"
|
} from "/appapi/index.js"
|
||||||
|
|
||||||
import {
|
import {
|
||||||
|
onBackPress,
|
||||||
onShow
|
onShow
|
||||||
} from "@dcloudio/uni-app"
|
} from "@dcloudio/uni-app"
|
||||||
|
|
||||||
|
// 页面管理
|
||||||
const refhistory = ref()
|
const refhistory = ref()
|
||||||
const refsetUp = ref()
|
const refsetUp = ref()
|
||||||
const refcamera = ref()
|
const refcamera = ref()
|
||||||
|
|
@ -124,7 +128,9 @@
|
||||||
const selectindex = ref("")
|
const selectindex = ref("")
|
||||||
const showout = ref(false);
|
const showout = ref(false);
|
||||||
const showsignOut = ref(false);
|
const showsignOut = ref(false);
|
||||||
|
// 结束
|
||||||
|
|
||||||
|
// 设备
|
||||||
const allDevices = ref([])
|
const allDevices = ref([])
|
||||||
const Devicesid = ref('')
|
const Devicesid = ref('')
|
||||||
// 子页面状态管理
|
// 子页面状态管理
|
||||||
|
|
@ -133,6 +139,17 @@
|
||||||
settab(0)
|
settab(0)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// 处理子页面弹窗 和详情页面打开 返回关闭详情页面不关闭应用
|
||||||
|
let _isback=false;
|
||||||
|
uni.$on('back',(e)=>{
|
||||||
|
_isback=e;
|
||||||
|
})
|
||||||
|
onBackPress(()=>{
|
||||||
|
uni.$emit('close')
|
||||||
|
return _isback
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
uni.$on('LOGOUT', () => {
|
uni.$on('LOGOUT', () => {
|
||||||
showout.value = true;
|
showout.value = true;
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -10,19 +10,19 @@
|
||||||
<view class="rbox">
|
<view class="rbox">
|
||||||
<block v-if="type==1">
|
<block v-if="type==1">
|
||||||
<view class="fn" v-if="!yesok" @click="showupimg=true">暂扣</view>
|
<view class="fn" v-if="!yesok" @click="showupimg=true">暂扣</view>
|
||||||
<view class="fn red " :class="{aft:tips}" v-if="yesok" @click="showupimg=true">
|
<view class="fn red " :class="{aft:tips}" v-if="yesok" @click="setwithhold">
|
||||||
确认暂扣
|
确认暂扣
|
||||||
<view class="tc" v-if="tips">
|
<view class="tc" v-if="tips">
|
||||||
是否确定暂时扣行该车辆,请点击此按钮。
|
<image src="/static/dp.png"></image> 是否确定暂时扣行该车辆,请点击此按钮。
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
<block v-if="type==2">
|
<block v-if="type==2">
|
||||||
<view class="fn fx" v-if="!yesok" @click="showupimg=true">放行</view>
|
<view class="fn fx" v-if="!yesok" @click="showupimg=true">放行</view>
|
||||||
<view class="fn yfx" :class="{aft:tips}" v-if="yesok" @click="showupimg=true">
|
<view class="fn yfx" :class="{aft:tips}" v-if="yesok" @click="setrelease">
|
||||||
确认放行
|
确认放行
|
||||||
<view class="tc" v-if="tips">
|
<view class="tc" v-if="tips">
|
||||||
是否确定放行该车辆,请点击此按钮。
|
<image src="/static/dp.png"></image> 是否确定放行该车辆,请点击此按钮。
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
|
|
@ -31,7 +31,7 @@
|
||||||
<view class="detailspage" @click="tips=false">
|
<view class="detailspage" @click="tips=false">
|
||||||
<view class="time">
|
<view class="time">
|
||||||
<view class="l">超速信息</view>
|
<view class="l">超速信息</view>
|
||||||
<view class="r">放行时间:2025-08-13 18:0</view>
|
<view class="r" v-if="info.releaseInfo?.releaseTime">放行时间:{{info.releaseInfo?.releaseTime}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="form">
|
<view class="form">
|
||||||
<view class="item">
|
<view class="item">
|
||||||
|
|
@ -39,55 +39,55 @@
|
||||||
车牌号码
|
车牌号码
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
<view class="number">晋MP6400</view>
|
<view class="number">{{info.basicInfo?.vehicleNumber}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="title">超速等级</view>
|
<view class="title">超速等级</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
超速10%-20%
|
{{info.overspeedInfo?.overspeedLevelInformation}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
设备001位置
|
设备{{info.intervalInfo?.startId}}位置
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
中国内蒙古自治区锡林郭勒盟西乌珠穆沁旗巴
|
{{info.intervalInfo?.startDeviceJson?.position}}
|
||||||
<view>108.000000 / 109.293</view>
|
<view>{{info.intervalInfo?.startDeviceJson?.longitude}} / {{info.intervalInfo?.startDeviceJson?.latitude}}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
设备002位置
|
设备{{info.intervalInfo?.endId}}位置
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
中国内蒙古自治区锡林郭勒盟西乌珠穆沁旗巴
|
{{info.intervalInfo?.endDeviceJson?.position}}
|
||||||
<view>108.000000 / 109.293</view>
|
<view>{{info.intervalInfo?.endDeviceJson?.longitude}} / {{info.intervalInfo?.endDeviceJson?.latitude}}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
通过设备001时间
|
通过设备{{info.intervalInfo?.startId}}时间
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
2025-08-13 12:00:00
|
{{info.intervalInfo?.startDeviceTime}}
|
||||||
</view>
|
</view>
|
||||||
<view class="title">区间距离</view>
|
<view class="title">区间距离</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
438公里
|
{{info.intervalInfo?.zoneDistanceText}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
通过设备001时间
|
通过设备{{info.intervalInfo?.endId}}时间
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
2025-08-13 12:00:00
|
{{info.intervalInfo?.endDeviceTime}}
|
||||||
</view>
|
</view>
|
||||||
<view class="title">区间限速</view>
|
<view class="title">区间限速</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
80km/h
|
{{info.intervalInfo?.speedText}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
|
|
@ -95,11 +95,11 @@
|
||||||
最短行驶时长
|
最短行驶时长
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
4小时02分钟
|
{{info.intervalInfo?.passingTimeText}}
|
||||||
</view>
|
</view>
|
||||||
<view class="title">实际行驶时长</view>
|
<view class="title">实际行驶时长</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
3小时48分钟
|
{{info.overspeedInfo?.exerciseDurationText}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
|
|
@ -107,31 +107,31 @@
|
||||||
平均车速
|
平均车速
|
||||||
</view>
|
</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
100km/h
|
{{info.overspeedInfo?.averageSpeedText}}
|
||||||
</view>
|
</view>
|
||||||
<view class="title">待休息时长</view>
|
<view class="title">待休息时长</view>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
15分钟
|
{{info.overspeedInfo?.restDurationText}}
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="imgs">
|
<view class="imgs">
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
设备001 抓取照片
|
设备{{info.intervalInfo?.startId}} 抓取照片
|
||||||
</view>
|
</view>
|
||||||
<view class="img">
|
<view class="img">
|
||||||
<image src="/static/tjbj.png"></image>
|
<image @click="openimg(info.imageInfo?.startDeviceImage)" :src="info.imageInfo?.startDeviceImage"></image>
|
||||||
<view class="time">2025-08-13 12:00:00</view>
|
<view class="time">{{info.intervalInfo?.startDeviceTime}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
设备001 抓取照片
|
设备{{info.intervalInfo?.endId}} 抓取照片
|
||||||
</view>
|
</view>
|
||||||
<view class="img">
|
<view class="img">
|
||||||
<image src="/static/tjbj.png"></image>
|
<image @click="openimg(info.imageInfo?.endDeviceImage)" :src="info.imageInfo?.endDeviceImage"></image>
|
||||||
<view class="time">2025-08-13 12:00:00</view>
|
<view class="time">{{info.intervalInfo?.endDeviceTime}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -142,18 +142,18 @@
|
||||||
<view class="tbody">
|
<view class="tbody">
|
||||||
<view class="ul">
|
<view class="ul">
|
||||||
<view class="title">暂扣时间</view>
|
<view class="title">暂扣时间</view>
|
||||||
<view class="txt">2025-08-13 12:00:00</view>
|
<view class="txt">{{info.detainTime?.detainTime || '/'}}</view>
|
||||||
<view class="title">放行时间</view>
|
<view class="title">放行时间</view>
|
||||||
<view class="txt">/</view>
|
<view class="txt">{{info.releaseInfo?.releaseTime || '/'}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="ul">
|
<view class="ul">
|
||||||
<view class="title">暂扣照片</view>
|
<view class="title">暂扣照片</view>
|
||||||
<view class="txt img">
|
<view class="txt img">
|
||||||
<image src="/static/tjbj.png"></image>
|
<image @click="openimg(info.imageInfo?.detainStartImage)" v-if="info.imageInfo?.detainStartImage" :src="info.imageInfo?.detainStartImage"></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="title">放行照片</view>
|
<view class="title">放行照片</view>
|
||||||
<view class="txt img">
|
<view class="txt img">
|
||||||
|
<image @click="openimg(info.imageInfo?.releaseImage)" v-if="info.imageInfo?.releaseImage" :src="info.imageInfo?.releaseImage"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -170,7 +170,7 @@
|
||||||
<image src="/static/k.png" v-if="type==1" mode=""></image>
|
<image src="/static/k.png" v-if="type==1" mode=""></image>
|
||||||
<view class="txt">
|
<view class="txt">
|
||||||
<view class="typename">{{type==1?"车辆暂扣":'车辆放行'}}</view>
|
<view class="typename">{{type==1?"车辆暂扣":'车辆放行'}}</view>
|
||||||
<view class="time" v-if="type==2">放行时间:2025-08-13 15:0</view>
|
<view class="time" v-if="type==2">放行时间:{{time}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="upimg" @click="upimg">
|
<view class="upimg" @click="upimg">
|
||||||
|
|
@ -191,15 +191,41 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import evn from "/evn.js";
|
import evn from "/evn.js";
|
||||||
import {
|
import {
|
||||||
ref
|
ref,
|
||||||
|
watch
|
||||||
} from "vue";
|
} from "vue";
|
||||||
|
import {
|
||||||
|
getdetails,
|
||||||
|
detainVehicle,
|
||||||
|
releaseVehicle
|
||||||
|
} from "/appapi/index.js"
|
||||||
|
|
||||||
const type = ref("");
|
const type = ref("");
|
||||||
const showupimg = ref(false)
|
const showupimg = ref(false)
|
||||||
const yesok = ref(false);
|
const yesok = ref(false);
|
||||||
const tips = ref(false)
|
const tips = ref(false)
|
||||||
const Emits = defineEmits(["opneinfo"])
|
const Emits = defineEmits(["opneinfo","refresh"])
|
||||||
const imgs = ref("")
|
const imgs = ref("")
|
||||||
|
const encoding=ref("")
|
||||||
|
const info=ref({})
|
||||||
|
|
||||||
|
const time=ref("")
|
||||||
|
|
||||||
|
watch(()=>showupimg.value,()=>{
|
||||||
|
formatTime()
|
||||||
|
})
|
||||||
|
function formatTime() {
|
||||||
|
function formatDateTime(date) {
|
||||||
|
let year = date.getFullYear();
|
||||||
|
let month = ("0" + (date.getMonth() + 1)).slice(-2); // 月份是从0开始的,所以要加1,并且需要补零
|
||||||
|
let day = ("0" + date.getDate()).slice(-2); // 日期补零
|
||||||
|
let hours = ("0" + date.getHours()).slice(-2); // 小时补零
|
||||||
|
let minutes = ("0" + date.getMinutes()).slice(-2); // 分钟补零
|
||||||
|
let seconds = ("0" + date.getSeconds()).slice(-2); // 秒补零
|
||||||
|
return `${year}年${month}月${day}日 ${hours}:${minutes}`;
|
||||||
|
}
|
||||||
|
time.value = formatDateTime(new Date());
|
||||||
|
}
|
||||||
function load() {
|
function load() {
|
||||||
console.log('预警信息load')
|
console.log('预警信息load')
|
||||||
}
|
}
|
||||||
|
|
@ -213,12 +239,16 @@
|
||||||
showupimg.value = false;
|
showupimg.value = false;
|
||||||
yesok.value = false;
|
yesok.value = false;
|
||||||
tips.value = false;
|
tips.value = false;
|
||||||
|
imgs.value=""
|
||||||
}
|
}
|
||||||
|
|
||||||
function show(id, indextype) {
|
function show(id, indextype) {
|
||||||
reset()
|
reset()
|
||||||
|
encoding.value=id;
|
||||||
|
if(indextype){
|
||||||
type.value = indextype;
|
type.value = indextype;
|
||||||
|
}
|
||||||
|
getinfo()
|
||||||
}
|
}
|
||||||
|
|
||||||
function yesupimg() {
|
function yesupimg() {
|
||||||
|
|
@ -229,10 +259,19 @@
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
// 弹窗打开详情通知
|
||||||
Emits("opneinfo")
|
Emits("opneinfo")
|
||||||
showupimg.value = false;
|
showupimg.value = false;
|
||||||
yesok.value = true;
|
yesok.value = true;
|
||||||
tips.value = true;
|
tips.value = true;
|
||||||
|
if(type.value==1){
|
||||||
|
// 设置暂扣照片
|
||||||
|
info.value.imageInfo.detainStartImage=imgs.value
|
||||||
|
}
|
||||||
|
if(type.value==2){
|
||||||
|
//设置放行照片
|
||||||
|
info.value.imageInfo.releaseImage=imgs.value
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function back() {
|
function back() {
|
||||||
|
|
@ -258,10 +297,57 @@
|
||||||
|
|
||||||
function opneshowupimg(id, indextype) {
|
function opneshowupimg(id, indextype) {
|
||||||
reset()
|
reset()
|
||||||
|
encoding.value=id;
|
||||||
type.value = indextype
|
type.value = indextype
|
||||||
showupimg.value = true;
|
showupimg.value = true;
|
||||||
|
getinfo()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function getinfo(){
|
||||||
|
getdetails({encoding:encoding.value}).then(res=>{
|
||||||
|
info.value=res.data;
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 确认暂扣
|
||||||
|
function setwithhold(){
|
||||||
|
detainVehicle({encoding:encoding.value,releaseImageUrl:imgs.value}).then(r=>{
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '已暂扣',
|
||||||
|
showCancel:false,
|
||||||
|
success: function (res) {
|
||||||
|
reset()
|
||||||
|
// 刷新列表通知
|
||||||
|
Emits("refresh")
|
||||||
|
uni.navigateBack()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
}
|
||||||
|
// 确认放行
|
||||||
|
function setrelease(){
|
||||||
|
releaseVehicle({encoding:encoding.value,releaseImageUrl:imgs.value}).then(r=>{
|
||||||
|
uni.showModal({
|
||||||
|
title: '提示',
|
||||||
|
content: '已放行',
|
||||||
|
showCancel:false,
|
||||||
|
success: function (res) {
|
||||||
|
reset()
|
||||||
|
// 刷新列表通知
|
||||||
|
Emits("refresh")
|
||||||
|
uni.navigateBack()
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 图片预览
|
||||||
|
function openimg(img){
|
||||||
|
uni.previewImage({
|
||||||
|
urls: [img],
|
||||||
|
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
defineExpose({
|
defineExpose({
|
||||||
load,
|
load,
|
||||||
|
|
@ -412,6 +498,13 @@
|
||||||
.tc {
|
.tc {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
image{
|
||||||
|
width: 12rpx;
|
||||||
|
height: 15rpx;
|
||||||
|
margin-right: 3rpx;
|
||||||
|
}
|
||||||
right: 0px;
|
right: 0px;
|
||||||
font-size: 11rpx;
|
font-size: 11rpx;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
|
|
@ -488,7 +581,7 @@
|
||||||
|
|
||||||
.item {
|
.item {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
// align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
border-bottom: 1px solid #979797;
|
border-bottom: 1px solid #979797;
|
||||||
|
|
||||||
|
|
@ -505,12 +598,15 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
|
|
||||||
background: #F3F5F8;
|
background: #F3F5F8;
|
||||||
font-size: 9rpx;
|
font-size: 9rpx;
|
||||||
padding: 7rpx;
|
padding: 7rpx;
|
||||||
width: 90rpx;
|
width: 100rpx;
|
||||||
text-align: right;
|
text-align: right;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content:flex-end ;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.txt {
|
.txt {
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@
|
||||||
<view class="reset" @click="emptydata">重置</view>
|
<view class="reset" @click="emptydata">重置</view>
|
||||||
</view>
|
</view>
|
||||||
<scroll-view :scroll-y="true" class="scroll-view" @scrolltolower='bottomingOut'>
|
<scroll-view :scroll-y="true" class="scroll-view" @scrolltolower='bottomingOut'>
|
||||||
<view v-for="item in list" class="item">
|
<view v-for="item in list" class="item" @click="openinfo(item.encoding)">
|
||||||
<view class="left">
|
<view class="left">
|
||||||
<view class="t">
|
<view class="t">
|
||||||
<!-- <image src="/static/err.png"></image> -->
|
<!-- <image src="/static/err.png"></image> -->
|
||||||
|
|
@ -41,9 +41,13 @@
|
||||||
</view>
|
</view>
|
||||||
<nynull txt="暂无历史数据" v-if="!list.length"></nynull>
|
<nynull txt="暂无历史数据" v-if="!list.length"></nynull>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
|
<pageanimation v-model="showdetails" @close="refdetails.hide()" >
|
||||||
|
<pagedetails ref="refdetails" />
|
||||||
|
</pageanimation>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
|
import pagedetails from "./details.vue";
|
||||||
import {
|
import {
|
||||||
ref
|
ref
|
||||||
} from 'vue';
|
} from 'vue';
|
||||||
|
|
@ -54,18 +58,28 @@
|
||||||
const queryDate=ref("")
|
const queryDate=ref("")
|
||||||
const Selectiondate=ref()
|
const Selectiondate=ref()
|
||||||
const vehicleNumber=ref("")
|
const vehicleNumber=ref("")
|
||||||
|
const refdetails=ref()
|
||||||
|
const showdetails=ref(false)
|
||||||
const list=ref([])
|
const list=ref([])
|
||||||
// 分页相关
|
// 分页相关
|
||||||
const pageSize=ref(40);
|
const pageSize=ref(40);
|
||||||
const pageNum=ref(1);
|
const pageNum=ref(1);
|
||||||
const hasNextPage=ref(true)
|
const hasNextPage=ref(true)
|
||||||
|
|
||||||
|
// 打开详情
|
||||||
|
function openinfo(id){
|
||||||
|
refdetails.value.show(id)
|
||||||
|
showdetails.value=true;
|
||||||
|
}
|
||||||
|
|
||||||
function load() {
|
function load() {
|
||||||
console.log('预警信息load')
|
console.log('预警信息load')
|
||||||
}
|
}
|
||||||
|
|
||||||
function hide() {
|
function hide() {
|
||||||
console.log('预警信息hide')
|
showdetails.value=false;
|
||||||
|
refdetails.value.hide()
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function show() {
|
function show() {
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<view class="title">预警设置</view>
|
<view class="title">预警设置</view>
|
||||||
<scroll-view :scroll-y="true" class="box">
|
<scroll-view :scroll-y="true" class="box" :scroll-top="scroll">
|
||||||
<view class="li">
|
<view class="li">
|
||||||
<view class="name">设备{{pointPosition1.id}}</view>
|
<view class="name">设备{{pointPosition1.id}}</view>
|
||||||
<view class="text">
|
<view class="text">
|
||||||
|
|
@ -465,6 +465,7 @@
|
||||||
address: "北京市东城区东华门街道中华路甲10号"
|
address: "北京市东城区东华门街道中华路甲10号"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
scroll:0,
|
||||||
pointPosition2: {
|
pointPosition2: {
|
||||||
point: "",
|
point: "",
|
||||||
id: '008',
|
id: '008',
|
||||||
|
|
@ -484,7 +485,9 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
emptydata(){
|
emptydata(){
|
||||||
this.pointPosition1.point="";
|
this.pointPosition1.point="";
|
||||||
this.pointPosition2.point="";
|
this.pointPosition2.point="";
|
||||||
|
|
@ -568,10 +571,13 @@
|
||||||
},
|
},
|
||||||
hide() {
|
hide() {
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
show() {
|
show() {
|
||||||
let _this = this;
|
let _this = this;
|
||||||
|
this.scroll=10;
|
||||||
getequipment().then(r => {
|
getequipment().then(r => {
|
||||||
|
this.scroll=0;
|
||||||
this.pointPosition1 = {
|
this.pointPosition1 = {
|
||||||
id: r.data.allDevices[0].encoding,
|
id: r.data.allDevices[0].encoding,
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<scroll-view :scroll-y="true" class="scroll-view">
|
<scroll-view :scroll-y="true" class="scroll-view">
|
||||||
<view v-for="item in info.data" class="item" @click.stop="listwithhold(item.id,status==2?1:2)">
|
<view v-for="item in info.data" class="item" @click.stop="listwithhold(item.encoding,status==2?1:2)">
|
||||||
<view class="left">
|
<view class="left">
|
||||||
<view class="t">
|
<view class="t">
|
||||||
<image v-if="status==2" src="/static/err.png"></image>
|
<image v-if="status==2" src="/static/err.png"></image>
|
||||||
|
|
@ -85,13 +85,13 @@
|
||||||
<view>{{item.restDuration}}</view>
|
<view>{{item.restDuration}}</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="right red" v-if="status==2" @click.stop="withhold(item.id,1)">暂扣</view>
|
<view class="right red" v-if="status==2" @click.stop="withhold(item.encoding,1)">暂扣</view>
|
||||||
<view class="right green" v-if="status==3" @click.stop="withhold(item.id,2)">放行</view>
|
<view class="right green" v-if="status==3" @click.stop="withhold(item.encoding,2)">放行</view>
|
||||||
</view>
|
</view>
|
||||||
<nynull v-if="!info.data?.length"></nynull>
|
<nynull v-if="!info.data?.length"></nynull>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
<pageanimation v-model="showdetails" @close="refdetails.hide()">
|
<pageanimation v-model="showdetails" @close="refdetails.hide()" >
|
||||||
<pagedetails ref="refdetails" @opneinfo='opneshowdetails' />
|
<pagedetails ref="refdetails" @opneinfo='opneshowdetails' @refresh="getinfo" />
|
||||||
</pageanimation>
|
</pageanimation>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<template>
|
<template>
|
||||||
<view class="page">
|
<view class="page">
|
||||||
<image class="bj" src="/static/signIn/signInbj.png" mode="aspectFill"></image>
|
<image class="left" src="/static/signIn/signIn.png" mode="aspectFit"></image>
|
||||||
<view class="box">
|
<view class="box">
|
||||||
<image class="title" src="/static/signIn/title.png" mode="aspectFit"></image>
|
<image class="title" src="/static/signIn/title.png" mode="aspectFit"></image>
|
||||||
<view class="desc">欢迎登录!很高兴再次见到你</view>
|
<view class="desc">欢迎登录!很高兴再次见到你</view>
|
||||||
|
|
@ -94,20 +94,18 @@
|
||||||
.page {
|
.page {
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
position: relative;
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
.bj {
|
justify-content: space-between;
|
||||||
position: absolute;
|
padding: 0rpx 118rpx 0 32rpx;
|
||||||
width: 100%;
|
background: #f1f5fd;
|
||||||
height: 100%;
|
.left {
|
||||||
|
width: 410rpx;
|
||||||
|
height: 310rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.box {
|
.box {
|
||||||
position: fixed;
|
|
||||||
|
|
||||||
top: 50%;
|
|
||||||
right: 110rpx;
|
|
||||||
transform: translate(0%, -50%);
|
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
height: 40rpx;
|
height: 40rpx;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue