Browse Source

add copy & change style in timing_list

course
zmt 4 years ago
parent
commit
f7818d4836
  1. 18
      src/subpackage/device/pages/index/index.vue
  2. 4
      src/subpackage/device/pages/timing/timing_list.vue

18
src/subpackage/device/pages/index/index.vue

@ -7,8 +7,8 @@
<view class="device-info"> <view class="device-info">
<text class="device-name">欧轩智能中控</text> <text class="device-name">欧轩智能中控</text>
<text>设备id: {{curStoreInfo.device_name||"-"}}</text>
<text>最后上线时间{{deviceInfo.LastOfflineTimeStr||"-"}}</text>
<text @click="copyDeviceID">设备id: {{curStoreInfo.device_name||"-"}} <text class="id-copy" >复制</text></text>
<text>最后上线时间{{deviceInfo.LastOfflineTimeStr||"-"}} </text>
<view class=""> <view class="">
<view class="">状态{{deviceInfo.Online==1?'在线':'离线'}}</view> <view class="">状态{{deviceInfo.Online==1?'在线':'离线'}}</view>
<view class="" @click="goTimingList"> <view class="" @click="goTimingList">
@ -103,6 +103,16 @@ export default {
this.updateAC()// this.updateAC()//
}, },
methods: { methods: {
copyDeviceID(){
let that = this
uni.setClipboardData({
data: that.curStoreInfo.device_name,
success: function () {
util.showNone(`复制成功!`);
console.log('复制成功',that.curStoreInfo.device_name);
}
});
},
updateAC(){ updateAC(){
if(!this.curStoreInfo.device_name)return if(!this.curStoreInfo.device_name)return
util.showLoad(); util.showLoad();
@ -193,6 +203,10 @@ export default {
flex-direction: column; flex-direction: column;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
.id-copy{
margin-left: 20rpx;
font-size: 28rpx;
}
> text:first-child{ > text:first-child{
font-weight: 900; font-weight: 900;
margin-top: 20rpx; margin-top: 20rpx;

4
src/subpackage/device/pages/timing/timing_list.vue

@ -240,7 +240,7 @@
font-size: 44rpx; font-size: 44rpx;
color: #1A1A1A; color: #1A1A1A;
font-weight: 900; font-weight: 900;
margin: 60rpx auto 72rpx 40rpx;
margin: 40rpx auto 10rpx 40rpx;
} }
.t-box { .t-box {
@ -322,7 +322,7 @@
} }
.i-box:last-child { .i-box:last-child {
width: 114rpx;
width: 144rpx;
} }
} }

Loading…
Cancel
Save