增加新版本web页面
This commit is contained in:
32
web/src/views/device/index.vue
Executable file
32
web/src/views/device/index.vue
Executable file
@@ -0,0 +1,32 @@
|
||||
<template>
|
||||
<div id="device" class="app-container">
|
||||
<deviceList v-show="deviceId === null" @show-channel="showChannelList" />
|
||||
<channelList v-if="deviceId !== null" :device-id="deviceId" @show-device="showDevice" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import deviceList from './list.vue'
|
||||
import channelList from './channel/index.vue'
|
||||
|
||||
export default {
|
||||
name: 'Device',
|
||||
components: {
|
||||
deviceList,
|
||||
channelList
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
deviceId: null
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
showChannelList: function(deviceId) {
|
||||
this.deviceId = deviceId
|
||||
},
|
||||
showDevice: function() {
|
||||
this.deviceId = null
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user