mirror of
https://github.com/Macrame-App/Macrame
synced 2025-12-29 15:29:26 +00:00
Devices view: Remote devices and servers
This commit is contained in:
parent
6029549cde
commit
e9e6f9e798
3 changed files with 135 additions and 0 deletions
44
fe/src/components/devices/ServerOverview.vue
Normal file
44
fe/src/components/devices/ServerOverview.vue
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
<template>
|
||||
<div class="server-overview">
|
||||
<AlertComp type="info"> This is a remote device. </AlertComp>
|
||||
|
||||
<div class="mcrm-block block__light grid gap-4">
|
||||
<h4 class="text-lg flex gap-4 items-center"><IconServer />Server</h4>
|
||||
<p>
|
||||
Connected to: <strong>{{ server.host }}</strong>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { IconServer } from '@tabler/icons-vue'
|
||||
import AlertComp from '../base/AlertComp.vue'
|
||||
import { onMounted, reactive } from 'vue'
|
||||
import { useDeviceStore } from '@/stores/device'
|
||||
|
||||
const device = useDeviceStore()
|
||||
|
||||
const server = reactive({
|
||||
host: '',
|
||||
access: false,
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
server.host = window.location.host
|
||||
|
||||
device.checkServerAccess()
|
||||
})
|
||||
|
||||
// console.log(window.location.host)
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
@reference "@/assets/main.css";
|
||||
|
||||
.server-overview {
|
||||
@apply grid
|
||||
gap-4
|
||||
content-start;
|
||||
}
|
||||
</style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue