2024-05-11 10:57:53 +08:00
|
|
|
|
<template>
|
|
|
|
|
<view class="page">
|
|
|
|
|
<u-navbar title="上报异常" :border-bottom="false" :background="bgc" title-color='#000' title-size='36'
|
2024-05-22 18:04:44 +08:00
|
|
|
|
height='58'></u-navbar>
|
2024-05-11 10:57:53 +08:00
|
|
|
|
<view class="box">
|
|
|
|
|
<view class="list">
|
|
|
|
|
<view class="sbbh">
|
|
|
|
|
<view class="onr">
|
2024-05-16 18:02:44 +08:00
|
|
|
|
<image src="https://api.ccttiot.com/smartmeter/img/static/uTo0sMNT1u6dyEgpvraQ" mode=""></image> 设备编号:
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
|
|
|
|
<view class="inp">
|
2024-05-22 18:04:44 +08:00
|
|
|
|
<input type="text" placeholder="请输入编号" v-model="result" style="color: #999;padding-left: 30rpx;"/>
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
2024-05-22 18:04:44 +08:00
|
|
|
|
<view class="sm" @click="scanQRCode">
|
2024-05-16 18:02:44 +08:00
|
|
|
|
<image src="https://api.ccttiot.com/smartmeter/img/static/uwtCTFeo0LULdRKL6wHG" mode=""></image>
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="gzyy">
|
|
|
|
|
<view class="">
|
|
|
|
|
故障原因:
|
|
|
|
|
</view>
|
2024-05-16 18:02:44 +08:00
|
|
|
|
<view class="tcsb" @click="btntc" style="color: #999;padding-left: 30rpx;">
|
2024-05-11 10:57:53 +08:00
|
|
|
|
{{text}}
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
<view class="bz">
|
|
|
|
|
<view class="tit">
|
2024-05-16 18:02:44 +08:00
|
|
|
|
<image src="https://api.ccttiot.com/smartmeter/img/static/uTo0sMNT1u6dyEgpvraQ" mode=""></image>备 注:
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
|
|
|
|
<view class="wb">
|
2024-05-22 18:04:44 +08:00
|
|
|
|
<textarea name="" placeholder="请输入备注" v-model="cont" id="" cols="30" rows="10"></textarea>
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
|
|
|
|
</view>
|
|
|
|
|
</view>
|
2024-05-22 18:04:44 +08:00
|
|
|
|
|
|
|
|
|
<view class="yc" @click="btnyc">上报异常</view>
|
2024-05-11 10:57:53 +08:00
|
|
|
|
</view>
|
|
|
|
|
|
2024-05-22 18:04:44 +08:00
|
|
|
|
|
2024-05-11 10:57:53 +08:00
|
|
|
|
<u-select v-model="listshow" :list="list" @confirm="confirm"></u-select>
|
|
|
|
|
</view>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
export default {
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
listshow:false,
|
|
|
|
|
list: [{
|
|
|
|
|
value: '1',
|
|
|
|
|
label: '弹出失败'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
value: '2',
|
|
|
|
|
label: '卡槽损坏'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
value: '3',
|
|
|
|
|
label: '设备破坏'
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
value: '4',
|
|
|
|
|
label: '仓位异常'
|
|
|
|
|
}
|
|
|
|
|
],
|
2024-05-22 18:04:44 +08:00
|
|
|
|
text:'弹出失败',
|
|
|
|
|
result:'',
|
|
|
|
|
cont:'',
|
|
|
|
|
type:1
|
2024-05-11 10:57:53 +08:00
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
btntc(){
|
|
|
|
|
this.listshow = true
|
|
|
|
|
},
|
|
|
|
|
confirm(e){
|
|
|
|
|
this.text = e[0].label
|
2024-05-22 18:04:44 +08:00
|
|
|
|
this.type = e[0].value
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
scanQRCode() {
|
|
|
|
|
uni.scanCode({
|
|
|
|
|
onlyFromCamera: true,
|
|
|
|
|
scanType: ['qrCode'],
|
|
|
|
|
success: res => {
|
|
|
|
|
console.log('扫描结果:', res);
|
|
|
|
|
this.result = res.result
|
|
|
|
|
},
|
|
|
|
|
fail: err => {
|
|
|
|
|
console.error('扫描失败:', err);
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: '扫描失败',
|
|
|
|
|
icon: 'none'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
btnyc(){
|
|
|
|
|
let data = {
|
|
|
|
|
cabinetSn:this.result,
|
|
|
|
|
type:this.type,
|
|
|
|
|
remark:this.cont
|
|
|
|
|
}
|
|
|
|
|
this.$u.post('/agent/abnormal',data).then(res =>{
|
|
|
|
|
if(res.code == 200){
|
|
|
|
|
uni.showToast({
|
|
|
|
|
title: '上报成功',
|
|
|
|
|
icon: 'none',
|
|
|
|
|
duration: 1000
|
|
|
|
|
})
|
|
|
|
|
setTimeout(()=>{
|
|
|
|
|
uni.navigateBack()
|
|
|
|
|
},1000)
|
|
|
|
|
}
|
|
|
|
|
})
|
2024-05-11 10:57:53 +08:00
|
|
|
|
}
|
2024-05-22 18:04:44 +08:00
|
|
|
|
|
2024-05-11 10:57:53 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss">
|
2024-05-22 18:04:44 +08:00
|
|
|
|
/deep/ .u-title,
|
|
|
|
|
/deep/ .uicon-nav-back{
|
|
|
|
|
padding-bottom: 40rpx;
|
|
|
|
|
}
|
2024-05-11 10:57:53 +08:00
|
|
|
|
page {
|
|
|
|
|
background: linear-gradient(180deg, #25CE88 0%, rgba(255, 255, 255, 0) 100%);
|
|
|
|
|
}
|
2024-05-22 18:04:44 +08:00
|
|
|
|
.yc{
|
|
|
|
|
width: 660rpx;
|
|
|
|
|
height: 108rpx;
|
|
|
|
|
margin: auto;
|
|
|
|
|
background: #1DBE7B;
|
|
|
|
|
border-radius: 20rpx;
|
|
|
|
|
color: #FFFFFF;
|
|
|
|
|
line-height: 108rpx;
|
|
|
|
|
text-align: center;
|
|
|
|
|
margin-top: 150rpx;
|
|
|
|
|
font-size: 36rpx;
|
|
|
|
|
}
|
2024-05-11 10:57:53 +08:00
|
|
|
|
|
|
|
|
|
.page {
|
|
|
|
|
width: 750rpx;
|
|
|
|
|
position: fixed;
|
|
|
|
|
top: 0;
|
|
|
|
|
left: 0;
|
|
|
|
|
|
|
|
|
|
.box {
|
|
|
|
|
width: 750rpx;
|
|
|
|
|
height: 1440rpx;
|
|
|
|
|
background: #F4F5F7;
|
|
|
|
|
padding-top: 30rpx;
|
|
|
|
|
|
|
|
|
|
.list {
|
|
|
|
|
width: 100%;
|
|
|
|
|
width: 680rpx;
|
|
|
|
|
height: 388rpx;
|
|
|
|
|
background: #FFFFFF;
|
|
|
|
|
border-radius: 24rpx 24rpx 24rpx 24rpx;
|
|
|
|
|
margin: auto;
|
|
|
|
|
padding: 42rpx 44rpx;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
.sbbh {
|
|
|
|
|
width: 100%;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
font-size: 28rpx;
|
|
|
|
|
color: #3D3D3D;
|
|
|
|
|
.onr {
|
|
|
|
|
margin-top: 10rpx;
|
|
|
|
|
image {
|
|
|
|
|
width: 20rpx;
|
|
|
|
|
height: 20rpx;
|
|
|
|
|
display: inline-block;
|
|
|
|
|
margin-right: 10rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.inp {
|
|
|
|
|
input {
|
|
|
|
|
width: 340rpx;
|
|
|
|
|
height: 50rpx;
|
|
|
|
|
border-radius: 12rpx 12rpx 12rpx 12rpx;
|
|
|
|
|
border: 2rpx solid #C9CDD4;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.sm{
|
|
|
|
|
image{
|
|
|
|
|
width: 52rpx;
|
|
|
|
|
height: 52rpx;
|
2024-05-16 18:02:44 +08:00
|
|
|
|
// background-color: #ccc;
|
2024-05-11 10:57:53 +08:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.gzyy{
|
|
|
|
|
margin-top: 20rpx;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
font-size: 28rpx;
|
|
|
|
|
color: #3D3D3D;
|
|
|
|
|
padding-left: 24rpx;
|
|
|
|
|
.tcsb{
|
2024-05-16 18:02:44 +08:00
|
|
|
|
width: 430rpx;
|
2024-05-11 10:57:53 +08:00
|
|
|
|
height: 50rpx;
|
|
|
|
|
line-height: 50rpx;
|
|
|
|
|
border-radius: 12rpx 12rpx 12rpx 12rpx;
|
|
|
|
|
border: 2rpx solid #C9CDD4;
|
|
|
|
|
font-size: 28rpx;
|
|
|
|
|
color: #3D3D3D;
|
|
|
|
|
padding-left: 30rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.bz{
|
|
|
|
|
margin-top: 20rpx;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
font-size: 28rpx;
|
|
|
|
|
color: #3D3D3D;
|
|
|
|
|
.tit{
|
|
|
|
|
image{
|
|
|
|
|
width: 20rpx;
|
|
|
|
|
height: 20rpx;
|
|
|
|
|
display: inline-block;
|
|
|
|
|
margin-right: 10rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
.wb{
|
2024-05-16 18:02:44 +08:00
|
|
|
|
width: 430rpx;
|
2024-05-11 10:57:53 +08:00
|
|
|
|
height: 150rpx;
|
|
|
|
|
border-radius: 12rpx 12rpx 12rpx 12rpx;
|
|
|
|
|
border: 2rpx solid #C9CDD4;
|
|
|
|
|
padding: 10rpx 30rpx;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|