| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158 |
- <template>
- <view class="">
- <view class="data" v-for="(item, index) in list" :key="index">
- <view class="top">
- <view class="left">
- <view class="title ">
- <text class="text-bold">IEMI:</text>
- <text>{{item.imei}}</text>
- <text @click="copy(item.imei)" style="text-decoration: underline;padding-left: 10rpx;color: #007AFF;">复制</text>
- </view>
- </view>
- <view class="right">
- <view v-if="item.defenseStatus==1" class="radius sm cu-btn line-green">
- 已上线
- </view>
- <view v-if="item.defenseStatus==2" class="radius sm cu-btn line-red">
- 已下线
- </view>
- </view>
- </view>
- <view class="item padding-left-20">
- <view class="content flex">
- <u-icon size="36" name="http://139.9.103.171:1888/miniofile/xlyq/xiaofangshuang.png"></u-icon>
- <text class="text-bold padding-left-10">设备名称:</text>
- <text>{{item.deviceName}}</text>
- </view>
- <view class="content flex">
- <view class="flex">
- <u-icon size="36" name="http://139.9.103.171:1888/miniofile/xlyq/dianchi.png"></u-icon>
- <text class="text-bold padding-left-10">电池电量:</text>
- </view>
- <view class="striped active cu-progress round margin-top-sm sm" style="width: 60%;">
- <view style="width: 68%;background-color: #16c60c;color: #FFFFFF;">
- {{item.battery?item.battery:0}}%
- </view>
- </view>
- </view>
- <view class="content flex">
- <view class="flex">
- <u-icon size="36" name="http://139.9.103.171:1888/miniofile/xlyq/wifi.png"></u-icon>
- <text class="text-bold padding-left-10">信号强弱:</text>
- </view>
- <view class="striped active cu-progress round margin-top-sm sm" style="width: 60%;">
- <view style="width: 58%;background-color: #fc5f44;color: #FFFFFF;">
- {{item.signalIntensity?item.signalIntensity:0}}%
- </view>
- </view>
- </view>
- <view class="content flex">
- <u-icon size="36" name="http://139.9.103.171:1888/miniofile/xlyq/jiance.png"></u-icon>
- <text class="text-bold padding-left-10">监测值:</text>
- <text class="text-bold" style="color: #1296db;padding-top: 6rpx;">{{item.monitorValue}}</text>
- </view>
- <view class="content flex">
- <u-icon size="36" name="http://139.9.103.171:1888/miniofile/xlyq/updateTime2.png"></u-icon>
- <text class="text-bold padding-left-10">更新时间:</text>
- <text style="padding-top: 6rpx;">{{item.lastUpdateTime}}</text>
- </view>
- </view>
- <view class="bottom" >
- <view class="cu-btn round sm line-blue" >
- 查看详情
- </view>
- <view class="cu-btn round sm line-blue" style="margin: 0 20rpx;">
- 告警记录
- </view>
- </view>
- </view>
- <u-divider height="100" bgColor="#f1f1f1">到底了</u-divider>
- </view>
- </template>
- <script>
- export default {
- name: 'card',
- props:{
- list:{
- type:Array,
- default:()=>{
- [
- // {
- // id:'1337708672083709954',
- // imei:'861878041367316',
- // defenseStatus:'1',
- // deviceName:'无线智能消防栓检测终端',
- // battery:'52',
- // signalIntensity:'90',
- // monitorValue:'0.0009Mpa',
- // lastUpdateTime:'2020-12-19 15:51:45'
- // }
- ]
- }
- }
- },
- data() {
- return {
- };
- },
- methods:{
- copy(data){
- uni.setClipboardData({
- data:data
- })
- },
- goDetail(item){
- uni.navigateTo({
-
- })
- },
- }
- };
- </script>
- <style lang="scss">
- .bg-blue{
- background-color: #59a5f0;
- color: #FFFFFF;
- }
- .data {
- width: 720rpx;
- background-color: #ffffff;
- margin: 20rpx auto;
- border-radius: 6rpx;
- box-sizing: border-box;
- padding: 20rpx;
- font-size: 28rpx;
- .top {
- display: flex;
- justify-content: space-between;
- padding-bottom: 20rpx;
- border-bottom: 1rpx dashed #DDDDDD;
- .left {
- display: flex;
- align-items: center;
- .title {
- margin: 0 10rpx;
- font-size: 30rpx;
- }
- }
- .right{
- margin-right: 10rpx;
- }
- }
- .item {
- margin: 5rpx 0 20rpx 0;
- .content {
- padding: 30rpx 0 ;
- border-bottom: 1rpx dashed #DDDDDD;
- }
- }
- .bottom {
- display: flex;
- padding-top: 10rpx;
- margin-top: 30rpx;
- justify-content: flex-end;
- align-items: center;
- }
- }
- </style>
|